Class ALcdASTERIXScalingFactorProvider

java.lang.Object
com.luciad.format.asterix.ALcdASTERIXScalingFactorProvider

public abstract class ALcdASTERIXScalingFactorProvider extends Object
Provider for scaling factors for some data items of some ASTERIX categories.

Some ASTERIX categories specify their data in fixed point notation, that is an integer value together with a factor. If for example the value is 16000, the unit is degrees, and the factor is 0.005, that means an angle of 80 degrees.

Some other data items of some ASTERIX categories however, specify that factor relative to a 'scaling factor' (f-value). For example the factor to multiply the value with is specified as 2 ^ -6+f. That scaling factor is to be found elsewhere in the data, or from an external source. This scaling factor provider serves the purpose of providing the scaling factor when it cannot be retrieved from the data source. This can happen because it is not specified where to retrieve the scaling factor from, or if it is specified, but the actual data omits the value.

  • Field Details

  • Constructor Details

    • ALcdASTERIXScalingFactorProvider

      public ALcdASTERIXScalingFactorProvider()
  • Method Details

    • scalingFactor

      public abstract int scalingFactor(ILcdModel aModel, int aID)
      Provides the scaling factor (f-value) for a given constant specified in this class.

      Whenever scaling factors are present in the data stream, they take precedence over values returned by this provider.

      Whenever Integer.MIN_VALUE is returned, defaults will be used. This can be useful to override the default behavior for a specific constant, but to leave the defaults unchanged for other categories.

      Parameters:
      aModel - The model containing the data for which the scaling factors are needed. It can be used to retrieve the User Application Profile (UAP) from its ILcdModelDescriptor, to retrieve the ILcdDataModelDescriptor, ILcdFeaturedDescriptor, and so on.
      aID - The id of the scaling factor: one of the constants specified in this class.
      Returns:
      The scaling factor, or Integer.MIN_VALUE to request to use a a default value.