forked from veraPDF/veraPDF-model
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCosLayer.mdl
More file actions
327 lines (283 loc) · 10.7 KB
/
Copy pathCosLayer.mdl
File metadata and controls
327 lines (283 loc) · 10.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
package org.verapdf.model.coslayer;
import org.verapdf.model.baselayer.Object;
import org.verapdf.model.pdlayer.PDMetadata;
import org.verapdf.model.pdlayer.PDDocument;
import org.verapdf.model.salayer.SAPDFDocument;
import org.verapdf.model.pdlayer.PDEncryption;
import org.verapdf.model.external.EmbeddedFile;
% Parent type for all basic PDF objects
type CosObject extends Object {
}
% Low-level PDF Document object
type CosDocument extends CosObject {
% number of indirect objects in the document
property nrIndirects: Integer;
% version of the document
property headerVersion: Decimal;
% true if the OCProperties key is present in the document Catalog
property isOptionalContentPresent: Boolean;
% size of data after the EOF and (optional) end of line marker
property postEOFDataSize: Integer;
% id of the first page trailer, if the document is linearized. Null, if the document is not linearized
property firstPageID: String;
% id of the last trailer in the document
property lastID: String;
% string representation of id of the first page trailer, if the document is linearized. Null, if the document is not linearized
property firstPageIDValue: String;
% string representation of id of the last trailer in the document
property lastIDValue: String;
% true if the document is linearized
property isLinearized: Boolean;
% link to all embedded file specifications
link EmbeddedFiles: CosFileSpecification*;
% link to the document cross reference table
link xref: CosXRef;
% trailer dictionary (first page trailer for the linearized PDF or the last trailer in the document)
link trailer: CosTrailer;
% all indirect objects referred from the xref table
link indirectObjects: CosIndirect+;
% offset of the PDF document header
property headerOffset: Integer;
% the content of the PDF header
property header: String;
% first four bytes in the comment that follows the PDF header
property headerByte1: Integer;
property headerByte2: Integer;
property headerByte3: Integer;
property headerByte4: Integer;
% link to the high-level PDF Document structure
link document: PDDocument;
% the value of the /Marked entry in the MarkInfo dictionary (false, if this entry is missing)
property Marked: Boolean;
% string representation of the value of /Requirements key in the document Catalog:
% - the space-concatenated values of the /S key in the requirement dictionaries in the array referenced by the /Requirements key
% - empty string if the array of requirement dictionaries is empty;
% - null, if the /Requirements key is not present in the document Catalog
property Requirements: String;
% NeedsRendering entry in the document's Catalog (false by default)
property NeedsRendering: Boolean;
% true, if the document contains the EmbeddedFiles entry in the names dictionary
property containsEmbeddedFiles: Boolean;
% value of the /Suspects entry in the MarkInfo dictionary
property Suspects: Boolean;
% value of the /DisplayDocTitle key in the ViewerPreferences dictionary
property DisplayDocTitle: Boolean;
% true if the trailer dictionary contains Info key
property containsInfo: Boolean;
% true if the document catalog dictionary contains PieceInfo entry
property containsPieceInfo: Boolean;
% string representation of the MarkInfo dictionary
property MarkInfo: String;
% string representation of the ViewerPreferences dictionary
property ViewerPreferences: String;
% link to Document structure for structure analysis
link doc: SAPDFDocument?;
}
% PDF Indirect object
type CosIndirect extends CosObject {
% the direct contents of the indirect object
link directObject: CosObject;
% true if the spacings around object number, generation number, keywords 'obj' and 'endobj' comply to PDF/A standard
property spacingCompliesPDFA: Boolean;
}
% PDF null object
type CosNull extends CosObject {
}
% PDF boolean object
type CosBool extends CosObject {
% value of this object
property value: Boolean;
}
% Generic Number type
type CosNumber extends CosObject {
% the string representing this object
property stringValue: String;
% truncated integer value
property intValue: Integer;
% original decimal value
property realValue: Decimal;
}
% PDF Real type
type CosReal extends CosNumber {
}
% PDF Integer type
type CosInteger extends CosNumber {
}
% PDF Name type
type CosName extends CosObject {
% Byte sequence representation of the Name object after applying escape mechanism
property internalRepresentation: String;
}
% blend mode
type CosBM extends CosName {
}
% actual text
type CosActualText extends CosString {
}
% alt
type CosAlt extends CosString {
}
% PDF Name representing a Utf8 string
type CosUnicodeName extends CosName {
% indicates if the Name represents a Unicode string correctly encoded by Utf8
property isValidUtf8: Boolean;
% the Unicode value of the Name object
property unicodeValue: String;
}
% PDF Name representing rendering intent
type CosRenderingIntent extends CosName {
}
% PDF Name representing a single stream filter including decode parameters
type CosFilter extends CosName {
% String representation of the decodeParms dictionary. Possible values are :
% "Default" : if decodeParms dictionary is not present
% "Identity" : the value of the Name entry in the Crypt parameters dictionary
% "Custom" : in all other cases
property decodeParms: String;
}
% PDF Name representing a single inline image filter
type CosIIFilter extends CosName {
}
% PDF String type
type CosString extends CosObject {
% internal byte presentation of the string after decoding from hex format (for strings in hexadecimal format) or after decoding all escape sequences (for strings in standard format)
property value: String;
% true if the string is stored in Hex format
property isHex: Boolean;
% true if the all non-white-space characters if the hexadecimal string belong to the range 0-9, a-f, A-F
property containsOnlyHex: Boolean;
% for hexadecimal strings the number of Hex digits (non-white-space characters in the range 0-9, a-f, A-F); 0 for strings in standard format
property hexCount: Integer;
% true if string value contains codes from Unicode Private Use Area
property containsPUA: Boolean;
}
% PDF Text String type
type CosTextString extends CosString {
% string in unicode
property unicodeValue: String;
}
% Lang type
type CosLang extends CosTextString {
}
% PDF Dict type
type CosDict extends CosObject {
% number of key/value pairs in the dictionary
property size: Integer;
% all keys of the dictionary
link keys: CosName*;
% all values of the dictionary
link values: CosObject*;
% XMP metadata if it is present
link metadata: PDMetadata?;
% ampersand separated list of all keys of the dictionary
property keysString: String;
}
% PDF Stream type
type CosStream extends CosDict {
% value of the Length key in the Stream dictionary
property Length: Integer;
% real length of stream
property realLength: Integer;
% represents value of F key or null if stream does not contain this key
property F: String;
% represents value of FFilter key or null if stream does not contain this key
property FFilter: String;
% represents value of FDecodeParms key or null if stream does not contain this key
property FDecodeParms: String;
% true if spacings around keywords 'stream' comply to the PDF/A standard
property streamKeywordCRLFCompliant: Boolean;
% true if spacings around keywords 'endstream' comply to the PDF/A standard
property endstreamKeywordEOLCompliant: Boolean;
% link to the stream filters
link filters: CosFilter*;
}
% File specification dictionary
type CosFileSpecification extends CosDict {
% link to the embedded file stream
link EF: EmbeddedFile?;
% true if the file specification dictionary contains EF key
property containsEF: Boolean;
% true if the file specification dictionary contains Desc key
property containsDesc: Boolean;
% a file specification string (F key)
property F: String;
% a unicode file specification (UF key)
property UF: String;
% the relationship between the component of the PDF document that refers to this file specification and the associated file (/AFRelationship key)
property AFRelationship: String;
% true if the file specification dictionary is associated (=referenced by the /AF key) with at least one of the following objects: catalog, page, XObject, annotation or structure element
property isAssociatedFile: Boolean;
% true if the file specification dictionary is present in the EmbeddedFiles name tree
property presentInEmbeddedFiles: Boolean;
}
% Trailer of the document
type CosTrailer extends CosDict {
% true if the document is encrypted
property isEncrypted: Boolean;
% link to the Encryption dictionary
link Encrypt: PDEncryption?;
% link to the document information dictionary
link Info: CosInfo?;
}
% Information dictionary
type CosInfo extends CosDict {
% value of ModDate entry
property ModDate: String;
% string representation of XMP Modify Date
property XMPModifyDate: String;
% true, if ModDate entry and XMP Modify Date have equivalent values
property doModDatesMatch: Boolean;
% value of CreationDate entry
property CreationDate: String;
% string representation of XMP Create Date
property XMPCreateDate: String;
% true, if CreationDate entry and XMP Create Date have equivalent values
property doCreationDatesMatch: Boolean;
% value of Title entry without trailing zero
property Title: String;
% value of XMP Title
property XMPTitle: String;
% value of Author entry without trailing zero
property Author: String;
% comma separated list of XMP Creator array
property XMPCreator: String;
% size of XMP Creator array
property XMPCreatorSize: Integer;
% value of Subject entry without trailing zero
property Subject: String;
% value of XMP Description
property XMPDescription: String;
% value of Producer entry without trailing zero
property Producer: String;
% value of XMP Producer
property XMPProducer: String;
% value of Creator entry without trailing zero
property Creator: String;
% value of XMP Creator Tool
property XMPCreatorTool: String;
% value of Keywords entry without trailing zero
property Keywords: String;
% value of XMP Keywords
property XMPKeywords: String;
}
% PDF Array type
type CosArray extends CosObject {
% number of elements in the array
property size: Integer;
% all objects contained in the array
link elements: CosObject*;
}
% Bounding box array
type CosBBox extends CosArray {
property top: Decimal;
property bottom: Decimal;
property left: Decimal;
property right: Decimal;
}
% Cross reference table of the document
type CosXRef extends CosObject {
% true if headers of all subsections of the cross reference table comply to PDF/A standard
property subsectionHeaderSpaceSeparated: Boolean;
% true if the 'xref' keyword and the following cross reference subsection header are separated by a single EOL marker
property xrefEOLMarkersComplyPDFA: Boolean;
}