org.eclipse.tigerstripe.profile.stereotype
Interface IStereotypeAttribute

All Known Subinterfaces:
IEntryListStereotypeAttribute

public interface IStereotypeAttribute

Top-level definition for user-defined attributes on a stereotype

Since:
1.2
Author:
Eric Dillon

Field Summary
static int CHECKABLE_KIND
          Static integer value for a Checkable kind of attribute.
static int ENTRY_LIST_KIND
          Static integer value for a Entry List kind of attribute.
static int STRING_ENTRY_KIND
          Static integer value for a String kind of attribute.
 
Method Summary
 org.dom4j.Element asElement()
           
 java.lang.String getDefaultValue()
          Get the default value for this attribute.
 java.lang.String getDescription()
          Returns the human readable description of this attribute.
 int getKind()
          The 'kind' of attribute.
 java.lang.String getName()
          Get the name of the attribute.
 boolean isArray()
          Returns true if this attribute is an array type.
 void parse(org.dom4j.Element element)
           
 void setArray(boolean isArray)
          Sets whether this attribute is an array
 void setDefaultValue(java.lang.String defaultValue)
           
 void setDescription(java.lang.String description)
           
 void setName(java.lang.String name)
           
 

Field Detail

CHECKABLE_KIND

static final int CHECKABLE_KIND
Static integer value for a Checkable kind of attribute. Checkable attributes can have only "true" or "false" values

See Also:
Constant Field Values

ENTRY_LIST_KIND

static final int ENTRY_LIST_KIND
Static integer value for a Entry List kind of attribute. Entry List attributes can take one value from a defined list.

See Also:
Constant Field Values

STRING_ENTRY_KIND

static final int STRING_ENTRY_KIND
Static integer value for a String kind of attribute.

See Also:
Constant Field Values
Method Detail

setName

void setName(java.lang.String name)

setDefaultValue

void setDefaultValue(java.lang.String defaultValue)

setDescription

void setDescription(java.lang.String description)

asElement

org.dom4j.Element asElement()

setArray

void setArray(boolean isArray)
Sets whether this attribute is an array

Parameters:
isArray -

parse

void parse(org.dom4j.Element element)

getDefaultValue

java.lang.String getDefaultValue()
Get the default value for this attribute. This will be a String irrespective of the kind of attribute.

Returns:

getDescription

java.lang.String getDescription()
Returns the human readable description of this attribute.

Returns:
description string.

getKind

int getKind()
The 'kind' of attribute. Possible values are defined in teh static fields of this class.

Returns:
int representing the kind of attribute

getName

java.lang.String getName()
Get the name of the attribute.

Returns:
the attribute name

isArray

boolean isArray()
Returns true if this attribute is an array type. Arrays are currently only supported for String Kind attributes.

Returns:
true if this attribute is an array