PDFWritable
PDFDPart
, PDFDPartRoot
, PDFEncoding
, PDFFileSpec
, PDFFont
, PDFFontDescriptor
, PDFIdentifiedDictionary
, PDFNames
, PDFNameTreeNode
, PDFNumberTreeNode
, PDFResourceContext
, PDFResources
, PDFRoot
, StructureHierarchyMember
, TransitionDictionary
public class PDFDictionary extends PDFObject
Modifier and Type | Field | Description |
---|---|---|
protected java.util.Map<java.lang.String,java.lang.Object> |
entries |
the entry map
|
protected java.util.List<java.lang.String> |
order |
maintains the order of the entries added to the entry map.
|
Constructor | Description |
---|---|
PDFDictionary() |
Create a new dictionary object.
|
PDFDictionary(PDFObject parent) |
Create a new dictionary object.
|
Modifier and Type | Method | Description |
---|---|---|
boolean |
containsKey(java.lang.String name) |
|
java.lang.Object |
get(java.lang.String name) |
Returns the value given a name.
|
static void |
getChildren(java.util.Collection<java.lang.Object> values,
java.util.Set<PDFObject> children) |
|
void |
getChildren(java.util.Set<PDFObject> children) |
|
java.util.Set<java.lang.String> |
keySet() |
|
int |
output(java.io.OutputStream stream) |
Write the PDF represention of this object
|
void |
put(java.lang.String name,
int value) |
Puts a new name/value pair.
|
void |
put(java.lang.String name,
java.lang.Object value) |
Puts a new name/value pair.
|
void |
remove(java.lang.String name) |
Removes the mapping for the specified key
|
protected void |
writeDictionary(java.io.OutputStream out,
java.lang.StringBuilder textBuffer) |
Writes the contents of the dictionary to a StringBuffer.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
contentEquals, encode, encodeBinaryToHexString, encodeString, encodeText, formatObject, getDocument, getDocumentSafely, getGeneration, getObjectID, getObjectNumber, getParent, hasObjectNumber, makeReference, outputInline, referencePDF, setDocument, setObjectNumber, setObjectNumber, setObjectNumber, setParent, toPDF, toPDFString
protected java.util.Map<java.lang.String,java.lang.Object> entries
protected java.util.List<java.lang.String> order
public PDFDictionary()
public PDFDictionary(PDFObject parent)
parent
- the object's parent if anypublic void put(java.lang.String name, java.lang.Object value)
name
- the namevalue
- the valuepublic void put(java.lang.String name, int value)
name
- the namevalue
- the valuepublic java.lang.Object get(java.lang.String name)
name
- the name of the valuepublic int output(java.io.OutputStream stream) throws java.io.IOException
protected void writeDictionary(java.io.OutputStream out, java.lang.StringBuilder textBuffer) throws java.io.IOException
out
- the OutputStream (for binary content)textBuffer
- the text buffer for text outputjava.io.IOException
- if an I/O error occurspublic void getChildren(java.util.Set<PDFObject> children)
getChildren
in class PDFObject
public static void getChildren(java.util.Collection<java.lang.Object> values, java.util.Set<PDFObject> children)
public java.util.Set<java.lang.String> keySet()
public boolean containsKey(java.lang.String name)
name
- The key to find in the map.Map.containsKey(Object)
public void remove(java.lang.String name)
name
- key whose mapping is to be removedCopyright 1999-2016 The Apache Software Foundation. All Rights Reserved.