no.kith.xmlstds.MO Maven / Gradle / Ivy
//
// This file was generated by the Eclipse Implementation of JAXB, v2.3.7
// See https://eclipse-ee4j.github.io/jaxb-ri
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2023.12.22 at 08:04:05 AM CET
//
package no.kith.xmlstds;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.Map;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlSchemaType;
import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import com.kscs.util.jaxb.Buildable;
import com.kscs.util.jaxb.PropertyTree;
import com.kscs.util.jaxb.PropertyTreeUse;
/**
* Java class for MO complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="MO">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="V" type="{http://www.w3.org/2001/XMLSchema}decimal" />
* <attribute name="U" type="{http://www.w3.org/2001/XMLSchema}token" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "MO")
public class MO {
@XmlAttribute(name = "V")
protected BigDecimal v;
@XmlAttribute(name = "U")
@XmlJavaTypeAdapter(CollapsedStringAdapter.class)
@XmlSchemaType(name = "token")
protected String u;
protected transient MO.Modifier __cachedModifier__;
/**
* Gets the value of the v property.
*
* @return
* possible object is
* {@link BigDecimal }
*
*/
public BigDecimal getV() {
return v;
}
/**
* Sets the value of the v property.
*
* @param value
* allowed object is
* {@link BigDecimal }
*
*/
public void setV(BigDecimal value) {
this.v = value;
}
/**
* Gets the value of the u property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getU() {
return u;
}
/**
* Sets the value of the u property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setU(String value) {
this.u = value;
}
/**
* Copies all state of this object to a builder. This method is used by the {@link
* #copyOf} method and should not be called directly by client code.
*
* @param _other
* A builder instance to which the state of this object will be copied.
*/
public<_B >void copyTo(final MO.Builder<_B> _other) {
_other.v = this.v;
_other.u = this.u;
}
public<_B >MO.Builder<_B> newCopyBuilder(final _B _parentBuilder) {
return new MO.Builder<_B>(_parentBuilder, this, true);
}
public MO.Builder newCopyBuilder() {
return newCopyBuilder(null);
}
public static MO.Builder builder() {
return new MO.Builder(null, null, false);
}
public static<_B >MO.Builder<_B> copyOf(final MO _other) {
final MO.Builder<_B> _newBuilder = new MO.Builder<_B>(null, null, false);
_other.copyTo(_newBuilder);
return _newBuilder;
}
/**
* Copies all state of this object to a builder. This method is used by the {@link
* #copyOf} method and should not be called directly by client code.
*
* @param _other
* A builder instance to which the state of this object will be copied.
*/
public<_B >void copyTo(final MO.Builder<_B> _other, final PropertyTree _propertyTree, final PropertyTreeUse _propertyTreeUse) {
final PropertyTree vPropertyTree = ((_propertyTree == null)?null:_propertyTree.get("v"));
if (((_propertyTreeUse == PropertyTreeUse.INCLUDE)?(vPropertyTree!= null):((vPropertyTree == null)||(!vPropertyTree.isLeaf())))) {
_other.v = this.v;
}
final PropertyTree uPropertyTree = ((_propertyTree == null)?null:_propertyTree.get("u"));
if (((_propertyTreeUse == PropertyTreeUse.INCLUDE)?(uPropertyTree!= null):((uPropertyTree == null)||(!uPropertyTree.isLeaf())))) {
_other.u = this.u;
}
}
public<_B >MO.Builder<_B> newCopyBuilder(final _B _parentBuilder, final PropertyTree _propertyTree, final PropertyTreeUse _propertyTreeUse) {
return new MO.Builder<_B>(_parentBuilder, this, true, _propertyTree, _propertyTreeUse);
}
public MO.Builder newCopyBuilder(final PropertyTree _propertyTree, final PropertyTreeUse _propertyTreeUse) {
return newCopyBuilder(null, _propertyTree, _propertyTreeUse);
}
public static<_B >MO.Builder<_B> copyOf(final MO _other, final PropertyTree _propertyTree, final PropertyTreeUse _propertyTreeUse) {
final MO.Builder<_B> _newBuilder = new MO.Builder<_B>(null, null, false);
_other.copyTo(_newBuilder, _propertyTree, _propertyTreeUse);
return _newBuilder;
}
public static MO.Builder copyExcept(final MO _other, final PropertyTree _propertyTree) {
return copyOf(_other, _propertyTree, PropertyTreeUse.EXCLUDE);
}
public static MO.Builder copyOnly(final MO _other, final PropertyTree _propertyTree) {
return copyOf(_other, _propertyTree, PropertyTreeUse.INCLUDE);
}
public MO.Modifier modifier() {
if (null == this.__cachedModifier__) {
this.__cachedModifier__ = new MO.Modifier();
}
return ((MO.Modifier) this.__cachedModifier__);
}
public static class Builder<_B >implements Buildable
{
protected final _B _parentBuilder;
protected final MO _storedValue;
private BigDecimal v;
private String u;
public Builder(final _B _parentBuilder, final MO _other, final boolean _copy) {
this._parentBuilder = _parentBuilder;
if (_other!= null) {
if (_copy) {
_storedValue = null;
this.v = _other.v;
this.u = _other.u;
} else {
_storedValue = _other;
}
} else {
_storedValue = null;
}
}
public Builder(final _B _parentBuilder, final MO _other, final boolean _copy, final PropertyTree _propertyTree, final PropertyTreeUse _propertyTreeUse) {
this._parentBuilder = _parentBuilder;
if (_other!= null) {
if (_copy) {
_storedValue = null;
final PropertyTree vPropertyTree = ((_propertyTree == null)?null:_propertyTree.get("v"));
if (((_propertyTreeUse == PropertyTreeUse.INCLUDE)?(vPropertyTree!= null):((vPropertyTree == null)||(!vPropertyTree.isLeaf())))) {
this.v = _other.v;
}
final PropertyTree uPropertyTree = ((_propertyTree == null)?null:_propertyTree.get("u"));
if (((_propertyTreeUse == PropertyTreeUse.INCLUDE)?(uPropertyTree!= null):((uPropertyTree == null)||(!uPropertyTree.isLeaf())))) {
this.u = _other.u;
}
} else {
_storedValue = _other;
}
} else {
_storedValue = null;
}
}
public _B end() {
return this._parentBuilder;
}
protected<_P extends MO >_P init(final _P _product) {
_product.v = this.v;
_product.u = this.u;
return _product;
}
/**
* Sets the new value of "v" (any previous value will be replaced)
*
* @param v
* New value of the "v" property.
*/
public MO.Builder<_B> withV(final BigDecimal v) {
this.v = v;
return this;
}
/**
* Sets the new value of "u" (any previous value will be replaced)
*
* @param u
* New value of the "u" property.
*/
public MO.Builder<_B> withU(final String u) {
this.u = u;
return this;
}
@Override
public MO build() {
if (_storedValue == null) {
return this.init(new MO());
} else {
return ((MO) _storedValue);
}
}
public MO.Builder<_B> copyOf(final MO _other) {
_other.copyTo(this);
return this;
}
public MO.Builder<_B> copyOf(final MO.Builder _other) {
return copyOf(_other.build());
}
}
public class Modifier {
public void setV(final BigDecimal v) {
MO.this.setV(v);
}
public void setU(final String u) {
MO.this.setU(u);
}
}
public static class Select
extends MO.Selector
{
Select() {
super(null, null, null);
}
public static MO.Select _root() {
return new MO.Select();
}
}
public static class Selector , TParent >
extends com.kscs.util.jaxb.Selector
{
private com.kscs.util.jaxb.Selector> v = null;
private com.kscs.util.jaxb.Selector> u = null;
public Selector(final TRoot root, final TParent parent, final String propertyName) {
super(root, parent, propertyName);
}
@Override
public Map buildChildren() {
final Map products = new HashMap();
products.putAll(super.buildChildren());
if (this.v!= null) {
products.put("v", this.v.init());
}
if (this.u!= null) {
products.put("u", this.u.init());
}
return products;
}
public com.kscs.util.jaxb.Selector> v() {
return ((this.v == null)?this.v = new com.kscs.util.jaxb.Selector>(this._root, this, "v"):this.v);
}
public com.kscs.util.jaxb.Selector> u() {
return ((this.u == null)?this.u = new com.kscs.util.jaxb.Selector>(this._root, this, "u"):this.u);
}
}
}