All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.dmg.pmml.ChildParent Maven / Gradle / Ivy

There is a newer version: 1.6.5
Show newest version

package org.dmg.pmml;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlEnum;
import javax.xml.bind.annotation.XmlEnumValue;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlTransient;
import javax.xml.bind.annotation.XmlType;
import com.sun.xml.bind.Locatable;
import com.sun.xml.bind.annotation.XmlLocation;
import org.jpmml.schema.Added;
import org.jpmml.schema.Version;
import org.xml.sax.Locator;


/**
 * 

Java class for anonymous complex type. * *

The following schema fragment specifies the expected content contained within this class. * *

 * <complexType>
 *   <complexContent>
 *     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
 *       <sequence>
 *         <element ref="{http://www.dmg.org/PMML-4_2}Extension" maxOccurs="unbounded" minOccurs="0"/>
 *         <element ref="{http://www.dmg.org/PMML-4_2}FieldColumnPair" maxOccurs="unbounded" minOccurs="0"/>
 *         <choice>
 *           <element ref="{http://www.dmg.org/PMML-4_2}TableLocator"/>
 *           <element ref="{http://www.dmg.org/PMML-4_2}InlineTable"/>
 *         </choice>
 *       </sequence>
 *       <attribute name="childField" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
 *       <attribute name="parentField" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
 *       <attribute name="parentLevelField" type="{http://www.w3.org/2001/XMLSchema}string" />
 *       <attribute name="isRecursive" default="no">
 *         <simpleType>
 *           <restriction base="{http://www.w3.org/2001/XMLSchema}string">
 *             <enumeration value="no"/>
 *             <enumeration value="yes"/>
 *           </restriction>
 *         </simpleType>
 *       </attribute>
 *     </restriction>
 *   </complexContent>
 * </complexType>
 * 
* * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "extensions", "fieldColumnPairs", "tableLocator", "inlineTable" }) @XmlRootElement(name = "ChildParent") public class ChildParent extends PMMLObject implements Locatable, HasExtensions { @XmlElement(name = "Extension") protected List extensions; @XmlElement(name = "FieldColumnPair") @Added(Version.PMML_4_2) protected List fieldColumnPairs; @XmlElement(name = "TableLocator") protected TableLocator tableLocator; @XmlElement(name = "InlineTable") protected InlineTable inlineTable; @XmlAttribute(name = "childField", required = true) protected String childField; @XmlAttribute(name = "parentField", required = true) protected String parentField; @XmlAttribute(name = "parentLevelField") protected String parentLevelField; @XmlAttribute(name = "isRecursive") protected ChildParent.Recursive recursive; @XmlLocation @XmlTransient protected Locator locator; public ChildParent() { super(); } public ChildParent(final String childField, final String parentField) { super(); this.childField = childField; this.parentField = parentField; } /** * Gets the value of the extensions property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the extensions property. * *

* For example, to add a new item, do as follows: *

     *    getExtensions().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link Extension } * * */ public List getExtensions() { if (extensions == null) { extensions = new ArrayList(); } return this.extensions; } /** * Gets the value of the fieldColumnPairs property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the fieldColumnPairs property. * *

* For example, to add a new item, do as follows: *

     *    getFieldColumnPairs().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link FieldColumnPair } * * */ public List getFieldColumnPairs() { if (fieldColumnPairs == null) { fieldColumnPairs = new ArrayList(); } return this.fieldColumnPairs; } /** * Gets the value of the tableLocator property. * * @return * possible object is * {@link TableLocator } * */ public TableLocator getTableLocator() { return tableLocator; } /** * Sets the value of the tableLocator property. * * @param value * allowed object is * {@link TableLocator } * */ public void setTableLocator(TableLocator value) { this.tableLocator = value; } /** * Gets the value of the inlineTable property. * * @return * possible object is * {@link InlineTable } * */ public InlineTable getInlineTable() { return inlineTable; } /** * Sets the value of the inlineTable property. * * @param value * allowed object is * {@link InlineTable } * */ public void setInlineTable(InlineTable value) { this.inlineTable = value; } /** * Gets the value of the childField property. * * @return * possible object is * {@link String } * */ public String getChildField() { return childField; } /** * Sets the value of the childField property. * * @param value * allowed object is * {@link String } * */ public void setChildField(String value) { this.childField = value; } /** * Gets the value of the parentField property. * * @return * possible object is * {@link String } * */ public String getParentField() { return parentField; } /** * Sets the value of the parentField property. * * @param value * allowed object is * {@link String } * */ public void setParentField(String value) { this.parentField = value; } /** * Gets the value of the parentLevelField property. * * @return * possible object is * {@link String } * */ public String getParentLevelField() { return parentLevelField; } /** * Sets the value of the parentLevelField property. * * @param value * allowed object is * {@link String } * */ public void setParentLevelField(String value) { this.parentLevelField = value; } /** * Gets the value of the recursive property. * * @return * possible object is * {@link ChildParent.Recursive } * */ public ChildParent.Recursive getRecursive() { if (recursive == null) { return ChildParent.Recursive.NO; } else { return recursive; } } /** * Sets the value of the recursive property. * * @param value * allowed object is * {@link ChildParent.Recursive } * */ public void setRecursive(ChildParent.Recursive value) { this.recursive = value; } public ChildParent withExtensions(Extension... values) { if (values!= null) { for (Extension value: values) { getExtensions().add(value); } } return this; } public ChildParent withExtensions(Collection values) { if (values!= null) { getExtensions().addAll(values); } return this; } public ChildParent withFieldColumnPairs(FieldColumnPair... values) { if (values!= null) { for (FieldColumnPair value: values) { getFieldColumnPairs().add(value); } } return this; } public ChildParent withFieldColumnPairs(Collection values) { if (values!= null) { getFieldColumnPairs().addAll(values); } return this; } public ChildParent withTableLocator(TableLocator value) { setTableLocator(value); return this; } public ChildParent withInlineTable(InlineTable value) { setInlineTable(value); return this; } public ChildParent withChildField(String value) { setChildField(value); return this; } public ChildParent withParentField(String value) { setParentField(value); return this; } public ChildParent withParentLevelField(String value) { setParentLevelField(value); return this; } public ChildParent withRecursive(ChildParent.Recursive value) { setRecursive(value); return this; } public Locator sourceLocation() { return locator; } public void setSourceLocation(Locator newLocator) { locator = newLocator; } @Override public VisitorAction accept(Visitor visitor) { VisitorAction status = visitor.visit(this); for (int i = 0; (((status == VisitorAction.CONTINUE)&&(this.extensions!= null))&&(iJava class for null. * *

The following schema fragment specifies the expected content contained within this class. *

*

     * <simpleType>
     *   <restriction base="{http://www.w3.org/2001/XMLSchema}string">
     *     <enumeration value="no"/>
     *     <enumeration value="yes"/>
     *   </restriction>
     * </simpleType>
     * 
* */ @XmlType(name = "") @XmlEnum public enum Recursive { @XmlEnumValue("no") NO("no"), @XmlEnumValue("yes") YES("yes"); private final String value; Recursive(String v) { value = v; } public String value() { return value; } public static ChildParent.Recursive fromValue(String v) { for (ChildParent.Recursive c: ChildParent.Recursive.values()) { if (c.value.equals(v)) { return c; } } throw new IllegalArgumentException(v); } } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy