• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 
7 #ifndef FXJS_CJS_REPORT_H_
8 #define FXJS_CJS_REPORT_H_
9 
10 #include <vector>
11 
12 #include "fxjs/JS_Define.h"
13 
14 class Report : public CJS_EmbedObj {
15  public:
16   explicit Report(CJS_Object* pJSObject);
17   ~Report() override;
18 
19  public:
20   CJS_Return save(CJS_Runtime* pRuntime,
21                   const std::vector<v8::Local<v8::Value>>& params);
22   CJS_Return writeText(CJS_Runtime* pRuntime,
23                        const std::vector<v8::Local<v8::Value>>& params);
24 };
25 
26 class CJS_Report : public CJS_Object {
27  public:
28   static void DefineJSObjects(CFXJS_Engine* pEngine, FXJSOBJTYPE eObjType);
29 
CJS_Report(v8::Local<v8::Object> pObject)30   explicit CJS_Report(v8::Local<v8::Object> pObject) : CJS_Object(pObject) {}
~CJS_Report()31   ~CJS_Report() override {}
32 
33   JS_STATIC_METHOD(save, Report)
34   JS_STATIC_METHOD(writeText, Report);
35 
36  private:
37   static int ObjDefnID;
38   static const JSMethodSpec MethodSpecs[];
39 };
40 
41 #endif  // FXJS_CJS_REPORT_H_
42