messif.operations
Enum AnswerType

java.lang.Object
  extended by java.lang.Enum<AnswerType>
      extended by messif.operations.AnswerType
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<AnswerType>

public enum AnswerType
extends java.lang.Enum<AnswerType>

Enumeration of types a query operation can return.

See Also:
QueryOperation

Enum Constant Summary
CLEARED_OBJECTS
          Answer contains clones of the original objects with cleared surplus data
CLONNED_OBJECTS
          Answer contains clones of the original objects
NODATA_OBJECTS
          Answer contains only objects
ORIGINAL_OBJECTS
          Answer contains the original objects as is
REMOTE_OBJECTS
          Deprecated. Use NODATA_OBJECTS instead.
 
Method Summary
 AbstractObject update(AbstractObject object)
          Updates a AbstractObject so that it conforms to this answer type.
static AnswerType valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static AnswerType[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ORIGINAL_OBJECTS

public static final AnswerType ORIGINAL_OBJECTS
Answer contains the original objects as is


CLONNED_OBJECTS

public static final AnswerType CLONNED_OBJECTS
Answer contains clones of the original objects


CLEARED_OBJECTS

public static final AnswerType CLEARED_OBJECTS
Answer contains clones of the original objects with cleared surplus data


NODATA_OBJECTS

public static final AnswerType NODATA_OBJECTS
Answer contains only objects


REMOTE_OBJECTS

@Deprecated
public static final AnswerType REMOTE_OBJECTS
Deprecated. Use NODATA_OBJECTS instead.
Answer contains only objects

Method Detail

values

public static AnswerType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (AnswerType c : AnswerType.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static AnswerType valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

update

public AbstractObject update(AbstractObject object)
                      throws java.lang.CloneNotSupportedException
Updates a AbstractObject so that it conforms to this answer type. That means, the object is clonned, cleared or transformed into a NoDataObject.

Parameters:
object - the object to update
Returns:
an updated object
Throws:
java.lang.CloneNotSupportedException - if a clone was requested but the specified object cannot be clonned