Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: experimental/PdfViewer/SkPdfObjectReferenceDictionary_autogen.h

Issue 16975013: Deal with ca and CA transparency operators in pdf. add comments to generated classes. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 #ifndef __DEFINED__SkPdfObjectReferenceDictionary 1 #ifndef __DEFINED__SkPdfObjectReferenceDictionary
2 #define __DEFINED__SkPdfObjectReferenceDictionary 2 #define __DEFINED__SkPdfObjectReferenceDictionary
3 3
4 #include "SkPdfEnums_autogen.h" 4 #include "SkPdfEnums_autogen.h"
5 #include "SkPdfArray_autogen.h" 5 #include "SkPdfArray_autogen.h"
6 #include "SkPdfDictionary_autogen.h" 6 #include "SkPdfDictionary_autogen.h"
7 7
8 // Entries in an object reference dictionary
8 class SkPdfObjectReferenceDictionary : public SkPdfDictionary { 9 class SkPdfObjectReferenceDictionary : public SkPdfDictionary {
9 public: 10 public:
10 virtual SkPdfObjectType getType() const { return kObjectReferenceDictionary_Sk PdfObjectType;} 11 virtual SkPdfObjectType getType() const { return kObjectReferenceDictionary_Sk PdfObjectType;}
11 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kObjectR eferenceDictionary_SkPdfObjectType + 1);} 12 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kObjectR eferenceDictionary_SkPdfObjectType + 1);}
12 public: 13 public:
13 virtual SkPdfObjectReferenceDictionary* asObjectReferenceDictionary() {return this;} 14 virtual SkPdfObjectReferenceDictionary* asObjectReferenceDictionary() {return this;}
14 virtual const SkPdfObjectReferenceDictionary* asObjectReferenceDictionary() co nst {return this;} 15 virtual const SkPdfObjectReferenceDictionary* asObjectReferenceDictionary() co nst {return this;}
15 16
16 private: 17 private:
17 virtual SkPdfALinkAnnotationDictionary* asALinkAnnotationDictionary() {return NULL;} 18 virtual SkPdfALinkAnnotationDictionary* asALinkAnnotationDictionary() {return NULL;}
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
514 515
515 public: 516 public:
516 private: 517 private:
517 public: 518 public:
518 SkPdfObjectReferenceDictionary(const PdfMemDocument* podofoDoc = NULL, const P dfObject* podofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {} 519 SkPdfObjectReferenceDictionary(const PdfMemDocument* podofoDoc = NULL, const P dfObject* podofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {}
519 520
520 virtual bool valid() const {return true;} 521 virtual bool valid() const {return true;}
521 522
522 SkPdfObjectReferenceDictionary& operator=(const SkPdfObjectReferenceDictionary & from) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; return *this;} 523 SkPdfObjectReferenceDictionary& operator=(const SkPdfObjectReferenceDictionary & from) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; return *this;}
523 524
525 /** (Required) The type of PDF object that this dictionary describes; must be OB JR for an
526 * object reference.
527 **/
528 bool has_Type() const {
529 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Type" , "", NULL));
530 }
531
524 std::string Type() const { 532 std::string Type() const {
525 std::string ret; 533 std::string ret;
526 if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Type", "", &ret)) return ret; 534 if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Type", "", &ret)) return ret;
527 // TODO(edisonn): warn about missing required field, assert for known good p dfs 535 // TODO(edisonn): warn about missing required field, assert for known good p dfs
528 return ""; 536 return "";
529 } 537 }
530 538
539 /** (Optional; must be an indirect reference) The page object representing the p age on
540 * which the object is rendered. This entry overrides any Pg entry in the struc ture ele-
541 * ment containing the object reference; it is required if the structure elemen t has no such
542 * entry.
543 **/
544 bool has_Pg() const {
545 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Pg", "", NULL));
546 }
547
531 SkPdfDictionary* Pg() const { 548 SkPdfDictionary* Pg() const {
532 SkPdfDictionary* ret; 549 SkPdfDictionary* ret;
533 if (DictionaryFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Pg", "", &ret)) return ret; 550 if (DictionaryFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Pg", "", &ret)) return ret;
534 // TODO(edisonn): warn about missing required field, assert for known good p dfs 551 // TODO(edisonn): warn about missing required field, assert for known good p dfs
535 return NULL; 552 return NULL;
536 } 553 }
537 554
555 /** (Required; must be an indirect reference) The referenced object.
556 **/
557 bool has_Obj() const {
558 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Obj", "", NULL));
559 }
560
538 SkPdfObject* Obj() const { 561 SkPdfObject* Obj() const {
539 SkPdfObject* ret; 562 SkPdfObject* ret;
540 if (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Obj", "", &ret)) return ret; 563 if (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Obj", "", &ret)) return ret;
541 // TODO(edisonn): warn about missing required field, assert for known good p dfs 564 // TODO(edisonn): warn about missing required field, assert for known good p dfs
542 return NULL; 565 return NULL;
543 } 566 }
544 567
545 }; 568 };
546 569
547 #endif // __DEFINED__SkPdfObjectReferenceDictionary 570 #endif // __DEFINED__SkPdfObjectReferenceDictionary
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698