Package org.ivoa.dm.executionbroker
Class IntegerDeltaOption
java.lang.Object
org.ivoa.dm.executionbroker.AbstractOption
org.ivoa.dm.executionbroker.IntegerDeltaOption
- All Implemented Interfaces:
org.ivoa.vodml.jpa.JPAManipulations,org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
@Entity
@VoDml(id="execbroker:IntegerDeltaOption",
role=objectType)
public class IntegerDeltaOption
extends AbstractOption
implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
A simple integer delta option. This option enables the client to increment or decrement an integer value pointed to by the path.
objectType: IntegerDeltaOption
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classA builder class for IntegerDeltaOption, mainly for use in the functional builder pattern.Nested classes/interfaces inherited from class org.ivoa.dm.executionbroker.AbstractOption
AbstractOption.AbstractOptionBuilder -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected IntegerThe maximum change that can be applied.protected IntegerThe minimum change that can be applied.protected StringThe units used for the maximum and minimum values and the default units used for the update.Fields inherited from class org.ivoa.dm.executionbroker.AbstractOption
_id, kind, path -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new IntegerDeltaOptionfull parameter constructor.IntegerDeltaOption(AbstractOption superinstance, Integer min, Integer max, String units) Constructor from supertype instance.Copy Constructor. -
Method Summary
Modifier and TypeMethodDescriptioncopyMe()make a clone of the object taking into account current polymorhic type.static IntegerDeltaOptioncreate a IntegerDeltaOption in functional builder style.voiddelete(jakarta.persistence.EntityManager em) voidgetMax()Returns max Attribute.getMin()Returns min Attribute.getUnits()Returns units Attribute.voidSet max Attribute.voidSet min Attribute.voidSet units Attribute.voidupdateUsing(IntegerDeltaOption other) Update this object with the content of the given object.fluent setter for max Attribute.fluent setter for min Attribute.fluent setter for units Attribute.Methods inherited from class org.ivoa.dm.executionbroker.AbstractOption
createAbstractOption, getId, getKind, getPath, setKind, setPath, updateUsing, withKind, withPathMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ivoa.vodml.jpa.JPAManipulationsForObjectType
getId
-
Field Details
-
min
@VoDml(id="execbroker:IntegerDeltaOption.min", role=attribute, type="ivoa:integer", typeRole=primitiveType) protected Integer minThe minimum change that can be applied. : Attribute min : multiplicity 1 -
max
@VoDml(id="execbroker:IntegerDeltaOption.max", role=attribute, type="ivoa:integer", typeRole=primitiveType) protected Integer maxThe maximum change that can be applied. : Attribute max : multiplicity 1 -
units
@VoDml(id="execbroker:IntegerDeltaOption.units", role=attribute, type="ivoa:string", typeRole=primitiveType) protected String unitsThe units used for the maximum and minimum values and the default units used for the update. The client may specify different units in the update if they need to. : Attribute units : multiplicity 1
-
-
Constructor Details
-
IntegerDeltaOption
public IntegerDeltaOption()Creates a new IntegerDeltaOption -
IntegerDeltaOption
full parameter constructor.- Parameters:
min- The minimum change that can be applied.max- The maximum change that can be applied.units- The units used for the maximum and minimum values and the default units used for the update. The client may specify different units in the update if they need to.kind- The kind of option.path- The path this option applies to.
-
IntegerDeltaOption
Copy Constructor. Note that references will remain as is rather than be copied.- Parameters:
other- the object to be copied.
-
IntegerDeltaOption
Constructor from supertype instance.- Parameters:
superinstance- The supertype.min- The minimum change that can be applied.max- The maximum change that can be applied.units- The units used for the maximum and minimum values and the default units used for the update. The client may specify different units in the update if they need to.
-
-
Method Details
-
copyMe
make a clone of the object taking into account current polymorhic type.- Overrides:
copyMein classAbstractOption- Returns:
- the cloned object.
-
updateUsing
Update this object with the content of the given object. Note that references will remain as is rather than be copied.- Parameters:
other- the object to be copied.
-
getMin
Returns min Attribute.- Returns:
- min Attribute
-
setMin
Set min Attribute.- Parameters:
pMin- value to set
-
withMin
fluent setter for min Attribute.- Parameters:
pMin- value to set- Returns:
- IntegerDeltaOption
-
getMax
Returns max Attribute.- Returns:
- max Attribute
-
setMax
Set max Attribute.- Parameters:
pMax- value to set
-
withMax
fluent setter for max Attribute.- Parameters:
pMax- value to set- Returns:
- IntegerDeltaOption
-
getUnits
Returns units Attribute.- Returns:
- units Attribute
-
setUnits
Set units Attribute.- Parameters:
pUnits- value to set
-
withUnits
fluent setter for units Attribute.- Parameters:
pUnits- value to set- Returns:
- IntegerDeltaOption
-
createIntegerDeltaOption
public static IntegerDeltaOption createIntegerDeltaOption(Consumer<IntegerDeltaOption.IntegerDeltaOptionBuilder> f) create a IntegerDeltaOption in functional builder style.- Parameters:
f- the functional builder.- Returns:
- an object initialized from the builder.
-
forceLoad
public void forceLoad()- Specified by:
forceLoadin interfaceorg.ivoa.vodml.jpa.JPAManipulations- Overrides:
forceLoadin classAbstractOption
-
delete
public void delete(jakarta.persistence.EntityManager em) - Specified by:
deletein interfaceorg.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>- Overrides:
deletein classAbstractOption
-