org.xwiki.gwt.wysiwyg.client.wiki
Enum EntityReference.EntityType

java.lang.Object
  extended by java.lang.Enum<EntityReference.EntityType>
      extended by org.xwiki.gwt.wysiwyg.client.wiki.EntityReference.EntityType
All Implemented Interfaces:
Serializable, Comparable<EntityReference.EntityType>
Enclosing class:
EntityReference

public static enum EntityReference.EntityType
extends Enum<EntityReference.EntityType>

Represents a type of entity that can be referenced from the client.


Enum Constant Summary
ATTACHMENT
          Represents an Attachment Entity.
DOCUMENT
          Represents a Document Entity.
EXTERNAL
          Represents an external entity, usually identified by an URI.
SPACE
          Represents a Space Entity.
WIKI
          Represents a Wiki Entity.
 
Method Summary
static boolean areEqual(EntityReference.EntityType expected, EntityReference.EntityType actual)
           
static EntityReference.EntityType valueOf(String name)
          Returns the enum constant of this type with the specified name.
static EntityReference.EntityType[] 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

WIKI

public static final EntityReference.EntityType WIKI
Represents a Wiki Entity.


SPACE

public static final EntityReference.EntityType SPACE
Represents a Space Entity.


DOCUMENT

public static final EntityReference.EntityType DOCUMENT
Represents a Document Entity.


ATTACHMENT

public static final EntityReference.EntityType ATTACHMENT
Represents an Attachment Entity.


EXTERNAL

public static final EntityReference.EntityType EXTERNAL
Represents an external entity, usually identified by an URI.

Method Detail

values

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

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

valueOf

public static EntityReference.EntityType 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

areEqual

public static boolean areEqual(EntityReference.EntityType expected,
                               EntityReference.EntityType actual)
Parameters:
expected - the expected type
actual - the actual type
Returns:
true if the given types are equal, false otherwise


Copyright © 2004–2015 XWiki. All rights reserved.