程序包 weka.core

类 SelectedTag

java.lang.Object
weka.core.SelectedTag
所有已实现的接口:
RevisionHandler

public class SelectedTag extends Object implements RevisionHandler
Represents a selected value from a finite set of values, where each value is a Tag (i.e. has some string associated with it). Primarily used in schemes to select between alternative behaviours, associating names with the alternative behaviours.
版本:
$Revision: 1.11 $
作者:
Len Trigg
  • 构造器详细资料

    • SelectedTag

      public SelectedTag(int tagID, Tag[] tags)
      Creates a new 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.
    • SelectedTag

      public SelectedTag(String tagText, Tag[] tags)
      Creates a new 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.
  • 方法详细资料

    • equals

      public boolean equals(Object o)
      Returns true if this SelectedTag equals another object
      覆盖:
      equals 在类中 Object
      参数:
      o - the object to compare with
      返回:
      true if the tags and the selected tag are the same
    • getSelectedTag

      public Tag getSelectedTag()
      Gets the selected Tag.
      返回:
      the selected Tag.
    • getTags

      public Tag[] getTags()
      Gets the set of all valid Tags.
      返回:
      an array containing the valid Tags.
    • toString

      public String toString()
      returns the selected tag in string representation
      覆盖:
      toString 在类中 Object
      返回:
      the selected tag as string
    • getRevision

      public String getRevision()
      Returns the revision string.
      指定者:
      getRevision 在接口中 RevisionHandler
      返回:
      the revision