コード例 #1
0
SkPdfFunction SkPdfType3ShadingDictionary::Function(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Function", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isFunction()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->functionValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkPdfFunction();
}
コード例 #2
0
SkPdfArray* SkPdfType3FunctionDictionary::Encode(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Encode", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isArray()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfArray*)ret;
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return NULL;
}
コード例 #3
0
SkPdfDictionary* SkPdfMovieActionDictionary::Annot(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Annot", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isDictionary()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfDictionary*)ret;
  // TODO(edisonn): warn about missing default value for optional fields
  return NULL;
}
コード例 #4
0
bool SkPdfInteractiveFormDictionary::NeedAppearances(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("NeedAppearances", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isBoolean()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->boolValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return false;
}
コード例 #5
0
SkString SkPdfInteractiveFormDictionary::DA(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("DA", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isAnyString()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->stringValue2();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkString();
}
コード例 #6
0
SkPdfFileSpec SkPdfFDFDictionary::F(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("F", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && false) || (doc == NULL && ret != NULL && ret->isReference())) return ret->fileSpecValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkPdfFileSpec();
}
コード例 #7
0
SkPdfDictionary* SkPdfAppearanceDictionary::getNAsDictionary(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("N", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isDictionary()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfDictionary*)ret;
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return NULL;
}
コード例 #8
0
SkMatrix SkPdfType1PatternDictionary::Matrix(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Matrix", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isMatrix()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->matrixValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkMatrix::I();
}
コード例 #9
0
int64_t SkPdfType1PatternDictionary::TilingType(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("TilingType", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isInteger()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->intValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return 0;
}
コード例 #10
0
SkPdfFunction SkPdfType4ShadingDictionary::Function(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Function", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isFunction()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->functionValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkPdfFunction();
}
コード例 #11
0
double SkPdfEncryptionCommonDictionary::V(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("V", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isNumber()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->numberValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return 0;
}
コード例 #12
0
SkString SkPdfStandardStructureDictionary::WritingMode(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("WritingMode", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isName()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->nameValue2();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkString();
}
SkPdfDictionary* SkPdfEmbeddedFileStreamDictionary::Params(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Params", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isDictionary()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfDictionary*)ret;
  // TODO(edisonn): warn about missing default value for optional fields
  return NULL;
}
SkString SkPdfEmbeddedFileStreamDictionary::Subtype(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Subtype", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isName()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->nameValue2();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkString();
}
コード例 #15
0
int64_t SkPdfWebCaptureImageSetDictionary::getRAsInteger(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("R", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isInteger()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->intValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return 0;
}
コード例 #16
0
SkRect SkPdfType1PatternDictionary::BBox(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("BBox", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isRectangle()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->rectangleValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkRect::MakeEmpty();
}
コード例 #17
0
SkPdfArray* SkPdfWebCaptureImageSetDictionary::getRAsArray(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("R", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isArray()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfArray*)ret;
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return NULL;
}
コード例 #18
0
double SkPdfType1PatternDictionary::YStep(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("YStep", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isNumber()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->numberValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return 0;
}
コード例 #19
0
SkPdfFileSpec SkPdfSubmitFormActionDictionary::F(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("F", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && false) || (doc == NULL && ret != NULL && ret->isReference())) return ret->fileSpecValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkPdfFileSpec();
}
コード例 #20
0
bool SkPdfViewerPreferencesDictionary::DisplayDocTitle(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("DisplayDocTitle", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isBoolean()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->boolValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return false;
}
コード例 #21
0
SkPdfStream* SkPdfAppearanceDictionary::getDAsStream(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("D", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->hasStream()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->getStream();
  // TODO(edisonn): warn about missing default value for optional fields
  return NULL;
}
コード例 #22
0
SkString SkPdfViewerPreferencesDictionary::NonFullScreenPageMode(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("NonFullScreenPageMode", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isName()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->nameValue2();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkString();
}
コード例 #23
0
SkPdfArray* SkPdfInteractiveFormDictionary::CO(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("CO", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isArray()) || (doc == NULL && ret != NULL && ret->isReference())) return (SkPdfArray*)ret;
  // TODO(edisonn): warn about missing default value for optional fields
  return NULL;
}
コード例 #24
0
SkString SkPdfFreeTextAnnotationDictionary::DA(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("DA", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isAnyString()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->stringValue2();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkString();
}
コード例 #25
0
int64_t SkPdfInteractiveFormDictionary::Q(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Q", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isInteger()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->intValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return 0;
}
コード例 #26
0
SkPdfDate SkPdfApplicationDataDictionary::LastModified(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("LastModified", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isDate()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->dateValue();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkPdfDate();
}
コード例 #27
0
SkString SkPdfMovieActionDictionary::S(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("S", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isName()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->nameValue2();
  // TODO(edisonn): warn about missing required field, assert for known good pdfs
  return SkString();
}
コード例 #28
0
SkPdfNativeObject* SkPdfApplicationDataDictionary::Private(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Private", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && true) || (doc == NULL && ret != NULL && ret->isReference())) return ret;
  // TODO(edisonn): warn about missing default value for optional fields
  return NULL;
}
コード例 #29
0
SkString SkPdfMovieActionDictionary::Operation(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("Operation", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isName()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->nameValue2();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkString();
}
コード例 #30
0
SkPdfDate SkPdfSourceInformationDictionary::E(SkPdfNativeDoc* doc) {
  SkPdfNativeObject* ret = get("E", "");
  if (doc) {ret = doc->resolveReference(ret);}
  if ((ret != NULL && ret->isDate()) || (doc == NULL && ret != NULL && ret->isReference())) return ret->dateValue();
  // TODO(edisonn): warn about missing default value for optional fields
  return SkPdfDate();
}