Class DiskAttribute

    • Field Detail

      • baseDirectory

        public static java.lang.String baseDirectory
      • deleteOnExitTemporaryFile

        public static boolean deleteOnExitTemporaryFile
    • Constructor Detail

      • DiskAttribute

        public DiskAttribute​(java.lang.String name)
        Constructor used for huge Attribute
      • DiskAttribute

        public DiskAttribute​(java.lang.String name,
                             java.lang.String value)
                      throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • getValue

        public java.lang.String getValue()
                                  throws java.io.IOException
        Description copied from interface: Attribute
        Returns the value of this HttpData.
        Specified by:
        getValue in interface Attribute
        Throws:
        java.io.IOException
      • setValue

        public void setValue​(java.lang.String value)
                      throws java.io.IOException
        Description copied from interface: Attribute
        Sets the value of this HttpData.
        Specified by:
        setValue in interface Attribute
        Throws:
        java.io.IOException
      • addContent

        public void addContent​(ChannelBuffer buffer,
                               boolean last)
                        throws java.io.IOException
        Description copied from interface: HttpData
        Add the content from the ChannelBuffer
        Specified by:
        addContent in interface HttpData
        Overrides:
        addContent in class AbstractDiskHttpData
        Parameters:
        buffer - must be not null except if last is set to False
        last - True of the buffer is the last one
        Throws:
        java.io.IOException
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • compareTo

        public int compareTo​(Attribute o)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • deleteOnExit

        protected boolean deleteOnExit()
        Specified by:
        deleteOnExit in class AbstractDiskHttpData
        Returns:
        True if the file should be deleted on Exit by default