Class RadioType

java.lang.Object
edu.nps.moves.dis7.pdus.RadioType
All Implemented Interfaces:
Serializable

public class RadioType extends Object implements Serializable
Identifies the type of radio. Section 6.2.71
See Also:
  • Field Details

    • entityKind

      protected EntityKind entityKind
      Kind of entity uid 7
    • domain

      protected byte domain
      Domain of entity (air, surface, subsurface, space, etc.)
    • country

      protected Country country
      country to which the design of the entity is attributed uid 29
    • category

      protected RadioCategory category
      category of entity uid 22
    • subcategory

      protected RadioSubcategory subcategory
      specific info based on subcategory field uid 23
    • specific

      protected byte specific
      specific is an undescribed parameter...
    • extra

      protected byte extra
      extra is an undescribed parameter...
  • Constructor Details

    • RadioType

      public RadioType()
      Constructor creates and configures a new instance object
  • Method Details

    • getMarshalledSize

      public int getMarshalledSize()
      Returns size of this serialized (marshalled) object in bytes
      Returns:
      serialized size in bytes
      See Also:
    • setEntityKind

      public RadioType setEntityKind(EntityKind pEntityKind)
      Setter for entityKind
      Parameters:
      pEntityKind - new value of interest
      Returns:
      same object to permit progressive setters
    • getEntityKind

      public EntityKind getEntityKind()
      Getter for entityKind
      Returns:
      value of interest
    • setDomain

      public RadioType setDomain(byte pDomain)
      Setter for domain
      Parameters:
      pDomain - new value of interest
      Returns:
      same object to permit progressive setters
    • setDomain

      public RadioType setDomain(int pDomain)
      Utility setter for domain
      Parameters:
      pDomain - new value of interest
      Returns:
      same object to permit progressive setters
    • getDomain

      public byte getDomain()
      Getter for domain
      Returns:
      value of interest
    • setCountry

      public RadioType setCountry(Country pCountry)
      Setter for country
      Parameters:
      pCountry - new value of interest
      Returns:
      same object to permit progressive setters
    • getCountry

      public Country getCountry()
      Getter for country
      Returns:
      value of interest
    • setCategory

      public RadioType setCategory(RadioCategory pCategory)
      Setter for category
      Parameters:
      pCategory - new value of interest
      Returns:
      same object to permit progressive setters
    • getCategory

      public RadioCategory getCategory()
      Getter for category
      Returns:
      value of interest
    • setSubcategory

      public RadioType setSubcategory(RadioSubcategory pSubcategory)
      Setter for subcategory
      Parameters:
      pSubcategory - new value of interest
      Returns:
      same object to permit progressive setters
    • getSubcategory

      public RadioSubcategory getSubcategory()
      Getter for subcategory
      Returns:
      value of interest
    • setSpecific

      public RadioType setSpecific(byte pSpecific)
      Setter for specific
      Parameters:
      pSpecific - new value of interest
      Returns:
      same object to permit progressive setters
    • setSpecific

      public RadioType setSpecific(int pSpecific)
      Utility setter for specific
      Parameters:
      pSpecific - new value of interest
      Returns:
      same object to permit progressive setters
    • getSpecific

      public byte getSpecific()
      Getter for specific
      Returns:
      value of interest
    • setExtra

      public RadioType setExtra(byte pExtra)
      Setter for extra
      Parameters:
      pExtra - new value of interest
      Returns:
      same object to permit progressive setters
    • setExtra

      public RadioType setExtra(int pExtra)
      Utility setter for extra
      Parameters:
      pExtra - new value of interest
      Returns:
      same object to permit progressive setters
    • getExtra

      public byte getExtra()
      Getter for extra
      Returns:
      value of interest
    • marshal

      public void marshal(DataOutputStream dos) throws Exception
      Serializes an object to a DataOutputStream.
      Parameters:
      dos - the OutputStream
      Throws:
      Exception - if something goes wrong
      See Also:
    • unmarshal

      public int unmarshal(DataInputStream dis) throws Exception
      Deserializes an object from a DataInputStream.
      Parameters:
      dis - the InputStream
      Returns:
      marshalled serialized size in bytes
      Throws:
      Exception - if something goes wrong
      See Also:
    • marshal

      public void marshal(ByteBuffer byteBuffer) throws Exception
      Packs an object into the ByteBuffer.
      Parameters:
      byteBuffer - The ByteBuffer at the position to begin writing
      Throws:
      BufferOverflowException - if byteBuffer is too small
      ReadOnlyBufferException - if byteBuffer is read only
      Exception - ByteBuffer-generated exception
      See Also:
    • unmarshal

      public int unmarshal(ByteBuffer byteBuffer) throws Exception
      Unpacks a Pdu from the underlying data.
      Parameters:
      byteBuffer - The ByteBuffer at the position to begin reading
      Returns:
      marshalled serialized size in bytes
      Throws:
      BufferUnderflowException - if byteBuffer is too small
      Exception - ByteBuffer-generated exception
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • equalsImpl

      public boolean equalsImpl(Object obj)
      Compare all fields that contribute to the state, ignoring transient and static fields, for this and the supplied object
      Parameters:
      obj - the object to compare to
      Returns:
      true if the objects are equal, false otherwise.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object