| Constructor and Description |
|---|
TemplateElement() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
equality method.
|
String |
getDescription()
Gets the description of this element.
|
String |
getName()
Gets the name of this element.
|
int |
hashCode()
Returns a hash code value for the object.
|
boolean |
isImplicit()
Gets whether this element is implicit.
|
boolean |
isOptional()
Gets whether this element is optional.
|
void |
setDescription(String desc)
Sets a textual description of this element,
for build documentation purposes only.
|
void |
setImplicit(boolean implicit)
Sets whether this element is implicit.
|
void |
setName(String name)
Sets the name of this element.
|
void |
setOptional(boolean optional)
Sets whether this element is optional.
|
public boolean equals(Object obj)
equals in class Objectobj - an Object valueboolean valueObject.hashCode(),
HashMappublic String getDescription()
null if
no description is available.public String getName()
public int hashCode()
ObjectHashMap.
The general contract of hashCode is:
hashCode method must consistently return the same integer, provided no
information used in equals comparisons on the object is modified. This integer need not
remain consistent from one execution of an application to another execution of the same
application.
equals(Object) method, then calling the
hashCode method on each of the two objects must produce the same integer result.
Object.equals(java.lang.Object) method, then calling the hashCode
method on each of the two objects must produce distinct integer results. However, the programmer
should be aware that producing distinct integer results for unequal objects may improve the
performance of hash tables.
As much as is reasonably practical, the hashCode method defined by class Object does
return distinct integers for distinct objects. (This is typically implemented by converting the
internal address of the object into an integer, but this implementation technique is not required
by the JavaTM programming language.)
hashCode in class ObjectObject.equals(java.lang.Object),
System.identityHashCode(java.lang.Object)public boolean isImplicit()
public boolean isOptional()
public void setDescription(String desc)
desc - Description of the element.public void setImplicit(boolean implicit)
implicit - if true this element may be left out, default
is false.public void setName(String name)
name - the name of the elementpublic void setOptional(boolean optional)
optional - if true this element may be left out, default
is false.