DynamicPDF by ceTe Software

com.cete.dynamicpdf.xmp
Class XmpWriter

java.lang.Object
  extended by com.cete.dynamicpdf.xmp.XmpWriter

public class XmpWriter
extends java.lang.Object

Class represents the writer for XMP metadata for a document.

Licensing:
This class is a DynamicPDF Generator Enterprise Edition feature. One of the following licenses is required for non-evaluation usage:


Constructor Summary
XmpWriter(DocumentWriter writer)
          Initializes a new instance of the XmpWriter class.
 
Method Summary
 void beginDescription()
          Writes the RDF description.
 void beginDescription(java.lang.String namespace, java.lang.String alias)
          Writes the RDF description for a given schema.
 void beginDescription(java.lang.String namespace, java.lang.String alias, java.lang.String about)
          Writes the RDF description for a given schema.
 void draw(boolean val)
          Writes the boolean value to XMP Packet.
 void draw(java.util.Date date)
          Writes the given date to XMP Packet in W3C recommended date format.
 void draw(DocumentWriter writer)
          Draws the XMP contents buffer to the given DocumentWriter object.
 void draw(java.lang.String value)
          Writes the given value to XMP Packet.
 void endDescription()
          Writes the end of RDF description.
 java.lang.String getAuthor()
          Gets the authors of the resource.
 java.util.Date getDate()
          Gets the date of the resource was originally created.
 java.lang.String getKeywords()
          Gets the keywords that specify the topic of the content of the resource.
 float getPdfVersion()
          Gets the pdf version of a document.
 java.lang.String getProducer()
          Gets the name of the tool that created the PDF document.
 java.lang.String getTitle()
          Gets the document title of the resource.
 int getTotalPages()
          Gets the number of pages in the document (including any in contained documents).
 byte[] getUtf8(java.lang.String value)
          Does the UTF-8 encoding for a given string text.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmpWriter

public XmpWriter(DocumentWriter writer)
Initializes a new instance of the XmpWriter class.

Parameters:
writer - DocumentWriter object to receive the metadata output.
See Also:
DocumentWriter
Method Detail

getProducer

public java.lang.String getProducer()

Gets the name of the tool that created the PDF document.

Returns:
the name of the tool that created the PDF document.

getAuthor

public java.lang.String getAuthor()

Gets the authors of the resource.

Returns:
the authors of the resource.

getTitle

public java.lang.String getTitle()

Gets the document title of the resource.

Returns:
the document title of the resource.

getKeywords

public java.lang.String getKeywords()

Gets the keywords that specify the topic of the content of the resource.

Returns:
the keywords that specify the topic of the content of the resource.

getPdfVersion

public float getPdfVersion()

Gets the pdf version of a document.

Returns:
the pdf version.

getDate

public java.util.Date getDate()

Gets the date of the resource was originally created.

Returns:
the date of resource creation.

getTotalPages

public int getTotalPages()

Gets the number of pages in the document (including any in contained documents).

Returns:
the number of pages in the document.

beginDescription

public void beginDescription(java.lang.String namespace,
                             java.lang.String alias,
                             java.lang.String about)

Writes the RDF description for a given schema.

Parameters:
namespace - the schema namespace URI
alias - the preferred schema namespace prefix
about - the rdf attribute on the rdf description element is a required attribute that identifies the resource whose metadata this XMP describes. Must follow URI syntax and may be an empty string.

beginDescription

public void beginDescription(java.lang.String namespace,
                             java.lang.String alias)

Writes the RDF description for a given schema.

Parameters:
namespace - the schema namespace URI
alias - the preferred schema namespace prefix

beginDescription

public void beginDescription()

Writes the RDF description.


endDescription

public void endDescription()

Writes the end of RDF description.


getUtf8

public byte[] getUtf8(java.lang.String value)

Does the UTF-8 encoding for a given string text.

Parameters:
value - string representing the text to convert to UTF-8 encoding.
Returns:
the UTF-8 encoded text, as a byte array.

draw

public void draw(java.lang.String value)

Writes the given value to XMP Packet.

Parameters:
value - A string value to be written.

draw

public void draw(boolean val)

Writes the boolean value to XMP Packet.

Parameters:
val - A boolean value to be written.

draw

public void draw(java.util.Date date)

Writes the given date to XMP Packet in W3C recommended date format.

Parameters:
date - A date to be written.

draw

public void draw(DocumentWriter writer)

Draws the XMP contents buffer to the given DocumentWriter object.

Parameters:
writer - DocumentWriter object to receive the XMP buffer's output.
See Also:
DocumentWriter

DynamicPDF by ceTe Software

API Reference for DynamicPDF v10.07 for Java generated on Aug 12, 2020
© Copyright 2020, ceTe Software