com.ibm.as400.access

Class Converter

  • java.lang.Object
    • com.ibm.as400.access.Converter
  • All Implemented Interfaces:
    java.io.Serializable


    public class Converter
    extends java.lang.Object
    implements java.io.Serializable
    A character set converter between Java String objects
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      com.ibm.as400.access.ConverterImpl impl 
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      java.lang.String byteArrayToString(byte[] source) 
      java.lang.String byteArrayToString(byte[] source, int offset) 
      java.lang.String byteArrayToString(byte[] source, int offset, int length) 
      int getCcsid() 
      java.lang.String getEncoding() 
      byte[] stringToByteArray(java.lang.String source) 
      void stringToByteArray(java.lang.String source, byte[] destination) 
      void stringToByteArray(java.lang.String source, byte[] destination, int offset) 
      void stringToByteArray(java.lang.String source, byte[] destination, int offset, int length) 
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • impl

        public transient com.ibm.as400.access.ConverterImpl impl
    • Constructor Detail

      • Converter

        public Converter()
      • Converter

        public Converter(java.lang.String encoding)
                  throws java.io.UnsupportedEncodingException
        Throws:
        java.io.UnsupportedEncodingException
      • Converter

        public Converter(int ccsid)
                  throws java.io.UnsupportedEncodingException
        Throws:
        java.io.UnsupportedEncodingException
      • Converter

        public Converter(int ccsid,
                 AS400 system)
                  throws java.io.UnsupportedEncodingException
        Throws:
        java.io.UnsupportedEncodingException
    • Method Detail

      • byteArrayToString

        public java.lang.String byteArrayToString(byte[] source)
      • byteArrayToString

        public java.lang.String byteArrayToString(byte[] source,
                                         int offset)
      • byteArrayToString

        public java.lang.String byteArrayToString(byte[] source,
                                         int offset,
                                         int length)
      • getCcsid

        public int getCcsid()
      • getEncoding

        public java.lang.String getEncoding()
      • stringToByteArray

        public byte[] stringToByteArray(java.lang.String source)
      • stringToByteArray

        public void stringToByteArray(java.lang.String source,
                             byte[] destination)
                               throws java.io.CharConversionException
        Throws:
        java.io.CharConversionException
      • stringToByteArray

        public void stringToByteArray(java.lang.String source,
                             byte[] destination,
                             int offset)
                               throws java.io.CharConversionException
        Throws:
        java.io.CharConversionException
      • stringToByteArray

        public void stringToByteArray(java.lang.String source,
                             byte[] destination,
                             int offset,
                             int length)
                               throws java.io.CharConversionException
        Throws:
        java.io.CharConversionException