org.apache.fop.pdf

Class PDFDictionary

Implemented Interfaces:
PDFWritable
Known Direct Subclasses:
PDFNames, PDFNameTreeNode

public class PDFDictionary
extends PDFObject

Class representing a PDF dictionary object

Field Summary

protected Map
entries
the entry map
protected List
order
maintains the order of the entries added to the entry map.

Fields inherited from class org.apache.fop.pdf.PDFObject

DATE_FORMAT, log

Constructor Summary

PDFDictionary()
Create the dictionary object

Method Summary

Object
get(String name)
Returns the value given a name.
void
put(String name, Object value)
Puts a new name/value pair.
String
toPDFString()

Methods inherited from class org.apache.fop.pdf.PDFObject

encode, encodeString, encodeText, formatDateTime, formatObject, getDocument, getDocumentSafely, getGeneration, getObjectID, getObjectNumber, hasObjectNumber, makeReference, output, referencePDF, setDocument, setObjectNumber, toInlinePDFString, toPDF, toPDFString

Field Details

entries

protected Map entries
the entry map

order

protected List order
maintains the order of the entries added to the entry map. Whenever you modify "entries", always make sure you adjust this list accordingly.

Constructor Details

PDFDictionary

public PDFDictionary()
Create the dictionary object

Method Details

get

public Object get(String name)
Returns the value given a name.
Parameters:
name - the name of the value
Returns:
the value or null, if there's no value with the given name.

put

public void put(String name,
                Object value)
Puts a new name/value pair.
Parameters:
name - the name
value - the value

toPDFString

public String toPDFString()
Overrides:
toPDFString in interface PDFObject

Copyright 1999-2007 The Apache Software Foundation. All Rights Reserved.