Module jonix.onix3

Class Velocity

java.lang.Object
com.tectonica.jonix.onix3.Velocity
All Implemented Interfaces:
OnixComposite, OnixComposite.OnixDataComposite<JonixVelocity>, OnixTag, Serializable

public class Velocity extends Object implements OnixComposite.OnixDataComposite<JonixVelocity>, Serializable

Velocity composite

An optional group of data elements which together specify the rate of stock depletion – or equally, a rate of accumulation of backorders. Repeatable if the rate of depletion is specified using more than one metric (eg specifying both a minimum and maximum daily sale).

Reference name <Velocity>
Short tag <velocity>
Cardinality 0…n

This tag may be included in the following composites:

Possible placements within ONIX message:

Since:
Onix-3.02
See Also:
  • Field Details

  • Constructor Details

    • Velocity

      public Velocity()
    • Velocity

      public Velocity(Element element)
  • Method Details

    • _initialize

      public void _initialize()
      Description copied from interface: OnixComposite
      This is an internal API. Since Jonix 8.0, composite objects are being populated lazily. This method initiates the population process, and is invoked internally by the accessor APIs of the composites
      Specified by:
      _initialize in interface OnixComposite
    • exists

      public boolean exists()
      Description copied from interface: OnixTag
      indicates whether this tag exists in the ONIX record
      Specified by:
      exists in interface OnixTag
      Returns:
      whether this tag (<Velocity> or <velocity>) is explicitly provided in the ONIX XML
    • ifExists

      public void ifExists(Consumer<Velocity> action)
    • getXmlElement

      public Element getXmlElement()
      Description copied from interface: OnixComposite
      For advanced use-cases only.
      Specified by:
      getXmlElement in interface OnixComposite
      Returns:
      native representation of the XML element underlying to this tag
    • velocityMetric

      public VelocityMetric velocityMetric()

      An ONIX code that specifies how the rate of stock depletion is measured. Mandatory within the <Velocity> composite, and non-repeating.

      Jonix-Comment: this field is required
    • rate

      public Rate rate()

      The stock depletion rate (as a number of copies, rounded to the nearest integer), measured according to the metric in <VelocityMetric>.

      Jonix-Comment: this field is required
    • proximity

      public Proximity proximity()

      An ONIX code which specifies the precision of the rate of stock depletion. Optional, and non-repeating.

      Jonix-Comment: this field is optional
    • asStruct

      public JonixVelocity asStruct()
      Specified by:
      asStruct in interface OnixComposite.OnixDataComposite<JonixVelocity>