pdfium/testing/v8_initializer.h
K. Moon 832a694e52 Update old-style copyright headers
Updates old-style copyright headers to the new style, by removing "All
rights reserved." Also inserts "The" before "PDFium Authors", which is
required by both styles.

Mechanically generated by this command:
  PATTERN='Copyright \([0-9]\+\) \(The \)\?PDFium Authors. All rights reserved.'
  git grep -l "$PATTERN" \
  | xargs sed "s/$PATTERN/Copyright \1 The PDFium Authors/" -i''

Fixed: pdfium:1884
Change-Id: I6f781d811df8839e2e21b85f716529b813828bcd
Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/100371
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: K. Moon <kmoon@chromium.org>
2022-10-31 20:11:31 +00:00

36 lines
905 B
C++

// Copyright 2019 The PDFium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef TESTING_V8_INITIALIZER_H_
#define TESTING_V8_INITIALIZER_H_
#include <memory>
#include <string>
#ifndef PDF_ENABLE_V8
#error "V8 must be enabled"
#endif
namespace v8 {
class Platform;
#ifdef V8_USE_EXTERNAL_STARTUP_DATA
class StartupData;
#endif
} // namespace v8
#ifdef V8_USE_EXTERNAL_STARTUP_DATA
// |snapshot_blob| is an optional out parameter.
std::unique_ptr<v8::Platform> InitializeV8ForPDFiumWithStartupData(
const std::string& exe_path,
const std::string& js_flags,
const std::string& bin_dir,
v8::StartupData* snapshot_blob);
#else
std::unique_ptr<v8::Platform> InitializeV8ForPDFium(
const std::string& js_flags,
const std::string& exe_path);
#endif
void ShutdownV8ForPDFium();
#endif // TESTING_V8_INITIALIZER_H_