oasis.names.specification.ubl.schema.xsd.commonaggregatecomponents_2.CommunicationType Maven / Gradle / Ivy
package oasis.names.specification.ubl.schema.xsd.commonaggregatecomponents_2;
import java.io.Serializable;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlType;
import com.phloc.commons.equals.EqualsUtils;
import com.phloc.commons.hash.HashCodeGenerator;
import com.phloc.commons.string.ToStringGenerator;
import oasis.names.specification.ubl.schema.xsd.commonbasiccomponents_2.ChannelCodeType;
import oasis.names.specification.ubl.schema.xsd.commonbasiccomponents_2.ChannelType;
import oasis.names.specification.ubl.schema.xsd.commonbasiccomponents_2.ValueType;
/**
*
*
* <?xml version="1.0" encoding="UTF-8"?><ccts:Component xmlns:ccts="urn:un:unece:uncefact:documentation:2" xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns:qdt="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDatatypes-2" xmlns:udt="urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><ccts:ComponentType>ABIE</ccts:ComponentType><ccts:DictionaryEntryName>Communication. Details</ccts:DictionaryEntryName><ccts:Definition>Information about a means of communication.</ccts:Definition><ccts:ObjectClass>Communication</ccts:ObjectClass></ccts:Component>
*
*
*
* Java class for CommunicationType complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="CommunicationType">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element ref="{urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2}ChannelCode" minOccurs="0"/>
* <element ref="{urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2}Channel" minOccurs="0"/>
* <element ref="{urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2}Value" minOccurs="0"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "CommunicationType", propOrder = {
"channelCode",
"channel",
"value"
})
public class CommunicationType implements Serializable
{
@XmlElement(name = "ChannelCode", namespace = "urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2")
private ChannelCodeType channelCode;
@XmlElement(name = "Channel", namespace = "urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2")
private ChannelType channel;
@XmlElement(name = "Value", namespace = "urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2")
private ValueType value;
/**
* Default constructor
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
*/
public CommunicationType() {
}
/**
* Constructor for value of type ValueType
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @param valueParam
* The value to be set. May be null
.
*/
public CommunicationType(
@Nullable
final ValueType valueParam) {
setValue(valueParam);
}
/**
*
*
* <?xml version="1.0" encoding="UTF-8"?><ccts:Component xmlns:ccts="urn:un:unece:uncefact:documentation:2" xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns:qdt="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDatatypes-2" xmlns:udt="urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><ccts:ComponentType>BBIE</ccts:ComponentType><ccts:DictionaryEntryName>Communication. Channel Code. Code</ccts:DictionaryEntryName><ccts:Definition>The method of communication, expressed as a code.</ccts:Definition><ccts:Cardinality>0..1</ccts:Cardinality><ccts:ObjectClass>Communication</ccts:ObjectClass><ccts:PropertyTerm>Channel Code</ccts:PropertyTerm><ccts:RepresentationTerm>Code</ccts:RepresentationTerm><ccts:DataType>Channel_ Code. Type</ccts:DataType><ccts:Examples>Phone Fax Email</ccts:Examples></ccts:Component>
*
*
*
* @return
* possible object is
* {@link ChannelCodeType }
*
*/
@Nullable
public ChannelCodeType getChannelCode() {
return channelCode;
}
/**
* Sets the value of the channelCode property.
*
* @param value
* allowed object is
* {@link ChannelCodeType }
*
*/
public void setChannelCode(
@Nullable
ChannelCodeType valueParam) {
this.channelCode = valueParam;
}
/**
*
*
* <?xml version="1.0" encoding="UTF-8"?><ccts:Component xmlns:ccts="urn:un:unece:uncefact:documentation:2" xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns:qdt="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDatatypes-2" xmlns:udt="urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><ccts:ComponentType>BBIE</ccts:ComponentType><ccts:DictionaryEntryName>Communication. Channel. Text</ccts:DictionaryEntryName><ccts:Definition>The method of communication, expressed as text.</ccts:Definition><ccts:Cardinality>0..1</ccts:Cardinality><ccts:ObjectClass>Communication</ccts:ObjectClass><ccts:PropertyTerm>Channel</ccts:PropertyTerm><ccts:RepresentationTerm>Text</ccts:RepresentationTerm><ccts:DataType>Text. Type</ccts:DataType><ccts:Examples>Skype</ccts:Examples></ccts:Component>
*
*
*
* @return
* possible object is
* {@link ChannelType }
*
*/
@Nullable
public ChannelType getChannel() {
return channel;
}
/**
* Sets the value of the channel property.
*
* @param value
* allowed object is
* {@link ChannelType }
*
*/
public void setChannel(
@Nullable
ChannelType valueParam) {
this.channel = valueParam;
}
/**
*
*
* <?xml version="1.0" encoding="UTF-8"?><ccts:Component xmlns:ccts="urn:un:unece:uncefact:documentation:2" xmlns="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns:qdt="urn:oasis:names:specification:ubl:schema:xsd:QualifiedDatatypes-2" xmlns:udt="urn:un:unece:uncefact:data:specification:UnqualifiedDataTypesSchemaModule:2" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><ccts:ComponentType>BBIE</ccts:ComponentType><ccts:DictionaryEntryName>Communication. Value. Text</ccts:DictionaryEntryName><ccts:Definition>The communication value, such as phone number or email address.</ccts:Definition><ccts:Cardinality>0..1</ccts:Cardinality><ccts:ObjectClass>Communication</ccts:ObjectClass><ccts:PropertyTerm>Value</ccts:PropertyTerm><ccts:RepresentationTerm>Text</ccts:RepresentationTerm><ccts:DataType>Text. Type</ccts:DataType><ccts:Examples>"+44 1 2345 6789" "[email protected]"</ccts:Examples></ccts:Component>
*
*
*
* @return
* possible object is
* {@link ValueType }
*
*/
@Nullable
public ValueType getValue() {
return value;
}
/**
* Sets the value of the value property.
*
* @param value
* allowed object is
* {@link ValueType }
*
*/
public void setValue(
@Nullable
ValueType valueParam) {
this.value = valueParam;
}
/**
* Created by phloc-jaxb22-plugin -Xphloc-equalshashcode
*
*/
@Override
public boolean equals(final Object o) {
if (o == this) {
return true;
}
if ((o == null)||(!getClass().equals(o.getClass()))) {
return false;
}
final CommunicationType rhs = ((CommunicationType) o);
if (!EqualsUtils.equals(channelCode, rhs.channelCode)) {
return false;
}
if (!EqualsUtils.equals(channel, rhs.channel)) {
return false;
}
if (!EqualsUtils.equals(value, rhs.value)) {
return false;
}
return true;
}
/**
* Created by phloc-jaxb22-plugin -Xphloc-equalshashcode
*
*/
@Override
public int hashCode() {
return new HashCodeGenerator(this).append(channelCode).append(channel).append(value).getHashCode();
}
/**
* Created by phloc-jaxb22-plugin -Xphloc-tostring
*
*/
@Override
public String toString() {
return new ToStringGenerator(this).append("channelCode", channelCode).append("channel", channel).append("value", value).toString();
}
/**
* Special setter with value of type String
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @param valueParam
* The value to be set. May be null
.
* @return
* The created intermediary object of type ChannelType and never null
*/
@Nonnull
public ChannelType setChannel(
@Nullable
final String valueParam) {
ChannelType aObj = getChannel();
if (aObj == null) {
aObj = new ChannelType(valueParam);
setChannel(aObj);
} else {
aObj.setValue(valueParam);
}
return aObj;
}
/**
* Special setter with value of type String
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @param valueParam
* The value to be set. May be null
.
* @return
* The created intermediary object of type ValueType and never null
*/
@Nonnull
public ValueType setValue(
@Nullable
final String valueParam) {
ValueType aObj = getValue();
if (aObj == null) {
aObj = new ValueType(valueParam);
setValue(aObj);
} else {
aObj.setValue(valueParam);
}
return aObj;
}
/**
* Special setter with value of type String
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @param valueParam
* The value to be set. May be null
.
* @return
* The created intermediary object of type ChannelCodeType and never null
*/
@Nonnull
public ChannelCodeType setChannelCode(
@Nullable
final String valueParam) {
ChannelCodeType aObj = getChannelCode();
if (aObj == null) {
aObj = new ChannelCodeType(valueParam);
setChannelCode(aObj);
} else {
aObj.setValue(valueParam);
}
return aObj;
}
/**
* Get the value of the contained ChannelCodeType object
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @return
* Either the value of the contained ChannelCodeType object or null
*/
@Nullable
public String getChannelCodeValue() {
ChannelCodeType aObj = getChannelCode();
return ((aObj == null)?null:aObj.getValue());
}
/**
* Get the value of the contained ChannelType object
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @return
* Either the value of the contained ChannelType object or null
*/
@Nullable
public String getChannelValue() {
ChannelType aObj = getChannel();
return ((aObj == null)?null:aObj.getValue());
}
/**
* Get the value of the contained ValueType object
* Created by phloc-ubl-jaxb-plugin -Xphloc-ubl-value
*
* @return
* Either the value of the contained ValueType object or null
*/
@Nullable
public String getValueValue() {
ValueType aObj = getValue();
return ((aObj == null)?null:aObj.getValue());
}
}