org.jboss.dependency.plugins.graph
Enum Search

java.lang.Object
  extended by java.lang.Enum<Search>
      extended by org.jboss.dependency.plugins.graph.Search
All Implemented Interfaces:
Serializable, Comparable<Search>, SearchInfo

public enum Search
extends Enum<Search>
implements SearchInfo

Search enum.

Author:
Ales Justin

Enum Constant Summary
CHILD_ONLY_DEPTH
           
CHILD_ONLY_LEAVES
           
CHILD_ONLY_WIDTH
           
DEFAULT
           
DEPTH
           
LEAVES
           
LOCAL
           
PARENT
           
PARENT_ONLY
           
TOP
           
WIDTH
           
 
Method Summary
 Map<String,?> getInfo()
          Get the info.
static SearchInfo getInstance(String typeString)
          Get SearchInfo instance.
 LookupStrategy getStrategy()
          Get the lookup strategy.
 String getType()
          The search type.
static Search valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Search[] 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

DEFAULT

public static final Search DEFAULT

LOCAL

public static final Search LOCAL

TOP

public static final Search TOP

PARENT_ONLY

public static final Search PARENT_ONLY

PARENT

public static final Search PARENT

DEPTH

public static final Search DEPTH

LEAVES

public static final Search LEAVES

WIDTH

public static final Search WIDTH

CHILD_ONLY_DEPTH

public static final Search CHILD_ONLY_DEPTH

CHILD_ONLY_LEAVES

public static final Search CHILD_ONLY_LEAVES

CHILD_ONLY_WIDTH

public static final Search CHILD_ONLY_WIDTH
Method Detail

values

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

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

valueOf

public static Search 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

getInstance

public static SearchInfo getInstance(String typeString)
Get SearchInfo instance.

Parameters:
typeString - the type string
Returns:
matching instance, lazy if none found

getType

public String getType()
Description copied from interface: SearchInfo
The search type. If there is no supported lookup strategy GraphController implementation might return context on itself.

Specified by:
getType in interface SearchInfo
Returns:
the type

getInfo

public Map<String,?> getInfo()
Description copied from interface: SearchInfo
Get the info. Additional parameters to be used for search.

Specified by:
getInfo in interface SearchInfo
Returns:
the additional info

getStrategy

public LookupStrategy getStrategy()
Description copied from interface: SearchInfo
Get the lookup strategy. Might be null, but then we expect the GraphController to implement this search type. Otherwise error should be thown by GraphController.

Specified by:
getStrategy in interface SearchInfo
Returns:
the strategy or null depending on GraphContorller


Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.