Save This Page
Home » iText-src-2.1.3 » com.lowagie » text » pdf » [javadoc | source]
com.lowagie.text.pdf
public class: PdfString [javadoc | source]
java.lang.Object
   com.lowagie.text.pdf.PdfObject
      com.lowagie.text.pdf.PdfString

Direct Known Subclasses:
    PdfDate

A PdfString-class is the PDF-equivalent of a JAVA-String-object.

A string is a sequence of characters delimited by parenthesis. If a string is too long to be conveniently placed on a single line, it may be split across multiple lines by using the backslash character (\) at the end of a line to indicate that the string continues on the following line. Within a string, the backslash character is used as an escape to specify unbalanced parenthesis, non-printing ASCII characters, and the backslash character itself. Use of the \ddd escape sequence is the preferred way to represent characters outside the printable ASCII character set.
This object is described in the 'Portable Document Format Reference Manual version 1.7' section 3.2.3 (page 53-56).

Field Summary
protected  String value    The value of this object. 
protected  String originalValue     
protected  String encoding    The encoding. 
protected  int objNum     
protected  int objGen     
protected  boolean hexWriting     
Fields inherited from com.lowagie.text.pdf.PdfObject:
BOOLEAN,  NUMBER,  STRING,  NAME,  ARRAY,  DICTIONARY,  STREAM,  NULL,  INDIRECT,  NOTHING,  TEXT_PDFDOCENCODING,  TEXT_UNICODE,  bytes,  type,  indRef
Constructor:
 public PdfString() 
 public PdfString(String value) 
    Constructs a PdfString-object.
    Parameters:
    value - the content of the string
 public PdfString(byte[] bytes) 
 public PdfString(String value,
    String encoding) 
    Constructs a PdfString-object.
    Parameters:
    value - the content of the string
    encoding - an encoding
Method from com.lowagie.text.pdf.PdfString Summary:
decrypt,   getBytes,   getEncoding,   getOriginalBytes,   isHexWriting,   setHexWriting,   setObjNum,   toPdf,   toString,   toUnicodeString
Methods from com.lowagie.text.pdf.PdfObject:
canBeInObjStm,   getBytes,   getIndRef,   isArray,   isBoolean,   isDictionary,   isIndirect,   isName,   isNull,   isNumber,   isStream,   isString,   length,   setContent,   setIndRef,   toPdf,   toString,   type
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from com.lowagie.text.pdf.PdfString Detail:
  void decrypt(PdfReader reader) 
 public byte[] getBytes() 
 public String getEncoding() 
    Gets the encoding of this string.
 public byte[] getOriginalBytes() 
 public boolean isHexWriting() 
 public PdfString setHexWriting(boolean hexWriting) 
  void setObjNum(int objNum,
    int objGen) 
 public  void toPdf(PdfWriter writer,
    OutputStream os) throws IOException 
    Returns the PDF representation of this PdfString.
 public String toString() 
    Returns the String value of the PdfString-object.
 public String toUnicodeString()