| OLD | NEW |
| 1 #ifndef __DEFINED__SkPdfWebCaptureImageSetDictionary | 1 #ifndef __DEFINED__SkPdfWebCaptureImageSetDictionary |
| 2 #define __DEFINED__SkPdfWebCaptureImageSetDictionary | 2 #define __DEFINED__SkPdfWebCaptureImageSetDictionary |
| 3 | 3 |
| 4 #include "SkPdfUtils.h" | 4 #include "SkPdfUtils.h" |
| 5 #include "SkPdfEnums_autogen.h" | 5 #include "SkPdfEnums_autogen.h" |
| 6 #include "SkPdfArray_autogen.h" | 6 #include "SkPdfArray_autogen.h" |
| 7 #include "SkPdfDictionary_autogen.h" | 7 #include "SkPdfDictionary_autogen.h" |
| 8 | 8 |
| 9 // Additional entries specific to a Web Capture image set | 9 // Additional entries specific to a Web Capture image set |
| 10 class SkPdfWebCaptureImageSetDictionary : public SkPdfDictionary { | 10 class SkPdfWebCaptureImageSetDictionary : public SkPdfDictionary { |
| (...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 525 | 525 |
| 526 SkPdfWebCaptureImageSetDictionary& operator=(const SkPdfWebCaptureImageSetDict
ionary& from) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodo
foObj; return *this;} | 526 SkPdfWebCaptureImageSetDictionary& operator=(const SkPdfWebCaptureImageSetDict
ionary& from) {this->fPodofoDoc = from.fPodofoDoc; this->fPodofoObj = from.fPodo
foObj; return *this;} |
| 527 | 527 |
| 528 /** (Required) The subtype of content set that this dictionary describes; must b
e SIS ("Spider | 528 /** (Required) The subtype of content set that this dictionary describes; must b
e SIS ("Spider |
| 529 * image set") for an image set. | 529 * image set") for an image set. |
| 530 **/ | 530 **/ |
| 531 bool has_S() const { | 531 bool has_S() const { |
| 532 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "S", "
", NULL)); | 532 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "S", "
", NULL)); |
| 533 } | 533 } |
| 534 | 534 |
| 535 std::string S() const { | 535 std::string S() const; |
| 536 std::string ret; | |
| 537 if (NameFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "S", "", &re
t)) return ret; | |
| 538 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
| 539 return ""; | |
| 540 } | |
| 541 | |
| 542 /** (Required) The reference counts (see below) for the image XObjects belonging
to the | 536 /** (Required) The reference counts (see below) for the image XObjects belonging
to the |
| 543 * image set. For an image set containing a single XObject, the value is simply
the integer | 537 * image set. For an image set containing a single XObject, the value is simply
the integer |
| 544 * reference count for that XObject. If the image set contains multiple XObject
s, the value is | 538 * reference count for that XObject. If the image set contains multiple XObject
s, the value is |
| 545 * an array of reference counts parallel to the O array (see Table 9.33 on page
668); that is, | 539 * an array of reference counts parallel to the O array (see Table 9.33 on page
668); that is, |
| 546 * each element in the R array holds the reference count for the image XObject
at the corre- | 540 * each element in the R array holds the reference count for the image XObject
at the corre- |
| 547 * sponding position in the O array. | 541 * sponding position in the O array. |
| 548 **/ | 542 **/ |
| 549 bool has_R() const { | 543 bool has_R() const { |
| 550 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "
", NULL)); | 544 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "
", NULL)); |
| 551 } | 545 } |
| 552 | 546 |
| 553 bool isRAInteger() const { | 547 bool isRAInteger() const { |
| 554 SkPdfObject* ret = NULL; | 548 SkPdfObject* ret = NULL; |
| 555 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "",
&ret)) return false; | 549 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "",
&ret)) return false; |
| 556 return ret->podofo()->GetDataType() == ePdfDataType_Number; | 550 return ret->podofo()->GetDataType() == ePdfDataType_Number; |
| 557 } | 551 } |
| 558 | 552 |
| 559 long getRAsInteger() const { | 553 long getRAsInteger() const; |
| 560 long ret = 0; | |
| 561 if (LongFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "", &re
t)) return ret; | |
| 562 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
| 563 return 0; | |
| 564 } | |
| 565 | |
| 566 bool isRAArray() const { | 554 bool isRAArray() const { |
| 567 SkPdfObject* ret = NULL; | 555 SkPdfObject* ret = NULL; |
| 568 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "",
&ret)) return false; | 556 if (!ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "",
&ret)) return false; |
| 569 return ret->podofo()->GetDataType() == ePdfDataType_Array; | 557 return ret->podofo()->GetDataType() == ePdfDataType_Array; |
| 570 } | 558 } |
| 571 | 559 |
| 572 SkPdfArray* getRAsArray() const { | 560 SkPdfArray* getRAsArray() const; |
| 573 SkPdfArray* ret = NULL; | |
| 574 if (ArrayFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "R", "", &r
et)) return ret; | |
| 575 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | |
| 576 return NULL; | |
| 577 } | |
| 578 | |
| 579 }; | 561 }; |
| 580 | 562 |
| 581 #endif // __DEFINED__SkPdfWebCaptureImageSetDictionary | 563 #endif // __DEFINED__SkPdfWebCaptureImageSetDictionary |
| OLD | NEW |