public class SelectedTag extends Object implements RevisionHandler
Constructor and Description |
---|
SelectedTag(int tagID,
Tag[] tags)
Creates a new
SelectedTag instance. |
SelectedTag(String tagText,
Tag[] tags)
Creates a new
SelectedTag instance. |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o)
Returns true if this SelectedTag equals another object
|
String |
getRevision()
Returns the revision string.
|
Tag |
getSelectedTag()
Gets the selected Tag.
|
Tag[] |
getTags()
Gets the set of all valid Tags.
|
String |
toString()
returns the selected tag in string representation
|
public SelectedTag(int tagID, Tag[] tags)
SelectedTag
instance.tagID
- the id of the selected tag.tags
- an array containing the possible valid Tags.IllegalArgumentException
- if the selected tag isn't in the array
of valid values or the IDs/IDStrs are not unique.public SelectedTag(String tagText, Tag[] tags)
SelectedTag
instance.tagText
- the text of the selected tag (case-insensitive).tags
- an array containing the possible valid Tags.IllegalArgumentException
- if the selected tag isn't in the array
of valid values.public boolean equals(Object o)
public Tag getSelectedTag()
public Tag[] getTags()
public String toString()
public String getRevision()
getRevision
in interface RevisionHandler
Copyright © 2019 University of Waikato, Hamilton, NZ. All rights reserved.