Class AWriter

  • Direct Known Subclasses:
    Writer

    public abstract class AWriter
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String XML_INCLUDE_FIELDS
      Constant for indicating if public fields should be written.
    • Constructor Summary

      Constructors 
      Constructor Description
      AWriter()  
    • Method Summary

      All Methods Static Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      static byte[] objectToByteArray​(AWriter writer, java.lang.Object val, java.lang.ClassLoader classloader, IObjectWriterHandler handler)
      Convert to a byte array.
      static byte[] objectToByteArray​(AWriter writer, java.lang.Object val, java.lang.ClassLoader classloader, java.lang.Object context, IObjectWriterHandler handler)
      Convert to a byte array.
      static byte[] objectToByteArray​(AWriter writer, java.lang.Object val, java.lang.String encoding, java.lang.ClassLoader classloader, java.lang.Object context, IObjectWriterHandler handler)
      Convert to a byte array.
      static void objectToOutputStream​(AWriter writer, java.lang.Object val, java.io.OutputStream os, java.lang.ClassLoader classloader, java.lang.Object context, IObjectWriterHandler handler)
      Write to output stream.
      static java.lang.String objectToXML​(AWriter writer, java.lang.Object val, java.lang.ClassLoader classloader, IObjectWriterHandler handler)
      Convert to a string.
      static java.lang.String objectToXML​(AWriter writer, java.lang.Object val, java.lang.ClassLoader classloader, java.lang.Object context, IObjectWriterHandler handler)
      Convert to a string.
      void write​(IObjectWriterHandler handler, java.lang.Object object, java.io.OutputStream out, java.lang.ClassLoader classloader, java.lang.Object context)
      Write the properties to an xml.
      abstract void write​(IObjectWriterHandler handler, java.lang.Object object, java.lang.String encoding, java.io.OutputStream out, java.lang.ClassLoader classloader, java.lang.Object context)
      Write the properties to an xml.
      • Methods inherited from class java.lang.Object

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

      • XML_INCLUDE_FIELDS

        public static final java.lang.String XML_INCLUDE_FIELDS
        Constant for indicating if public fields should be written. The field has to be declared as public and its value will be used to determine if fields should be included.
        See Also:
        Constant Field Values
    • Constructor Detail

      • AWriter

        public AWriter()
    • Method Detail

      • write

        public void write​(IObjectWriterHandler handler,
                          java.lang.Object object,
                          java.io.OutputStream out,
                          java.lang.ClassLoader classloader,
                          java.lang.Object context)
                   throws java.lang.Exception
        Write the properties to an xml.
        Parameters:
        input - The input stream.
        classloader - The classloader.
        context - The context.
        Throws:
        java.lang.Exception
      • write

        public abstract void write​(IObjectWriterHandler handler,
                                   java.lang.Object object,
                                   java.lang.String encoding,
                                   java.io.OutputStream out,
                                   java.lang.ClassLoader classloader,
                                   java.lang.Object context)
                            throws java.lang.Exception
        Write the properties to an xml.
        Parameters:
        input - The input stream.
        classloader - The classloader.
        context - The context.
        Throws:
        java.lang.Exception
      • objectToXML

        public static java.lang.String objectToXML​(AWriter writer,
                                                   java.lang.Object val,
                                                   java.lang.ClassLoader classloader,
                                                   IObjectWriterHandler handler)
        Convert to a string.
      • objectToXML

        public static java.lang.String objectToXML​(AWriter writer,
                                                   java.lang.Object val,
                                                   java.lang.ClassLoader classloader,
                                                   java.lang.Object context,
                                                   IObjectWriterHandler handler)
        Convert to a string.
      • objectToByteArray

        public static byte[] objectToByteArray​(AWriter writer,
                                               java.lang.Object val,
                                               java.lang.ClassLoader classloader,
                                               IObjectWriterHandler handler)
        Convert to a byte array.
      • objectToByteArray

        public static byte[] objectToByteArray​(AWriter writer,
                                               java.lang.Object val,
                                               java.lang.ClassLoader classloader,
                                               java.lang.Object context,
                                               IObjectWriterHandler handler)
        Convert to a byte array.
      • objectToByteArray

        public static byte[] objectToByteArray​(AWriter writer,
                                               java.lang.Object val,
                                               java.lang.String encoding,
                                               java.lang.ClassLoader classloader,
                                               java.lang.Object context,
                                               IObjectWriterHandler handler)
        Convert to a byte array.
      • objectToOutputStream

        public static void objectToOutputStream​(AWriter writer,
                                                java.lang.Object val,
                                                java.io.OutputStream os,
                                                java.lang.ClassLoader classloader,
                                                java.lang.Object context,
                                                IObjectWriterHandler handler)
        Write to output stream.