Class DBElementDescriptor

java.lang.Object
org.scictrl.mp.orbitcorrect.DBElementDescriptor

public final class DBElementDescriptor extends Object

DBElementDescriptor class.

Author:
igor@scictrl.com
  • Field Details

    • EL_DBINFO

      public static final int EL_DBINFO
      Constant EL_DBINFO=0
      See Also:
    • EL_POWER_SUPPLY

      public static final int EL_POWER_SUPPLY
      Constant EL_POWER_SUPPLY=1
      See Also:
    • EL_MARKER

      public static final int EL_MARKER
      Constant EL_MARKER=2
      See Also:
    • EL_BPM

      public static final int EL_BPM
      Constant EL_BPM=3
      See Also:
    • EL_APERTURE

      public static final int EL_APERTURE
      Constant EL_APERTURE=4
      See Also:
    • EL_CAVITY

      public static final int EL_CAVITY
      Constant EL_CAVITY=5
      See Also:
    • EL_SEPTUM

      public static final int EL_SEPTUM
      Constant EL_SEPTUM=6
      See Also:
    • EL_KICKER

      public static final int EL_KICKER
      Constant EL_KICKER=7
      See Also:
    • EL_HOR_CORRECTOR

      public static final int EL_HOR_CORRECTOR
      Constant EL_HOR_CORRECTOR=8
      See Also:
    • EL_VER_CORRECTOR

      public static final int EL_VER_CORRECTOR
      Constant EL_VER_CORRECTOR=9
      See Also:
    • EL_SBENDING

      public static final int EL_SBENDING
      Constant EL_SBENDING=10
      See Also:
    • EL_RBENDING

      public static final int EL_RBENDING
      Constant EL_RBENDING=11
      See Also:
    • EL_QUADRUPOLE

      public static final int EL_QUADRUPOLE
      Constant EL_QUADRUPOLE=12
      See Also:
    • EL_SEXTUPOLE

      public static final int EL_SEXTUPOLE
      Constant EL_SEXTUPOLE=13
      See Also:
    • EL_RF_GENERATOR

      public static final int EL_RF_GENERATOR
      Constant EL_RF_GENERATOR=14
      See Also:
    • ELDES_DBINFO

      public static final DBElementDescriptor ELDES_DBINFO
      Constant ELDES_DBINFO
    • ELDES_POWER_SUPPLY

      public static final DBElementDescriptor ELDES_POWER_SUPPLY
      Constant ELDES_POWER_SUPPLY
    • ELDES_MARKER

      public static final DBElementDescriptor ELDES_MARKER
      Constant ELDES_MARKER
    • ELDES_BPM

      public static final DBElementDescriptor ELDES_BPM
      Constant ELDES_BPM
    • ELDES_APERTURE

      public static final DBElementDescriptor ELDES_APERTURE
      Constant ELDES_APERTURE
    • ELDES_CAVITY

      public static final DBElementDescriptor ELDES_CAVITY
      Constant ELDES_CAVITY
    • ELDES_SEPTUM

      public static final DBElementDescriptor ELDES_SEPTUM
      Constant ELDES_SEPTUM
    • ELDES_KICKER

      public static final DBElementDescriptor ELDES_KICKER
      Constant ELDES_KICKER
    • ELDES_HOR_CORRECTOR

      public static final DBElementDescriptor ELDES_HOR_CORRECTOR
      Constant ELDES_HOR_CORRECTOR
    • ELDES_VER_CORRECTOR

      public static final DBElementDescriptor ELDES_VER_CORRECTOR
      Constant ELDES_VER_CORRECTOR
    • ELDES_SBENDING

      public static final DBElementDescriptor ELDES_SBENDING
      Constant ELDES_SBENDING
    • ELDES_RBENDING

      public static final DBElementDescriptor ELDES_RBENDING
      Constant ELDES_RBENDING
    • ELDES_QUADRUPOLE

      public static final DBElementDescriptor ELDES_QUADRUPOLE
      Constant ELDES_QUADRUPOLE
    • ELDES_SEXTUPOLE

      public static final DBElementDescriptor ELDES_SEXTUPOLE
      Constant ELDES_SEXTUPOLE
    • ELDES_RF_GENERATOR

      public static final DBElementDescriptor ELDES_RF_GENERATOR
      Constant ELDES_RF_GENERATOR
    • ELEMENT_TAG

      public static final String ELEMENT_TAG
      Constant ELEMENT_TAG="element"
      See Also:
    • TEMPLATE_TAG

      public static final String TEMPLATE_TAG
      Constant TEMPLATE_TAG="template"
      See Also:
    • PARAMETERS_TAGS

      public static final String[][] PARAMETERS_TAGS
      Constant PARAMETERS_TAGS
    • ELEMENTS_CLASS_TAGS

      public static final String[] ELEMENTS_CLASS_TAGS
      Constant ELEMENTS_CLASS_TAGS
    • PARAMETERS

      public static final Object[][] PARAMETERS
      Constant PARAMETERS
    • SINGLE_PARAMETER_CLASS

      public static final Class<?>[] SINGLE_PARAMETER_CLASS
      Constant SINGLE_PARAMETER_CLASS
    • PARAMETERS_CLASSES

      public static final Class<?>[][] PARAMETERS_CLASSES
      Constant PARAMETERS_CLASSES
    • ELEMENT_CLASSES

      public static final String[] ELEMENT_CLASSES
      Constant ELEMENT_CLASSES
    • EL_CLASSES

      public static final String[] EL_CLASSES
      Constant EL_CLASSES
  • Method Details

    • defaultParameters

      public Object[] defaultParameters()
      This method returns default values for descripted element.
      Returns:
      java.lang.Object[]
    • fromElementClassTag

      public static DBElementDescriptor fromElementClassTag(String tag) throws IllegalArgumentException
      This method returns DBElementDescriptor for element, whose tag is specified with parameter. It checks all element from ELEMENT_CLASS_TAGS and if any of them has the same tag as specified with parameter, it is returned.
      Parameters:
      tag - a String object
      Returns:
      DBDescriptor
      Throws:
      IllegalArgumentException - if any.
      See Also:
    • fromInt

      public static DBElementDescriptor fromInt(int code) throws IllegalArgumentException
      This method returns DBElementDescriptor for element, whose code is specified with parameter.
      Parameters:
      code - int
      Returns:
      DBDescriptor
      Throws:
      IllegalArgumentException - if any.
      See Also:
    • getElClass

      public String getElClass()
      This method return class name of descripted element.
      Returns:
      java.lang.String
    • getElementClass

      public String getElementClass()
      This method return class name of descripted element, with full classpath.
      Returns:
      java.lang.String
    • getElementClassTag

      public String getElementClassTag()
      This method return class tag of descripted element.
      Returns:
      java.lang.String
    • getParameterTag

      public String getParameterTag(int par) throws IllegalArgumentException
      This method returns specified parameters tag of descripted element.
      Parameters:
      par - int specification, which tag (name, energy, virtual, ...)
      Returns:
      java.lang.String tag
      Throws:
      IllegalArgumentException - if any.
      See Also:
    • parametersClasses

      public Class<?>[] parametersClasses()

      parametersClasses.

      Returns:
      java.lang.String
    • parametersCount

      public int parametersCount()
      This method return number of descriptor tags of descripted element.
      Returns:
      int
    • parametersTags

      public String[] parametersTags()
      This method returns array of tags of descripted element.
      Returns:
      java.lang.String tag
      See Also:
    • value

      public int value()
      This method returns code of descripted element. Code is provided by constructor and with this code is determinated element, because each element has it unique code, which can be seen at fields, starting with EL_ (EL_KICKER, EL_MARKER,..., except EL_CLASSES).
      Returns:
      int