    All Packages  Class Hierarchy  This Package  Previous  Next  Index

# Class org.w3c.tools.resources.AttributeHolderAttribute

    java.lang.Object
       |
       +----org.w3c.tools.resources.Attribute
               |
               +----org.w3c.tools.resources.AttributeHolderAttribute

public class AttributeHolderAttribute
extends Attribute

The generic description of an attribute whose value is an attribute holder.

##

AttributeHolderAttribute(String, AttributeHolder, int)

##

checkValue(Object)
  Is the given object a valid AttributeHolder value ?
getPickleLength(Object)
  Get the number of bytes required to save that attribute value.
pickle(DataOutputStream, Object)
  Pickle an attribute holder to the given output stream.
unpickle(DataInputStream)
  Unpickle an attribute holder from the given input stream.

##

AttributeHolderAttribute

     public AttributeHolderAttribute(String name,
                                     AttributeHolder def,
                                     int flags)

##

checkValue

     public boolean checkValue(Object obj)

  Is the given object a valid AttributeHolder value ?

  Parameters:
    obj - The object to test.
  Returns:
    A boolean true if okay.
  Overrides:
    checkValue in class Attribute

getPickleLength

     public int getPickleLength(Object value)

  Get the number of bytes required to save that attribute value.

  Parameters:
    The - value about to be pickled.
  Returns:
    The number of bytes needed to pickle that value.
  Overrides:
    getPickleLength in class Attribute

pickle

     public void pickle(DataOutputStream out,
                        Object ah) throws IOException

  Pickle an attribute holder to the given output stream.

  Parameters:
    out - The output stream to pickle to.
    obj - The object to pickle.
  Throws: IOException
    If some IO error occured.
  Overrides:
    pickle in class Attribute

unpickle

     public Object unpickle(DataInputStream in) throws IOException

  Unpickle an attribute holder from the given input stream. The unpickled attribute holder is to be initialized by the caller.

  Parameters:
    in - The input stream to unpickle from.
  Returns:
    An AttributeHolder instance.
  Throws: IOException
    If some IO error occured.
  Overrides:
    unpickle in class Attribute

    All Packages  Class Hierarchy  This Package  Previous  Next  Index