| OLD | NEW |
| 1 #ifndef __DEFINED__SkPdfURIDictionary | 1 #ifndef __DEFINED__SkPdfURIDictionary |
| 2 #define __DEFINED__SkPdfURIDictionary | 2 #define __DEFINED__SkPdfURIDictionary |
| 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 // Entry in a URI dictionary |
| 8 class SkPdfURIDictionary : public SkPdfDictionary { | 9 class SkPdfURIDictionary : public SkPdfDictionary { |
| 9 public: | 10 public: |
| 10 virtual SkPdfObjectType getType() const { return kURIDictionary_SkPdfObjectTyp
e;} | 11 virtual SkPdfObjectType getType() const { return kURIDictionary_SkPdfObjectTyp
e;} |
| 11 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kURIDict
ionary_SkPdfObjectType + 1);} | 12 virtual SkPdfObjectType getTypeEnd() const { return (SkPdfObjectType)(kURIDict
ionary_SkPdfObjectType + 1);} |
| 12 public: | 13 public: |
| 13 virtual SkPdfURIDictionary* asURIDictionary() {return this;} | 14 virtual SkPdfURIDictionary* asURIDictionary() {return this;} |
| 14 virtual const SkPdfURIDictionary* asURIDictionary() const {return this;} | 15 virtual const SkPdfURIDictionary* asURIDictionary() const {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 Loading... |
| 514 | 515 |
| 515 public: | 516 public: |
| 516 private: | 517 private: |
| 517 public: | 518 public: |
| 518 SkPdfURIDictionary(const PdfMemDocument* podofoDoc = NULL, const PdfObject* po
dofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {} | 519 SkPdfURIDictionary(const PdfMemDocument* podofoDoc = NULL, const PdfObject* po
dofoObj = NULL) : SkPdfDictionary(podofoDoc, podofoObj) {} |
| 519 | 520 |
| 520 virtual bool valid() const {return true;} | 521 virtual bool valid() const {return true;} |
| 521 | 522 |
| 522 SkPdfURIDictionary& operator=(const SkPdfURIDictionary& from) {this->fPodofoDo
c = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; return *this;} | 523 SkPdfURIDictionary& operator=(const SkPdfURIDictionary& from) {this->fPodofoDo
c = from.fPodofoDoc; this->fPodofoObj = from.fPodofoObj; return *this;} |
| 523 | 524 |
| 525 /** (Optional) The base URI to be used in resolving relative URI references. URI
actions |
| 526 * within the document may specify URIs in partial form, to be interpreted rela
tive to |
| 527 * this base address. If no base URI is specified, such partial URIs will be in
terpreted rel- |
| 528 * ative to the location of the document itself. The use of this entry is paral
lel to that of |
| 529 * the body element <BASE>, as described in section 2.7.2 of Internet RFC 1866,
Hyper- |
| 530 * text Markup Language 2.0 Proposed Standard (see the Bibliography). |
| 531 **/ |
| 532 bool has_Base() const { |
| 533 return (ObjectFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Base"
, "", NULL)); |
| 534 } |
| 535 |
| 524 std::string Base() const { | 536 std::string Base() const { |
| 525 std::string ret; | 537 std::string ret; |
| 526 if (StringFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Base", ""
, &ret)) return ret; | 538 if (StringFromDictionary(fPodofoDoc, fPodofoObj->GetDictionary(), "Base", ""
, &ret)) return ret; |
| 527 // TODO(edisonn): warn about missing required field, assert for known good p
dfs | 539 // TODO(edisonn): warn about missing required field, assert for known good p
dfs |
| 528 return ""; | 540 return ""; |
| 529 } | 541 } |
| 530 | 542 |
| 531 }; | 543 }; |
| 532 | 544 |
| 533 #endif // __DEFINED__SkPdfURIDictionary | 545 #endif // __DEFINED__SkPdfURIDictionary |
| OLD | NEW |