Cos Arrays; Cos Names - Adobe ACROBAT SDK 8.1 Manual

Developing plug-ins and applications
Table of Contents

Advertisement

Adobe Acrobat SDK
Developing Plug-ins and Applications
Hexadecimal strings
Strings may also be written in hexadecimal form, which is useful for including arbitrary binary data in a
PDF file. A hexadecimal string is written as a sequence of hexadecimal digits (0–9 and either A–F or a–f )
enclosed within angle brackets (< and >). Consider the following example:
<4E6F762073686D6F7A206B6120706F702E >
Each pair of hexadecimal digits defines one byte of the string. White-space characters (such as space, tab,
carriage return, line feed, and form feed) are ignored. If the final digit of a hexadecimal string is missing,
that is, if there is an odd number of digits, the final digit is assumed to be 0. Consider the following
example:
<901FA3>
This is a 3-byte string consisting of the characters whose hexadecimal codes are 90, 1F, and A3, but
<901FA>

Cos arrays

Arrays are one-dimensional collections of objects accessed by a numeric index. Array indexes are
zero-based and may be any combination of the Cos data types. The following array has seven elements:
three integers, a string, a Boolean value, a dictionary (containing one key-value pair), and an indirect
object reference.
[ 1 2 3 (This is a string) true << /Key (The value) >> 6 0 R ]

Cos names

A name object is an atomic symbol uniquely defined by a sequence of characters. Uniquely defined means
that any two name objects made up of the same sequence of characters are identically the same object.
Atomic means that a name has no internal structure; although it is defined by a sequence of characters,
those characters are not considered elements of the name.
/AName
A slash character (/) introduces a name. The slash is not part of the name but is a prefix indicating that the
following sequence of characters constitutes a name. There can be no white-space characters between the
slash and the first character in the name. The name may include any regular characters, but not delimiter
or white-space characters. Uppercase and lowercase letters are considered distinct: /A and /a are different
names. The following examples are valid literal names:
/Name1
/ASomewhatLongerName
/A;Name_With-Various***Characters?
/1.2
/$$
/@pattern
/.notdef
is a 3-byte string containing the characters whose hexadecimal codes are 90, 1F, and A0.
Working with Cos Objects
About Cos object types
181

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ACROBAT SDK 8.1 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents