346 lines
14 KiB
Java
346 lines
14 KiB
Java
|
|
package com.sforce.soap.tooling;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* This is a generated class for the SObject Enterprise API.
|
||
|
|
* Do not edit this file, as your changes will be lost.
|
||
|
|
*/
|
||
|
|
public class SchemaField implements com.sforce.ws.bind.XMLizable {
|
||
|
|
|
||
|
|
/**
|
||
|
|
* Constructor
|
||
|
|
*/
|
||
|
|
public SchemaField() {}
|
||
|
|
|
||
|
|
/* Cache the typeInfo instead of declaring static fields throughout*/
|
||
|
|
private transient java.util.Map<String, com.sforce.ws.bind.TypeInfo> typeInfoCache = new java.util.HashMap<String, com.sforce.ws.bind.TypeInfo>();
|
||
|
|
private com.sforce.ws.bind.TypeInfo _lookupTypeInfo(String fieldName, String namespace, String name, String typeNS, String type, int minOcc, int maxOcc, boolean elementForm) {
|
||
|
|
com.sforce.ws.bind.TypeInfo typeInfo = typeInfoCache.get(fieldName);
|
||
|
|
if (typeInfo == null) {
|
||
|
|
typeInfo = new com.sforce.ws.bind.TypeInfo(namespace, name, typeNS, type, minOcc, maxOcc, elementForm);
|
||
|
|
typeInfoCache.put(fieldName, typeInfo);
|
||
|
|
}
|
||
|
|
return typeInfo;
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : digits of type {http://www.w3.org/2001/XMLSchema}int
|
||
|
|
* java type: int
|
||
|
|
*/
|
||
|
|
private boolean digits__is_set = false;
|
||
|
|
|
||
|
|
private int digits;
|
||
|
|
|
||
|
|
public int getDigits() {
|
||
|
|
return digits;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setDigits(int digits) {
|
||
|
|
this.digits = digits;
|
||
|
|
digits__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setDigits(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("digits", "urn:tooling.soap.sforce.com","digits","http://www.w3.org/2001/XMLSchema","int",1,1,true))) {
|
||
|
|
setDigits((int)__typeMapper.readInt(__in, _lookupTypeInfo("digits", "urn:tooling.soap.sforce.com","digits","http://www.w3.org/2001/XMLSchema","int",1,1,true), int.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldDigits(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("digits", "urn:tooling.soap.sforce.com","digits","http://www.w3.org/2001/XMLSchema","int",1,1,true), digits, digits__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : length of type {http://www.w3.org/2001/XMLSchema}int
|
||
|
|
* java type: int
|
||
|
|
*/
|
||
|
|
private boolean length__is_set = false;
|
||
|
|
|
||
|
|
private int length;
|
||
|
|
|
||
|
|
public int getLength() {
|
||
|
|
return length;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setLength(int length) {
|
||
|
|
this.length = length;
|
||
|
|
length__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setLength(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("length", "urn:tooling.soap.sforce.com","length","http://www.w3.org/2001/XMLSchema","int",1,1,true))) {
|
||
|
|
setLength((int)__typeMapper.readInt(__in, _lookupTypeInfo("length", "urn:tooling.soap.sforce.com","length","http://www.w3.org/2001/XMLSchema","int",1,1,true), int.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldLength(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("length", "urn:tooling.soap.sforce.com","length","http://www.w3.org/2001/XMLSchema","int",1,1,true), length, length__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : name of type {http://www.w3.org/2001/XMLSchema}string
|
||
|
|
* java type: java.lang.String
|
||
|
|
*/
|
||
|
|
private boolean name__is_set = false;
|
||
|
|
|
||
|
|
private java.lang.String name;
|
||
|
|
|
||
|
|
public java.lang.String getName() {
|
||
|
|
return name;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setName(java.lang.String name) {
|
||
|
|
this.name = name;
|
||
|
|
name__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setName(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("name", "urn:tooling.soap.sforce.com","name","http://www.w3.org/2001/XMLSchema","string",1,1,true))) {
|
||
|
|
setName(__typeMapper.readString(__in, _lookupTypeInfo("name", "urn:tooling.soap.sforce.com","name","http://www.w3.org/2001/XMLSchema","string",1,1,true), java.lang.String.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldName(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("name", "urn:tooling.soap.sforce.com","name","http://www.w3.org/2001/XMLSchema","string",1,1,true), name, name__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : nillable of type {http://www.w3.org/2001/XMLSchema}boolean
|
||
|
|
* java type: boolean
|
||
|
|
*/
|
||
|
|
private boolean nillable__is_set = false;
|
||
|
|
|
||
|
|
private boolean nillable;
|
||
|
|
|
||
|
|
public boolean getNillable() {
|
||
|
|
return nillable;
|
||
|
|
}
|
||
|
|
|
||
|
|
public boolean isNillable() {
|
||
|
|
return nillable;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setNillable(boolean nillable) {
|
||
|
|
this.nillable = nillable;
|
||
|
|
nillable__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setNillable(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("nillable", "urn:tooling.soap.sforce.com","nillable","http://www.w3.org/2001/XMLSchema","boolean",1,1,true))) {
|
||
|
|
setNillable(__typeMapper.readBoolean(__in, _lookupTypeInfo("nillable", "urn:tooling.soap.sforce.com","nillable","http://www.w3.org/2001/XMLSchema","boolean",1,1,true), boolean.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldNillable(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("nillable", "urn:tooling.soap.sforce.com","nillable","http://www.w3.org/2001/XMLSchema","boolean",1,1,true), nillable, nillable__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : precision of type {http://www.w3.org/2001/XMLSchema}int
|
||
|
|
* java type: int
|
||
|
|
*/
|
||
|
|
private boolean precision__is_set = false;
|
||
|
|
|
||
|
|
private int precision;
|
||
|
|
|
||
|
|
public int getPrecision() {
|
||
|
|
return precision;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setPrecision(int precision) {
|
||
|
|
this.precision = precision;
|
||
|
|
precision__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setPrecision(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("precision", "urn:tooling.soap.sforce.com","precision","http://www.w3.org/2001/XMLSchema","int",1,1,true))) {
|
||
|
|
setPrecision((int)__typeMapper.readInt(__in, _lookupTypeInfo("precision", "urn:tooling.soap.sforce.com","precision","http://www.w3.org/2001/XMLSchema","int",1,1,true), int.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldPrecision(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("precision", "urn:tooling.soap.sforce.com","precision","http://www.w3.org/2001/XMLSchema","int",1,1,true), precision, precision__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : scale of type {http://www.w3.org/2001/XMLSchema}int
|
||
|
|
* java type: int
|
||
|
|
*/
|
||
|
|
private boolean scale__is_set = false;
|
||
|
|
|
||
|
|
private int scale;
|
||
|
|
|
||
|
|
public int getScale() {
|
||
|
|
return scale;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setScale(int scale) {
|
||
|
|
this.scale = scale;
|
||
|
|
scale__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setScale(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("scale", "urn:tooling.soap.sforce.com","scale","http://www.w3.org/2001/XMLSchema","int",1,1,true))) {
|
||
|
|
setScale((int)__typeMapper.readInt(__in, _lookupTypeInfo("scale", "urn:tooling.soap.sforce.com","scale","http://www.w3.org/2001/XMLSchema","int",1,1,true), int.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldScale(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("scale", "urn:tooling.soap.sforce.com","scale","http://www.w3.org/2001/XMLSchema","int",1,1,true), scale, scale__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : type of type {http://www.w3.org/2001/XMLSchema}string
|
||
|
|
* java type: java.lang.String
|
||
|
|
*/
|
||
|
|
private boolean type__is_set = false;
|
||
|
|
|
||
|
|
private java.lang.String type;
|
||
|
|
|
||
|
|
public java.lang.String getType() {
|
||
|
|
return type;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setType(java.lang.String type) {
|
||
|
|
this.type = type;
|
||
|
|
type__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setType(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("type", "urn:tooling.soap.sforce.com","type","http://www.w3.org/2001/XMLSchema","string",1,1,true))) {
|
||
|
|
setType(__typeMapper.readString(__in, _lookupTypeInfo("type", "urn:tooling.soap.sforce.com","type","http://www.w3.org/2001/XMLSchema","string",1,1,true), java.lang.String.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldType(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("type", "urn:tooling.soap.sforce.com","type","http://www.w3.org/2001/XMLSchema","string",1,1,true), type, type__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* element : unique of type {http://www.w3.org/2001/XMLSchema}boolean
|
||
|
|
* java type: boolean
|
||
|
|
*/
|
||
|
|
private boolean unique__is_set = false;
|
||
|
|
|
||
|
|
private boolean unique;
|
||
|
|
|
||
|
|
public boolean getUnique() {
|
||
|
|
return unique;
|
||
|
|
}
|
||
|
|
|
||
|
|
public boolean isUnique() {
|
||
|
|
return unique;
|
||
|
|
}
|
||
|
|
|
||
|
|
public void setUnique(boolean unique) {
|
||
|
|
this.unique = unique;
|
||
|
|
unique__is_set = true;
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void setUnique(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__in.peekTag();
|
||
|
|
if (__typeMapper.verifyElement(__in, _lookupTypeInfo("unique", "urn:tooling.soap.sforce.com","unique","http://www.w3.org/2001/XMLSchema","boolean",1,1,true))) {
|
||
|
|
setUnique(__typeMapper.readBoolean(__in, _lookupTypeInfo("unique", "urn:tooling.soap.sforce.com","unique","http://www.w3.org/2001/XMLSchema","boolean",1,1,true), boolean.class));
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFieldUnique(com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
__typeMapper.writeObject(__out, _lookupTypeInfo("unique", "urn:tooling.soap.sforce.com","unique","http://www.w3.org/2001/XMLSchema","boolean",1,1,true), unique, unique__is_set);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
*/
|
||
|
|
@Override
|
||
|
|
public void write(javax.xml.namespace.QName __element,
|
||
|
|
com.sforce.ws.parser.XmlOutputStream __out, com.sforce.ws.bind.TypeMapper __typeMapper)
|
||
|
|
throws java.io.IOException {
|
||
|
|
__out.writeStartTag(__element.getNamespaceURI(), __element.getLocalPart());
|
||
|
|
writeFields(__out, __typeMapper);
|
||
|
|
__out.writeEndTag(__element.getNamespaceURI(), __element.getLocalPart());
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void writeFields(com.sforce.ws.parser.XmlOutputStream __out,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper)
|
||
|
|
throws java.io.IOException {
|
||
|
|
writeFields1(__out, __typeMapper);
|
||
|
|
}
|
||
|
|
|
||
|
|
@Override
|
||
|
|
public void load(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
__typeMapper.consumeStartTag(__in);
|
||
|
|
loadFields(__in, __typeMapper);
|
||
|
|
__typeMapper.consumeEndTag(__in);
|
||
|
|
}
|
||
|
|
|
||
|
|
protected void loadFields(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
loadFields1(__in, __typeMapper);
|
||
|
|
}
|
||
|
|
|
||
|
|
@Override
|
||
|
|
public String toString() {
|
||
|
|
java.lang.StringBuilder sb = new java.lang.StringBuilder();
|
||
|
|
sb.append("[SchemaField ");
|
||
|
|
toString1(sb);
|
||
|
|
|
||
|
|
sb.append("]\n");
|
||
|
|
return sb.toString();
|
||
|
|
}
|
||
|
|
|
||
|
|
private void toStringHelper(StringBuilder sb, String name, Object value) {
|
||
|
|
sb.append(' ').append(name).append("='").append(com.sforce.ws.util.Verbose.toString(value)).append("'\n");
|
||
|
|
}
|
||
|
|
|
||
|
|
private void writeFields1(com.sforce.ws.parser.XmlOutputStream __out,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException {
|
||
|
|
writeFieldDigits(__out, __typeMapper);
|
||
|
|
writeFieldLength(__out, __typeMapper);
|
||
|
|
writeFieldName(__out, __typeMapper);
|
||
|
|
writeFieldNillable(__out, __typeMapper);
|
||
|
|
writeFieldPrecision(__out, __typeMapper);
|
||
|
|
writeFieldScale(__out, __typeMapper);
|
||
|
|
writeFieldType(__out, __typeMapper);
|
||
|
|
writeFieldUnique(__out, __typeMapper);
|
||
|
|
}
|
||
|
|
|
||
|
|
private void loadFields1(com.sforce.ws.parser.XmlInputStream __in,
|
||
|
|
com.sforce.ws.bind.TypeMapper __typeMapper) throws java.io.IOException, com.sforce.ws.ConnectionException {
|
||
|
|
setDigits(__in, __typeMapper);
|
||
|
|
setLength(__in, __typeMapper);
|
||
|
|
setName(__in, __typeMapper);
|
||
|
|
setNillable(__in, __typeMapper);
|
||
|
|
setPrecision(__in, __typeMapper);
|
||
|
|
setScale(__in, __typeMapper);
|
||
|
|
setType(__in, __typeMapper);
|
||
|
|
setUnique(__in, __typeMapper);
|
||
|
|
}
|
||
|
|
|
||
|
|
private void toString1(StringBuilder sb) {
|
||
|
|
toStringHelper(sb, "digits", digits);
|
||
|
|
toStringHelper(sb, "length", length);
|
||
|
|
toStringHelper(sb, "name", name);
|
||
|
|
toStringHelper(sb, "nillable", nillable);
|
||
|
|
toStringHelper(sb, "precision", precision);
|
||
|
|
toStringHelper(sb, "scale", scale);
|
||
|
|
toStringHelper(sb, "type", type);
|
||
|
|
toStringHelper(sb, "unique", unique);
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
}
|