Module JNISpice
Package spice.basic

Class InstrumentCode


  • public class InstrumentCode
    extends IDMap
    Class InstrumentCode represents instrument-name mappings that are initialized by specification of a instrument ID code.

    SPICE applications normally won't need to use this class directly; they should use the class Instrument instead.

    Version 2.0.0 26-DEC-2016 (NJB)

    Added deepCopy method.

    Version 1.0.0 25-AUG-2009 (NJB)

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int IDcode  
    • Constructor Summary

      Constructors 
      Constructor Description
      InstrumentCode​(int code)
      Create a new InstrumentCode from an int ID code.
    • Method Summary

      Modifier and Type Method Description
      InstrumentCode deepCopy()
      Return a deep copy of this instance.
      int getIDCode()
      Return the integer Instrument ID code of this InstrumentCode instance.
      java.lang.String getName()
      Return the instrument name associated with this ID code.The name is that associated with the ID code at the time of the call.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • IDcode

        private int IDcode
    • Constructor Detail

      • InstrumentCode

        public InstrumentCode​(int code)
        Create a new InstrumentCode from an int ID code.
        Parameters:
        code - int
    • Method Detail

      • getIDCode

        public int getIDCode()
        Return the integer Instrument ID code of this InstrumentCode instance.
        Specified by:
        getIDCode in class IDMap
        Returns:
        int
      • getName

        public java.lang.String getName()
                                 throws SpiceException
        Return the instrument name associated with this ID code.The name is that associated with the ID code at the time of the call.
        Specified by:
        getName in class IDMap
        Returns:
        String
        Throws:
        SpiceException - exception