| /*******************************************************************************
|
| * Copyright (c) 2012, 2013 Oracle. All rights reserved.
|
| * This program and the accompanying materials are made available under the
|
| * terms of the Eclipse Public License 2.0, which accompanies this distribution
|
| * and is available at https://www.eclipse.org/legal/epl-2.0/
|
| *
|
| * SPDX-License-Identifier: EPL-2.0
|
| *
|
| * Contributors:
|
| * Oracle - initial API and implementation
|
| *******************************************************************************/ |
| package org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm;
|
|
|
| import java.util.Collection;
|
| import org.eclipse.emf.common.notify.Notification;
|
| import org.eclipse.emf.common.notify.NotificationChain;
|
| import org.eclipse.emf.common.util.EList;
|
| import org.eclipse.emf.ecore.EClass;
|
| import org.eclipse.emf.ecore.InternalEObject;
|
| import org.eclipse.emf.ecore.impl.ENotificationImpl;
|
| import org.eclipse.emf.ecore.util.EObjectContainmentEList;
|
| import org.eclipse.emf.ecore.util.InternalEList;
|
| import org.eclipse.emf.ecore.EObject;
|
| import org.eclipse.emf.ecore.EStructuralFeature;
|
| import org.eclipse.wst.common.internal.emf.resource.Translator;
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * A representation of the model object '<em><b>EXml Elements</b></em>'.
|
| * <!-- end-user-doc -->
|
| *
|
| * <p>
|
| * The following features are supported:
|
| * <ul>
|
| * <li>{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isXmlIdRef <em>Xml Id Ref</em>}</li>
|
| * <li>{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isXmlList <em>Xml List</em>}</li>
|
| * <li>{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getXmlElements <em>Xml Elements</em>}</li>
|
| * <li>{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getXmlElementWrapper <em>Xml Element Wrapper</em>}</li>
|
| * <li>{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getXmlJoinNodes <em>Xml Join Nodes</em>}</li>
|
| * </ul>
|
| * </p>
|
| *
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements()
|
| * @model kind="class"
|
| * @generated
|
| */
|
| public class EXmlElements extends EJavaAttribute implements EAccessibleJavaAttribute, EContainerJavaAttribute, EReadWriteJavaAttribute, EPropertyHolder
|
| {
|
| /**
|
| * The cached value of the '{@link #getXmlAccessMethods() <em>Xml Access Methods</em>}' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getXmlAccessMethods()
|
| * @generated
|
| * @ordered
|
| */
|
| protected EXmlAccessMethods xmlAccessMethods;
|
| /**
|
| * The default value of the '{@link #getContainerType() <em>Container Type</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getContainerType()
|
| * @generated
|
| * @ordered
|
| */
|
| protected static final String CONTAINER_TYPE_EDEFAULT = null;
|
| /**
|
| * The cached value of the '{@link #getContainerType() <em>Container Type</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getContainerType()
|
| * @generated
|
| * @ordered
|
| */
|
| protected String containerType = CONTAINER_TYPE_EDEFAULT;
|
| /**
|
| * The default value of the '{@link #isReadOnly() <em>Read Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isReadOnly()
|
| * @generated
|
| * @ordered
|
| */
|
| protected static final boolean READ_ONLY_EDEFAULT = false;
|
| /**
|
| * The cached value of the '{@link #isReadOnly() <em>Read Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isReadOnly()
|
| * @generated
|
| * @ordered
|
| */
|
| protected boolean readOnly = READ_ONLY_EDEFAULT;
|
| /**
|
| * The default value of the '{@link #isWriteOnly() <em>Write Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isWriteOnly()
|
| * @generated
|
| * @ordered
|
| */
|
| protected static final boolean WRITE_ONLY_EDEFAULT = false;
|
| /**
|
| * The cached value of the '{@link #isWriteOnly() <em>Write Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isWriteOnly()
|
| * @generated
|
| * @ordered
|
| */
|
| protected boolean writeOnly = WRITE_ONLY_EDEFAULT;
|
| /**
|
| * The cached value of the '{@link #getXmlProperties() <em>Xml Properties</em>}' containment reference list.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getXmlProperties()
|
| * @generated
|
| * @ordered
|
| */
|
| protected EList<EXmlProperty> xmlProperties;
|
| /**
|
| * The default value of the '{@link #isXmlIdRef() <em>Xml Id Ref</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isXmlIdRef()
|
| * @generated
|
| * @ordered
|
| */
|
| protected static final boolean XML_ID_REF_EDEFAULT = false;
|
| /**
|
| * The cached value of the '{@link #isXmlIdRef() <em>Xml Id Ref</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isXmlIdRef()
|
| * @generated
|
| * @ordered
|
| */
|
| protected boolean xmlIdRef = XML_ID_REF_EDEFAULT;
|
| /**
|
| * The default value of the '{@link #isXmlList() <em>Xml List</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isXmlList()
|
| * @generated
|
| * @ordered
|
| */
|
| protected static final boolean XML_LIST_EDEFAULT = false;
|
| /**
|
| * The cached value of the '{@link #isXmlList() <em>Xml List</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #isXmlList()
|
| * @generated
|
| * @ordered
|
| */
|
| protected boolean xmlList = XML_LIST_EDEFAULT;
|
| /**
|
| * The cached value of the '{@link #getXmlElements() <em>Xml Elements</em>}' containment reference list.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getXmlElements()
|
| * @generated
|
| * @ordered
|
| */
|
| protected EList<EXmlElement> xmlElements;
|
| /**
|
| * The cached value of the '{@link #getXmlElementWrapper() <em>Xml Element Wrapper</em>}' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getXmlElementWrapper()
|
| * @generated
|
| * @ordered
|
| */
|
| protected EXmlElementWrapper xmlElementWrapper;
|
| /**
|
| * The cached value of the '{@link #getXmlJoinNodes() <em>Xml Join Nodes</em>}' containment reference list.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @see #getXmlJoinNodes()
|
| * @generated
|
| * @ordered
|
| */
|
| protected EList<EXmlJoinNodes> xmlJoinNodes;
|
|
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| protected EXmlElements()
|
| {
|
| super();
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| protected EClass eStaticClass()
|
| {
|
| return OxmPackage.Literals.EXML_ELEMENTS;
|
| }
|
|
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Access Methods</b></em>' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Access Methods</em>' containment reference isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Access Methods</em>' containment reference.
|
| * @see #setXmlAccessMethods(EXmlAccessMethods)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEAccessibleJavaAttribute_XmlAccessMethods()
|
| * @model containment="true"
|
| * @generated
|
| */
|
| public EXmlAccessMethods getXmlAccessMethods()
|
| {
|
| return xmlAccessMethods;
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| public NotificationChain basicSetXmlAccessMethods(EXmlAccessMethods newXmlAccessMethods, NotificationChain msgs)
|
| {
|
| EXmlAccessMethods oldXmlAccessMethods = xmlAccessMethods;
|
| xmlAccessMethods = newXmlAccessMethods;
|
| if (eNotificationRequired())
|
| {
|
| ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS, oldXmlAccessMethods, newXmlAccessMethods);
|
| if (msgs == null) msgs = notification; else msgs.add(notification);
|
| }
|
| return msgs;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getXmlAccessMethods <em>Xml Access Methods</em>}' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Xml Access Methods</em>' containment reference.
|
| * @see #getXmlAccessMethods()
|
| * @generated
|
| */
|
| public void setXmlAccessMethods(EXmlAccessMethods newXmlAccessMethods)
|
| {
|
| if (newXmlAccessMethods != xmlAccessMethods)
|
| {
|
| NotificationChain msgs = null;
|
| if (xmlAccessMethods != null)
|
| msgs = ((InternalEObject)xmlAccessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS, null, msgs);
|
| if (newXmlAccessMethods != null)
|
| msgs = ((InternalEObject)newXmlAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS, null, msgs);
|
| msgs = basicSetXmlAccessMethods(newXmlAccessMethods, msgs);
|
| if (msgs != null) msgs.dispatch();
|
| }
|
| else if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS, newXmlAccessMethods, newXmlAccessMethods));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Container Type</b></em>' attribute.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Container Type</em>' attribute isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Container Type</em>' attribute.
|
| * @see #setContainerType(String)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEContainerJavaAttribute_ContainerType()
|
| * @model
|
| * @generated
|
| */
|
| public String getContainerType()
|
| {
|
| return containerType;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getContainerType <em>Container Type</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Container Type</em>' attribute.
|
| * @see #getContainerType()
|
| * @generated
|
| */
|
| public void setContainerType(String newContainerType)
|
| {
|
| String oldContainerType = containerType;
|
| containerType = newContainerType;
|
| if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE, oldContainerType, containerType));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Read Only</b></em>' attribute.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Read Only</em>' attribute isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Read Only</em>' attribute.
|
| * @see #setReadOnly(boolean)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEReadWriteJavaAttribute_ReadOnly()
|
| * @model
|
| * @generated
|
| */
|
| public boolean isReadOnly()
|
| {
|
| return readOnly;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isReadOnly <em>Read Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Read Only</em>' attribute.
|
| * @see #isReadOnly()
|
| * @generated
|
| */
|
| public void setReadOnly(boolean newReadOnly)
|
| {
|
| boolean oldReadOnly = readOnly;
|
| readOnly = newReadOnly;
|
| if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__READ_ONLY, oldReadOnly, readOnly));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Write Only</b></em>' attribute.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Write Only</em>' attribute isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Write Only</em>' attribute.
|
| * @see #setWriteOnly(boolean)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEReadWriteJavaAttribute_WriteOnly()
|
| * @model
|
| * @generated
|
| */
|
| public boolean isWriteOnly()
|
| {
|
| return writeOnly;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isWriteOnly <em>Write Only</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Write Only</em>' attribute.
|
| * @see #isWriteOnly()
|
| * @generated
|
| */
|
| public void setWriteOnly(boolean newWriteOnly)
|
| {
|
| boolean oldWriteOnly = writeOnly;
|
| writeOnly = newWriteOnly;
|
| if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__WRITE_ONLY, oldWriteOnly, writeOnly));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Properties</b></em>' containment reference list.
|
| * The list contents are of type {@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlProperty}.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Properties</em>' containment reference list isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Properties</em>' containment reference list.
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEPropertyHolder_XmlProperties()
|
| * @model containment="true"
|
| * @generated
|
| */
|
| public EList<EXmlProperty> getXmlProperties()
|
| {
|
| if (xmlProperties == null)
|
| {
|
| xmlProperties = new EObjectContainmentEList<EXmlProperty>(EXmlProperty.class, this, OxmPackage.EXML_ELEMENTS__XML_PROPERTIES);
|
| }
|
| return xmlProperties;
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Id Ref</b></em>' attribute.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Id Ref</em>' attribute isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Id Ref</em>' attribute.
|
| * @see #setXmlIdRef(boolean)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements_XmlIdRef()
|
| * @model
|
| * @generated
|
| */
|
| public boolean isXmlIdRef()
|
| {
|
| return xmlIdRef;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isXmlIdRef <em>Xml Id Ref</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Xml Id Ref</em>' attribute.
|
| * @see #isXmlIdRef()
|
| * @generated
|
| */
|
| public void setXmlIdRef(boolean newXmlIdRef)
|
| {
|
| boolean oldXmlIdRef = xmlIdRef;
|
| xmlIdRef = newXmlIdRef;
|
| if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_ID_REF, oldXmlIdRef, xmlIdRef));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml List</b></em>' attribute.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml List</em>' attribute isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml List</em>' attribute.
|
| * @see #setXmlList(boolean)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements_XmlList()
|
| * @model
|
| * @generated
|
| */
|
| public boolean isXmlList()
|
| {
|
| return xmlList;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#isXmlList <em>Xml List</em>}' attribute.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Xml List</em>' attribute.
|
| * @see #isXmlList()
|
| * @generated
|
| */
|
| public void setXmlList(boolean newXmlList)
|
| {
|
| boolean oldXmlList = xmlList;
|
| xmlList = newXmlList;
|
| if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_LIST, oldXmlList, xmlList));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Elements</b></em>' containment reference list.
|
| * The list contents are of type {@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElement}.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Elements</em>' containment reference list isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Elements</em>' containment reference list.
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements_XmlElements()
|
| * @model containment="true"
|
| * @generated
|
| */
|
| public EList<EXmlElement> getXmlElements()
|
| {
|
| if (xmlElements == null)
|
| {
|
| xmlElements = new EObjectContainmentEList<EXmlElement>(EXmlElement.class, this, OxmPackage.EXML_ELEMENTS__XML_ELEMENTS);
|
| }
|
| return xmlElements;
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Element Wrapper</b></em>' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Element Wrapper</em>' containment reference isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Element Wrapper</em>' containment reference.
|
| * @see #setXmlElementWrapper(EXmlElementWrapper)
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements_XmlElementWrapper()
|
| * @model containment="true"
|
| * @generated
|
| */
|
| public EXmlElementWrapper getXmlElementWrapper()
|
| {
|
| return xmlElementWrapper;
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| public NotificationChain basicSetXmlElementWrapper(EXmlElementWrapper newXmlElementWrapper, NotificationChain msgs)
|
| {
|
| EXmlElementWrapper oldXmlElementWrapper = xmlElementWrapper;
|
| xmlElementWrapper = newXmlElementWrapper;
|
| if (eNotificationRequired())
|
| {
|
| ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER, oldXmlElementWrapper, newXmlElementWrapper);
|
| if (msgs == null) msgs = notification; else msgs.add(notification);
|
| }
|
| return msgs;
|
| }
|
|
|
| /**
|
| * Sets the value of the '{@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlElements#getXmlElementWrapper <em>Xml Element Wrapper</em>}' containment reference.
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @param value the new value of the '<em>Xml Element Wrapper</em>' containment reference.
|
| * @see #getXmlElementWrapper()
|
| * @generated
|
| */
|
| public void setXmlElementWrapper(EXmlElementWrapper newXmlElementWrapper)
|
| {
|
| if (newXmlElementWrapper != xmlElementWrapper)
|
| {
|
| NotificationChain msgs = null;
|
| if (xmlElementWrapper != null)
|
| msgs = ((InternalEObject)xmlElementWrapper).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER, null, msgs);
|
| if (newXmlElementWrapper != null)
|
| msgs = ((InternalEObject)newXmlElementWrapper).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER, null, msgs);
|
| msgs = basicSetXmlElementWrapper(newXmlElementWrapper, msgs);
|
| if (msgs != null) msgs.dispatch();
|
| }
|
| else if (eNotificationRequired())
|
| eNotify(new ENotificationImpl(this, Notification.SET, OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER, newXmlElementWrapper, newXmlElementWrapper));
|
| }
|
|
|
| /**
|
| * Returns the value of the '<em><b>Xml Join Nodes</b></em>' containment reference list.
|
| * The list contents are of type {@link org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.EXmlJoinNodes}.
|
| * <!-- begin-user-doc -->
|
| * <p>
|
| * If the meaning of the '<em>Xml Join Nodes</em>' containment reference list isn't clear,
|
| * there really should be more of a description here...
|
| * </p>
|
| * <!-- end-user-doc -->
|
| * @return the value of the '<em>Xml Join Nodes</em>' containment reference list.
|
| * @see org.eclipse.jpt.jaxb.eclipselink.core.resource.oxm.OxmPackage#getEXmlElements_XmlJoinNodes()
|
| * @model containment="true"
|
| * @generated
|
| */
|
| public EList<EXmlJoinNodes> getXmlJoinNodes()
|
| {
|
| if (xmlJoinNodes == null)
|
| {
|
| xmlJoinNodes = new EObjectContainmentEList<EXmlJoinNodes>(EXmlJoinNodes.class, this, OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES);
|
| }
|
| return xmlJoinNodes;
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
|
| {
|
| switch (featureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS:
|
| return basicSetXmlAccessMethods(null, msgs);
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES:
|
| return ((InternalEList<?>)getXmlProperties()).basicRemove(otherEnd, msgs);
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENTS:
|
| return ((InternalEList<?>)getXmlElements()).basicRemove(otherEnd, msgs);
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER:
|
| return basicSetXmlElementWrapper(null, msgs);
|
| case OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES:
|
| return ((InternalEList<?>)getXmlJoinNodes()).basicRemove(otherEnd, msgs);
|
| }
|
| return super.eInverseRemove(otherEnd, featureID, msgs);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public Object eGet(int featureID, boolean resolve, boolean coreType)
|
| {
|
| switch (featureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS:
|
| return getXmlAccessMethods();
|
| case OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE:
|
| return getContainerType();
|
| case OxmPackage.EXML_ELEMENTS__READ_ONLY:
|
| return isReadOnly();
|
| case OxmPackage.EXML_ELEMENTS__WRITE_ONLY:
|
| return isWriteOnly();
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES:
|
| return getXmlProperties();
|
| case OxmPackage.EXML_ELEMENTS__XML_ID_REF:
|
| return isXmlIdRef();
|
| case OxmPackage.EXML_ELEMENTS__XML_LIST:
|
| return isXmlList();
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENTS:
|
| return getXmlElements();
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER:
|
| return getXmlElementWrapper();
|
| case OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES:
|
| return getXmlJoinNodes();
|
| }
|
| return super.eGet(featureID, resolve, coreType);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @SuppressWarnings("unchecked")
|
| @Override
|
| public void eSet(int featureID, Object newValue)
|
| {
|
| switch (featureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS:
|
| setXmlAccessMethods((EXmlAccessMethods)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE:
|
| setContainerType((String)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__READ_ONLY:
|
| setReadOnly((Boolean)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__WRITE_ONLY:
|
| setWriteOnly((Boolean)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES:
|
| getXmlProperties().clear();
|
| getXmlProperties().addAll((Collection<? extends EXmlProperty>)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ID_REF:
|
| setXmlIdRef((Boolean)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_LIST:
|
| setXmlList((Boolean)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENTS:
|
| getXmlElements().clear();
|
| getXmlElements().addAll((Collection<? extends EXmlElement>)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER:
|
| setXmlElementWrapper((EXmlElementWrapper)newValue);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES:
|
| getXmlJoinNodes().clear();
|
| getXmlJoinNodes().addAll((Collection<? extends EXmlJoinNodes>)newValue);
|
| return;
|
| }
|
| super.eSet(featureID, newValue);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public void eUnset(int featureID)
|
| {
|
| switch (featureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS:
|
| setXmlAccessMethods((EXmlAccessMethods)null);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE:
|
| setContainerType(CONTAINER_TYPE_EDEFAULT);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__READ_ONLY:
|
| setReadOnly(READ_ONLY_EDEFAULT);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__WRITE_ONLY:
|
| setWriteOnly(WRITE_ONLY_EDEFAULT);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES:
|
| getXmlProperties().clear();
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ID_REF:
|
| setXmlIdRef(XML_ID_REF_EDEFAULT);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_LIST:
|
| setXmlList(XML_LIST_EDEFAULT);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENTS:
|
| getXmlElements().clear();
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER:
|
| setXmlElementWrapper((EXmlElementWrapper)null);
|
| return;
|
| case OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES:
|
| getXmlJoinNodes().clear();
|
| return;
|
| }
|
| super.eUnset(featureID);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public boolean eIsSet(int featureID)
|
| {
|
| switch (featureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS:
|
| return xmlAccessMethods != null;
|
| case OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE:
|
| return CONTAINER_TYPE_EDEFAULT == null ? containerType != null : !CONTAINER_TYPE_EDEFAULT.equals(containerType);
|
| case OxmPackage.EXML_ELEMENTS__READ_ONLY:
|
| return readOnly != READ_ONLY_EDEFAULT;
|
| case OxmPackage.EXML_ELEMENTS__WRITE_ONLY:
|
| return writeOnly != WRITE_ONLY_EDEFAULT;
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES:
|
| return xmlProperties != null && !xmlProperties.isEmpty();
|
| case OxmPackage.EXML_ELEMENTS__XML_ID_REF:
|
| return xmlIdRef != XML_ID_REF_EDEFAULT;
|
| case OxmPackage.EXML_ELEMENTS__XML_LIST:
|
| return xmlList != XML_LIST_EDEFAULT;
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENTS:
|
| return xmlElements != null && !xmlElements.isEmpty();
|
| case OxmPackage.EXML_ELEMENTS__XML_ELEMENT_WRAPPER:
|
| return xmlElementWrapper != null;
|
| case OxmPackage.EXML_ELEMENTS__XML_JOIN_NODES:
|
| return xmlJoinNodes != null && !xmlJoinNodes.isEmpty();
|
| }
|
| return super.eIsSet(featureID);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass)
|
| {
|
| if (baseClass == EAccessibleJavaAttribute.class)
|
| {
|
| switch (derivedFeatureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS: return OxmPackage.EACCESSIBLE_JAVA_ATTRIBUTE__XML_ACCESS_METHODS;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EContainerJavaAttribute.class)
|
| {
|
| switch (derivedFeatureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE: return OxmPackage.ECONTAINER_JAVA_ATTRIBUTE__CONTAINER_TYPE;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EReadWriteJavaAttribute.class)
|
| {
|
| switch (derivedFeatureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__READ_ONLY: return OxmPackage.EREAD_WRITE_JAVA_ATTRIBUTE__READ_ONLY;
|
| case OxmPackage.EXML_ELEMENTS__WRITE_ONLY: return OxmPackage.EREAD_WRITE_JAVA_ATTRIBUTE__WRITE_ONLY;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EPropertyHolder.class)
|
| {
|
| switch (derivedFeatureID)
|
| {
|
| case OxmPackage.EXML_ELEMENTS__XML_PROPERTIES: return OxmPackage.EPROPERTY_HOLDER__XML_PROPERTIES;
|
| default: return -1;
|
| }
|
| }
|
| return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public int eDerivedStructuralFeatureID(int baseFeatureID, Class<?> baseClass)
|
| {
|
| if (baseClass == EAccessibleJavaAttribute.class)
|
| {
|
| switch (baseFeatureID)
|
| {
|
| case OxmPackage.EACCESSIBLE_JAVA_ATTRIBUTE__XML_ACCESS_METHODS: return OxmPackage.EXML_ELEMENTS__XML_ACCESS_METHODS;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EContainerJavaAttribute.class)
|
| {
|
| switch (baseFeatureID)
|
| {
|
| case OxmPackage.ECONTAINER_JAVA_ATTRIBUTE__CONTAINER_TYPE: return OxmPackage.EXML_ELEMENTS__CONTAINER_TYPE;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EReadWriteJavaAttribute.class)
|
| {
|
| switch (baseFeatureID)
|
| {
|
| case OxmPackage.EREAD_WRITE_JAVA_ATTRIBUTE__READ_ONLY: return OxmPackage.EXML_ELEMENTS__READ_ONLY;
|
| case OxmPackage.EREAD_WRITE_JAVA_ATTRIBUTE__WRITE_ONLY: return OxmPackage.EXML_ELEMENTS__WRITE_ONLY;
|
| default: return -1;
|
| }
|
| }
|
| if (baseClass == EPropertyHolder.class)
|
| {
|
| switch (baseFeatureID)
|
| {
|
| case OxmPackage.EPROPERTY_HOLDER__XML_PROPERTIES: return OxmPackage.EXML_ELEMENTS__XML_PROPERTIES;
|
| default: return -1;
|
| }
|
| }
|
| return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass);
|
| }
|
|
|
| /**
|
| * <!-- begin-user-doc -->
|
| * <!-- end-user-doc -->
|
| * @generated
|
| */
|
| @Override
|
| public String toString()
|
| {
|
| if (eIsProxy()) return super.toString();
|
|
|
| StringBuffer result = new StringBuffer(super.toString());
|
| result.append(" (containerType: ");
|
| result.append(containerType);
|
| result.append(", readOnly: ");
|
| result.append(readOnly);
|
| result.append(", writeOnly: ");
|
| result.append(writeOnly);
|
| result.append(", xmlIdRef: ");
|
| result.append(xmlIdRef);
|
| result.append(", xmlList: ");
|
| result.append(xmlList);
|
| result.append(')');
|
| return result.toString();
|
| }
|
|
|
|
|
| // ***** misc *****
|
|
|
| @Override
|
| public String getElementName() {
|
| return Oxm.XML_ELEMENTS;
|
| }
|
|
|
|
|
| // ***** translators *****
|
|
|
| static class XmlElementsTranslator
|
| extends AbstractJavaAttributeTranslator {
|
|
|
| XmlElementsTranslator(String domPathAndName, EStructuralFeature eStructuralFeature) {
|
| super(domPathAndName, eStructuralFeature, buildTranslatorChildren());
|
| }
|
|
|
| private static Translator[] buildTranslatorChildren() {
|
| return new Translator[] {
|
| buildJavaAttributeTranslator(),
|
| buildXmlAccessorTypeTranslator()
|
| };
|
| }
|
|
|
| @Override
|
| public EObject createEMFObject(String nodeName, String readAheadName) {
|
| return OxmFactory.eINSTANCE.createEXmlElements();
|
| }
|
| }
|
| }
|