Class ConverterToString

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String fromBoolean​(boolean data)
      Converts data from Boolean to the output format.
      java.lang.String fromByte​(byte data)
      Converts data from byte to the output format.
      java.lang.String fromByteArray​(byte[] data)
      Converts data from a byte array to the output format.
      java.lang.String fromDate​(java.util.Date data, java.lang.String format)
      Converts data from a date to the output format.
      java.lang.String fromDouble​(double data)
      Converts data from double to the output format.
      java.lang.String fromDoubleArray​(double[] data)
      Converts data from a double array to the output format.
      java.lang.String fromFloat​(float data)
      Converts data from float to the output format.
      java.lang.String fromInteger​(int data)
      Converts data from int to the output format.
      java.lang.String fromIntegerArray​(int[] data)
      Converts data from an integer array to the output format.
      java.lang.String fromLong​(long data)
      Converts data from long to the output format.
      java.lang.String fromObject​(java.lang.Object data)
      Converts data from an object the output format.
      java.lang.String fromShort​(short data)
      Converts data from short to the output format.
      java.lang.String fromString​(java.lang.String data)
      Converts data from String to the output format.
      java.lang.String fromStringArray​(java.lang.String[] data)
      Converts data from a string array to the output format.
      • Methods inherited from class java.lang.Object

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

      • ConverterToString

        public ConverterToString()
    • Method Detail

      • fromInteger

        public java.lang.String fromInteger​(int data)
                                     throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from int to the output format.
        Specified by:
        fromInteger in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromByte

        public java.lang.String fromByte​(byte data)
                                  throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from byte to the output format.
        Specified by:
        fromByte in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromLong

        public java.lang.String fromLong​(long data)
                                  throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from long to the output format.
        Specified by:
        fromLong in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromShort

        public java.lang.String fromShort​(short data)
                                   throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from short to the output format.
        Specified by:
        fromShort in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromString

        public java.lang.String fromString​(java.lang.String data)
                                    throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from String to the output format.
        Specified by:
        fromString in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromDouble

        public java.lang.String fromDouble​(double data)
                                    throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from double to the output format.
        Specified by:
        fromDouble in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromFloat

        public java.lang.String fromFloat​(float data)
                                   throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from float to the output format.
        Specified by:
        fromFloat in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromBoolean

        public java.lang.String fromBoolean​(boolean data)
                                     throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from Boolean to the output format.
        Specified by:
        fromBoolean in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromIntegerArray

        public java.lang.String fromIntegerArray​(int[] data)
                                          throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from an integer array to the output format.
        Specified by:
        fromIntegerArray in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromDoubleArray

        public java.lang.String fromDoubleArray​(double[] data)
                                         throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from a double array to the output format.
        Specified by:
        fromDoubleArray in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromStringArray

        public java.lang.String fromStringArray​(java.lang.String[] data)
                                         throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from a string array to the output format.
        Specified by:
        fromStringArray in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromByteArray

        public java.lang.String fromByteArray​(byte[] data)
                                       throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from a byte array to the output format.
        Specified by:
        fromByteArray in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromObject

        public java.lang.String fromObject​(java.lang.Object data)
                                    throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from an object the output format. [fallback dummy]
        Specified by:
        fromObject in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the data
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails
      • fromDate

        public java.lang.String fromDate​(java.util.Date data,
                                         java.lang.String format)
                                  throws java.io.IOException
        Description copied from interface: OutputFormatter.OutputConverter
        Converts data from a date to the output format.
        Specified by:
        fromDate in interface OutputFormatter.OutputConverter<java.lang.String>
        Parameters:
        data - the date
        format - the target date format (see SimpleDateFormat)
        Returns:
        the converted output format
        Throws:
        java.io.IOException - if conversion fails