org.apache.fop.render.pcl.fonts

## Class PCLByteWriterUtil

- java.lang.Object
- - org.apache.fop.render.pcl.fonts.PCLByteWriterUtil

-     public final class PCLByteWriterUtil
      extends java.lang.Object

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static byte[]` | `insertIntoArray(int index, byte[] insertTo, byte[] data)`
    `static int` | `log(int x, int base)`
    `static int` | `maxPower2(int value)`
    `static byte[]` | `padBytes(byte[] in, int length)`
    `static byte[]` | `padBytes(byte[] in, int length, int value)`
    `static byte` | `signedByte(int s)`
    `static byte[]` | `signedInt(int s)`
    `static byte[]` | `toByteArray(int[] s)`
    `static int` | `unsignedByte(int b)`
    `static byte[]` | `unsignedInt(int s)`
    `static byte[]` | `unsignedLongInt(int s)`
    `static byte[]` | `unsignedLongInt(long s)`
    `static byte[]` | `updateDataAtLocation(byte[] data, byte[] update, int offset)`
    `static byte[]` | `writeCommand(java.lang.String cmd)` Writes a PCL escape command to the output stream.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### padBytes

          public static byte[] padBytes(byte[] in,
                                        int length)

    - #### padBytes

          public static byte[] padBytes(byte[] in,
                                        int length,
                                        int value)

    - #### signedInt

          public static byte[] signedInt(int s)

    - #### signedByte

          public static byte signedByte(int s)

    - #### unsignedLongInt

          public static byte[] unsignedLongInt(int s)

    - #### unsignedLongInt

          public static byte[] unsignedLongInt(long s)

    - #### unsignedInt

          public static byte[] unsignedInt(int s)

    - #### unsignedByte

          public static int unsignedByte(int b)

    - #### maxPower2

          public static int maxPower2(int value)

    - #### log

          public static int log(int x,
                                int base)

    - #### toByteArray

          public static byte[] toByteArray(int[] s)

    - #### insertIntoArray

          public static byte[] insertIntoArray(int index,
                                               byte[] insertTo,
                                               byte[] data)
                                        throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### updateDataAtLocation

          public static byte[] updateDataAtLocation(byte[] data,
                                                    byte[] update,
                                                    int offset)

    - #### writeCommand

          public static byte[] writeCommand(java.lang.String cmd)
                                     throws java.io.IOException

      Writes a PCL escape command to the output stream.
      Parameters:
        `cmd` - the command (without the ESCAPE character)
      Throws:
        `java.io.IOException` - In case of an I/O error

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