Packages

  • package root
    Definition Classes
    root
  • package csw
    Definition Classes
    root
  • package params

    This project is intended to hold reusable models and params used throughout the csw source code.

    Params

    This project is intended to hold reusable models and params used throughout the csw source code.

    This also provides out of the box support to cater to the diverse communication requirements. Consumer of this library will be able to create Commands, Events, States to store ParameterSets.

    Imp Packages

    Commands and Events

    This packages contains classes, traits and models used to create *commands* and *events*. These are all based on type-safe keys and items (a set of values with optional units). Each key has a specific type and the key's values must be of that type.

    Two types of csw.params.commands.Command are supported:

    Following are the concrete commands supported by csw:

    Two types of csw.params.events.Event are supported:

    core

    This package supports serialization and deserialization of commands, events and state variables in JSON format csw.params.core.formats.JsonSupport.

    Scala and Java APIs

    All the param and event classes are immutable. The set methods return a new instance of the object with a new item added and the get methods return an Option, in case the Key is not found. There are also value methods that return a value directly, throwing an exception if the key or value is not found.

    Key Types

    A set of standard key types and matching items are defined. Each key accepts one or more values of the given type.

    Following csw.params.core.generics.KeyType are supported by csw:

    +--------------+-------------------------+---------------------------+
    |  Primitive   |      Scala KeyType      |       Java KeyType        |
    +--------------+-------------------------+---------------------------+
    | Boolean      | KeyType.BooleanKey      | JKeyType.BooleanKey      |
    | Character    | KeyType.CharKey         | JKeyType.JCharKey        |
    | Byte         | KeyType.ByteKey         | JKeyType.ByteKey         |
    | Short        | KeyType.ShortKey        | JKeyType.ShortKey        |
    | Long         | KeyType.LongKey         | JKeyType.LongKey         |
    | Int          | KeyType.IntKey          | JKeyType.IntKey          |
    | Float        | KeyType.FloatKey        | JKeyType.FloatKey        |
    | Double       | KeyType.DoubleKey       | JKeyType.DoubleKey       |
    | String       | KeyType.StringKey       | JKeyType.StringKey       |
    | UtcTime      | KeyType.UTCTimeKey      | JKeyType.UTCTimeKey      |
    | TaiTime      | KeyType.TAITimeKey      | JKeyType.TAITimeKey      |
    | ----------   | ----------              | ----------               |
    | ByteArray    | KeyType.ByteArrayKey    | JKeyType.ByteArrayKey    |
    | ShortArray   | KeyType.ShortArrayKey   | JKeyType.ShortArrayKey   |
    | LongArray    | KeyType.LongArrayKey    | JKeyType.LongArrayKey    |
    | IntArray     | KeyType.IntArrayKey     | JKeyType.IntArrayKey     |
    | FloatArray   | KeyType.FloatArrayKey   | JKeyType.FloatArrayKey   |
    | DoubleArray  | KeyType.DoubleArrayKey  | JKeyType.DoubleArrayKey  |
    | ----------   | ----------              | ----------               |
    | ByteMatrix   | KeyType.ByteMatrixKey   | JKeyType.ByteMatrixKey   |
    | ShortMatrix  | KeyType.ShortMatrixKey  | JKeyType.ShortMatrixKey  |
    | LongMatrix   | KeyType.LongMatrixKey   | JKeyType.LongMatrixKey   |
    | IntMatrix    | KeyType.IntMatrixKey    | JKeyType.IntMatrixKey    |
    | FloatMatrix  | KeyType.FloatMatrixKey  | JKeyType.FloatMatrixKey  |
    | DoubleMatrix | KeyType.DoubleMatrixKey | JKeyType.DoubleMatrixKey |
    | ----------   | ----------              | ----------               |
    | Choice       | KeyType.ChoiceKey       | JKeyType.ChoiceKey       |
    +--------------+-------------------------+---------------------------+

    Detailed information about creating Keys and Parameters can be found here: https://tmtsoftware.github.io/csw/services/messages/keys-parameters.html

    Detailed information about creating commands can be found here: https://tmtsoftware.github.io/csw/services/messages/commands.html

    Detailed information about creating events can be found here: https://tmtsoftware.github.io/csw/services/messages/events.html

    Definition Classes
    csw
  • package core
    Definition Classes
    params
  • package generics
    Definition Classes
    core
  • ArrayKeyType
  • GChoiceKey
  • Key
  • KeyType
  • MatrixKeyType
  • Parameter
  • ParameterSetFilters
  • ParameterSetKeyData
  • ParameterSetType
  • SimpleKeyType
  • SimpleKeyTypeWithUnits

case class Parameter[S](keyName: String, keyType: KeyType[S], items: ArraySeq[S], units: Units) extends Product with Serializable

Parameter represents a KeyName, KeyType, array of values and units applicable to values. Parameter sits as payload for sending commands and events between components.

S

the type of items this parameter holds

keyName

the name of the key

keyType

reference to an object of type KeyType[S]

items

an Array of values of type S

units

applicable units

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Parameter
  2. Serializable
  3. Product
  4. Equals
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new Parameter(keyName: String, keyType: KeyType[S], items: ArraySeq[S], units: Units)

    keyName

    the name of the key

    keyType

    reference to an object of type KeyType[S]

    items

    an Array of values of type S

    units

    applicable units

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def apply(index: Int): S

    Returns the value at the given index, throwing an exception if the index is out of range

    Returns the value at the given index, throwing an exception if the index is out of range

    index

    the index of a value

    returns

    the value at the given index (may throw an exception if the index is out of range)

  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def get(index: Int): Option[S]

    Get method returns an option of value if present at the given index else none

    Get method returns an option of value if present at the given index else none

    index

    the index of a value

    returns

    some value at the given index as an Option, if the index is in range, otherwise None

  9. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  10. def head: S

    Returns the first value as a convenience when storing a single value

    Returns the first value as a convenience when storing a single value

    returns

    the first or default value (Use this if you know there is only a single value)

  11. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  12. val items: ArraySeq[S]
  13. def jGet(index: Int): Optional[S]

    A Java helper that returns an option of value if present at the given index else empty

    A Java helper that returns an option of value if present at the given index else empty

    index

    the index of a value

    returns

    value at the given index as an Optional, if the index is in range, otherwise empty

  14. def jValues: List[S]

    A Java helper that returns a List of values this parameter holds

  15. val keyName: String
  16. val keyType: KeyType[S]
  17. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  18. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  19. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  20. def productElementNames: Iterator[String]
    Definition Classes
    Product
  21. def size: Int

    The number of values in this parameter (values.size)

    The number of values in this parameter (values.size)

    returns

    length of the array of items

  22. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  23. def toString(): String

    Returns a formatted string representation with a KeyName

    Returns a formatted string representation with a KeyName

    Definition Classes
    Parameter → AnyRef → Any
  24. val units: Units
  25. def value(index: Int): S

    Returns the value at the given index, throwing an exception if the index is out of range This is a Scala convenience method

    Returns the value at the given index, throwing an exception if the index is out of range This is a Scala convenience method

    index

    the index of a value

    returns

    the value at the given index (may throw an exception if the index is out of range)

  26. def values: Array[S]

    An Array of values this parameter holds

  27. def valuesToString: String

    A comma separated string representation of all values this parameter holds

  28. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  29. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  30. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  31. def withUnits(unitsIn: Units): Parameter[S]

    Sets the units for the values

    Sets the units for the values

    unitsIn

    the units for the values

    returns

    a new instance of this parameter with the units set

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped