Enum Area.Type

java.lang.Object
java.lang.Enum<Area.Type>
uk.ac.starlink.ttools.plot2.data.Area.Type
All Implemented Interfaces:
Serializable, Comparable<Area.Type>, java.lang.constant.Constable
Enclosing class:
Area

public static enum Area.Type extends Enum<Area.Type>
Available shape types.
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    Circle defined by central point and a radius (x, y, r).
    Multi-Order Coverage map; each array element contains 64-bit NUNIQ bit pattern equivalenced to the double value.
    Point defined by two coordinates (x, y).
    Polygon or sequence of polygons defined by a list of vertices (x1, y1, x2, y2, ..., xN, yN).
  • Method Summary

    Modifier and Type
    Method
    Description
    static Area.Type
    fromInt(int itype)
    Retrieves an instance of this enum from its numeric code.
    abstract boolean
    Indicates whether a given data array length can represent a shape of this type.
    static Area.Type
    Returns the enum constant of this type with the specified name.
    static Area.Type[]
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • POLYGON

      public static final Area.Type POLYGON
      Polygon or sequence of polygons defined by a list of vertices (x1, y1, x2, y2, ..., xN, yN). If a coordinate pair (xA,yA) are both NaN, it indicates a break between polygons: so for instance (0,0, 0,1, 1,0, NaN,NaN, 2,2, 2,3, 3,2) defines two disjoint triangles. Breaks may not occur at the start or end of the array, or adjacent to each other.
    • CIRCLE

      public static final Area.Type CIRCLE
      Circle defined by central point and a radius (x, y, r).
    • POINT

      public static final Area.Type POINT
      Point defined by two coordinates (x, y).
    • MOC

      public static final Area.Type MOC
      Multi-Order Coverage map; each array element contains 64-bit NUNIQ bit pattern equivalenced to the double value.
  • Method Details

    • values

      public static Area.Type[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static Area.Type 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
    • isLegalArrayLength

      public abstract boolean isLegalArrayLength(int n)
      Indicates whether a given data array length can represent a shape of this type.
      Parameters:
      n - length of candidate array
      Returns:
      true iff this shape can be represented by a data array of the given length
    • fromInt

      public static Area.Type fromInt(int itype)
      Retrieves an instance of this enum from its numeric code.
      Parameters:
      itype - type ordinal
      Returns:
      type instance