eu.scape_project.watch.domain
Enum RequestTarget

java.lang.Object
  extended by java.lang.Enum<RequestTarget>
      extended by eu.scape_project.watch.domain.RequestTarget
All Implemented Interfaces:
Serializable, Comparable<RequestTarget>

public enum RequestTarget
extends Enum<RequestTarget>

Possible targets for a Request/Question.

Author:
Luis Faria

Enum Constant Summary
ENTITY
          Target class is Entity.
ENTITY_TYPE
          Target class is EntityType.
PROPERTY
          Target class is Property.
PROPERTY_VALUE
          Target class is PropertyValue.
 
Method Summary
static Class<? extends thewebsemantic.binding.RdfBean<?>> getClassByTarget(RequestTarget target)
          Get the class the target refers to.
static RequestTarget getTargetByClass(Class<? extends thewebsemantic.binding.RdfBean<?>> targetClass)
          Get request target based on the target class it refers to.
 Class<? extends thewebsemantic.binding.RdfBean<?>> getTargetClass()
          Get the class this target refers to.
static RequestTarget valueOf(String name)
          Returns the enum constant of this type with the specified name.
static RequestTarget[] 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

ENTITY_TYPE

public static final RequestTarget ENTITY_TYPE
Target class is EntityType.


PROPERTY

public static final RequestTarget PROPERTY
Target class is Property.


ENTITY

public static final RequestTarget ENTITY
Target class is Entity.


PROPERTY_VALUE

public static final RequestTarget PROPERTY_VALUE
Target class is PropertyValue.

Method Detail

values

public static RequestTarget[] 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 (RequestTarget c : RequestTarget.values())
    System.out.println(c);

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

valueOf

public static RequestTarget valueOf(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:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getTargetByClass

public static RequestTarget getTargetByClass(Class<? extends thewebsemantic.binding.RdfBean<?>> targetClass)
Get request target based on the target class it refers to.

Parameters:
targetClass - The target class.
Returns:
The request target value or null if not found.

getClassByTarget

public static Class<? extends thewebsemantic.binding.RdfBean<?>> getClassByTarget(RequestTarget target)
Get the class the target refers to.

Parameters:
target - The request target.
Returns:
The class or null if not found.

getTargetClass

public Class<? extends thewebsemantic.binding.RdfBean<?>> getTargetClass()
Get the class this target refers to.

Returns:
The class or null if not found.


Copyright © 2012. All Rights Reserved.