Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| fop 2.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.fop.fonts.type1
Class PFBData

    java.lang.Object
      org.apache.fop.fonts.type1.PFBData

    public class PFBData

extends java.lang.Object

Class that represents the contents of a PFB file.

See Also:
  `PFBParser`

Field Summary
`static int` | `PFB_MAC` MAC Format (unsupported, yet)
`static int` | `PFB_PC` PC format
`static int` | `PFB_RAW` Raw format, no special file structure

Constructor Summary
`PFBData()`

Method Summary
`byte[]` | `getEncryptedSegment()` Gets the encrypted segment of the font file
`byte[]` | `getHeaderSegment()` Gets the header segment of the font file
`int` | `getLength()` Returns the full length of the raw font file.
`int` | `getLength1()` Returns the Length1 (length of the header segment).
`int` | `getLength2()` Returns the Length2 (length of the encrypted segment).
`int` | `getLength3()` Returns the Length3 (length of the trailer segment).
`int` | `getPFBFormat()` Returns the format the font was loaded with.
`byte[]` | `getTrailerSegment()` Gets the trailer segment of the font file
`void` | `outputAllParts(java.io.OutputStream out)` Writes the PFB file in raw format to an OutputStream.
`void` | `setEncryptedSegment(byte[] encryptedSeg)` Sets the encrypted segment of the font file.
`void` | `setHeaderSegment(byte[] headerSeg)` Sets the header segment of the font file.
`void` | `setPFBFormat(int format)` Sets the PFB format the font was loaded with.
`void` | `setTrailerSegment(byte[] trailerSeg)` Sets the trailer segment of the font file.
`java.lang.String` | `toString()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### PFB_RAW

    public static final int PFB_RAW

  Raw format, no special file structure

  See Also:
    Constant Field Values

### PFB_PC

    public static final int PFB_PC

  PC format

  See Also:
    Constant Field Values

### PFB_MAC

    public static final int PFB_MAC

  MAC Format (unsupported, yet)

  See Also:
    Constant Field Values

Constructor Detail

### PFBData

    public PFBData()

Method Detail

### setPFBFormat

    public void setPFBFormat(int format)

  Sets the PFB format the font was loaded with.

  Parameters:
    `format` - one of the PFB_* constants

### getPFBFormat

    public int getPFBFormat()

  Returns the format the font was loaded with.

  Returns:
    int one of the PFB_* constants

### setHeaderSegment

    public void setHeaderSegment(byte[] headerSeg)

  Sets the header segment of the font file.

  Parameters:
    `headerSeg` - the header segment

### getHeaderSegment

    public byte[] getHeaderSegment()

  Gets the header segment of the font file

  Returns:
    Header segment as a byte array

### setEncryptedSegment

    public void setEncryptedSegment(byte[] encryptedSeg)

  Sets the encrypted segment of the font file.

  Parameters:
    `encryptedSeg` - the encrypted segment

### getEncryptedSegment

    public byte[] getEncryptedSegment()

  Gets the encrypted segment of the font file

  Returns:
    The encrypted segment as a byte array

### setTrailerSegment

    public void setTrailerSegment(byte[] trailerSeg)

  Sets the trailer segment of the font file.

  Parameters:
    `trailerSeg` - the trailer segment

### getTrailerSegment

    public byte[] getTrailerSegment()

  Gets the trailer segment of the font file

  Returns:
    The trailer segment as a byte array

### getLength

    public int getLength()

  Returns the full length of the raw font file.

  Returns:
    int the raw file length

### getLength1

    public int getLength1()

  Returns the Length1 (length of the header segment).

  Returns:
    int Length1

### getLength2

    public int getLength2()

  Returns the Length2 (length of the encrypted segment).

  Returns:
    int Length2

### getLength3

    public int getLength3()

  Returns the Length3 (length of the trailer segment).

  Returns:
    int Length3

### outputAllParts

    public void outputAllParts(java.io.OutputStream out)
                        throws java.io.IOException

  Writes the PFB file in raw format to an OutputStream.

  Parameters:
    `out` - the OutputStream to write to
  Throws:
    `java.io.IOException` - In case of an I/O problem

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| fop 2.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

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