diff options
author | nhauge | 2009-01-30 02:19:01 +0000 |
---|---|---|
committer | nhauge | 2009-01-30 02:19:01 +0000 |
commit | 44bd7d42ec0741804c42a036020d8b6d9bdb0c70 (patch) | |
tree | 8daa9a9fd74797fd7a572217fd43d383b5bd4582 /jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org | |
parent | 53de0728457402049c170f5f1113fd392bd651cd (diff) | |
download | webtools.dali-44bd7d42ec0741804c42a036020d8b6d9bdb0c70.tar.gz webtools.dali-44bd7d42ec0741804c42a036020d8b6d9bdb0c70.tar.xz webtools.dali-44bd7d42ec0741804c42a036020d8b6d9bdb0c70.zip |
This commit was manufactured by cvs2svn to create tag 'v200901290000'.v200901290000
Diffstat (limited to 'jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org')
370 files changed, 0 insertions, 60986 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/EclipseLinkMappingKeys.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/EclipseLinkMappingKeys.java deleted file mode 100644 index 68e3a96e1e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/EclipseLinkMappingKeys.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - */ -@SuppressWarnings("nls") -public interface EclipseLinkMappingKeys { - - String BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY = "basicCollection"; - String BASIC_MAP_ATTRIBUTE_MAPPING_KEY = "basicMap"; - String TRANSFORMATION_ATTRIBUTE_MAPPING_KEY = "transformation"; - String VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY = "variableOneToOne"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicCollectionMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicCollectionMapping.java deleted file mode 100644 index e396ef0d7c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicCollectionMapping.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.AttributeMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface BasicCollectionMapping extends AttributeMapping -{ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicMapMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicMapMapping.java deleted file mode 100644 index f9a37b3d73..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/BasicMapMapping.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.AttributeMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface BasicMapMapping extends AttributeMapping -{ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheCoordinationType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheCoordinationType.java deleted file mode 100644 index 33bb3c8391..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheCoordinationType.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum CacheCoordinationType { - - SEND_OBJECT_CHANGES, - INVALIDATE_CHANGED_OBJECTS, - SEND_NEW_OBJECTS_WITH_CHANGES, - NONE; - - - public static CacheCoordinationType fromJavaResourceModel(org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType javaCacheCoordinationType) { - if (javaCacheCoordinationType == null) { - return null; - } - switch (javaCacheCoordinationType) { - case SEND_OBJECT_CHANGES: - return SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS: - return INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES: - return SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE: - return NONE; - default: - throw new IllegalArgumentException("unknown cache coordination type: " + javaCacheCoordinationType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType toJavaResourceModel(CacheCoordinationType cacheCoordinationType) { - if (cacheCoordinationType == null) { - return null; - } - switch (cacheCoordinationType) { - case SEND_OBJECT_CHANGES: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType.SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType.INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType.SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType.NONE; - default: - throw new IllegalArgumentException("unknown cache coordination type: " + cacheCoordinationType); //$NON-NLS-1$ - } - } - - - public static CacheCoordinationType fromOrmResourceModel(org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType ormCacheCoordinationType) { - if (ormCacheCoordinationType == null) { - return null; - } - switch (ormCacheCoordinationType) { - case SEND_OBJECT_CHANGES: - return SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS: - return INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES: - return SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE: - return NONE; - default: - throw new IllegalArgumentException("unknown cache coordination type: " + ormCacheCoordinationType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType toOrmResourceModel(CacheCoordinationType cacheCoordinationType) { - if (cacheCoordinationType == null) { - return null; - } - switch (cacheCoordinationType) { - case SEND_OBJECT_CHANGES: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType.SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType.INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType.SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType.NONE; - default: - throw new IllegalArgumentException("unknown cache coordination type: " + cacheCoordinationType); //$NON-NLS-1$ - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheType.java deleted file mode 100644 index ade7450182..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CacheType.java +++ /dev/null @@ -1,133 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum CacheType { - - SOFT_WEAK, - HARD_WEAK, - WEAK, - SOFT, - FULL, - CACHE, - NONE; - - - public static CacheType fromJavaResourceModel(org.eclipse.jpt.eclipselink.core.resource.java.CacheType javaCacheType) { - if (javaCacheType == null) { - return null; - } - switch (javaCacheType) { - case FULL: - return FULL; - case WEAK: - return WEAK; - case SOFT: - return SOFT; - case SOFT_WEAK: - return SOFT_WEAK; - case HARD_WEAK: - return HARD_WEAK; - case CACHE: - return CACHE; - case NONE: - return NONE; - default: - throw new IllegalArgumentException("unknown cache type: " + javaCacheType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.java.CacheType toJavaResourceModel(CacheType cacheType) { - if (cacheType == null) { - return null; - } - switch (cacheType) { - case FULL: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.FULL; - case WEAK: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.WEAK; - case SOFT: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.SOFT; - case SOFT_WEAK: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.SOFT_WEAK; - case HARD_WEAK: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.HARD_WEAK; - case CACHE: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.CACHE; - case NONE: - return org.eclipse.jpt.eclipselink.core.resource.java.CacheType.NONE; - default: - throw new IllegalArgumentException("unknown cache type: " + cacheType); //$NON-NLS-1$ - } - } - - - public static CacheType fromOrmResourceModel(org.eclipse.jpt.eclipselink.core.resource.orm.CacheType ormCacheType) { - if (ormCacheType == null) { - return null; - } - switch (ormCacheType) { - case FULL: - return FULL; - case WEAK: - return WEAK; - case SOFT: - return SOFT; - case SOFT_WEAK: - return SOFT_WEAK; - case HARD_WEAK: - return HARD_WEAK; - case CACHE: - return CACHE; - case NONE: - return NONE; - default: - throw new IllegalArgumentException("unknown cache type: " + ormCacheType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.orm.CacheType toOrmResourceModel(CacheType cacheType) { - if (cacheType == null) { - return null; - } - switch (cacheType) { - case FULL: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.FULL; - case WEAK: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.WEAK; - case SOFT: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.SOFT; - case SOFT_WEAK: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.SOFT_WEAK; - case HARD_WEAK: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.HARD_WEAK; - case CACHE: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.CACHE; - case NONE: - return org.eclipse.jpt.eclipselink.core.resource.orm.CacheType.NONE; - default: - throw new IllegalArgumentException("unknown cache type: " + cacheType); //$NON-NLS-1$ - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Caching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Caching.java deleted file mode 100644 index 5f9ab68768..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Caching.java +++ /dev/null @@ -1,205 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface Caching extends JpaContextNode -{ - //***************** shared ************************ - - /** - * This is the combination of defaultShared and specifiedShared. - * If getSpecifiedShared() returns null, then return isDefaultShared() - */ - boolean isShared(); - - boolean isDefaultShared(); - String DEFAULT_SHARED_PROPERTY = "defaultSharedProperty"; //$NON-NLS-1$ - boolean DEFAULT_SHARED = true; - - Boolean getSpecifiedShared(); - - /** - * Setting this to false means that cacheType, cacheSize, alwaysRefresh, - * refreshOnlyIfNewer, disableHits, cacheCoordinationType will all be set - * to their default states. These settings do not apply to a cache that is not shared - * @param newSpecifiedShared - */ - void setSpecifiedShared(Boolean newSpecifiedShared); - String SPECIFIED_SHARED_PROPERTY = "specifiedSharedProperty"; //$NON-NLS-1$ - - - //***************** cache type ************************ - - /** - * This is the combination of defaultType and specifiedType. - * If getSpecifiedType() returns null, then return getDefaultType() - */ - CacheType getType(); - - CacheType getDefaultType(); - String DEFAULT_TYPE_PROPERTY = "defaultTypeProperty"; //$NON-NLS-1$ - CacheType DEFAULT_TYPE = CacheType.SOFT_WEAK; - - CacheType getSpecifiedType(); - void setSpecifiedType(CacheType newSpecifiedType); - String SPECIFIED_TYPE_PROPERTY = "specifiedTypeProperty"; //$NON-NLS-1$ - - - //***************** size ************************ - - /** - * This is the combination of defaultSize and specifiedSize. - * If getSpecifiedSize() returns null, then return getDefaultSize() - */ - int getSize(); - - int getDefaultSize(); - int DEFAULT_SIZE = 100; - String DEFAULT_SIZE_PROPERTY = "defaultSizeProperty"; //$NON-NLS-1$ - - Integer getSpecifiedSize(); - void setSpecifiedSize(Integer newSpecifiedSize); - String SPECIFIED_SIZE_PROPERTY = "spcifiedSizeProperty"; //$NON-NLS-1$ - - //***************** always refresh ************************ - - /** - * This is the combination of defaultAlwaysRefresh and specifiedAlwaysRefresh. - * If getSpecifiedAlwaysRefresh() returns null, then return isDefaultAlwaysRefresh() - */ - boolean isAlwaysRefresh(); - - boolean isDefaultAlwaysRefresh(); - String DEFAULT_ALWAYS_REFRESH_PROPERTY = "defaultAlwaysRefreshProperty"; //$NON-NLS-1$ - boolean DEFAULT_ALWAYS_REFRESH = false; - - Boolean getSpecifiedAlwaysRefresh(); - void setSpecifiedAlwaysRefresh(Boolean newSpecifiedAlwaysRefresh); - String SPECIFIED_ALWAYS_REFRESH_PROPERTY = "specifiedAlwaysRefreshProperty"; //$NON-NLS-1$ - - - //***************** refresh only if newer ************************ - - /** - * This is the combination of defaultRefreshOnlyIfNewer and specifiedRefreshOnlyIfNewer. - * If getSpecifiedRefreshOnlyIfNewer() returns null, then return isDefaultRefreshOnlyIfNewer() - */ - boolean isRefreshOnlyIfNewer(); - - boolean isDefaultRefreshOnlyIfNewer(); - String DEFAULT_REFRESH_ONLY_IF_NEWER_PROPERTY = "defaultRefreshOnlyIfNewerProperty"; //$NON-NLS-1$ - boolean DEFAULT_REFRESH_ONLY_IF_NEWER = false; - - Boolean getSpecifiedRefreshOnlyIfNewer(); - void setSpecifiedRefreshOnlyIfNewer(Boolean newSpecifiedRefreshOnlyIfNewer); - String SPECIFIED_REFRESH_ONLY_IF_NEWER_PROPERTY = "specifiedRefreshOnlyIfNewerProperty"; //$NON-NLS-1$ - - - //***************** disable hits ************************ - - /** - * This is the combination of defaultDisableHits and specifiedDisableHits. - * If getSpecifiedDisableHits() returns null, then return getDefaultDisableHits() - */ - boolean isDisableHits(); - - boolean isDefaultDisableHits(); - String DEFAULT_DISABLE_HITS_PROPERTY = "defaultDisableHitsProperty"; //$NON-NLS-1$ - boolean DEFAULT_DISABLE_HITS = false; - - Boolean getSpecifiedDisableHits(); - void setSpecifiedDisableHits(Boolean newSpecifiedDisableHits); - String SPECIFIED_DISABLE_HITS_PROPERTY = "specifiedDisableHitsProperty"; //$NON-NLS-1$ - - - //***************** coordination type ************************ - - /** - * This is the combination of defaultCoordinationType and specifiedCoordinationType. - * If getSpecifiedCoordinationType() returns null, then return getDefaultCoordinationType() - */ - CacheCoordinationType getCoordinationType(); - - CacheCoordinationType getDefaultCoordinationType(); - String DEFAULT_COORDINATION_TYPE_PROPERTY = "defaultCoordinationTypeProperty"; //$NON-NLS-1$ - CacheCoordinationType DEFAULT_COORDINATION_TYPE = CacheCoordinationType.SEND_OBJECT_CHANGES; - - CacheCoordinationType getSpecifiedCoordinationType(); - void setSpecifiedCoordinationType(CacheCoordinationType newSpecifiedCoordinationType); - String SPECIFIED_COORDINATION_TYPE_PROPERTY = "specifiedCoordinationTypeProperty"; //$NON-NLS-1$ - - - //***************** existence checking ************************ - - /** - * This is the combination of defaultExistenceType and specifiedExistenceType. - * If getSpecifiedExistenceType() returns null, then return getDefaultExistenceType() - */ - ExistenceType getExistenceType(); - - ExistenceType getDefaultExistenceType(); - String DEFAULT_EXISTENCE_TYPE_PROPERTY = "defaultExistenceTypeProperty"; //$NON-NLS-1$ - ExistenceType DEFAULT_EXISTENCE_TYPE = ExistenceType.CHECK_DATABASE; - - ExistenceType getSpecifiedExistenceType(); - void setSpecifiedExistenceType(ExistenceType newSpecifiedExistenceType); - String SPECIFIED_EXISTENCE_TYPE_PROPERTY = "specifiedExistenceTypeProperty"; //$NON-NLS-1$ - - - //***************** expiry ************************ - - /** - * corresponds to the Cache expiry element. If this returns - * a non-null value then getExpiryTimeOfDay will return null. - * It is not valid to specify both - */ - Integer getExpiry(); - - /** - * Setting this to a non-null value will set timeOfDayExpiry to null - * @param expiry - */ - void setExpiry(Integer expiry); - String EXPIRY_PROPERTY = "expiryProperty"; //$NON-NLS-1$ - - - /** - * corresponds to the Cache expiryTimeOfDay annotation or xml element. - * If this returns a non-null value then getExpiry will return null. - * It is not valid to specify both. - */ - ExpiryTimeOfDay getExpiryTimeOfDay(); - - /** - * Add Cache expiryTimeOfDay annotation or xml element, this will set - * Expiry to null as it is not valid to set both expiry and timeOfDayExpiry - */ - ExpiryTimeOfDay addExpiryTimeOfDay(); - - /** - * Removes the Cache expiryTimeOfDay annotation/xml element - */ - void removeExpiryTimeOfDay(); - String EXPIRY_TIME_OF_DAY_PROPERTY = "expiryTimeOfDayProperty"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTracking.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTracking.java deleted file mode 100644 index 2f64b2d8b6..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTracking.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ChangeTracking extends JpaContextNode -{ - /** - * This is the combination of defaultType and specifiedType. - * If getSpecifiedType() returns null, then return getDefaultType() - */ - ChangeTrackingType getType(); - - ChangeTrackingType getDefaultType(); - String DEFAULT_TYPE_PROPERTY = "defaultTypeProperty"; //$NON-NLS-1$ - ChangeTrackingType DEFAULT_TYPE = ChangeTrackingType.AUTO; - - ChangeTrackingType getSpecifiedType(); - void setSpecifiedType(ChangeTrackingType newSpecifiedType); - String SPECIFIED_TYPE_PROPERTY = "specifiedTypeProperty"; //$NON-NLS-1$ -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTrackingType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTrackingType.java deleted file mode 100644 index 396500f9f8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ChangeTrackingType.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType; - - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum ChangeTrackingType { - - ATTRIBUTE, - OBJECT, - DEFERRED, - AUTO; - - - public static ChangeTrackingType fromJavaResourceModel(org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType javaChangeTrackingType) { - if (javaChangeTrackingType == null) { - return null; - } - switch (javaChangeTrackingType) { - case ATTRIBUTE: - return ATTRIBUTE; - case OBJECT: - return OBJECT; - case DEFERRED: - return DEFERRED; - case AUTO: - return AUTO; - default: - throw new IllegalArgumentException("unknown change tracking type: " + javaChangeTrackingType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType toJavaResourceModel(ChangeTrackingType changeTrackingType) { - if (changeTrackingType == null) { - return null; - } - switch (changeTrackingType) { - case ATTRIBUTE: - return org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType.ATTRIBUTE; - case OBJECT: - return org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType.OBJECT; - case DEFERRED: - return org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType.DEFERRED; - case AUTO: - return org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType.AUTO; - default: - throw new IllegalArgumentException("unknown change tracking type: " + changeTrackingType); //$NON-NLS-1$ - } - } - - public static ChangeTrackingType fromOrmResourceModel(XmlChangeTrackingType ormChangeTrackingType) { - if (ormChangeTrackingType == null) { - return null; - } - switch (ormChangeTrackingType) { - case ATTRIBUTE: - return ATTRIBUTE; - case OBJECT: - return OBJECT; - case DEFERRED: - return DEFERRED; - case AUTO: - return AUTO; - default: - throw new IllegalArgumentException("unknown change tracking type: " + ormChangeTrackingType); - } - } - - public static XmlChangeTrackingType toOrmResourceModel(ChangeTrackingType changeTrackingType) { - if (changeTrackingType == null) { - return null; - } - switch (changeTrackingType) { - case ATTRIBUTE: - return XmlChangeTrackingType.ATTRIBUTE; - case OBJECT: - return XmlChangeTrackingType.OBJECT; - case DEFERRED: - return XmlChangeTrackingType.DEFERRED; - case AUTO: - return XmlChangeTrackingType.AUTO; - default: - throw new IllegalArgumentException("unknown change tracking type: " + changeTrackingType); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ConversionValue.java deleted file mode 100644 index 0e36428e39..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ConversionValue.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Corresponds to a ConversionValue resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ConversionValue extends JpaContextNode -{ - String getDataValue(); - void setDataValue(String dataValue); - String DATA_VALUE_PROPERTY = "dataValueProperty"; //$NON-NLS-1$ - - String getObjectValue(); - void setObjectValue(String objectValue); - String OBJECT_VALUE_PROPERTY = "objectValueProperty"; //$NON-NLS-1$ - - ObjectTypeConverter getParent(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Convert.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Convert.java deleted file mode 100644 index 87a9ff9b04..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Convert.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.Converter; -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Corresponds to a Convert resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface Convert extends JpaContextNode, Converter -{ - - String ECLIPSE_LINK_CONVERTER = "eclipseLinkConverter"; //$NON-NLS-1$ - - String getConverterName(); - - String getDefaultConverterName(); - String DEFAULT_CONVERTER_NAME_PROPERTY = "defaultConverterNameProperty"; //$NON-NLS-1$ - - String getSpecifiedConverterName(); - - void setSpecifiedConverterName(String converterName); - String SPECIFIED_CONVERTER_NAME_PROPERTY = "specifiedConverterNameProperty"; //$NON-NLS-1$ - - /** - * Reserved name for specifying a serialized object converter. In this - * case there does not need to be a corresponding @CustomConverter defined. - */ - String SERIALIZED_CONVERTER = "serialized"; //$NON-NLS-1$ - - /** - * Reserved name for specifying a class instance converter. Will use a ClassInstanceConverter - * on the associated mapping. When using a ClassInstanceConverter the database representation is a - * String representing the Class name and the object-model representation is an instance - * of that class built with a no-args constructor - * In this case there does not need to be a corresponding @CustomConverter defined. - */ - String CLASS_INSTANCE_CONVERTER = "class-instance"; //$NON-NLS-1$ - - /** - * Reserved name for specifying no converter. This can be used to override a situation where either - * another converter is defaulted or another converter is set. - * In this case there does not need to be a corresponding @CustomConverter defined. - */ - String NO_CONVERTER = "none"; //$NON-NLS-1$ - - String[] RESERVED_CONVERTER_NAMES = {NO_CONVERTER, CLASS_INSTANCE_CONVERTER, SERIALIZED_CONVERTER}; - - String DEFAULT_CONVERTER_NAME = NO_CONVERTER; - - /** - * This will return null if there is no converter specified on the mapping - * @return - */ - EclipseLinkConverter getConverter(); - String CONVERTER_PROPERTY = "converterProperty"; //$NON-NLS-1$ - - /** - * Possible values for converter type are: - * {@value EclipseLinkNamedConverter#TYPE_CONVERTER} - * {@value EclipseLinkNamedConverter#STRUCT_CONVERTER} - * {@value EclipseLinkNamedConverter#CUSTOM_CONVERTER} - * {@value EclipseLinkNamedConverter#NO_CONVERTER} - * {@value EclipseLinkNamedConverter#OBJECT_TYPE_CONVERTER} - * @param converterType - */ - void setConverter(String converterType); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CustomConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CustomConverter.java deleted file mode 100644 index ccf8a356e6..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/CustomConverter.java +++ /dev/null @@ -1,32 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -/** - * Corresponds to a CustomConverter resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface CustomConverter extends EclipseLinkConverter -{ - - String getConverterClass(); - void setConverterClass(String converterClass); - String CONVERTER_CLASS_PROPERTY = "converterClassProperty"; //$NON-NLS-1$ - String ECLIPSELINK_CONVERTER_CLASS_NAME = "org.eclipse.persistence.mappings.converters.Converter"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Customizer.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Customizer.java deleted file mode 100644 index d302f566ab..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Customizer.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Corresponds to a Customizer resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface Customizer extends JpaContextNode -{ - - String getCustomizerClass(); - - String getDefaultCustomizerClass(); - String DEFAULT_CUSTOMIZER_CLASS_PROPERTY = "defaultCustomizerClassProperty"; //$NON-NLS-1$ - - String getSpecifiedCustomizerClass(); - void setSpecifiedCustomizerClass(String customizerClass); - String SPECIFIED_CUSTOMIZER_CLASS_PROPERTY = "specifiedCustomizerClassProperty"; //$NON-NLS-1$ - String ECLIPSELINK_DESCRIPTOR_CUSTOMIZER_CLASS_NAME = "org.eclipse.persistence.config.DescriptorCustomizer"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkBasicMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkBasicMapping.java deleted file mode 100644 index 3bd5ae1909..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkBasicMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.BasicMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkBasicMapping extends BasicMapping -{ - Mutable getMutable(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkConverter.java deleted file mode 100644 index b47a1af53c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkConverter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Corresponds to a *CustomConverter resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkConverter extends JpaContextNode -{ - /** - * Return a string that represents the type of converter. - * Possibilities are below, NO_CONVERTER, CUSTOM_CONVERTER, - * OBJECT_TYPE_CONVERTER, STRUCT_CONVERTER, TYPE_CONVERTER - */ - String getType(); - String NO_CONVERTER = "noConverter"; //$NON-NLS-1$ - String CUSTOM_CONVERTER = "customConverter"; //$NON-NLS-1$ - String OBJECT_TYPE_CONVERTER = "objectTypeConverter"; //$NON-NLS-1$ - String STRUCT_CONVERTER = "structConverter"; //$NON-NLS-1$ - String TYPE_CONVERTER = "typeConverter"; //$NON-NLS-1$ - - String getName(); - void setName(String name); - String NAME_PROPERTY = "nameProperty"; //$NON-NLS-1$ - - /** - * Return whether the converter definition overrides the definition of the - * given converter - * (e.g. a converter defined in orm.xml overrides one defined in java). - */ - boolean overrides(EclipseLinkConverter converter); - - /** - * Return whether the converter is a duplicate of the given converter. - * A converter is not a duplicate of another converter if is the same exact converter, - * if it is a nameless converter (which is an error condition), or if it overrides - * or is overridden by the other converter. - */ - boolean duplicates(EclipseLinkConverter converter); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEmbeddable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEmbeddable.java deleted file mode 100644 index 03c1395da4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEmbeddable.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.Embeddable; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkEmbeddable extends Embeddable -{ - Customizer getCustomizer(); - - ChangeTracking getChangeTracking(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEntity.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEntity.java deleted file mode 100644 index c6683a695c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkEntity.java +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.Entity; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkEntity extends Entity -{ - Caching getCaching(); - - ReadOnly getReadOnly(); - - Customizer getCustomizer(); - - ChangeTracking getChangeTracking(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkIdMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkIdMapping.java deleted file mode 100644 index c5b6ac9cc5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkIdMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.IdMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkIdMapping extends IdMapping -{ - Mutable getMutable(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkMappedSuperclass.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkMappedSuperclass.java deleted file mode 100644 index 4ab4a1a6a2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkMappedSuperclass.java +++ /dev/null @@ -1,33 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.MappedSuperclass; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkMappedSuperclass extends MappedSuperclass -{ - Caching getCaching(); - - ReadOnly getReadOnly(); - - Customizer getCustomizer(); - - ChangeTracking getChangeTracking(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToManyMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToManyMapping.java deleted file mode 100644 index 41342ead4e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToManyMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.OneToManyMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkOneToManyMapping extends OneToManyMapping, EclipseLinkRelationshipMapping -{ - PrivateOwned getPrivateOwned(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToOneMapping.java deleted file mode 100644 index be1c9b3e2f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkOneToOneMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.OneToOneMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkOneToOneMapping extends OneToOneMapping, EclipseLinkRelationshipMapping -{ - PrivateOwned getPrivateOwned(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkRelationshipMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkRelationshipMapping.java deleted file mode 100644 index 810e8d9cef..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkRelationshipMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.RelationshipMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkRelationshipMapping extends RelationshipMapping -{ - JoinFetch getJoinFetch(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkVersionMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkVersionMapping.java deleted file mode 100644 index 90ff9aba9a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/EclipseLinkVersionMapping.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.VersionMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkVersionMapping extends VersionMapping -{ - Mutable getMutable(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExistenceType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExistenceType.java deleted file mode 100644 index a1e3807511..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExistenceType.java +++ /dev/null @@ -1,106 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum ExistenceType { - - CHECK_CACHE, - CHECK_DATABASE, - ASSUME_EXISTENCE, - ASSUME_NON_EXISTENCE; - - - public static ExistenceType fromJavaResourceModel(org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType javaExistenceType) { - if (javaExistenceType == null) { - return null; - } - switch (javaExistenceType) { - case CHECK_CACHE: - return CHECK_CACHE; - case CHECK_DATABASE: - return CHECK_DATABASE; - case ASSUME_EXISTENCE: - return ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE: - return ASSUME_NON_EXISTENCE; - default: - throw new IllegalArgumentException("unknown existence type: " + javaExistenceType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType toJavaResourceModel(ExistenceType existenceType) { - if (existenceType == null) { - return null; - } - switch (existenceType) { - case CHECK_CACHE: - return org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType.CHECK_CACHE; - case CHECK_DATABASE: - return org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType.CHECK_DATABASE; - case ASSUME_EXISTENCE: - return org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType.ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE: - return org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType.ASSUME_NON_EXISTENCE; - default: - throw new IllegalArgumentException("unknown existence type: " + existenceType); //$NON-NLS-1$ - } - } - - - public static ExistenceType fromOrmResourceModel(org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType ormExistenceType) { - if (ormExistenceType == null) { - return null; - } - switch (ormExistenceType) { - case CHECK_CACHE: - return CHECK_CACHE; - case CHECK_DATABASE: - return CHECK_DATABASE; - case ASSUME_EXISTENCE: - return ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE: - return ASSUME_NON_EXISTENCE; - default: - throw new IllegalArgumentException("unknown existence type: " + ormExistenceType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType toOrmResourceModel(ExistenceType existenceType) { - if (existenceType == null) { - return null; - } - switch (existenceType) { - case CHECK_CACHE: - return org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType.CHECK_CACHE; - case CHECK_DATABASE: - return org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType.CHECK_DATABASE; - case ASSUME_EXISTENCE: - return org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType.ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE: - return org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType.ASSUME_NON_EXISTENCE; - default: - throw new IllegalArgumentException("unknown existence type: " + existenceType); //$NON-NLS-1$ - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExpiryTimeOfDay.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExpiryTimeOfDay.java deleted file mode 100644 index a5bbdbbfd7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ExpiryTimeOfDay.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Corresponds to a TimeOfDay resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ExpiryTimeOfDay extends JpaContextNode -{ - - Integer getHour(); - void setHour(Integer hour); - String HOUR_PROPERTY = "hourProperty"; //$NON-NLS-1$ - - Integer getMinute(); - void setMinute(Integer minute); - String MINUTE_PROPERTY = "minuteProperty"; //$NON-NLS-1$ - - Integer getSecond(); - void setSecond(Integer second); - String SECOND_PROPERTY = "secondProperty"; //$NON-NLS-1$ - - Integer getMillisecond(); - void setMillisecond(Integer millisecond); - String MILLISECOND_PROPERTY = "millisecondProperty"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetch.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetch.java deleted file mode 100644 index da4e7ba413..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetch.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface JoinFetch extends JpaContextNode -{ - JoinFetchType getValue(); - void setValue(JoinFetchType newJoinFetchValue); - String VALUE_PROPERTY = "JoinFetch.valueProperty"; //$NON-NLS-1$ - JoinFetchType DEFAULT_VALUE = JoinFetchType.INNER; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetchType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetchType.java deleted file mode 100644 index c01b4edfe8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/JoinFetchType.java +++ /dev/null @@ -1,89 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum JoinFetchType { - - INNER, - OUTER; - - - public static JoinFetchType fromJavaResourceModel(org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType javaJoinFetchType) { - if (javaJoinFetchType == null) { - return null; - } - switch (javaJoinFetchType) { - case INNER: - return INNER; - case OUTER: - return OUTER; - default: - throw new IllegalArgumentException("unknown join fetch type: " + javaJoinFetchType); //$NON-NLS-1$ - } - } - - public static org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType toJavaResourceModel(JoinFetchType joinFetchType) { - if (joinFetchType == null) { - return null; - } - switch (joinFetchType) { - case INNER: - return org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType.INNER; - case OUTER: - return org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType.OUTER; - default: - throw new IllegalArgumentException("unknown join fetch type: " + joinFetchType); //$NON-NLS-1$ - } - } - - - public static JoinFetchType fromOrmResourceModel(XmlJoinFetchType ormJoinFetchType) { - if (ormJoinFetchType == null) { - return null; - } - switch (ormJoinFetchType) { - case INNER: - return INNER; - case OUTER: - return OUTER; - default: - throw new IllegalArgumentException("unknown join fetch type: " + ormJoinFetchType); //$NON-NLS-1$ - } - } - - public static XmlJoinFetchType toOrmResourceModel(JoinFetchType fetchType) { - if (fetchType == null) { - return null; - } - switch (fetchType) { - case INNER: - return XmlJoinFetchType.INNER; - case OUTER: - return XmlJoinFetchType.OUTER; - default: - throw new IllegalArgumentException("unknown join fetch type: " + fetchType); //$NON-NLS-1$ - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Mutable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Mutable.java deleted file mode 100644 index a4bb91911b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/Mutable.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface Mutable extends JpaContextNode -{ - boolean isMutable(); - - boolean isDefaultMutable(); - String DEFAULT_MUTABLE_PROPERTY = "defaultMutableProperty"; //$NON-NLS-1$ - - Boolean getSpecifiedMutable(); - void setSpecifiedMutable(Boolean newSpecifiedMutable); - String SPECIFIED_MUTABLE_PROPERTY = "specifiedMutableProperty"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ObjectTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ObjectTypeConverter.java deleted file mode 100644 index e659130306..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ObjectTypeConverter.java +++ /dev/null @@ -1,92 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import java.util.ListIterator; - -/** - * Corresponds to a ObjectTypeConverter resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ObjectTypeConverter extends EclipseLinkConverter -{ - String getDataType(); - void setDataType(String dataType); - String DATA_TYPE_PROPERTY = "dataTypeProperty"; //$NON-NLS-1$ - - String getObjectType(); - void setObjectType(String objectType); - String OBJECT_TYPE_PROPERTY = "objectTypeProperty"; //$NON-NLS-1$ - - - // **************** conversion values ************************************** - - /** - * Return a list iterator of the conversion values. - * This will not be null. - */ - <T extends ConversionValue> ListIterator<T> conversionValues(); - - /** - * Return the number of conversion values. - */ - int conversionValuesSize(); - - /** - * Add a conversion value to the object type mapping return the object - * representing it. - */ - ConversionValue addConversionValue(int index); - - /** - * Add a conversion value to the object type mapping return the object - * representing it. - */ - ConversionValue addConversionValue(); - - /** - * Remove the conversion value at the given index from the entity. - */ - void removeConversionValue(int index); - - /** - * Remove the conversion value from the entity. - */ - void removeConversionValue(ConversionValue conversionValue); - - /** - * Move the conversion values from the source index to the target index. - */ - void moveConversionValue(int targetIndex, int sourceIndex); - String CONVERSION_VALUES_LIST = "conversionValuesList"; //$NON-NLS-1$ - - - /** - * Returns a ListIterator of the ConversionValue dataValues. - * @return - */ - ListIterator<String> dataValues(); - - - // **************** default object value ************************************** - - String getDefaultObjectValue(); - void setDefaultObjectValue(String defaultObjectValue); - String DEFAULT_OBJECT_VALUE_PROPERTY = "defaultObjectValueProperty"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/PrivateOwned.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/PrivateOwned.java deleted file mode 100644 index edae11e299..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/PrivateOwned.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface PrivateOwned extends JpaContextNode -{ - boolean isPrivateOwned(); - void setPrivateOwned(boolean privateOwned); - String PRIVATE_OWNED_PROPERTY = "privateOwnedProperty"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ReadOnly.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ReadOnly.java deleted file mode 100644 index 78f3ceea33..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/ReadOnly.java +++ /dev/null @@ -1,37 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.JpaContextNode; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ReadOnly extends JpaContextNode -{ - boolean isReadOnly(); - - boolean isDefaultReadOnly(); - String DEFAULT_READ_ONLY_PROPERTY = "defaultReadOnly"; //$NON-NLS-1$ - boolean DEFAULT_READ_ONLY = false; - - Boolean getSpecifiedReadOnly(); - void setSpecifiedReadOnly(Boolean newSpecifiedReadOnly); - String SPECIFIED_READ_ONLY_PROPERTY = "specifiedReadOnly"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/StructConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/StructConverter.java deleted file mode 100644 index c351d591c8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/StructConverter.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -/** - * Corresponds to a StructConverter resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface StructConverter extends EclipseLinkConverter -{ - String getConverterClass(); - void setConverterClass(String converterClass); - String CONVERTER_CLASS_PROPERTY = "converterClassProperty"; //$NON-NLS-1$ - String ECLIPSELINK_STRUCT_CONVERTER_CLASS_NAME = "org.eclipse.persistence.platform.database.converters.StructConverter"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TransformationMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TransformationMapping.java deleted file mode 100644 index d2f8015cc3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TransformationMapping.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.AttributeMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TransformationMapping extends AttributeMapping -{ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TypeConverter.java deleted file mode 100644 index 7297776e04..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/TypeConverter.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -/** - * Corresponds to a TypeConverter resource model object - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TypeConverter extends EclipseLinkConverter -{ - String getDataType(); - void setDataType(String dataType); - String DATA_TYPE_PROPERTY = "dataTypeProperty"; //$NON-NLS-1$ - - String getObjectType(); - void setObjectType(String objectType); - String OBJECT_TYPE_PROPERTY = "objectTypeProperty"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/VariableOneToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/VariableOneToOneMapping.java deleted file mode 100644 index 21068b5d19..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/VariableOneToOneMapping.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context; - -import org.eclipse.jpt.core.context.AttributeMapping; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - */ -public interface VariableOneToOneMapping extends AttributeMapping -{ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEmbeddable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEmbeddable.java deleted file mode 100644 index 7ce177464a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEmbeddable.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.java; - -import org.eclipse.jpt.core.context.java.JavaEmbeddable; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkEmbeddable; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkJavaEmbeddable extends EclipseLinkEmbeddable, JavaEmbeddable -{ - JavaConverterHolder getConverterHolder(); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEntity.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEntity.java deleted file mode 100644 index c8b60cc7bd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaEntity.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.java; - -import java.util.ListIterator; -import org.eclipse.jpt.core.context.java.JavaAssociationOverride; -import org.eclipse.jpt.core.context.java.JavaAttributeOverride; -import org.eclipse.jpt.core.context.java.JavaEntity; -import org.eclipse.jpt.core.context.java.JavaNamedNativeQuery; -import org.eclipse.jpt.core.context.java.JavaNamedQuery; -import org.eclipse.jpt.core.context.java.JavaPrimaryKeyJoinColumn; -import org.eclipse.jpt.core.context.java.JavaSecondaryTable; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkEntity; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkJavaEntity extends EclipseLinkEntity, JavaEntity -{ - JavaConverterHolder getConverterHolder(); - - JavaCaching getCaching(); - - // included these to prevent warnings on the implementation - ListIterator<JavaSecondaryTable> secondaryTables(); - ListIterator<JavaSecondaryTable> specifiedSecondaryTables(); - ListIterator<JavaPrimaryKeyJoinColumn> primaryKeyJoinColumns(); - ListIterator<JavaPrimaryKeyJoinColumn> specifiedPrimaryKeyJoinColumns(); - ListIterator<JavaAttributeOverride> attributeOverrides(); - ListIterator<JavaAttributeOverride> specifiedAttributeOverrides(); - ListIterator<JavaAttributeOverride> virtualAttributeOverrides(); - ListIterator<JavaAssociationOverride> associationOverrides(); - ListIterator<JavaAssociationOverride> specifiedAssociationOverrides(); - ListIterator<JavaAssociationOverride> virtualAssociationOverrides(); - ListIterator<JavaNamedQuery> namedQueries(); - ListIterator<JavaNamedNativeQuery> namedNativeQueries(); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaMappedSuperclass.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaMappedSuperclass.java deleted file mode 100644 index 2b8aab7da4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/EclipseLinkJavaMappedSuperclass.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.java.JavaMappedSuperclass; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkMappedSuperclass; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkJavaMappedSuperclass extends EclipseLinkMappedSuperclass, JavaMappedSuperclass -{ - JavaConverterHolder getConverterHolder(); - - //********* covariant overrides *********** - - JavaCaching getCaching(); - - Iterator<JavaPersistentAttribute> overridableAttributes(); - Iterator<JavaPersistentAttribute> overridableAssociations(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaCaching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaCaching.java deleted file mode 100644 index efee968cba..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaCaching.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.java; - -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.context.Caching; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface JavaCaching extends Caching, JavaJpaContextNode -{ - - /** - * Return true if the existence-checking model object exists. - * Have to have a separate flag for this since the default existence - * type is different depending on whether hasExistenceChecking() returns - * true or false. - */ - boolean hasExistenceChecking(); - void setExistenceChecking(boolean existenceChecking); - String EXISTENCE_CHECKING_PROPERTY = "existenceCheckingProperty"; //$NON-NLS-1$ - - /** - * Initialize the EclipseLinkJavaCaching context model object to match the CacheAnnotation - * resource model object. This should be called immediately after object creation. - */ - void initialize(JavaResourcePersistentType resourcePersistentType); - - /** - * Update the EclipseLinkJavaCaching context model object to match the CacheAnnotation - * resource model object. see {@link org.eclipse.jpt.core.JpaProject#update()} - */ - void update(JavaResourcePersistentType resourcePersistentType); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaConverterHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaConverterHolder.java deleted file mode 100644 index 3feaf70186..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/java/JavaConverterHolder.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.java; - -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.2 - */ -public interface JavaConverterHolder extends JavaJpaContextNode -{ - /** - * Initialize the JavaConverterHolder context model object to match the JavaResourcePersistentType - * resource model object. This should be called immediately after object creation. - */ - void initialize(JavaResourcePersistentType jrpt); - - /** - * Update the JavaConverterHolder context model object to match the JavaResourcePersistentType - * resource model object. see {@link org.eclipse.jpt.core.JpaProject#update()} - */ - void update(JavaResourcePersistentType jrpt); - - CustomConverter getCustomConverter(); - CustomConverter addCustomConverter(); - void removeCustomConverter(); - String CUSTOM_CONVERTER_PROPERTY = "customConverterProperty"; //$NON-NLS-1$ - - ObjectTypeConverter getObjectTypeConverter(); - ObjectTypeConverter addObjectTypeConverter(); - void removeObjectTypeConverter(); - String OBJECT_TYPE_CONVERTER_PROPERTY = "objectTypeConverterProperty"; //$NON-NLS-1$ - - StructConverter getStructConverter(); - StructConverter addStructConverter(); - void removeStructConverter(); - String STRUCT_CONVERTER_PROPERTY = "structConverterProperty"; //$NON-NLS-1$ - - TypeConverter getTypeConverter(); - TypeConverter addTypeConverter(); - void removeTypeConverter(); - String TYPE_CONVERTER_PROPERTY = "typeCnverterProperty"; //$NON-NLS-1$ - -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/orm/XmlCaching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/orm/XmlCaching.java deleted file mode 100644 index 6dd707cadd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/context/orm/XmlCaching.java +++ /dev/null @@ -1,19 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.context.orm; - -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.eclipselink.core.context.Caching; - -public interface XmlCaching - extends Caching, XmlContextNode -{ - // just combine two interfaces -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/DefaultEclipseLinkJpaValidationMessages.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/DefaultEclipseLinkJpaValidationMessages.java deleted file mode 100644 index a8198e009f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/DefaultEclipseLinkJpaValidationMessages.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2005, 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; -import org.eclipse.jpt.core.JptCorePlugin; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.wst.validation.internal.core.Message; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class DefaultEclipseLinkJpaValidationMessages { - - private static String[] DEFAULT_PARMS = new String[0]; - private static TextRange DEFAULT_TEXT_RANGE = TextRange.Empty.instance(); - - public static IMessage buildMessage( - int severity, String messageId, Object targetObject) { - return buildMessage(severity, messageId, DEFAULT_PARMS, targetObject); - } - - public static IMessage buildMessage( - int severity, String messageId, String[] parms, Object targetObject) { - return buildMessage(severity, messageId, parms, targetObject, DEFAULT_TEXT_RANGE); - } - - public static IMessage buildMessage( - int severity, String messageId, Object targetObject, TextRange textRange) { - return buildMessage(severity, messageId, DEFAULT_PARMS, targetObject, textRange); - } - - public static IMessage buildMessage( - int severity, String messageId, String[] parms, Object targetObject, TextRange textRange) { - IMessage message = new EclipseLinkMessage(EclipseLinkJpaValidationMessages.BUNDLE_NAME, severity, messageId, parms, targetObject); - if (textRange == null) { - //log an exception and then continue without setting location information - //At least the user will still get the validation message and will - //be able to see other validation messages with valid textRanges - JptCorePlugin.log(new IllegalArgumentException("Null text range for message ID: " + messageId)); //$NON-NLS-1$ - } - else { - message.setLineNo(textRange.getLineNumber()); - message.setOffset(textRange.getOffset()); - message.setLength(textRange.getLength()); - } - return message; - } - - - private DefaultEclipseLinkJpaValidationMessages() { - super(); - throw new UnsupportedOperationException(); - } - - /** - * Used so that we can find the resource bundle using this classLoader. - * Otherwise the wst validation message attempts to use the ClassLoader - * of JpaValidator which is in the org.eclipse.jpt.core plugin. - * - * Another way we could potentially solve this is to have a separate - * EclispeLinkJpaValidator and set up the extension points so that - * it only runs against jpaProjects with the EclispeLinkPlatform - * while JpaValidator runs against jpaProjects with the GenericPlatform. - * I am unsure if this is possible - */ - private static class EclipseLinkMessage extends Message { - public EclipseLinkMessage(String aBundleName, int aSeverity, String anId, String[] aParams, Object aTargetObject) { - super(aBundleName, aSeverity, anId, aParams, aTargetObject); - } - - @Override - public ResourceBundle getBundle(Locale locale, ClassLoader classLoader) { - ResourceBundle bundle = null; - try { - bundle = ResourceBundle.getBundle(getBundleName(), locale, getClass().getClassLoader()); - } catch (MissingResourceException e) { - return super.getBundle(locale, classLoader); - } - return bundle; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaAnnotationDefinitionProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaAnnotationDefinitionProvider.java deleted file mode 100644 index 1ac1e768f3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaAnnotationDefinitionProvider.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import java.util.List; -import org.eclipse.jpt.core.JpaAnnotationDefinitionProvider; -import org.eclipse.jpt.core.internal.platform.AbstractJpaAnnotationDefintionProvider; -import org.eclipse.jpt.core.internal.resource.java.AccessImpl.AccessAnnotationDefinition; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; - -/** - * Provides annotations for 1.1 EclipseLink which includes JPA annotations, JPA 2.0 annotation, - * EclipseLink 1.0 annotation and EclipseLink 1.1 annotations - */ -public class EclipseLink1_1JpaAnnotationDefinitionProvider - extends AbstractJpaAnnotationDefintionProvider -{ - // singleton - private static final JpaAnnotationDefinitionProvider INSTANCE = new EclipseLink1_1JpaAnnotationDefinitionProvider(); - - /** - * Return the singleton. - */ - public static JpaAnnotationDefinitionProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLink1_1JpaAnnotationDefinitionProvider() { - super(); - } - - @Override - protected void addTypeMappingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - //none - } - - @Override - protected void addTypeSupportingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - definitions.add(AccessAnnotationDefinition.instance()); - } - - @Override - protected void addAttributeMappingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - //none - } - - @Override - protected void addAttributeSupportingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - definitions.add(AccessAnnotationDefinition.instance()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaFactory.java deleted file mode 100644 index 9889c11c2a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaFactory.java +++ /dev/null @@ -1,29 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.jpt.core.context.PersistentType.Owner; -import org.eclipse.jpt.core.context.java.JavaPersistentType; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLink1_1JavaPersistentTypeImpl; - -public class EclipseLink1_1JpaFactory - extends EclipseLinkJpaFactory -{ - protected EclipseLink1_1JpaFactory() { - super(); - } - - @Override - public JavaPersistentType buildJavaPersistentType(Owner owner, JavaResourcePersistentType jrpt) { - return new EclipseLink1_1JavaPersistentTypeImpl(owner, jrpt); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformFactory.java deleted file mode 100644 index f788102151..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformFactory.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.jpt.core.JpaAnnotationProvider; -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.JpaPlatform; -import org.eclipse.jpt.core.JpaPlatformFactory; -import org.eclipse.jpt.core.internal.platform.GenericJpaAnnotationDefinitionProvider; -import org.eclipse.jpt.core.internal.platform.GenericJpaAnnotationProvider; -import org.eclipse.jpt.core.internal.platform.GenericJpaPlatform; -import org.eclipse.jpt.core.internal.platform.GenericJpaPlatformProvider; - -/** - * All the state in the JPA platform should be "static" (i.e. unchanging once - * it is initialized). - */ -public class EclipseLink1_1JpaPlatformFactory - implements JpaPlatformFactory -{ - - /** - * zero-argument constructor - */ - public EclipseLink1_1JpaPlatformFactory() { - super(); - } - - public JpaPlatform buildJpaPlatform(String id) { - return new GenericJpaPlatform( - id, - buildJpaFactory(), - buildJpaAnnotationProvider(), - EclipseLinkJpaPlatformProvider.instance(), - //put eclipselink first because of the default java attribute mapping providers order, - //maybe there is a better way to handle that order dependency - GenericJpaPlatformProvider.instance(), - EclipseLink1_1JpaPlatformProvider.instance()); - } - - protected JpaFactory buildJpaFactory() { - return new EclipseLink1_1JpaFactory(); - } - - protected JpaAnnotationProvider buildJpaAnnotationProvider() { - return new GenericJpaAnnotationProvider( - GenericJpaAnnotationDefinitionProvider.instance(), - EclipseLinkJpaAnnotationDefinitionProvider.instance(), - EclipseLink1_1JpaAnnotationDefinitionProvider.instance()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformProvider.java deleted file mode 100644 index d6294f55a0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLink1_1JpaPlatformProvider.java +++ /dev/null @@ -1,104 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import java.util.List; -import org.eclipse.jpt.core.JpaPlatformProvider; -import org.eclipse.jpt.core.JpaResourceModelProvider; -import org.eclipse.jpt.core.context.MappingFileProvider; -import org.eclipse.jpt.core.context.java.DefaultJavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.ExtendedOrmTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmTypeMappingProvider; -import org.eclipse.jpt.core.internal.platform.AbstractJpaPlatformProvider; - -/** - * EclipseLink platform - */ -public class EclipseLink1_1JpaPlatformProvider - extends AbstractJpaPlatformProvider -{ - public static final String ID = "eclipselink1_1"; //$NON-NLS-1$ - - // singleton - private static final JpaPlatformProvider INSTANCE = new EclipseLink1_1JpaPlatformProvider(); - - /** - * Return the singleton. - */ - public static JpaPlatformProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLink1_1JpaPlatformProvider() { - super(); - } - - - // ********* JPA files ********* - - @Override - protected void addResourceModelProvidersTo(@SuppressWarnings("unused") List<JpaResourceModelProvider> providers) { - //none specific to EclipseLink1.1 - } - - - // ********* java ********* - - @Override - protected void addJavaTypeMappingProvidersTo(@SuppressWarnings("unused") List<JavaTypeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - - @Override - protected void addJavaAttributeMappingProvidersTo(@SuppressWarnings("unused") List<JavaAttributeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - - @Override - protected void addDefaultJavaAttributeMappingProvidersTo(@SuppressWarnings("unused") List<DefaultJavaAttributeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - - - // ********* ORM ********* - - @Override - protected void addOrmTypeMappingProvidersTo(@SuppressWarnings("unused") List<OrmTypeMappingProvider> providers) { - //none specific to EclipseLink - } - - @Override - protected void addMappingFileProvidersTo(@SuppressWarnings("unused") List<MappingFileProvider> providers) { - //none specific to EclipseLink1.1 - } - - @Override - protected void addExtendedOrmTypeMappingProvidersTo(@SuppressWarnings("unused") List<ExtendedOrmTypeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - - @Override - protected void addOrmAttributeMappingProvidersTo(@SuppressWarnings("unused") List<OrmAttributeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - - @Override - protected void addExtendedOrmAttributeMappingProvidersTo(@SuppressWarnings("unused") List<ExtendedOrmAttributeMappingProvider> providers) { - //none specific to EclipseLink1.1 - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkConstants.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkConstants.java deleted file mode 100644 index 2f777d2b19..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkConstants.java +++ /dev/null @@ -1,19 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -public interface EclipseLinkConstants -{ - String ECLIPSELINK_ORM_NS_URL = "http://www.eclipse.org/eclipselink/xsds/persistence/orm"; //$NON-NLS-1$ - String ECLIPSELINK_ORM_SCHEMA_LOC_1_0 = "http://www.eclipse.org/eclipselink/xsds/eclipselink_orm_1_0.xsd"; //$NON-NLS-1$ - - String VERSION_1_0_TEXT = "1.0"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaAnnotationDefinitionProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaAnnotationDefinitionProvider.java deleted file mode 100644 index 0e8b4a4120..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaAnnotationDefinitionProvider.java +++ /dev/null @@ -1,100 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import java.util.List; -import org.eclipse.jpt.core.JpaAnnotationDefinitionProvider; -import org.eclipse.jpt.core.internal.platform.AbstractJpaAnnotationDefintionProvider; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.BasicCollectionImpl.BasicCollectionAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.BasicMapImpl.BasicMapAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.CacheImpl.CacheAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ChangeTrackingImpl.ChangeTrackingAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ConvertImpl.ConvertAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ConverterImpl.ConverterAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.CustomizerImpl.CustomizerAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ExistenceCheckingImpl.ExistenceCheckingAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.JoinFetchImpl.JoinFetchAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.MutableImpl.MutableAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ObjectTypeConverterImpl.ObjectTypeConverterAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.PrivateOwnedImpl.PrivateOwnedAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ReadOnlyImpl.ReadOnlyAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.ReadTransformerImpl.ReadTransformerAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.StructConverterImpl.StructConverterAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.TransformationImpl.TransformationAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.TypeConverterImpl.TypeConverterAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.VariableOneToOneImpl.VariableOneToOneAnnotationDefinition; -import org.eclipse.jpt.eclipselink.core.internal.resource.java.WriteTransformerImpl.WriteTransformerAnnotationDefinition; - -/** - * Provides annotations for 1.0 EclipseLink platform which includes JPA annotations and - * EclipseLink 1.0 annotations - */ -public class EclipseLinkJpaAnnotationDefinitionProvider - extends AbstractJpaAnnotationDefintionProvider -{ - // singleton - private static final JpaAnnotationDefinitionProvider INSTANCE = new EclipseLinkJpaAnnotationDefinitionProvider(); - - /** - * Return the singleton. - */ - public static JpaAnnotationDefinitionProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkJpaAnnotationDefinitionProvider() { - super(); - } - - @Override - protected void addTypeMappingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - //none - } - - @Override - protected void addTypeSupportingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - definitions.add(CacheAnnotationDefinition.instance()); - definitions.add(ChangeTrackingAnnotationDefinition.instance()); - definitions.add(ConverterAnnotationDefinition.instance()); - definitions.add(CustomizerAnnotationDefinition.instance()); - definitions.add(ExistenceCheckingAnnotationDefinition.instance()); - definitions.add(ObjectTypeConverterAnnotationDefinition.instance()); - definitions.add(ReadOnlyAnnotationDefinition.instance()); - definitions.add(StructConverterAnnotationDefinition.instance()); - definitions.add(TypeConverterAnnotationDefinition.instance()); - } - - // 245996 addresses how the attribute mapping annotations should be ordered - @Override - protected void addAttributeMappingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - definitions.add(BasicCollectionAnnotationDefinition.instance()); - definitions.add(BasicMapAnnotationDefinition.instance()); - definitions.add(TransformationAnnotationDefinition.instance()); - definitions.add(VariableOneToOneAnnotationDefinition.instance()); - } - - @Override - protected void addAttributeSupportingAnnotationDefinitionsTo(List<AnnotationDefinition> definitions) { - definitions.add(ConvertAnnotationDefinition.instance()); - definitions.add(ConverterAnnotationDefinition.instance()); - definitions.add(JoinFetchAnnotationDefinition.instance()); - definitions.add(MutableAnnotationDefinition.instance()); - definitions.add(ObjectTypeConverterAnnotationDefinition.instance()); - definitions.add(PrivateOwnedAnnotationDefinition.instance()); - definitions.add(ReadTransformerAnnotationDefinition.instance()); - definitions.add(StructConverterAnnotationDefinition.instance()); - definitions.add(TypeConverterAnnotationDefinition.instance()); - definitions.add(WriteTransformerAnnotationDefinition.instance()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaFactory.java deleted file mode 100644 index 23e9f0d14b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaFactory.java +++ /dev/null @@ -1,339 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.jpt.core.context.MappingFile; -import org.eclipse.jpt.core.context.java.JavaBasicMapping; -import org.eclipse.jpt.core.context.java.JavaEmbeddable; -import org.eclipse.jpt.core.context.java.JavaEmbeddedIdMapping; -import org.eclipse.jpt.core.context.java.JavaEmbeddedMapping; -import org.eclipse.jpt.core.context.java.JavaIdMapping; -import org.eclipse.jpt.core.context.java.JavaManyToManyMapping; -import org.eclipse.jpt.core.context.java.JavaManyToOneMapping; -import org.eclipse.jpt.core.context.java.JavaOneToManyMapping; -import org.eclipse.jpt.core.context.java.JavaOneToOneMapping; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.context.java.JavaPersistentType; -import org.eclipse.jpt.core.context.java.JavaVersionMapping; -import org.eclipse.jpt.core.context.orm.EntityMappings; -import org.eclipse.jpt.core.context.orm.OrmBasicMapping; -import org.eclipse.jpt.core.context.orm.OrmEmbeddable; -import org.eclipse.jpt.core.context.orm.OrmEmbeddedIdMapping; -import org.eclipse.jpt.core.context.orm.OrmEmbeddedMapping; -import org.eclipse.jpt.core.context.orm.OrmEntity; -import org.eclipse.jpt.core.context.orm.OrmIdMapping; -import org.eclipse.jpt.core.context.orm.OrmManyToManyMapping; -import org.eclipse.jpt.core.context.orm.OrmManyToOneMapping; -import org.eclipse.jpt.core.context.orm.OrmMappedSuperclass; -import org.eclipse.jpt.core.context.orm.OrmOneToManyMapping; -import org.eclipse.jpt.core.context.orm.OrmOneToOneMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.context.orm.OrmVersionMapping; -import org.eclipse.jpt.core.context.persistence.MappingFileRef; -import org.eclipse.jpt.core.context.persistence.Persistence; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.core.internal.platform.GenericJpaFactory; -import org.eclipse.jpt.core.resource.orm.XmlBasic; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.core.resource.orm.XmlId; -import org.eclipse.jpt.core.resource.orm.XmlManyToMany; -import org.eclipse.jpt.core.resource.orm.XmlManyToOne; -import org.eclipse.jpt.core.resource.orm.XmlOneToMany; -import org.eclipse.jpt.core.resource.orm.XmlOneToOne; -import org.eclipse.jpt.core.resource.orm.XmlVersion; -import org.eclipse.jpt.core.resource.persistence.XmlPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaEntity; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaMappedSuperclass; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaBasicMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaEmbeddableImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaEntityImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaIdMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaManyToManyMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaManyToOneMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaMappedSuperclassImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToManyMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToOneMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaVersionMappingImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicCollectionMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicMapMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaTransformationMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaVariableOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkEntityMappings; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkEntityMappingsImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmBasicMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddableImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddedIdMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddedMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEntityImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmIdMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmManyToManyMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmManyToOneMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmMappedSuperclassImpl; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmOneToManyMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmPersistentType; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmVersionMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmXml; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlBasic; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlEmbedded; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlEmbeddedId; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlId; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlManyToMany; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlManyToOne; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlOneToMany; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlOneToOne; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkVirtualXmlVersion; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmBasicCollectionMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmBasicMapMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmTransformationMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmVariableOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.VirtualXmlBasicCollection; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.VirtualXmlBasicMap; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.VirtualXmlTransformation; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.VirtualXmlVariableOneToOne; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne; - -public class EclipseLinkJpaFactory - extends GenericJpaFactory -{ - protected EclipseLinkJpaFactory() { - super(); - } - - - // ********** Context Nodes ********** - - public MappingFile buildEclipseLinkMappingFile(MappingFileRef parent, EclipseLinkOrmXmlResource resource) { - return this.buildEclipseLinkOrmXml(parent, resource); - } - - protected EclipseLinkOrmXml buildEclipseLinkOrmXml(MappingFileRef parent, EclipseLinkOrmXmlResource resource) { - EclipseLinkOrmXml eclipseLinkOrmXml = new EclipseLinkOrmXml(parent); - eclipseLinkOrmXml.initialize(resource); - return eclipseLinkOrmXml; - } - - - // ********** Persistence Context Model ********** - - @Override - public PersistenceUnit buildPersistenceUnit(Persistence parent, XmlPersistenceUnit persistenceUnit) { - return new EclipseLinkPersistenceUnit(parent, persistenceUnit); - } - - - // ********** EclipseLink-specific ORM Virtual Resource Model ********** - - public XmlBasic buildEclipseLinkVirtualXmlBasic(OrmTypeMapping ormTypeMapping, JavaBasicMapping javaBasicMapping) { - return new EclipseLinkVirtualXmlBasic(ormTypeMapping, javaBasicMapping); - } - - public XmlId buildEclipseLinkVirtualXmlId(OrmTypeMapping ormTypeMapping, JavaIdMapping javaIdMapping) { - return new EclipseLinkVirtualXmlId(ormTypeMapping, javaIdMapping); - } - - public XmlEmbeddedId buildEclipseLinkVirtualXmlEmbeddedId(OrmTypeMapping ormTypeMapping, JavaEmbeddedIdMapping javaEmbeddedIdMapping) { - return new EclipseLinkVirtualXmlEmbeddedId(ormTypeMapping, javaEmbeddedIdMapping); - } - - public XmlEmbedded buildEclipseLinkVirtualXmlEmbedded(OrmTypeMapping ormTypeMapping, JavaEmbeddedMapping javaEmbeddedMapping) { - return new EclipseLinkVirtualXmlEmbedded(ormTypeMapping, javaEmbeddedMapping); - } - - public XmlManyToMany buildEclipseLinkVirtualXmlManyToMany(OrmTypeMapping ormTypeMapping, JavaManyToManyMapping javaManyToManyMapping) { - return new EclipseLinkVirtualXmlManyToMany(ormTypeMapping, javaManyToManyMapping); - } - - public XmlManyToOne buildEclipseLinkVirtualXmlManyToOne(OrmTypeMapping ormTypeMapping, JavaManyToOneMapping javaManyToOneMapping) { - return new EclipseLinkVirtualXmlManyToOne(ormTypeMapping, javaManyToOneMapping); - } - - public XmlOneToMany buildEclipseLinkVirtualXmlOneToMany(OrmTypeMapping ormTypeMapping, JavaOneToManyMapping javaOneToManyMapping) { - return new EclipseLinkVirtualXmlOneToMany(ormTypeMapping, javaOneToManyMapping); - } - - public XmlOneToOne buildEclipseLinkVirtualXmlOneToOne(OrmTypeMapping ormTypeMapping, JavaOneToOneMapping javaOneToOneMapping) { - return new EclipseLinkVirtualXmlOneToOne(ormTypeMapping, javaOneToOneMapping); - } - - public XmlVersion buildEclipseLinkVirtualXmlVersion(OrmTypeMapping ormTypeMapping, JavaVersionMapping javaVersionMapping) { - return new EclipseLinkVirtualXmlVersion(ormTypeMapping, javaVersionMapping); - } - - public XmlBasicCollection buildVirtualXmlBasicCollection(OrmTypeMapping ormTypeMapping, JavaBasicCollectionMapping javaBasicCollectionMapping) { - return new VirtualXmlBasicCollection(ormTypeMapping, javaBasicCollectionMapping); - } - - public XmlBasicMap buildVirtualXmlBasicMap(OrmTypeMapping ormTypeMapping, JavaBasicMapMapping javaBasicMapMapping) { - return new VirtualXmlBasicMap(ormTypeMapping, javaBasicMapMapping); - } - - public XmlTransformation buildVirtualXmlTransformation(OrmTypeMapping ormTypeMapping, JavaTransformationMapping javaTransformationMapping) { - return new VirtualXmlTransformation(ormTypeMapping, javaTransformationMapping); - } - - public XmlVariableOneToOne buildVirtualXmlVariableOneToOne(OrmTypeMapping ormTypeMapping, JavaVariableOneToOneMapping javaVariableOneToOneMapping) { - return new VirtualXmlVariableOneToOne(ormTypeMapping, javaVariableOneToOneMapping); - } - - - // ********** EclipseLink-specific ORM Context Model ********** - - public EntityMappings buildEclipseLinkEntityMappings(EclipseLinkOrmXml parent, XmlEntityMappings xmlEntityMappings) { - EntityMappings entityMappings = new EclipseLinkEntityMappingsImpl(parent); - entityMappings.initialize(xmlEntityMappings); - return entityMappings; - } - - public OrmPersistentType buildEclipseLinkOrmPersistentType(EclipseLinkEntityMappings parent, String mappingKey) { - return new EclipseLinkOrmPersistentType(parent, mappingKey); - } - - public OrmEmbeddable buildEclipseLinkOrmEmbeddable(OrmPersistentType type) { - return new EclipseLinkOrmEmbeddableImpl(type); - } - - public OrmEntity buildEclipseLinkOrmEntity(OrmPersistentType type) { - return new EclipseLinkOrmEntityImpl(type); - } - - public OrmMappedSuperclass buildEclipseLinkOrmMappedSuperclass(OrmPersistentType type) { - return new EclipseLinkOrmMappedSuperclassImpl(type); - } - - public OrmBasicMapping buildEclipseLinkOrmBasicMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmBasicMapping(parent); - } - - public OrmIdMapping buildEclipseLinkOrmIdMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmIdMapping(parent); - } - - public OrmEmbeddedIdMapping buildEclipseLinkOrmEmbeddedIdMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmEmbeddedIdMapping(parent); - } - - public OrmEmbeddedMapping buildEclipseLinkOrmEmbeddedMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmEmbeddedMapping(parent); - } - - public OrmManyToManyMapping buildEclipseLinkOrmManyToManyMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmManyToManyMapping(parent); - } - - public OrmManyToOneMapping buildEclipseLinkOrmManyToOneMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmManyToOneMapping(parent); - } - - public OrmOneToManyMapping buildEclipseLinkOrmOneToManyMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmOneToManyMapping(parent); - } - - public OrmOneToOneMapping buildEclipseLinkOrmOneToOneMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmOneToOneMapping(parent); - } - - public OrmVersionMapping buildEclipseLinkOrmVersionMapping(OrmPersistentAttribute parent) { - return new EclipseLinkOrmVersionMapping(parent); - } - - public OrmBasicCollectionMapping buildOrmBasicCollectionMapping(OrmPersistentAttribute parent) { - return new OrmBasicCollectionMapping(parent); - } - - public OrmBasicMapMapping buildOrmBasicMapMapping(OrmPersistentAttribute parent) { - return new OrmBasicMapMapping(parent); - } - - public OrmTransformationMapping buildOrmTransformationMapping(OrmPersistentAttribute parent) { - return new OrmTransformationMapping(parent); - } - - public OrmVariableOneToOneMapping buildOrmVariableOneToOneMapping(OrmPersistentAttribute parent) { - return new OrmVariableOneToOneMapping(parent); - } - - // ********** Java Context Model ********** - - @Override - public JavaBasicMapping buildJavaBasicMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaBasicMappingImpl(parent); - } - - @Override - public JavaEmbeddable buildJavaEmbeddable(JavaPersistentType parent) { - return new EclipseLinkJavaEmbeddableImpl(parent); - } - - @Override - public EclipseLinkJavaEntity buildJavaEntity(JavaPersistentType parent) { - return new EclipseLinkJavaEntityImpl(parent); - } - - @Override - public JavaIdMapping buildJavaIdMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaIdMappingImpl(parent); - } - - @Override - public EclipseLinkJavaMappedSuperclass buildJavaMappedSuperclass(JavaPersistentType parent) { - return new EclipseLinkJavaMappedSuperclassImpl(parent); - } - - @Override - public JavaVersionMapping buildJavaVersionMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaVersionMappingImpl(parent); - } - - @Override - public JavaOneToManyMapping buildJavaOneToManyMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaOneToManyMappingImpl(parent); - } - - @Override - public JavaOneToOneMapping buildJavaOneToOneMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaOneToOneMappingImpl(parent); - } - - @Override - public JavaManyToManyMapping buildJavaManyToManyMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaManyToManyMappingImpl(parent); - } - - @Override - public JavaManyToOneMapping buildJavaManyToOneMapping(JavaPersistentAttribute parent) { - return new EclipseLinkJavaManyToOneMappingImpl(parent); - } - - public JavaBasicCollectionMapping buildJavaBasicCollectionMapping(JavaPersistentAttribute parent) { - return new JavaBasicCollectionMapping(parent); - } - - public JavaBasicMapMapping buildJavaBasicMapMapping(JavaPersistentAttribute parent) { - return new JavaBasicMapMapping(parent); - } - - public JavaTransformationMapping buildJavaTransformationMapping(JavaPersistentAttribute parent) { - return new JavaTransformationMapping(parent); - } - - public JavaVariableOneToOneMapping buildJavaVariableOneToOneMapping(JavaPersistentAttribute parent) { - return new JavaVariableOneToOneMapping(parent); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformFactory.java deleted file mode 100644 index 9c30d9af93..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformFactory.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.jpt.core.JpaAnnotationProvider; -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.JpaPlatform; -import org.eclipse.jpt.core.JpaPlatformFactory; -import org.eclipse.jpt.core.internal.platform.GenericJpaAnnotationDefinitionProvider; -import org.eclipse.jpt.core.internal.platform.GenericJpaAnnotationProvider; -import org.eclipse.jpt.core.internal.platform.GenericJpaPlatform; -import org.eclipse.jpt.core.internal.platform.GenericJpaPlatformProvider; - -/** - * All the state in the JPA platform should be "static" (i.e. unchanging once - * it is initialized). - */ -public class EclipseLinkJpaPlatformFactory - implements JpaPlatformFactory -{ - - /** - * zero-argument constructor - */ - public EclipseLinkJpaPlatformFactory() { - super(); - } - - public JpaPlatform buildJpaPlatform(String id) { - return new GenericJpaPlatform( - id, - buildJpaFactory(), - buildJpaAnnotationProvider(), - EclipseLinkJpaPlatformProvider.instance(), - //put eclipselink first because of the default java attribute mapping providers order, - //maybe there is a better way to handle that order dependency - GenericJpaPlatformProvider.instance()); - } - - protected JpaFactory buildJpaFactory() { - return new EclipseLinkJpaFactory(); - } - - protected JpaAnnotationProvider buildJpaAnnotationProvider() { - return new GenericJpaAnnotationProvider( - GenericJpaAnnotationDefinitionProvider.instance(), - EclipseLinkJpaAnnotationDefinitionProvider.instance()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformProvider.java deleted file mode 100644 index 81387a5cdb..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaPlatformProvider.java +++ /dev/null @@ -1,147 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import java.util.List; -import org.eclipse.jpt.core.JpaPlatformProvider; -import org.eclipse.jpt.core.JpaResourceModelProvider; -import org.eclipse.jpt.core.context.MappingFileProvider; -import org.eclipse.jpt.core.context.java.DefaultJavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.ExtendedOrmTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmTypeMappingProvider; -import org.eclipse.jpt.core.internal.platform.AbstractJpaPlatformProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.EclipseLinkMappingFileProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToManyMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToOneMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicCollectionMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicMapMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaTransformationMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaVariableOneToOneMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmBasicMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddableProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddedIdMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEmbeddedMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmEntityProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmIdMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmManyToManyMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmManyToOneMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmMappedSuperclassProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmOneToManyMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmOneToOneMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.EclipseLinkOrmVersionMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmBasicCollectionMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmBasicMapMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmTransformationMappingProvider; -import org.eclipse.jpt.eclipselink.core.internal.context.orm.OrmVariableOneToOneMappingProvider; - -/** - * EclipseLink platform - */ -public class EclipseLinkJpaPlatformProvider - extends AbstractJpaPlatformProvider -{ - - public static final String ID = "org.eclipse.eclipselink.platform"; //$NON-NLS-1$ - - // singleton - private static final JpaPlatformProvider INSTANCE = new EclipseLinkJpaPlatformProvider(); - - /** - * Return the singleton. - */ - public static JpaPlatformProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkJpaPlatformProvider() { - super(); - } - - - // ********* JPA files ********* - - @Override - protected void addResourceModelProvidersTo(List<JpaResourceModelProvider> providers) { - providers.add(EclipseLinkOrmResourceModelProvider.instance()); - } - - - // ********* java ********* - - @Override - protected void addJavaTypeMappingProvidersTo(@SuppressWarnings("unused") List<JavaTypeMappingProvider> providers) { - //none specific to EclipseLink - } - - @Override - protected void addJavaAttributeMappingProvidersTo(List<JavaAttributeMappingProvider> providers) { - providers.add(JavaBasicCollectionMappingProvider.instance()); - providers.add(JavaBasicMapMappingProvider.instance()); - providers.add(JavaTransformationMappingProvider.instance()); - providers.add(JavaVariableOneToOneMappingProvider.instance()); - } - - @Override - protected void addDefaultJavaAttributeMappingProvidersTo(List<DefaultJavaAttributeMappingProvider> providers) { - // these need to be checked first, so we can check for Basic last in case the reference object is Serializable - providers.add(EclipseLinkJavaOneToOneMappingProvider.instance()); - providers.add(EclipseLinkJavaOneToManyMappingProvider.instance()); - providers.add(JavaVariableOneToOneMappingProvider.instance()); - } - - - // ********* ORM ********* - - @Override - protected void addOrmTypeMappingProvidersTo(@SuppressWarnings("unused") List<OrmTypeMappingProvider> providers) { - //none specific to EclipseLink - } - - @Override - protected void addMappingFileProvidersTo(List<MappingFileProvider> providers) { - providers.add(EclipseLinkMappingFileProvider.instance()); - } - - @Override - protected void addExtendedOrmTypeMappingProvidersTo(List<ExtendedOrmTypeMappingProvider> providers) { - providers.add(EclipseLinkOrmEmbeddableProvider.instance()); - providers.add(EclipseLinkOrmEntityProvider.instance()); - providers.add(EclipseLinkOrmMappedSuperclassProvider.instance()); - } - - @Override - protected void addOrmAttributeMappingProvidersTo(List<OrmAttributeMappingProvider> providers) { - providers.add(OrmBasicCollectionMappingProvider.instance()); - providers.add(OrmBasicMapMappingProvider.instance()); - providers.add(OrmTransformationMappingProvider.instance()); - providers.add(OrmVariableOneToOneMappingProvider.instance()); - } - - @Override - protected void addExtendedOrmAttributeMappingProvidersTo(List<ExtendedOrmAttributeMappingProvider> providers) { - providers.add(EclipseLinkOrmBasicMappingProvider.instance()); - providers.add(EclipseLinkOrmIdMappingProvider.instance()); - providers.add(EclipseLinkOrmEmbeddedIdMappingProvider.instance()); - providers.add(EclipseLinkOrmEmbeddedMappingProvider.instance()); - providers.add(EclipseLinkOrmManyToManyMappingProvider.instance()); - providers.add(EclipseLinkOrmManyToOneMappingProvider.instance()); - providers.add(EclipseLinkOrmOneToManyMappingProvider.instance()); - providers.add(EclipseLinkOrmOneToOneMappingProvider.instance()); - providers.add(EclipseLinkOrmVersionMappingProvider.instance()); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaValidationMessages.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaValidationMessages.java deleted file mode 100644 index 352eaa4aae..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkJpaValidationMessages.java +++ /dev/null @@ -1,25 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -@SuppressWarnings("nls") -public interface EclipseLinkJpaValidationMessages { - - public static final String BUNDLE_NAME = "eclipselink_jpa_validation"; - - public static final String CACHE_EXPIRY_AND_EXPIRY_TIME_OF_DAY_BOTH_SPECIFIED = "CACHE_EXPIRY_AND_EXPIRY_TIME_OF_DAY_BOTH_SPECIFIED"; - - public static final String CONVERTER_CLASS_IMPLEMENTS_CONVERTER = "CONVERTER_CLASS_IMPLEMENTS_CONVERTER"; - - public static final String CUSTOMIZER_CLASS_IMPLEMENTS_DESCRIPTOR_CUSTOMIZER = "CUSTOMIZER_CLASS_IMPLEMENTS_DESCRIPTOR_CUSTOMIZER"; - - public static final String MULTIPLE_OBJECT_VALUES_FOR_DATA_VALUE = "MULTIPLE_OBJECT_VALUES_FOR_DATA_VALUE"; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkOrmResourceModelProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkOrmResourceModelProvider.java deleted file mode 100644 index 04bf176ca8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/EclipseLinkOrmResourceModelProvider.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.runtime.content.IContentType; -import org.eclipse.jpt.core.JpaProject; -import org.eclipse.jpt.core.JpaResourceModel; -import org.eclipse.jpt.core.JpaResourceModelProvider; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.EclipseLinkOrmXmlResourceProvider; - -/** - * EclipseLink orm.xml - */ -public class EclipseLinkOrmResourceModelProvider - implements JpaResourceModelProvider -{ - // singleton - private static final JpaResourceModelProvider INSTANCE = new EclipseLinkOrmResourceModelProvider(); - - /** - * Return the singleton. - */ - public static JpaResourceModelProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmResourceModelProvider() { - super(); - } - - public IContentType getContentType() { - return JptEclipseLinkCorePlugin.ECLIPSELINK_ORM_XML_CONTENT_TYPE; - } - - public JpaResourceModel buildResourceModel(JpaProject jpaProject, IFile file) { - return EclipseLinkOrmXmlResourceProvider.getXmlResourceProvider(file).getXmlResource(); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/JptEclipseLinkCorePlugin.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/JptEclipseLinkCorePlugin.java deleted file mode 100644 index 314815355c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/JptEclipseLinkCorePlugin.java +++ /dev/null @@ -1,104 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.Platform; -import org.eclipse.core.runtime.Plugin; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.content.IContentType; -import org.eclipse.jpt.core.JptCorePlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - */ -public class JptEclipseLinkCorePlugin extends Plugin -{ - // The plug-in ID - public static final String PLUGIN_ID = "org.eclipse.jpt.eclipselink.core"; //$NON-NLS-1$ - - /** - * Value of the content-type for eclipselink-orm.xml mappings files. Use this - * value to retrieve the ORM xml content type from the content type manager - * and to add new eclipselink-orm.xml-like extensions to this content type. - * - * @see org.eclipse.core.runtime.content.IContentTypeManager#getContentType(String) - */ - public static final IContentType ECLIPSELINK_ORM_XML_CONTENT_TYPE = Platform.getContentTypeManager().getContentType(PLUGIN_ID + ".content.orm"); //$NON-NLS-1$ - - public static final String DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH = "META-INF/eclipselink-orm.xml"; //$NON-NLS-1$ - - - // The shared instance - private static JptEclipseLinkCorePlugin plugin; - - - /** - * The constructor - */ - public JptEclipseLinkCorePlugin() {} - - - /** - * Return the default mapping file deployment URI for the specified project. - * ("WEB-INF/classes/META-INF/eclipselink-orm.xml" for web projects and - * "META-INF/eclipselink-orm.xml" in other cases) - */ - public static String getDefaultEclipseLinkOrmXmlDeploymentURI(IProject project) { - return JptCorePlugin.getDeploymentURI(project, DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH); - } - - /** - * Log the specified status. - */ - public static void log(IStatus status) { - plugin.getLog().log(status); - } - - /** - * Log the specified message. - */ - public static void log(String msg) { - log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.OK, msg, null)); - } - - /** - * Log the specified exception or error. - */ - public static void log(Throwable throwable) { - log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.OK, throwable.getLocalizedMessage(), throwable)); - } - - - // ********** plug-in implementation ********** - - @Override - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - @Override - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static JptEclipseLinkCorePlugin getDefault() { - return plugin; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/EclipseLinkMappingFileProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/EclipseLinkMappingFileProvider.java deleted file mode 100644 index 96d6e37e7e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/EclipseLinkMappingFileProvider.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.MappingFile; -import org.eclipse.jpt.core.context.MappingFileProvider; -import org.eclipse.jpt.core.context.persistence.MappingFileRef; -import org.eclipse.jpt.core.resource.orm.OrmXmlResource; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkMappingFileProvider - implements MappingFileProvider -{ - // singleton - private static final MappingFileProvider INSTANCE = new EclipseLinkMappingFileProvider(); - - /** - * Return the singleton. - */ - public static MappingFileProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkMappingFileProvider() { - super(); - } - - public String getResourceType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public MappingFile buildMappingFile(MappingFileRef parent, OrmXmlResource resource, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkMappingFile(parent, (EclipseLinkOrmXmlResource) resource); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLink1_1JavaPersistentTypeImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLink1_1JavaPersistentTypeImpl.java deleted file mode 100644 index 31a2ee3f3a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLink1_1JavaPersistentTypeImpl.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.AccessType; -import org.eclipse.jpt.core.context.PersistentType; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaPersistentType; -import org.eclipse.jpt.core.resource.java.AccessAnnotation; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.utility.internal.iterators.CompositeIterator; - -public class EclipseLink1_1JavaPersistentTypeImpl extends AbstractJavaPersistentType -{ - protected AccessType specifiedAccess; - - public EclipseLink1_1JavaPersistentTypeImpl(PersistentType.Owner parent, JavaResourcePersistentType jrpt) { - super(parent, jrpt); - } - - protected AccessAnnotation getAccessAnnotation() { - return (AccessAnnotation) this.resourcePersistentType.getNonNullSupportingAnnotation(getAccessAnnotationName()); - } - - protected String getAccessAnnotationName() { - return AccessAnnotation.ANNOTATION_NAME; - } - - public AccessType getSpecifiedAccess() { - return this.specifiedAccess; - } - - public void setSpecifiedAccess(AccessType newSpecifiedAccess) { - AccessType oldAccess = this.specifiedAccess; - this.specifiedAccess = newSpecifiedAccess; - getAccessAnnotation().setValue(AccessType.toJavaResourceModel(newSpecifiedAccess)); - firePropertyChanged(SPECIFIED_ACCESS_PROPERTY, oldAccess, newSpecifiedAccess); - } - - protected void setSpecifiedAccess_(AccessType newSpecifiedAccess) { - AccessType oldAccess = this.specifiedAccess; - this.specifiedAccess = newSpecifiedAccess; - firePropertyChanged(SPECIFIED_ACCESS_PROPERTY, oldAccess, newSpecifiedAccess); - } - - @SuppressWarnings("unchecked") - @Override - protected Iterator<JavaResourcePersistentAttribute> persistentAttributes() { - AccessType specifiedAccess = getSpecifiedAccess(); - if (specifiedAccess == AccessType.FIELD) { - return new CompositeIterator<JavaResourcePersistentAttribute>( - this.resourcePersistentType.persistableFields(), - this.resourcePersistentType.persistablePropertiesWithSpecifiedPropertyAccess()); - - } - else if (specifiedAccess == AccessType.PROPERTY) { - return new CompositeIterator<JavaResourcePersistentAttribute>( - this.resourcePersistentType.persistableProperties(), - this.resourcePersistentType.persistableFieldsWithSpecifiedFieldAccess()); - } - return super.persistentAttributes(); - } - - @Override - protected void initializeAccess() { - super.initializeAccess(); - this.specifiedAccess = this.getResourceAccess(); - } - - @Override - public void updateAccess() { - super.updateAccess(); - this.setSpecifiedAccess_(this.getResourceAccess()); - } - - protected AccessType getResourceAccess() { - return AccessType.fromJavaResourceModel(getAccessAnnotation().getValue()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaBasicMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaBasicMappingImpl.java deleted file mode 100644 index 3b6f520830..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaBasicMappingImpl.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaConverter; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaBasicMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkBasicMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.java.ConvertAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaBasicMappingImpl extends GenericJavaBasicMapping implements EclipseLinkBasicMapping -{ - - protected final EclipseLinkJavaMutable mutable; - - public EclipseLinkJavaBasicMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkJavaMutable(this); - } - - @Override - protected JavaConverter buildSpecifiedConverter(String converterType) { - JavaConverter javaConverter = super.buildSpecifiedConverter(converterType); - if (javaConverter != null) { - return javaConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkJavaConvert(this, this.resourcePersistentAttribute); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (this.resourcePersistentAttribute.getSupportingAnnotation(ConvertAnnotation.ANNOTATION_NAME) != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - //************ EclipselinkJavaBasicMapping implementation **************** - - public Mutable getMutable() { - return this.mutable; - } - - - //************ initialization/update **************** - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.mutable.update(this.resourcePersistentAttribute); - } - - - //************ validation **************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.mutable.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCaching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCaching.java deleted file mode 100644 index f16ace15c3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCaching.java +++ /dev/null @@ -1,557 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaTypeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.CacheCoordinationType; -import org.eclipse.jpt.eclipselink.core.context.CacheType; -import org.eclipse.jpt.eclipselink.core.context.Caching; -import org.eclipse.jpt.eclipselink.core.context.ExistenceType; -import org.eclipse.jpt.eclipselink.core.context.ExpiryTimeOfDay; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.internal.DefaultEclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ExistenceCheckingAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.TimeOfDayAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaCaching extends AbstractJavaJpaContextNode implements JavaCaching -{ - - protected CacheType specifiedType; - protected Integer specifiedSize; - protected Boolean specifiedShared; - protected Boolean specifiedAlwaysRefresh; - protected Boolean specifiedRefreshOnlyIfNewer; - protected Boolean specifiedDisableHits; - - protected boolean existenceChecking; - protected ExistenceType specifiedExistenceType; - protected ExistenceType defaultExistenceType; - - protected CacheCoordinationType specifiedCoordinationType; - - protected Integer expiry; - protected EclipseLinkJavaExpiryTimeOfDay expiryTimeOfDay; - - - protected JavaResourcePersistentType resourcePersistentType; - - public EclipseLinkJavaCaching(JavaTypeMapping parent) { - super(parent); - } - - @Override - public JavaTypeMapping getParent() { - return (JavaTypeMapping) super.getParent(); - } - - - //query for the cache annotation every time on setters. - //call one setter and the CacheAnnotation could change. - //You could call more than one setter before this object has received any notification - //from the java resource model - protected CacheAnnotation getCacheAnnotation() { - return (CacheAnnotation) this.resourcePersistentType.getNonNullSupportingAnnotation(getCacheAnnotationName()); - } - - protected ExistenceCheckingAnnotation getExistenceCheckingAnnotation() { - return (ExistenceCheckingAnnotation) this.resourcePersistentType.getSupportingAnnotation(getExistenceCheckingAnnotationName()); - } - - protected String getCacheAnnotationName() { - return CacheAnnotation.ANNOTATION_NAME; - } - - protected String getExistenceCheckingAnnotationName() { - return ExistenceCheckingAnnotation.ANNOTATION_NAME; - } - - public CacheType getType() { - return (this.getSpecifiedType() == null) ? this.getDefaultType() : this.getSpecifiedType(); - } - - public CacheType getDefaultType() { - return DEFAULT_TYPE; - } - - public CacheType getSpecifiedType() { - return this.specifiedType; - } - - public void setSpecifiedType(CacheType newSpecifiedType) { - CacheType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - this.getCacheAnnotation().setType(CacheType.toJavaResourceModel(newSpecifiedType)); - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - /** - * internal setter used only for updating from the resource model. - * There were problems with InvalidThreadAccess exceptions in the UI - * when you set a value from the UI and the annotation doesn't exist yet. - * Adding the annotation causes an update to occur and then the exception. - */ - protected void setSpecifiedType_(CacheType newSpecifiedType) { - CacheType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - public int getSize() { - return (this.getSpecifiedSize() == null) ? getDefaultSize() : this.getSpecifiedSize().intValue(); - } - - public int getDefaultSize() { - return Caching.DEFAULT_SIZE; - } - - public Integer getSpecifiedSize() { - return this.specifiedSize; - } - - public void setSpecifiedSize(Integer newSpecifiedSize) { - Integer oldSpecifiedSize = this.specifiedSize; - this.specifiedSize = newSpecifiedSize; - getCacheAnnotation().setSize(newSpecifiedSize); - firePropertyChanged(SPECIFIED_SIZE_PROPERTY, oldSpecifiedSize, newSpecifiedSize); - } - - protected void setSpecifiedSize_(Integer newSpecifiedSize) { - Integer oldSpecifiedSize = this.specifiedSize; - this.specifiedSize = newSpecifiedSize; - firePropertyChanged(SPECIFIED_SIZE_PROPERTY, oldSpecifiedSize, newSpecifiedSize); - } - - - public boolean isShared() { - return (this.specifiedShared == null) ? this.isDefaultShared() : this.specifiedShared.booleanValue(); - } - - public boolean isDefaultShared() { - return Caching.DEFAULT_SHARED; - } - - public Boolean getSpecifiedShared() { - return this.specifiedShared; - } - - public void setSpecifiedShared(Boolean newSpecifiedShared) { - Boolean oldShared = this.specifiedShared; - this.specifiedShared = newSpecifiedShared; - this.getCacheAnnotation().setShared(newSpecifiedShared); - firePropertyChanged(Caching.SPECIFIED_SHARED_PROPERTY, oldShared, newSpecifiedShared); - - if (newSpecifiedShared == Boolean.FALSE) { - setSpecifiedType(null); - setSpecifiedSize(null); - setSpecifiedAlwaysRefresh(null); - setSpecifiedRefreshOnlyIfNewer(null); - setSpecifiedDisableHits(null); - setSpecifiedCoordinationType(null); - setExpiry(null); - if (this.expiryTimeOfDay != null) { - removeExpiryTimeOfDay(); - } - } - } - - protected void setSpecifiedShared_(Boolean newSpecifiedShared) { - Boolean oldSpecifiedShared = this.specifiedShared; - this.specifiedShared = newSpecifiedShared; - firePropertyChanged(Caching.SPECIFIED_SHARED_PROPERTY, oldSpecifiedShared, newSpecifiedShared); - } - - public boolean isAlwaysRefresh() { - return (this.specifiedAlwaysRefresh == null) ? this.isDefaultAlwaysRefresh() : this.specifiedAlwaysRefresh.booleanValue(); - } - - public boolean isDefaultAlwaysRefresh() { - return Caching.DEFAULT_ALWAYS_REFRESH; - } - - public Boolean getSpecifiedAlwaysRefresh() { - return this.specifiedAlwaysRefresh; - } - - public void setSpecifiedAlwaysRefresh(Boolean newSpecifiedAlwaysRefresh) { - Boolean oldAlwaysRefresh = this.specifiedAlwaysRefresh; - this.specifiedAlwaysRefresh = newSpecifiedAlwaysRefresh; - this.getCacheAnnotation().setAlwaysRefresh(newSpecifiedAlwaysRefresh); - firePropertyChanged(Caching.SPECIFIED_ALWAYS_REFRESH_PROPERTY, oldAlwaysRefresh, newSpecifiedAlwaysRefresh); - } - - protected void setSpecifiedAlwaysRefresh_(Boolean newSpecifiedAlwaysRefresh) { - Boolean oldAlwaysRefresh = this.specifiedAlwaysRefresh; - this.specifiedAlwaysRefresh = newSpecifiedAlwaysRefresh; - firePropertyChanged(Caching.SPECIFIED_ALWAYS_REFRESH_PROPERTY, oldAlwaysRefresh, newSpecifiedAlwaysRefresh); - } - - public boolean isRefreshOnlyIfNewer() { - return (this.specifiedRefreshOnlyIfNewer == null) ? this.isDefaultRefreshOnlyIfNewer() : this.specifiedRefreshOnlyIfNewer.booleanValue(); - } - - public boolean isDefaultRefreshOnlyIfNewer() { - return Caching.DEFAULT_REFRESH_ONLY_IF_NEWER; - } - - public Boolean getSpecifiedRefreshOnlyIfNewer() { - return this.specifiedRefreshOnlyIfNewer; - } - - public void setSpecifiedRefreshOnlyIfNewer(Boolean newSpecifiedRefreshOnlyIfNewer) { - Boolean oldRefreshOnlyIfNewer = this.specifiedRefreshOnlyIfNewer; - this.specifiedRefreshOnlyIfNewer = newSpecifiedRefreshOnlyIfNewer; - this.getCacheAnnotation().setRefreshOnlyIfNewer(newSpecifiedRefreshOnlyIfNewer); - firePropertyChanged(Caching.SPECIFIED_REFRESH_ONLY_IF_NEWER_PROPERTY, oldRefreshOnlyIfNewer, newSpecifiedRefreshOnlyIfNewer); - } - - protected void setSpecifiedRefreshOnlyIfNewer_(Boolean newSpecifiedRefreshOnlyIfNewer) { - Boolean oldRefreshOnlyIfNewer = this.specifiedRefreshOnlyIfNewer; - this.specifiedRefreshOnlyIfNewer = newSpecifiedRefreshOnlyIfNewer; - firePropertyChanged(Caching.SPECIFIED_REFRESH_ONLY_IF_NEWER_PROPERTY, oldRefreshOnlyIfNewer, newSpecifiedRefreshOnlyIfNewer); - } - - public boolean isDisableHits() { - return (this.specifiedDisableHits == null) ? this.isDefaultDisableHits() : this.specifiedDisableHits.booleanValue(); - } - - public boolean isDefaultDisableHits() { - return Caching.DEFAULT_DISABLE_HITS; - } - - public Boolean getSpecifiedDisableHits() { - return this.specifiedDisableHits; - } - - public void setSpecifiedDisableHits(Boolean newSpecifiedDisableHits) { - Boolean oldDisableHits = this.specifiedDisableHits; - this.specifiedDisableHits = newSpecifiedDisableHits; - this.getCacheAnnotation().setDisableHits(newSpecifiedDisableHits); - firePropertyChanged(Caching.SPECIFIED_DISABLE_HITS_PROPERTY, oldDisableHits, newSpecifiedDisableHits); - } - - protected void setSpecifiedDisableHits_(Boolean newSpecifiedDisableHits) { - Boolean oldDisableHits = this.specifiedDisableHits; - this.specifiedDisableHits = newSpecifiedDisableHits; - firePropertyChanged(Caching.SPECIFIED_DISABLE_HITS_PROPERTY, oldDisableHits, newSpecifiedDisableHits); - } - - public CacheCoordinationType getCoordinationType() { - return (this.getSpecifiedCoordinationType() == null) ? this.getDefaultCoordinationType() : this.getSpecifiedCoordinationType(); - } - - public CacheCoordinationType getDefaultCoordinationType() { - return DEFAULT_COORDINATION_TYPE; - } - - public CacheCoordinationType getSpecifiedCoordinationType() { - return this.specifiedCoordinationType; - } - - public void setSpecifiedCoordinationType(CacheCoordinationType newSpecifiedCoordinationType) { - CacheCoordinationType oldSpecifiedCoordinationType = this.specifiedCoordinationType; - this.specifiedCoordinationType = newSpecifiedCoordinationType; - this.getCacheAnnotation().setCoordinationType(CacheCoordinationType.toJavaResourceModel(newSpecifiedCoordinationType)); - firePropertyChanged(SPECIFIED_COORDINATION_TYPE_PROPERTY, oldSpecifiedCoordinationType, newSpecifiedCoordinationType); - } - - /** - * internal setter used only for updating from the resource model. - * There were problems with InvalidThreadAccess exceptions in the UI - * when you set a value from the UI and the annotation doesn't exist yet. - * Adding the annotation causes an update to occur and then the exception. - */ - protected void setSpecifiedCoordinationType_(CacheCoordinationType newSpecifiedCoordinationType) { - CacheCoordinationType oldSpecifiedCoordinationType = this.specifiedCoordinationType; - this.specifiedCoordinationType = newSpecifiedCoordinationType; - firePropertyChanged(SPECIFIED_COORDINATION_TYPE_PROPERTY, oldSpecifiedCoordinationType, newSpecifiedCoordinationType); - } - - public boolean hasExistenceChecking() { - return this.existenceChecking; - } - - public void setExistenceChecking(boolean newExistenceChecking) { - boolean oldExistenceChecking = this.existenceChecking; - this.existenceChecking = newExistenceChecking; - if (newExistenceChecking) { - this.resourcePersistentType.addSupportingAnnotation(getExistenceCheckingAnnotationName()); - } - else { - this.resourcePersistentType.removeSupportingAnnotation(getExistenceCheckingAnnotationName()); - } - firePropertyChanged(EXISTENCE_CHECKING_PROPERTY, oldExistenceChecking, newExistenceChecking); - setDefaultExistenceType(caclulateDefaultExistenceType()); - } - - protected void setExistenceChecking_(boolean newExistenceChecking) { - boolean oldExistenceChecking = this.existenceChecking; - this.existenceChecking = newExistenceChecking; - firePropertyChanged(EXISTENCE_CHECKING_PROPERTY, oldExistenceChecking, newExistenceChecking); - } - - protected ExistenceType caclulateDefaultExistenceType() { - if (hasExistenceChecking()) { - return ExistenceType.CHECK_CACHE; - } - return DEFAULT_EXISTENCE_TYPE; - } - - public ExistenceType getExistenceType() { - return (this.getSpecifiedExistenceType() == null) ? this.getDefaultExistenceType() : this.getSpecifiedExistenceType(); - } - - public ExistenceType getDefaultExistenceType() { - return this.defaultExistenceType; - } - - protected void setDefaultExistenceType(ExistenceType newDefaultExistenceType) { - ExistenceType oldDefaultExistenceType = this.defaultExistenceType; - this.defaultExistenceType = newDefaultExistenceType; - firePropertyChanged(DEFAULT_EXISTENCE_TYPE_PROPERTY, oldDefaultExistenceType, newDefaultExistenceType); - } - - public ExistenceType getSpecifiedExistenceType() { - return this.specifiedExistenceType; - } - - public void setSpecifiedExistenceType(ExistenceType newSpecifiedExistenceType) { - if (!hasExistenceChecking()) { - if (newSpecifiedExistenceType != null) { - setExistenceChecking(true); - } - else { - return; - } - } - ExistenceType oldSpecifiedExistenceType = this.specifiedExistenceType; - this.specifiedExistenceType = newSpecifiedExistenceType; - this.getExistenceCheckingAnnotation().setValue(ExistenceType.toJavaResourceModel(newSpecifiedExistenceType)); - firePropertyChanged(SPECIFIED_EXISTENCE_TYPE_PROPERTY, oldSpecifiedExistenceType, newSpecifiedExistenceType); - } - - /** - * internal setter used only for updating from the resource model. - * There were problems with InvalidThreadAccess exceptions in the UI - * when you set a value from the UI and the annotation doesn't exist yet. - * Adding the annotation causes an update to occur and then the exception. - */ - protected void setSpecifiedExistenceType_(ExistenceType newSpecifiedExistenceType) { - ExistenceType oldSpecifiedExistenceType = this.specifiedExistenceType; - this.specifiedExistenceType = newSpecifiedExistenceType; - firePropertyChanged(SPECIFIED_EXISTENCE_TYPE_PROPERTY, oldSpecifiedExistenceType, newSpecifiedExistenceType); - } - - public Integer getExpiry() { - return this.expiry; - } - - public void setExpiry(Integer newExpiry) { - Integer oldExpiry = this.expiry; - this.expiry = newExpiry; - getCacheAnnotation().setExpiry(newExpiry); - firePropertyChanged(EXPIRY_PROPERTY, oldExpiry, newExpiry); - if (newExpiry != null && this.expiryTimeOfDay != null) { - removeExpiryTimeOfDay(); - } - } - - protected void setExpiry_(Integer newExpiry) { - Integer oldExpiry = this.expiry; - this.expiry = newExpiry; - firePropertyChanged(EXPIRY_PROPERTY, oldExpiry, newExpiry); - } - - public ExpiryTimeOfDay getExpiryTimeOfDay() { - return this.expiryTimeOfDay; - } - - public ExpiryTimeOfDay addExpiryTimeOfDay() { - if (this.expiryTimeOfDay != null) { - throw new IllegalStateException("expiryTimeOfDay already exists, use getExpiryTimeOfDay()"); //$NON-NLS-1$ - } - if (this.resourcePersistentType.getSupportingAnnotation(getCacheAnnotationName()) == null) { - this.resourcePersistentType.addSupportingAnnotation(getCacheAnnotationName()); - } - EclipseLinkJavaExpiryTimeOfDay newExpiryTimeOfDay = new EclipseLinkJavaExpiryTimeOfDay(this); - this.expiryTimeOfDay = newExpiryTimeOfDay; - TimeOfDayAnnotation timeOfDayAnnotation = getCacheAnnotation().addExpiryTimeOfDay(); - newExpiryTimeOfDay.initialize(timeOfDayAnnotation); - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, null, newExpiryTimeOfDay); - setExpiry(null); - return newExpiryTimeOfDay; - } - - public void removeExpiryTimeOfDay() { - if (this.expiryTimeOfDay == null) { - throw new IllegalStateException("timeOfDayExpiry does not exist"); //$NON-NLS-1$ - } - ExpiryTimeOfDay oldExpiryTimeOfDay = this.expiryTimeOfDay; - this.expiryTimeOfDay = null; - getCacheAnnotation().removeExpiryTimeOfDay(); - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, oldExpiryTimeOfDay, null); - } - - protected void setExpiryTimeOfDay(EclipseLinkJavaExpiryTimeOfDay newExpiryTimeOfDay) { - EclipseLinkJavaExpiryTimeOfDay oldExpiryTimeOfDay = this.expiryTimeOfDay; - this.expiryTimeOfDay = newExpiryTimeOfDay; - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, oldExpiryTimeOfDay, newExpiryTimeOfDay); - } - - public void initialize(JavaResourcePersistentType resourcePersistentType) { - this.resourcePersistentType = resourcePersistentType; - initialize(getCacheAnnotation()); - initialize(getExistenceCheckingAnnotation()); - } - - protected void initialize(CacheAnnotation cache) { - this.specifiedType = this.specifiedType(cache); - this.specifiedSize = this.specifiedSize(cache); - this.specifiedShared = this.specifiedShared(cache); - this.specifiedAlwaysRefresh = this.specifiedAlwaysRefresh(cache); - this.specifiedRefreshOnlyIfNewer = this.specifiedRefreshOnlyIfNewer(cache); - this.specifiedDisableHits = this.specifiedDisableHits(cache); - this.specifiedCoordinationType = this.specifiedCoordinationType(cache); - this.initializeExpiry(cache); - } - - protected void initialize(ExistenceCheckingAnnotation existenceChecking) { - this.existenceChecking = existenceChecking != null; - this.specifiedExistenceType = specifiedExistenceType(existenceChecking); - this.defaultExistenceType = this.caclulateDefaultExistenceType(); - } - - protected void initializeExpiry(CacheAnnotation cache) { - if (cache.getExpiryTimeOfDay() == null) { - this.expiry = cache.getExpiry(); - } - else { - if (cache.getExpiry() == null) { //handle with validation if both expiry and expiryTimeOfDay are set - this.expiryTimeOfDay = new EclipseLinkJavaExpiryTimeOfDay(this); - this.expiryTimeOfDay.initialize(cache.getExpiryTimeOfDay()); - } - } - } - - public void update(JavaResourcePersistentType resourcePersistentType) { - this.resourcePersistentType = resourcePersistentType; - update(getCacheAnnotation()); - update(getExistenceCheckingAnnotation()); - updateExpiry(getCacheAnnotation()); - } - - protected void update(CacheAnnotation cache) { - setSpecifiedType_(this.specifiedType(cache)); - setSpecifiedSize_(this.specifiedSize(cache)); - setSpecifiedShared_(this.specifiedShared(cache)); - setSpecifiedAlwaysRefresh_(this.specifiedAlwaysRefresh(cache)); - setSpecifiedRefreshOnlyIfNewer_(this.specifiedRefreshOnlyIfNewer(cache)); - setSpecifiedDisableHits_(this.specifiedDisableHits(cache)); - setSpecifiedCoordinationType_(this.specifiedCoordinationType(cache)); - } - - protected void update(ExistenceCheckingAnnotation existenceChecking) { - setExistenceChecking_(existenceChecking != null); - setSpecifiedExistenceType_(specifiedExistenceType(existenceChecking)); - setDefaultExistenceType(caclulateDefaultExistenceType()); - } - - protected void updateExpiry(CacheAnnotation cache) { - if (cache.getExpiryTimeOfDay() == null) { - setExpiryTimeOfDay(null); - setExpiry_(cache.getExpiry()); - } - else { - if (this.expiryTimeOfDay != null) { - this.expiryTimeOfDay.update(cache.getExpiryTimeOfDay()); - } - else if (cache.getExpiry() == null){ - setExpiryTimeOfDay(new EclipseLinkJavaExpiryTimeOfDay(this)); - this.expiryTimeOfDay.initialize(cache.getExpiryTimeOfDay()); - } - else { //handle with validation if both expiry and expiryTimeOfDay are set - setExpiryTimeOfDay(null); - } - } - } - - protected CacheType specifiedType(CacheAnnotation cache) { - return CacheType.fromJavaResourceModel(cache.getType()); - } - - protected Integer specifiedSize(CacheAnnotation cache) { - return cache.getSize(); - } - - protected Boolean specifiedShared(CacheAnnotation cache) { - return cache.getShared(); - } - - protected Boolean specifiedAlwaysRefresh(CacheAnnotation cache) { - return cache.getAlwaysRefresh(); - } - - protected Boolean specifiedRefreshOnlyIfNewer(CacheAnnotation cache) { - return cache.getRefreshOnlyIfNewer(); - } - - protected Boolean specifiedDisableHits(CacheAnnotation cache) { - return cache.getDisableHits(); - } - - protected CacheCoordinationType specifiedCoordinationType(CacheAnnotation cache) { - return CacheCoordinationType.fromJavaResourceModel(cache.getCoordinationType()); - } - - protected Integer expiry(CacheAnnotation cache) { - return cache.getExpiry(); - } - - protected ExistenceType specifiedExistenceType(ExistenceCheckingAnnotation existenceChecking) { - if (existenceChecking == null) { - return null; - } - return ExistenceType.fromJavaResourceModel(existenceChecking.getValue()); - } - - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - TextRange textRange = getCacheAnnotation().getTextRange(astRoot); - return (textRange != null) ? textRange : this.getParent().getValidationTextRange(astRoot); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.validateExpiry(messages, astRoot); - } - - protected void validateExpiry(List<IMessage> messages, CompilationUnit astRoot) { - CacheAnnotation cache = getCacheAnnotation(); - if (cache.getExpiry() != null && cache.getExpiryTimeOfDay() != null) { - messages.add( - DefaultEclipseLinkJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - EclipseLinkJpaValidationMessages.CACHE_EXPIRY_AND_EXPIRY_TIME_OF_DAY_BOTH_SPECIFIED, - new String[] {this.getParent().getPersistentType().getName()}, - this, - getValidationTextRange(astRoot) - ) - ); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaChangeTracking.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaChangeTracking.java deleted file mode 100644 index 429c3281fa..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaChangeTracking.java +++ /dev/null @@ -1,134 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaTypeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.ChangeTrackingType; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingAnnotation; - -public class EclipseLinkJavaChangeTracking extends AbstractJavaJpaContextNode implements ChangeTracking -{ - protected JavaResourcePersistentType resourcePersistentType; - - protected ChangeTrackingType specifiedType; - - - public EclipseLinkJavaChangeTracking(JavaTypeMapping parent) { - super(parent); - } - - @Override - public JavaTypeMapping getParent() { - return (JavaTypeMapping) super.getParent(); - } - - @Override - protected EclipseLinkJpaFactory getJpaFactory() { - return (EclipseLinkJpaFactory) super.getJpaFactory(); - } - - protected String getChangeTrackingAnnotationName() { - return ChangeTrackingAnnotation.ANNOTATION_NAME; - } - - protected ChangeTrackingAnnotation getChangeTrackingAnnotation() { - return (ChangeTrackingAnnotation) this.resourcePersistentType.getSupportingAnnotation(getChangeTrackingAnnotationName()); - } - - protected void addChangeTrackingAnnotation() { - this.resourcePersistentType.addSupportingAnnotation(getChangeTrackingAnnotationName()); - } - - protected void removeChangeTrackingAnnotation() { - this.resourcePersistentType.removeSupportingAnnotation(getChangeTrackingAnnotationName()); - } - - public ChangeTrackingType getType() { - return (this.getSpecifiedType() != null) ? this.getSpecifiedType() : this.getDefaultType(); - } - - public ChangeTrackingType getDefaultType() { - return DEFAULT_TYPE; - } - - public ChangeTrackingType getSpecifiedType() { - return this.specifiedType; - } - - public void setSpecifiedType(ChangeTrackingType newSpecifiedType) { - if (this.specifiedType == newSpecifiedType) { - return; - } - - ChangeTrackingType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - - if (newSpecifiedType != null) { - if (getChangeTrackingAnnotation() == null) { - addChangeTrackingAnnotation(); - } - getChangeTrackingAnnotation().setValue(ChangeTrackingType.toJavaResourceModel(newSpecifiedType)); - } - else { - if (getChangeTrackingAnnotation() != null) { - removeChangeTrackingAnnotation(); - } - } - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - /** - * internal setter used only for updating from the resource model. - * There were problems with InvalidThreadAccess exceptions in the UI - * when you set a value from the UI and the annotation doesn't exist yet. - * Adding the annotation causes an update to occur and then the exception. - */ - protected void setSpecifiedType_(ChangeTrackingType newSpecifiedType) { - ChangeTrackingType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - public void initialize(JavaResourcePersistentType resourcePersistentType) { - this.resourcePersistentType = resourcePersistentType; - ChangeTrackingAnnotation changeTrackingAnnotation = this.getChangeTrackingAnnotation(); - this.specifiedType = changeTrackingType(changeTrackingAnnotation); - } - - public void update(JavaResourcePersistentType resourcePersistentType) { - this.resourcePersistentType = resourcePersistentType; - ChangeTrackingAnnotation changeTrackingAnnotation = this.getChangeTrackingAnnotation(); - this.setSpecifiedType_(changeTrackingType(changeTrackingAnnotation)); - } - - protected ChangeTrackingType changeTrackingType(ChangeTrackingAnnotation changeTracking) { - if (changeTracking == null) { - return null; - } - else if (changeTracking.getValue() == null) { - return ChangeTracking.DEFAULT_TYPE; - } - else { - return ChangeTrackingType.fromJavaResourceModel(changeTracking.getValue()); - } - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - ChangeTrackingAnnotation changeTrackingAnnotation = getChangeTrackingAnnotation(); - TextRange textRange = changeTrackingAnnotation == null ? null : changeTrackingAnnotation.getTextRange(astRoot); - return (textRange != null) ? textRange : this.getParent().getValidationTextRange(astRoot); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConversionValue.java deleted file mode 100644 index c1c579d3b9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConversionValue.java +++ /dev/null @@ -1,131 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.internal.DefaultEclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.resource.java.ConversionValueAnnotation; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaConversionValue extends AbstractJavaJpaContextNode implements ConversionValue -{ - private ConversionValueAnnotation resourceConversionValue; - - private String dataValue; - - private String objectValue; - - public EclipseLinkJavaConversionValue(EclipseLinkJavaObjectTypeConverter parent) { - super(parent); - } - - @Override - public EclipseLinkJavaObjectTypeConverter getParent() { - return (EclipseLinkJavaObjectTypeConverter) super.getParent(); - } - - protected String getAnnotationName() { - return ConversionValueAnnotation.ANNOTATION_NAME; - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return this.resourceConversionValue.getTextRange(astRoot); - } - - public String getDataValue() { - return this.dataValue; - } - - public void setDataValue(String newDataValue) { - String oldDataValue = this.dataValue; - this.dataValue = newDataValue; - this.resourceConversionValue.setDataValue(newDataValue); - firePropertyChanged(DATA_VALUE_PROPERTY, oldDataValue, newDataValue); - } - - protected void setDataValue_(String newDataValue) { - String oldDataValue = this.dataValue; - this.dataValue = newDataValue; - firePropertyChanged(DATA_VALUE_PROPERTY, oldDataValue, newDataValue); - } - - public String getObjectValue() { - return this.objectValue; - } - - public void setObjectValue(String newObjectValue) { - String oldObjectValue = this.objectValue; - this.objectValue = newObjectValue; - this.resourceConversionValue.setObjectValue(newObjectValue); - firePropertyChanged(OBJECT_VALUE_PROPERTY, oldObjectValue, newObjectValue); - } - - protected void setObjectValue_(String newObjectValue) { - String oldObjectValue = this.objectValue; - this.objectValue = newObjectValue; - firePropertyChanged(OBJECT_VALUE_PROPERTY, oldObjectValue, newObjectValue); - } - - public void initialize(ConversionValueAnnotation resourceConversionValue) { - this.resourceConversionValue = resourceConversionValue; - this.dataValue = this.dataValue(); - this.objectValue = this.objectValue(); - } - - public void update(ConversionValueAnnotation resourceConversionValue) { - this.resourceConversionValue = resourceConversionValue; - this.setDataValue_(this.dataValue()); - this.setObjectValue_(this.objectValue()); - } - - protected String dataValue() { - return this.resourceConversionValue.getDataValue(); - } - - protected String objectValue() { - return this.resourceConversionValue.getObjectValue(); - } - - public TextRange getDataValueTextRange(CompilationUnit astRoot) { - return this.resourceConversionValue.getDataValueTextRange(astRoot); - } - - public TextRange getObjectValueTextRange(CompilationUnit astRoot) { - return this.resourceConversionValue.getObjectValueTextRange(astRoot); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - validateDataValuesUnique(messages, astRoot); - } - - protected void validateDataValuesUnique(List<IMessage> messages, CompilationUnit astRoot) { - List<String> dataValues = CollectionTools.list(getParent().dataValues()); - dataValues.remove(this.dataValue); - if (dataValues.contains(this.dataValue)) { - messages.add( - DefaultEclipseLinkJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - EclipseLinkJpaValidationMessages.MULTIPLE_OBJECT_VALUES_FOR_DATA_VALUE, - new String[] {this.dataValue}, - this, - this.getDataValueTextRange(astRoot) - ) - ); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConvert.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConvert.java deleted file mode 100644 index 4c7eaf15c4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConvert.java +++ /dev/null @@ -1,224 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaConverter; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.resource.java.ConvertAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ObjectTypeConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.StructConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.TypeConverterAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaConvert extends AbstractJavaJpaContextNode implements Convert, JavaConverter -{ - private String specifiedConverterName; - - private JavaResourcePersistentAttribute resourcePersistentAttribute; - - private EclipseLinkJavaConverter converter; - - public EclipseLinkJavaConvert(JavaAttributeMapping parent, JavaResourcePersistentAttribute jrpa) { - super(parent); - this.initialize(jrpa); - } - - @Override - public JavaAttributeMapping getParent() { - return (JavaAttributeMapping) super.getParent(); - } - - public String getType() { - return Convert.ECLIPSE_LINK_CONVERTER; - } - - protected String getAnnotationName() { - return ConvertAnnotation.ANNOTATION_NAME; - } - - public void addToResourceModel() { - this.resourcePersistentAttribute.addSupportingAnnotation(getAnnotationName()); - } - - public void removeFromResourceModel() { - this.resourcePersistentAttribute.removeSupportingAnnotation(getAnnotationName()); - if (getConverter() != null) { - this.resourcePersistentAttribute.removeSupportingAnnotation(getConverter().getAnnotationName()); - } - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return getResourceConvert().getTextRange(astRoot); - } - - protected ConvertAnnotation getResourceConvert() { - return (ConvertAnnotation) this.resourcePersistentAttribute.getSupportingAnnotation(getAnnotationName()); - } - - public String getConverterName() { - return getSpecifiedConverterName() == null ? getDefaultConverterName() : getSpecifiedConverterName(); - } - - public String getDefaultConverterName() { - return DEFAULT_CONVERTER_NAME; - } - - public String getSpecifiedConverterName() { - return this.specifiedConverterName; - } - - public void setSpecifiedConverterName(String newSpecifiedConverterName) { - String oldSpecifiedConverterName = this.specifiedConverterName; - this.specifiedConverterName = newSpecifiedConverterName; - getResourceConvert().setValue(newSpecifiedConverterName); - firePropertyChanged(SPECIFIED_CONVERTER_NAME_PROPERTY, oldSpecifiedConverterName, newSpecifiedConverterName); - } - - protected void setSpecifiedConverterName_(String newSpecifiedConverterName) { - String oldSpecifiedConverterName = this.specifiedConverterName; - this.specifiedConverterName = newSpecifiedConverterName; - firePropertyChanged(SPECIFIED_CONVERTER_NAME_PROPERTY, oldSpecifiedConverterName, newSpecifiedConverterName); - } - - public EclipseLinkJavaConverter getConverter() { - return this.converter; - } - - protected String getConverterType() { - if (this.converter == null) { - return EclipseLinkConverter.NO_CONVERTER; - } - return this.converter.getType(); - } - - public void setConverter(String converterType) { - if (getConverterType() == converterType) { - return; - } - EclipseLinkJavaConverter oldConverter = this.converter; - EclipseLinkJavaConverter newConverter = buildConverter(converterType); - this.converter = null; - if (oldConverter != null) { - this.resourcePersistentAttribute.removeSupportingAnnotation(oldConverter.getAnnotationName()); - } - this.converter = newConverter; - if (newConverter != null) { - this.resourcePersistentAttribute.addSupportingAnnotation(newConverter.getAnnotationName()); - } - firePropertyChanged(CONVERTER_PROPERTY, oldConverter, newConverter); - } - - protected void setConverter(EclipseLinkJavaConverter newConverter) { - EclipseLinkJavaConverter oldConverter = this.converter; - this.converter = newConverter; - firePropertyChanged(CONVERTER_PROPERTY, oldConverter, newConverter); - } - - protected void initialize(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - this.specifiedConverterName = this.getResourceConverterName(); - this.converter = this.buildConverter(this.getResourceConverterType()); - } - - public void update(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - this.setSpecifiedConverterName_(this.getResourceConverterName()); - if (getResourceConverterType() == getConverterType()) { - getConverter().update(this.resourcePersistentAttribute); - } - else { - EclipseLinkJavaConverter javaConverter = buildConverter(getResourceConverterType()); - setConverter(javaConverter); - } - } - - protected String getResourceConverterName() { - ConvertAnnotation resourceConvert = getResourceConvert(); - return resourceConvert == null ? null : resourceConvert.getValue(); - } - - - protected EclipseLinkJavaConverter buildConverter(String converterType) { - if (converterType == EclipseLinkConverter.NO_CONVERTER) { - return null; - } - if (converterType == EclipseLinkConverter.CUSTOM_CONVERTER) { - return buildCustomConverter(); - } - else if (converterType == EclipseLinkConverter.TYPE_CONVERTER) { - return buildTypeConverter(); - } - else if (converterType == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return buildObjectTypeConverter(); - } - else if (converterType == EclipseLinkConverter.STRUCT_CONVERTER) { - return buildStructConverter(); - } - return null; - } - - protected EclipseLinkJavaCustomConverter buildCustomConverter() { - EclipseLinkJavaCustomConverter contextConverter = new EclipseLinkJavaCustomConverter(this); - contextConverter.initialize(this.resourcePersistentAttribute); - return contextConverter; - } - - protected EclipseLinkJavaTypeConverter buildTypeConverter() { - EclipseLinkJavaTypeConverter contextConverter = new EclipseLinkJavaTypeConverter(this); - contextConverter.initialize(this.resourcePersistentAttribute); - return contextConverter; - } - - protected EclipseLinkJavaObjectTypeConverter buildObjectTypeConverter() { - EclipseLinkJavaObjectTypeConverter contextConverter = new EclipseLinkJavaObjectTypeConverter(this); - contextConverter.initialize(this.resourcePersistentAttribute); - return contextConverter; - } - - protected EclipseLinkJavaStructConverter buildStructConverter() { - EclipseLinkJavaStructConverter contextConverter = new EclipseLinkJavaStructConverter(this); - contextConverter.initialize(this.resourcePersistentAttribute); - return contextConverter; - } - - protected String getResourceConverterType() { - if (this.resourcePersistentAttribute.getSupportingAnnotation(ConverterAnnotation.ANNOTATION_NAME) != null) { - return EclipseLinkConverter.CUSTOM_CONVERTER; - } - else if (this.resourcePersistentAttribute.getSupportingAnnotation(TypeConverterAnnotation.ANNOTATION_NAME) != null) { - return EclipseLinkConverter.TYPE_CONVERTER; - } - else if (this.resourcePersistentAttribute.getSupportingAnnotation(ObjectTypeConverterAnnotation.ANNOTATION_NAME) != null) { - return EclipseLinkConverter.OBJECT_TYPE_CONVERTER; - } - else if (this.resourcePersistentAttribute.getSupportingAnnotation(StructConverterAnnotation.ANNOTATION_NAME) != null) { - return EclipseLinkConverter.STRUCT_CONVERTER; - } - - return null; - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - if (getConverter() != null) { - getConverter().validate(messages, astRoot); - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverter.java deleted file mode 100644 index 07467fc5ee..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverter.java +++ /dev/null @@ -1,105 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.resource.java.NamedConverterAnnotation; -import org.eclipse.jpt.utility.internal.StringTools; - -public abstract class EclipseLinkJavaConverter extends AbstractJavaJpaContextNode - implements EclipseLinkConverter -{ - private JavaResourcePersistentMember resourcePersistentMember; - - private String name; - - - protected EclipseLinkJavaConverter(JavaJpaContextNode parent) { - super(parent); - } - - - protected NamedConverterAnnotation getAnnotation() { - return (NamedConverterAnnotation) this.resourcePersistentMember.getSupportingAnnotation(getAnnotationName()); - } - - protected abstract String getAnnotationName(); - - @Override - public EclipseLinkPersistenceUnit getPersistenceUnit() { - return (EclipseLinkPersistenceUnit) super.getPersistenceUnit(); - } - - - // **************** name *************************************************** - - public String getName() { - return this.name; - } - - public void setName(String newName) { - String oldName = this.name; - this.name = newName; - getAnnotation().setName(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - protected void setName_(String newName) { - String oldName = this.name; - this.name = newName; - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - - // **************** resource interaction *********************************** - - protected void initialize(JavaResourcePersistentMember jrpm) { - this.resourcePersistentMember = jrpm; - this.name = this.name(getAnnotation()); - getPersistenceUnit().addConverter(this); - } - - protected void update(JavaResourcePersistentMember jrpm) { - this.resourcePersistentMember = jrpm; - this.setName_(this.name(getAnnotation())); - getPersistenceUnit().addConverter(this); - } - - protected String name(NamedConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getName(); - } - - - // **************** validation ********************************************* - - public boolean overrides(EclipseLinkConverter converter) { - // java is at the base of the tree - return false; - } - - public boolean duplicates(EclipseLinkConverter converter) { - return (this != converter) - && ! StringTools.stringIsEmpty(this.name) - && this.name.equals(converter.getName()) - && ! this.overrides(converter) - && ! converter.overrides(this); - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return getAnnotation().getTextRange(astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverterHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverterHolder.java deleted file mode 100644 index 806eeb1401..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaConverterHolder.java +++ /dev/null @@ -1,368 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaTypeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.context.java.JavaConverterHolder; -import org.eclipse.jpt.eclipselink.core.resource.java.ConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ObjectTypeConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.StructConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.TypeConverterAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaConverterHolder extends AbstractJavaJpaContextNode implements JavaConverterHolder -{ - protected JavaResourcePersistentType resourcePersistentType; - - protected EclipseLinkJavaCustomConverter customConverter; - protected EclipseLinkJavaObjectTypeConverter objectTypeConverter; - protected EclipseLinkJavaStructConverter structConverter; - protected EclipseLinkJavaTypeConverter typeConverter; - - public EclipseLinkJavaConverterHolder(JavaTypeMapping parent) { - super(parent); - } - - //************** converter ************* - public CustomConverter getCustomConverter() { - return this.customConverter; - } - - public CustomConverter addCustomConverter() { - if (this.customConverter != null) { - throw new IllegalStateException("custom converter already exists"); //$NON-NLS-1$ - } - this.customConverter = buildCustomConverter(); - this.resourcePersistentType.addSupportingAnnotation(this.customConverter.getAnnotationName()); - firePropertyChanged(CUSTOM_CONVERTER_PROPERTY, null, this.customConverter); - return this.customConverter; - } - - protected void addCustomConverter_() { - this.customConverter = buildCustomConverter(); - firePropertyChanged(CUSTOM_CONVERTER_PROPERTY, null, this.customConverter); - } - - public void removeCustomConverter() { - if (this.customConverter == null) { - throw new IllegalStateException("converter is null"); //$NON-NLS-1$ - } - EclipseLinkJavaCustomConverter oldConverter = this.customConverter; - this.customConverter = null; - this.resourcePersistentType.removeSupportingAnnotation(oldConverter.getAnnotationName()); - firePropertyChanged(CUSTOM_CONVERTER_PROPERTY, oldConverter, null); - } - - protected void removeCustomConverter_() { - this.customConverter = null; - firePropertyChanged(CUSTOM_CONVERTER_PROPERTY, this.customConverter, null); - } - - protected String getConverterAnnotationName() { - return ConverterAnnotation.ANNOTATION_NAME; - } - - protected ConverterAnnotation getResourceConverter() { - return (ConverterAnnotation) this.resourcePersistentType.getSupportingAnnotation(getConverterAnnotationName()); - } - - - //************** object type converter ************* - public ObjectTypeConverter getObjectTypeConverter() { - return this.objectTypeConverter; - } - - public ObjectTypeConverter addObjectTypeConverter() { - if (this.objectTypeConverter != null) { - throw new IllegalStateException("object type converter already exists"); //$NON-NLS-1$ - } - this.objectTypeConverter = buildObjectTypeConverter(); - this.resourcePersistentType.addSupportingAnnotation(this.objectTypeConverter.getAnnotationName()); - firePropertyChanged(OBJECT_TYPE_CONVERTER_PROPERTY, null, this.objectTypeConverter); - return this.objectTypeConverter; - } - - protected void addObjectTypeConverter_() { - this.objectTypeConverter = buildObjectTypeConverter(); - firePropertyChanged(OBJECT_TYPE_CONVERTER_PROPERTY, null, this.objectTypeConverter); - } - - public void removeObjectTypeConverter() { - if (this.objectTypeConverter == null) { - throw new IllegalStateException("object type converter is null"); //$NON-NLS-1$ - } - EclipseLinkJavaObjectTypeConverter oldConverter = this.objectTypeConverter; - this.objectTypeConverter = null; - this.resourcePersistentType.removeSupportingAnnotation(oldConverter.getAnnotationName()); - firePropertyChanged(OBJECT_TYPE_CONVERTER_PROPERTY, oldConverter, null); - } - - protected void removeObjectTypeConverter_() { - ObjectTypeConverter oldConverter = this.objectTypeConverter; - this.objectTypeConverter = null; - firePropertyChanged(OBJECT_TYPE_CONVERTER_PROPERTY, oldConverter, null); - } - - protected String getObjectTypeConverterAnnotationName() { - return ObjectTypeConverterAnnotation.ANNOTATION_NAME; - } - - protected ObjectTypeConverterAnnotation getResourceObjectTypeConverter() { - return (ObjectTypeConverterAnnotation) this.resourcePersistentType.getSupportingAnnotation(getObjectTypeConverterAnnotationName()); - } - - - //************** type converter ************* - public TypeConverter getTypeConverter() { - return this.typeConverter; - } - - public TypeConverter addTypeConverter() { - if (this.typeConverter != null) { - throw new IllegalStateException("type converter already exists"); //$NON-NLS-1$ - } - this.typeConverter = buildTypeConverter(); - this.resourcePersistentType.addSupportingAnnotation(this.typeConverter.getAnnotationName()); - firePropertyChanged(TYPE_CONVERTER_PROPERTY, null, this.typeConverter); - return this.typeConverter; - } - - protected void addTypeConverter_() { - this.typeConverter = buildTypeConverter(); - firePropertyChanged(TYPE_CONVERTER_PROPERTY, null, this.typeConverter); - } - - public void removeTypeConverter() { - if (this.typeConverter == null) { - throw new IllegalStateException("type converter is null"); //$NON-NLS-1$ - } - EclipseLinkJavaTypeConverter oldConverter = this.typeConverter; - this.typeConverter = null; - this.resourcePersistentType.removeSupportingAnnotation(oldConverter.getAnnotationName()); - firePropertyChanged(TYPE_CONVERTER_PROPERTY, oldConverter, null); - } - - protected void removeTypeConverter_() { - TypeConverter oldConverter = this.typeConverter; - this.typeConverter = null; - firePropertyChanged(TYPE_CONVERTER_PROPERTY, oldConverter, null); - } - - protected String getTypeConverterAnnotationName() { - return TypeConverterAnnotation.ANNOTATION_NAME; - } - - protected TypeConverterAnnotation getResourceTypeConverter() { - return (TypeConverterAnnotation) this.resourcePersistentType.getSupportingAnnotation(getTypeConverterAnnotationName()); - } - - - //************** struct converter ************* - public StructConverter getStructConverter() { - return this.structConverter; - } - - public StructConverter addStructConverter() { - if (this.structConverter != null) { - throw new IllegalStateException("struct converter already exists"); //$NON-NLS-1$ - } - this.structConverter = buildStructConverter(); - this.resourcePersistentType.addSupportingAnnotation(this.structConverter.getAnnotationName()); - firePropertyChanged(STRUCT_CONVERTER_PROPERTY, null, this.structConverter); - return this.structConverter; - } - - protected void addStructConverter_() { - this.structConverter = buildStructConverter(); - firePropertyChanged(STRUCT_CONVERTER_PROPERTY, null, this.structConverter); - } - - public void removeStructConverter() { - if (this.structConverter == null) { - throw new IllegalStateException("struct converter is null"); //$NON-NLS-1$ - } - EclipseLinkJavaStructConverter oldConverter = this.structConverter; - this.structConverter = null; - this.resourcePersistentType.removeSupportingAnnotation(oldConverter.getAnnotationName()); - firePropertyChanged(STRUCT_CONVERTER_PROPERTY, oldConverter, null); - } - - protected void removeStructConverter_() { - StructConverter oldConverter = this.structConverter; - this.structConverter = null; - firePropertyChanged(STRUCT_CONVERTER_PROPERTY, oldConverter, null); - } - - protected String getStructConverterAnnotationName() { - return StructConverterAnnotation.ANNOTATION_NAME; - } - - protected StructConverterAnnotation getResourceStructConverter() { - return (StructConverterAnnotation) this.resourcePersistentType.getSupportingAnnotation(getStructConverterAnnotationName()); - } - - public void update(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - this.updateCustomConverter(); - this.updateObjectTypeConverter(); - this.updateTypeConverter(); - this.updateStructConverter(); - } - - protected void updateCustomConverter() { - if (getResourceConverter() != null) { - if (this.customConverter != null) { - this.customConverter.update(this.resourcePersistentType); - } - else { - addCustomConverter_(); - } - } - else { - if (this.customConverter != null) { - removeCustomConverter_(); - } - } - } - - protected void updateObjectTypeConverter() { - if (getResourceObjectTypeConverter() != null) { - if (this.objectTypeConverter != null) { - this.objectTypeConverter.update(this.resourcePersistentType); - } - else { - addObjectTypeConverter_(); - } - } - else { - if (this.objectTypeConverter != null) { - removeObjectTypeConverter_(); - } - } - } - - protected void updateTypeConverter() { - if (getResourceTypeConverter() != null) { - if (this.typeConverter != null) { - this.typeConverter.update(this.resourcePersistentType); - } - else { - addTypeConverter_(); - } - } - else { - if (this.typeConverter != null) { - removeTypeConverter(); - } - } - } - - protected void updateStructConverter() { - if (getResourceStructConverter() != null) { - if (this.structConverter != null) { - this.structConverter.update(this.resourcePersistentType); - } - else { - addStructConverter_(); - } - } - else { - if (this.structConverter != null) { - removeStructConverter_(); - } - } - } - - public void initialize(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - this.initializeCustomConverter(); - this.initializeObjectTypeConverter(); - this.initializeTypeConverter(); - this.initializeStructConverter(); - } - - protected void initializeCustomConverter() { - if (getResourceConverter() != null) { - this.customConverter = buildCustomConverter(); - } - } - - protected void initializeObjectTypeConverter() { - if (getResourceObjectTypeConverter() != null) { - this.objectTypeConverter = buildObjectTypeConverter(); - } - } - - protected void initializeTypeConverter() { - if (getResourceTypeConverter() != null) { - this.typeConverter = buildTypeConverter(); - } - } - - protected void initializeStructConverter() { - if (getResourceStructConverter() != null) { - this.structConverter = buildStructConverter(); - } - } - protected EclipseLinkJavaCustomConverter buildCustomConverter() { - EclipseLinkJavaCustomConverter contextConverter = new EclipseLinkJavaCustomConverter(this); - contextConverter.initialize(this.resourcePersistentType); - return contextConverter; - } - - protected EclipseLinkJavaTypeConverter buildTypeConverter() { - EclipseLinkJavaTypeConverter contextConverter = new EclipseLinkJavaTypeConverter(this); - contextConverter.initialize(this.resourcePersistentType); - return contextConverter; - } - - protected EclipseLinkJavaObjectTypeConverter buildObjectTypeConverter() { - EclipseLinkJavaObjectTypeConverter contextConverter = new EclipseLinkJavaObjectTypeConverter(this); - contextConverter.initialize(this.resourcePersistentType); - return contextConverter; - } - - protected EclipseLinkJavaStructConverter buildStructConverter() { - EclipseLinkJavaStructConverter contextConverter = new EclipseLinkJavaStructConverter(this); - contextConverter.initialize(this.resourcePersistentType); - return contextConverter; - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return this.resourcePersistentType.getTextRange(astRoot); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - if (this.customConverter != null) { - this.customConverter.validate(messages, astRoot); - } - if (this.objectTypeConverter != null) { - this.objectTypeConverter.validate(messages, astRoot); - } - if (this.typeConverter != null) { - this.typeConverter.validate(messages, astRoot); - } - if (this.structConverter != null) { - this.structConverter.validate(messages, astRoot); - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomConverter.java deleted file mode 100644 index 2fd4ae278a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomConverter.java +++ /dev/null @@ -1,113 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.internal.DefaultEclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.resource.java.ConverterAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaCustomConverter extends EclipseLinkJavaConverter - implements CustomConverter -{ - private String converterClass; - - public EclipseLinkJavaCustomConverter(JavaJpaContextNode parent) { - super(parent); - } - - - public String getType() { - return EclipseLinkConverter.CUSTOM_CONVERTER; - } - - @Override - public String getAnnotationName() { - return ConverterAnnotation.ANNOTATION_NAME; - } - - @Override - protected ConverterAnnotation getAnnotation() { - return (ConverterAnnotation) super.getAnnotation(); - } - - - // **************** converter class **************************************** - - public String getConverterClass() { - return this.converterClass; - } - - public void setConverterClass(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - getAnnotation().setConverterClass(newConverterClass); - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - protected void setConverterClass_(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(JavaResourcePersistentMember jrpm) { - super.initialize(jrpm); - this.converterClass = this.converterClass(getAnnotation()); - } - - @Override - public void update(JavaResourcePersistentMember jrpm) { - super.update(jrpm); - this.setConverterClass_(this.converterClass(getAnnotation())); - } - - protected String converterClass(ConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getConverterClass(); - } - - public TextRange getConverterClassTextRange(CompilationUnit astRoot) { - return getAnnotation().getConverterClassTextRange(astRoot); - } - - - //************ validation *************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - validateConverterClass(messages, astRoot); - } - - protected void validateConverterClass(List<IMessage> messages, CompilationUnit astRoot) { - if (! getAnnotation().converterClassImplementsInterface(ECLIPSELINK_CONVERTER_CLASS_NAME, astRoot)) { - messages.add( - DefaultEclipseLinkJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - EclipseLinkJpaValidationMessages.CONVERTER_CLASS_IMPLEMENTS_CONVERTER, - new String[] {this.converterClass}, - this, - getConverterClassTextRange(astRoot) - ) - ); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomizer.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomizer.java deleted file mode 100644 index 695895aec2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaCustomizer.java +++ /dev/null @@ -1,138 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.internal.DefaultEclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.resource.java.CustomizerAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaCustomizer extends AbstractJavaJpaContextNode implements Customizer -{ - private JavaResourcePersistentType resourcePersistentType; - - private String customizerClass; - - public EclipseLinkJavaCustomizer(JavaJpaContextNode parent) { - super(parent); - } - - @Override - protected EclipseLinkJpaFactory getJpaFactory() { - return (EclipseLinkJpaFactory) super.getJpaFactory(); - } - - protected String getAnnotationName() { - return CustomizerAnnotation.ANNOTATION_NAME; - } - - protected void addResourceCustomizer() { - this.resourcePersistentType.addSupportingAnnotation(getAnnotationName()); - } - - protected void removeResourceCustomizer() { - this.resourcePersistentType.removeSupportingAnnotation(getAnnotationName()); - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return getResourceCustomizer().getTextRange(astRoot); - } - - protected CustomizerAnnotation getResourceCustomizer() { - return (CustomizerAnnotation) this.resourcePersistentType.getSupportingAnnotation(getAnnotationName()); - } - - public String getCustomizerClass() { - return getSpecifiedCustomizerClass(); - } - - public String getDefaultCustomizerClass() { - return null; - } - - public String getSpecifiedCustomizerClass() { - return this.customizerClass; - } - - public void setSpecifiedCustomizerClass(String newCustomizerClass) { - if (attributeValueHasNotChanged(this.customizerClass, newCustomizerClass)) { - return; - } - String oldCustomizerClass = this.customizerClass; - this.customizerClass = newCustomizerClass; - if (this.customizerClass != null) { - addResourceCustomizer(); - } - else { - removeResourceCustomizer(); - } - if (newCustomizerClass != null) { - getResourceCustomizer().setValue(newCustomizerClass); - } - firePropertyChanged(SPECIFIED_CUSTOMIZER_CLASS_PROPERTY, oldCustomizerClass, newCustomizerClass); - } - - protected void setCustomizerClass_(String newCustomizerClass) { - String oldCustomizerClass = this.customizerClass; - this.customizerClass = newCustomizerClass; - firePropertyChanged(SPECIFIED_CUSTOMIZER_CLASS_PROPERTY, oldCustomizerClass, newCustomizerClass); - } - - public void initialize(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - CustomizerAnnotation resourceCustomizer = getResourceCustomizer(); - this.customizerClass = this.customizerClass(resourceCustomizer); - } - - public void update(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - CustomizerAnnotation resourceCustomizer = getResourceCustomizer(); - this.setCustomizerClass_(this.customizerClass(resourceCustomizer)); - } - - protected String customizerClass(CustomizerAnnotation resourceCustomizer) { - return resourceCustomizer == null ? null : resourceCustomizer.getValue(); - } - - public TextRange getCustomizerClassTextRange(CompilationUnit astRoot) { - return getResourceCustomizer().getValueTextRange(astRoot); - } - - //************ validation *************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - validateConverterClass(messages, astRoot); - } - - protected void validateConverterClass(List<IMessage> messages, CompilationUnit astRoot) { - CustomizerAnnotation resourceCustomizer = getResourceCustomizer(); - if (resourceCustomizer != null && !resourceCustomizer.customizerClassImplementsInterface(ECLIPSELINK_DESCRIPTOR_CUSTOMIZER_CLASS_NAME, astRoot)) { - messages.add( - DefaultEclipseLinkJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - EclipseLinkJpaValidationMessages.CUSTOMIZER_CLASS_IMPLEMENTS_DESCRIPTOR_CUSTOMIZER, - new String[] {this.customizerClass}, - this, - getCustomizerClassTextRange(astRoot) - ) - ); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEmbeddableImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEmbeddableImpl.java deleted file mode 100644 index d3e1c24a66..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEmbeddableImpl.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentType; -import org.eclipse.jpt.core.internal.context.java.GenericJavaEmbeddable; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaEmbeddable; -import org.eclipse.jpt.eclipselink.core.context.java.JavaConverterHolder; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaEmbeddableImpl extends GenericJavaEmbeddable implements EclipseLinkJavaEmbeddable -{ - - protected final JavaConverterHolder converterHolder; - - protected final EclipseLinkJavaCustomizer customizer; - - protected final EclipseLinkJavaChangeTracking changeTracking; - - public EclipseLinkJavaEmbeddableImpl(JavaPersistentType parent) { - super(parent); - this.converterHolder = new EclipseLinkJavaConverterHolder(this); - this.customizer = new EclipseLinkJavaCustomizer(this); - this.changeTracking = new EclipseLinkJavaChangeTracking(this); - } - - public JavaConverterHolder getConverterHolder() { - return this.converterHolder; - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - @Override - public void initialize(JavaResourcePersistentType jrpt) { - super.initialize(jrpt); - this.converterHolder.initialize(jrpt); - this.customizer.initialize(jrpt); - this.changeTracking.initialize(jrpt); - } - - @Override - public void update(JavaResourcePersistentType jrpt) { - super.update(jrpt); - this.converterHolder.update(jrpt); - this.customizer.update(jrpt); - this.changeTracking.update(jrpt); - } - - - //********** Validation ******************************************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.converterHolder.validate(messages, astRoot); - this.customizer.validate(messages, astRoot); - this.changeTracking.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEntityImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEntityImpl.java deleted file mode 100644 index e8f0dfc4d0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaEntityImpl.java +++ /dev/null @@ -1,98 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentType; -import org.eclipse.jpt.core.internal.context.java.GenericJavaEntity; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaEntity; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.context.java.JavaConverterHolder; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaEntityImpl extends GenericJavaEntity implements EclipseLinkJavaEntity -{ - protected final JavaCaching eclipseLinkCaching; - - protected final JavaConverterHolder converterHolder; - - protected final EclipseLinkJavaReadOnly readOnly; - - protected final EclipseLinkJavaCustomizer customizer; - - protected final EclipseLinkJavaChangeTracking changeTracking; - - public EclipseLinkJavaEntityImpl(JavaPersistentType parent) { - super(parent); - this.eclipseLinkCaching = new EclipseLinkJavaCaching(this); - this.converterHolder = new EclipseLinkJavaConverterHolder(this); - this.readOnly = new EclipseLinkJavaReadOnly(this); - this.changeTracking = new EclipseLinkJavaChangeTracking(this); - this.customizer = new EclipseLinkJavaCustomizer(this); - } - - public JavaCaching getCaching() { - return this.eclipseLinkCaching; - } - - public JavaConverterHolder getConverterHolder() { - return this.converterHolder; - } - - public ReadOnly getReadOnly() { - return this.readOnly; - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - @Override - public void initialize(JavaResourcePersistentType jrpt) { - super.initialize(jrpt); - this.eclipseLinkCaching.initialize(jrpt); - this.converterHolder.initialize(jrpt); - this.readOnly.initialize(jrpt); - this.customizer.initialize(jrpt); - this.changeTracking.initialize(jrpt); - } - - @Override - public void update(JavaResourcePersistentType jrpt) { - super.update(jrpt); - this.eclipseLinkCaching.update(jrpt); - this.converterHolder.update(jrpt); - this.readOnly.update(jrpt); - this.customizer.update(jrpt); - this.changeTracking.update(jrpt); - } - - - //********** Validation ******************************************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.eclipseLinkCaching.validate(messages, astRoot); - this.converterHolder.validate(messages, astRoot); - this.readOnly.validate(messages, astRoot); - this.customizer.validate(messages, astRoot); - this.changeTracking.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaExpiryTimeOfDay.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaExpiryTimeOfDay.java deleted file mode 100644 index b893c2c6cd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaExpiryTimeOfDay.java +++ /dev/null @@ -1,137 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Caching; -import org.eclipse.jpt.eclipselink.core.context.ExpiryTimeOfDay; -import org.eclipse.jpt.eclipselink.core.resource.java.TimeOfDayAnnotation; - -public class EclipseLinkJavaExpiryTimeOfDay extends AbstractJavaJpaContextNode - implements ExpiryTimeOfDay -{ - - protected Integer hour; - protected Integer minute; - protected Integer second; - protected Integer millisecond; - - protected TimeOfDayAnnotation timeOfDay; - - public EclipseLinkJavaExpiryTimeOfDay(Caching parent) { - super(parent); - } - - public Integer getHour() { - return this.hour; - } - - public void setHour(Integer newHour) { - Integer oldHour = this.hour; - this.hour = newHour; - this.timeOfDay.setHour(newHour); - firePropertyChanged(HOUR_PROPERTY, oldHour, newHour); - } - - protected void setHour_(Integer newHour) { - Integer oldHour = this.hour; - this.hour = newHour; - firePropertyChanged(HOUR_PROPERTY, oldHour, newHour); - } - - public Integer getMinute() { - return this.minute; - } - - public void setMinute(Integer newMinute) { - Integer oldMinute = this.minute; - this.minute = newMinute; - this.timeOfDay.setMinute(newMinute); - firePropertyChanged(MINUTE_PROPERTY, oldMinute, newMinute); - } - - protected void setMinute_(Integer newMinute) { - Integer oldMinute = this.minute; - this.minute = newMinute; - firePropertyChanged(MINUTE_PROPERTY, oldMinute, newMinute); - } - - public Integer getSecond() { - return this.second; - } - - public void setSecond(Integer newSecond) { - Integer oldSecond = this.second; - this.second = newSecond; - this.timeOfDay.setSecond(newSecond); - firePropertyChanged(SECOND_PROPERTY, oldSecond, newSecond); - } - - protected void setSecond_(Integer newSecond) { - Integer oldSecond = this.second; - this.second = newSecond; - firePropertyChanged(SECOND_PROPERTY, oldSecond, newSecond); - } - - public Integer getMillisecond() { - return this.millisecond; - } - - public void setMillisecond(Integer newMillisecond) { - Integer oldMillisecond = this.millisecond; - this.millisecond = newMillisecond; - this.timeOfDay.setMillisecond(newMillisecond); - firePropertyChanged(MILLISECOND_PROPERTY, oldMillisecond, newMillisecond); - } - - protected void setMillisecond_(Integer newMillisecond) { - Integer oldMillisecond = this.millisecond; - this.millisecond = newMillisecond; - firePropertyChanged(MILLISECOND_PROPERTY, oldMillisecond, newMillisecond); - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - return this.timeOfDay.getTextRange(astRoot); - } - - public void initialize(TimeOfDayAnnotation timeOfDay) { - this.timeOfDay = timeOfDay; - this.hour = getHour(timeOfDay); - this.minute = getMinute(timeOfDay); - this.second = getSecond(timeOfDay); - this.millisecond = getMillisecond(timeOfDay); - } - - public void update(TimeOfDayAnnotation timeOfDay) { - this.timeOfDay = timeOfDay; - this.setHour_(getHour(timeOfDay)); - this.setMinute_(getMinute(timeOfDay)); - this.setSecond_(getSecond(timeOfDay)); - this.setMillisecond_(getMillisecond(timeOfDay)); - } - - protected Integer getHour(TimeOfDayAnnotation timeOfDay) { - return timeOfDay.getHour(); - } - - protected Integer getMinute(TimeOfDayAnnotation timeOfDay) { - return timeOfDay.getMinute(); - } - - protected Integer getSecond(TimeOfDayAnnotation timeOfDay) { - return timeOfDay.getSecond(); - } - - protected Integer getMillisecond(TimeOfDayAnnotation timeOfDay) { - return timeOfDay.getMillisecond(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaIdMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaIdMappingImpl.java deleted file mode 100644 index d0719d5d2b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaIdMappingImpl.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaConverter; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaIdMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkIdMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.java.ConvertAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaIdMappingImpl extends GenericJavaIdMapping implements EclipseLinkIdMapping -{ - protected final EclipseLinkJavaMutable mutable; - - public EclipseLinkJavaIdMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkJavaMutable(this); - } - - @Override - protected JavaConverter buildSpecifiedConverter(String converterType) { - JavaConverter javaConverter = super.buildSpecifiedConverter(converterType); - if (javaConverter != null) { - return javaConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkJavaConvert(this, this.resourcePersistentAttribute); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (this.resourcePersistentAttribute.getSupportingAnnotation(ConvertAnnotation.ANNOTATION_NAME) != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - - //************ EclipselinkJavaIdMapping implementation **************** - - public Mutable getMutable() { - return this.mutable; - } - - - //************ initialization/update **************** - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.mutable.update(this.resourcePersistentAttribute); - } - - - //************ validation **************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.mutable.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaJoinFetch.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaJoinFetch.java deleted file mode 100644 index 73d73b83c7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaJoinFetch.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchAnnotation; - -public class EclipseLinkJavaJoinFetch extends AbstractJavaJpaContextNode implements JoinFetch -{ - protected JoinFetchType joinFetchValue; - - protected JavaResourcePersistentAttribute resourcePersistentAttribute; - - - public EclipseLinkJavaJoinFetch(JavaAttributeMapping parent) { - super(parent); - } - - - protected String getJoinFetchAnnotationName() { - return JoinFetchAnnotation.ANNOTATION_NAME; - } - - protected JoinFetchAnnotation getResourceJoinFetch() { - return (JoinFetchAnnotation) this.resourcePersistentAttribute.getSupportingAnnotation(getJoinFetchAnnotationName()); - } - - protected void addResourceJoinFetch() { - this.resourcePersistentAttribute.addSupportingAnnotation(getJoinFetchAnnotationName()); - } - - protected void removeResourceJoinFetch() { - this.resourcePersistentAttribute.removeSupportingAnnotation(getJoinFetchAnnotationName()); - } - - public JoinFetchType getValue() { - return this.joinFetchValue; - } - - protected JoinFetchType getDefaultValue() { - return JoinFetch.DEFAULT_VALUE; - } - - public void setValue(JoinFetchType newJoinFetchValue) { - if (this.joinFetchValue == newJoinFetchValue) { - return; - } - - JoinFetchType oldJoinFetchValue = this.joinFetchValue; - this.joinFetchValue = newJoinFetchValue; - - if (newJoinFetchValue != null) { - if (getResourceJoinFetch() == null) { - addResourceJoinFetch(); - } - getResourceJoinFetch().setValue(JoinFetchType.toJavaResourceModel(newJoinFetchValue)); - } - else { - if (getResourceJoinFetch() != null) { - removeResourceJoinFetch(); - } - } - firePropertyChanged(JoinFetch.VALUE_PROPERTY, oldJoinFetchValue, newJoinFetchValue); - } - - /** - * internal setter used only for updating from the resource model. - * There were problems with InvalidThreadAccess exceptions in the UI - * when you set a value from the UI and the annotation doesn't exist yet. - * Adding the annotation causes an update to occur and then the exception. - */ - protected void setValue_(JoinFetchType newJoinFetchValue) { - JoinFetchType oldJoinFetchValue = this.joinFetchValue; - this.joinFetchValue = newJoinFetchValue; - firePropertyChanged(JoinFetch.VALUE_PROPERTY, oldJoinFetchValue, newJoinFetchValue); - } - - public void initialize(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - JoinFetchAnnotation resourceJoinFetch = this.getResourceJoinFetch(); - this.joinFetchValue = this.joinFetch(resourceJoinFetch); - } - - public void update(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - JoinFetchAnnotation resourceJoinFetch = this.getResourceJoinFetch(); - setValue_(joinFetch(resourceJoinFetch)); - } - - private JoinFetchType joinFetch(JoinFetchAnnotation resourceJoinFetch) { - if (resourceJoinFetch == null) { - return null; - } - if (resourceJoinFetch.getValue() == null) { - // @JoinFetch is equivalent to @JoinFetch(JoinFetch.INNER) - return getDefaultValue(); - } - return JoinFetchType.fromJavaResourceModel(resourceJoinFetch.getValue()); - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - JoinFetchAnnotation resourceJoinFetch = this.getResourceJoinFetch(); - return resourceJoinFetch == null ? null : resourceJoinFetch.getTextRange(astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToManyMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToManyMappingImpl.java deleted file mode 100644 index 0c2f51fdd7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToManyMappingImpl.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaManyToManyMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkRelationshipMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaManyToManyMappingImpl extends GenericJavaManyToManyMapping implements EclipseLinkRelationshipMapping -{ - protected final EclipseLinkJavaJoinFetch joinFetch; - - - public EclipseLinkJavaManyToManyMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkJavaJoinFetch(this); - } - - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.joinFetch.update(this.resourcePersistentAttribute); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.joinFetch.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToOneMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToOneMappingImpl.java deleted file mode 100644 index d0ed97fc58..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaManyToOneMappingImpl.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaManyToOneMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkRelationshipMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaManyToOneMappingImpl extends GenericJavaManyToOneMapping implements EclipseLinkRelationshipMapping -{ - protected final EclipseLinkJavaJoinFetch joinFetch; - - - public EclipseLinkJavaManyToOneMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkJavaJoinFetch(this); - } - - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.joinFetch.update(this.resourcePersistentAttribute); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.joinFetch.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMappedSuperclassImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMappedSuperclassImpl.java deleted file mode 100644 index de0fa20727..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMappedSuperclassImpl.java +++ /dev/null @@ -1,98 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentType; -import org.eclipse.jpt.core.internal.context.java.GenericJavaMappedSuperclass; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaMappedSuperclass; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.context.java.JavaConverterHolder; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaMappedSuperclassImpl extends GenericJavaMappedSuperclass implements EclipseLinkJavaMappedSuperclass -{ - protected JavaCaching eclipseLinkCaching; - - protected final JavaConverterHolder converterHolder; - - protected final EclipseLinkJavaReadOnly readOnly; - - protected final EclipseLinkJavaCustomizer customizer; - - protected final EclipseLinkJavaChangeTracking changeTracking; - - public EclipseLinkJavaMappedSuperclassImpl(JavaPersistentType parent) { - super(parent); - this.eclipseLinkCaching = new EclipseLinkJavaCaching(this); - this.converterHolder = new EclipseLinkJavaConverterHolder(this); - this.readOnly = new EclipseLinkJavaReadOnly(this); - this.customizer = new EclipseLinkJavaCustomizer(this); - this.changeTracking = new EclipseLinkJavaChangeTracking(this); - } - - public JavaCaching getCaching() { - return this.eclipseLinkCaching; - } - - public JavaConverterHolder getConverterHolder() { - return this.converterHolder; - } - - public ReadOnly getReadOnly() { - return this.readOnly; - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - @Override - public void initialize(JavaResourcePersistentType jrpt) { - super.initialize(jrpt); - this.eclipseLinkCaching.initialize(jrpt); - this.converterHolder.initialize(jrpt); - this.readOnly.initialize(jrpt); - this.customizer.initialize(jrpt); - this.changeTracking.initialize(jrpt); - } - - @Override - public void update(JavaResourcePersistentType jrpt) { - super.update(jrpt); - this.eclipseLinkCaching.update(jrpt); - this.converterHolder.update(jrpt); - this.readOnly.update(jrpt); - this.customizer.update(jrpt); - this.changeTracking.update(jrpt); - } - - - //********** Validation ******************************************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.eclipseLinkCaching.validate(messages, astRoot); - this.converterHolder.validate(messages, astRoot); - this.readOnly.validate(messages, astRoot); - this.customizer.validate(messages, astRoot); - this.changeTracking.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMutable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMutable.java deleted file mode 100644 index 154baa39be..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaMutable.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.resource.java.MutableAnnotation; - -public class EclipseLinkJavaMutable extends AbstractJavaJpaContextNode implements Mutable -{ - protected boolean defaultMutable; - protected Boolean specifiedMutable; - - protected JavaResourcePersistentAttribute resourcePersistentAttribute; - - public EclipseLinkJavaMutable(JavaAttributeMapping parent) { - super(parent); - } - - @Override - public EclipseLinkPersistenceUnit getPersistenceUnit() { - return (EclipseLinkPersistenceUnit) super.getPersistenceUnit(); - } - - protected String getMutableAnnotationName() { - return MutableAnnotation.ANNOTATION_NAME; - } - - protected MutableAnnotation getResourceMutable() { - return (MutableAnnotation) this.resourcePersistentAttribute.getSupportingAnnotation(getMutableAnnotationName()); - } - - protected void addResourceMutable() { - this.resourcePersistentAttribute.addSupportingAnnotation(getMutableAnnotationName()); - } - - protected void removeResourceMutable() { - this.resourcePersistentAttribute.removeSupportingAnnotation(getMutableAnnotationName()); - } - - protected boolean calculateDefaultMutable() { - if (this.resourcePersistentAttribute.typeIsDateOrCalendar()) { - Boolean persistenceUnitDefaultMutable = getPersistenceUnit().getOptions().getTemporalMutable(); - return persistenceUnitDefaultMutable == null ? false : persistenceUnitDefaultMutable.booleanValue(); - } - return this.resourcePersistentAttribute.typeIsSerializable(); - } - - public boolean isMutable() { - return this.specifiedMutable != null ? this.specifiedMutable.booleanValue() : this.defaultMutable; - } - - public boolean isDefaultMutable() { - return this.defaultMutable; - } - - protected void setDefaultMutable(boolean newDefaultMutable) { - boolean oldDefaultMutable = this.defaultMutable; - this.defaultMutable = newDefaultMutable; - firePropertyChanged(DEFAULT_MUTABLE_PROPERTY, oldDefaultMutable, newDefaultMutable); - } - - public Boolean getSpecifiedMutable() { - return this.specifiedMutable; - } - - public void setSpecifiedMutable(Boolean newSpecifiedMutable) { - if (this.specifiedMutable == newSpecifiedMutable) { - return; - } - Boolean oldSpecifiedMutable = this.specifiedMutable; - this.specifiedMutable = newSpecifiedMutable; - - if (newSpecifiedMutable != null) { - if (getResourceMutable() == null) { - addResourceMutable(); - } - if (newSpecifiedMutable.booleanValue()) { - if (getResourceMutable().getValue() == Boolean.FALSE) { - getResourceMutable().setValue(null); - } - } - else { - getResourceMutable().setValue(Boolean.FALSE); - } - } - else { - removeResourceMutable(); - } - firePropertyChanged(Mutable.SPECIFIED_MUTABLE_PROPERTY, oldSpecifiedMutable, newSpecifiedMutable); - } - - protected void setSpecifiedMutable_(Boolean newSpecifiedMutable) { - Boolean oldSpecifiedMutable = this.specifiedMutable; - this.specifiedMutable = newSpecifiedMutable; - firePropertyChanged(SPECIFIED_MUTABLE_PROPERTY, oldSpecifiedMutable, newSpecifiedMutable); - } - - public void initialize(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - MutableAnnotation resourceMutable = this.getResourceMutable(); - this.specifiedMutable = this.specifiedMutable(resourceMutable); - this.defaultMutable = this.calculateDefaultMutable(); - } - - public void update(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - MutableAnnotation resourceMutable = this.getResourceMutable(); - this.setSpecifiedMutable_(this.specifiedMutable(resourceMutable)); - this.setDefaultMutable(this.calculateDefaultMutable()); - } - - private Boolean specifiedMutable(MutableAnnotation resourceMutable) { - if (resourceMutable == null) { - return null; - } - if (resourceMutable.getValue() == null) { //@Mutable is equivalent to @Mutable(true) - return Boolean.TRUE; - } - return resourceMutable.getValue(); - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - MutableAnnotation resourceMutable = this.getResourceMutable(); - return resourceMutable == null ? null : resourceMutable.getTextRange(astRoot); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaObjectTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaObjectTypeConverter.java deleted file mode 100644 index 6f6c6d9a90..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaObjectTypeConverter.java +++ /dev/null @@ -1,262 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.ListIterator; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.java.ConversionValueAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ObjectTypeConverterAnnotation; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; -import org.eclipse.jpt.utility.internal.iterators.TransformationListIterator; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaObjectTypeConverter extends EclipseLinkJavaConverter - implements ObjectTypeConverter -{ - private String dataType; - - private String objectType; - - private String defaultObjectValue; - - private final List<EclipseLinkJavaConversionValue> conversionValues; - - - public EclipseLinkJavaObjectTypeConverter(JavaJpaContextNode parent) { - super(parent); - this.conversionValues = new ArrayList<EclipseLinkJavaConversionValue>(); - } - - - public String getType() { - return EclipseLinkConverter.OBJECT_TYPE_CONVERTER; - } - - @Override - public String getAnnotationName() { - return ObjectTypeConverterAnnotation.ANNOTATION_NAME; - } - - @Override - protected ObjectTypeConverterAnnotation getAnnotation() { - return (ObjectTypeConverterAnnotation) super.getAnnotation(); - } - - - // **************** data type ********************************************** - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - getAnnotation().setDataType(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - protected void setDataType_(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - - // **************** object type ******************************************** - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - getAnnotation().setObjectType(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - protected void setObjectType_(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - - // **************** conversion values ************************************** - - public ListIterator<EclipseLinkJavaConversionValue> conversionValues() { - return new CloneListIterator<EclipseLinkJavaConversionValue>(this.conversionValues); - } - - public int conversionValuesSize() { - return this.conversionValues.size(); - } - - public EclipseLinkJavaConversionValue addConversionValue(int index) { - EclipseLinkJavaConversionValue conversionValue = new EclipseLinkJavaConversionValue(this); - this.conversionValues.add(index, conversionValue); - ConversionValueAnnotation resourceConversionValue = getAnnotation().addConversionValue(index); - conversionValue.initialize(resourceConversionValue); - fireItemAdded(CONVERSION_VALUES_LIST, index, conversionValue); - return conversionValue; - } - - public EclipseLinkJavaConversionValue addConversionValue() { - return this.addConversionValue(this.conversionValues.size()); - } - - protected void addConversionValue(int index, EclipseLinkJavaConversionValue conversionValue) { - addItemToList(index, conversionValue, this.conversionValues, CONVERSION_VALUES_LIST); - } - - protected void addConversionValue(EclipseLinkJavaConversionValue conversionValue) { - this.addConversionValue(this.conversionValues.size(), conversionValue); - } - - public void removeConversionValue(ConversionValue conversionValue) { - this.removeConversionValue(this.conversionValues.indexOf(conversionValue)); - } - - public void removeConversionValue(int index) { - EclipseLinkJavaConversionValue removedConversionValue = this.conversionValues.remove(index); - getAnnotation().removeConversionValue(index); - fireItemRemoved(CONVERSION_VALUES_LIST, index, removedConversionValue); - } - - protected void removeConversionValue_(EclipseLinkJavaConversionValue conversionValue) { - removeItemFromList(conversionValue, this.conversionValues, CONVERSION_VALUES_LIST); - } - - public void moveConversionValue(int targetIndex, int sourceIndex) { - CollectionTools.move(this.conversionValues, targetIndex, sourceIndex); - getAnnotation().moveConversionValue(targetIndex, sourceIndex); - fireItemMoved(CONVERSION_VALUES_LIST, targetIndex, sourceIndex); - } - - public ListIterator<String> dataValues() { - return new TransformationListIterator<EclipseLinkJavaConversionValue, String>(conversionValues()) { - @Override - protected String transform(EclipseLinkJavaConversionValue next) { - return next.getDataValue(); - } - }; - } - - - // **************** default object value *********************************** - - public String getDefaultObjectValue() { - return this.defaultObjectValue; - } - - public void setDefaultObjectValue(String newDefaultObjectValue) { - String oldDefaultObjectValue = this.defaultObjectValue; - this.defaultObjectValue = newDefaultObjectValue; - getAnnotation().setDefaultObjectValue(newDefaultObjectValue); - firePropertyChanged(DEFAULT_OBJECT_VALUE_PROPERTY, oldDefaultObjectValue, newDefaultObjectValue); - } - - protected void setDefaultObjectValue_(String newDefaultObjectValue) { - String oldDefaultObjectValue = this.defaultObjectValue; - this.defaultObjectValue = newDefaultObjectValue; - firePropertyChanged(DEFAULT_OBJECT_VALUE_PROPERTY, oldDefaultObjectValue, newDefaultObjectValue); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(JavaResourcePersistentMember jrpm) { - super.initialize(jrpm); - ObjectTypeConverterAnnotation resourceConverter = getAnnotation(); - this.dataType = this.dataType(resourceConverter); - this.objectType = this.objectType(resourceConverter); - this.defaultObjectValue = this.defaultObjectValue(resourceConverter); - this.initializeConversionValues(resourceConverter); - } - - protected void initializeConversionValues(ObjectTypeConverterAnnotation resourceConverter) { - if (resourceConverter == null) { - return; - } - ListIterator<ConversionValueAnnotation> resourceConversionValues = resourceConverter.conversionValues(); - - while(resourceConversionValues.hasNext()) { - this.conversionValues.add(buildConversionValue(resourceConversionValues.next())); - } - } - - protected EclipseLinkJavaConversionValue buildConversionValue(ConversionValueAnnotation resourceConversionValue) { - EclipseLinkJavaConversionValue conversionValue = new EclipseLinkJavaConversionValue(this); - conversionValue.initialize(resourceConversionValue); - return conversionValue; - } - - @Override - public void update(JavaResourcePersistentMember jrpm) { - super.update(jrpm); - ObjectTypeConverterAnnotation resourceConverter = getAnnotation(); - this.setDataType_(this.dataType(resourceConverter)); - this.setObjectType_(this.objectType(resourceConverter)); - this.setDefaultObjectValue_(this.defaultObjectValue(resourceConverter)); - this.updateConversionValues(resourceConverter); - } - - protected void updateConversionValues(ObjectTypeConverterAnnotation resourceConverter) { - ListIterator<EclipseLinkJavaConversionValue> contextConversionValues = conversionValues(); - ListIterator<ConversionValueAnnotation> resourceConversionValues = resourceConverter.conversionValues(); - while (contextConversionValues.hasNext()) { - EclipseLinkJavaConversionValue conversionValues = contextConversionValues.next(); - if (resourceConversionValues.hasNext()) { - conversionValues.update(resourceConversionValues.next()); - } - else { - removeConversionValue_(conversionValues); - } - } - - while (resourceConversionValues.hasNext()) { - addConversionValue(buildConversionValue(resourceConversionValues.next())); - } - } - - protected String dataType(ObjectTypeConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getDataType(); - } - - protected String objectType(ObjectTypeConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getObjectType(); - } - - protected String defaultObjectValue(ObjectTypeConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getDefaultObjectValue(); - } - - - // **************** validation ********************************************* - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - for (Iterator<EclipseLinkJavaConversionValue> stream = conversionValues(); stream.hasNext();) { - stream.next().validate(messages, astRoot); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingImpl.java deleted file mode 100644 index 9434150474..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingImpl.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.AttributeMapping; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaOneToManyMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkOneToManyMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.jpt.eclipselink.core.resource.java.PrivateOwnedAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaOneToManyMappingImpl extends GenericJavaOneToManyMapping implements EclipseLinkOneToManyMapping -{ - protected final EclipseLinkJavaJoinFetch joinFetch; - - protected final EclipseLinkJavaPrivateOwned privateOwned; - - - public EclipseLinkJavaOneToManyMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkJavaJoinFetch(this); - this.privateOwned = new EclipseLinkJavaPrivateOwned(this); - } - - // ********** NonOwningMapping implementation ********** - @Override - public boolean mappedByIsValid(AttributeMapping mappedByMapping) { - return super.mappedByIsValid(mappedByMapping) || (mappedByMapping.getKey() == MappingKeys.ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY); - } - - protected String getPrivateOwnedAnnotationName() { - return PrivateOwnedAnnotation.ANNOTATION_NAME; - } - - protected PrivateOwnedAnnotation getResourcePrivateOwned() { - return (PrivateOwnedAnnotation) this.resourcePersistentAttribute.getSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - protected void addResourcePrivateOwned() { - this.resourcePersistentAttribute.addSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - protected void removeResourcePrivateOwned() { - this.resourcePersistentAttribute.removeSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - public PrivateOwned getPrivateOwned() { - return this.privateOwned; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize(this.resourcePersistentAttribute); - this.privateOwned.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.joinFetch.update(this.resourcePersistentAttribute); - this.privateOwned.update(this.resourcePersistentAttribute); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.joinFetch.validate(messages, astRoot); - this.privateOwned.validate(messages, astRoot); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingProvider.java deleted file mode 100644 index 9f03ae01bb..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToManyMappingProvider.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.DefaultJavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.JavaOneToManyMappingProvider; - -public class EclipseLinkJavaOneToManyMappingProvider - implements DefaultJavaAttributeMappingProvider -{ - - // singleton - private static final EclipseLinkJavaOneToManyMappingProvider INSTANCE = new EclipseLinkJavaOneToManyMappingProvider(); - - /** - * Return the singleton. - */ - public static DefaultJavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkJavaOneToManyMappingProvider() { - super(); - } - - public String getKey() { - return JavaOneToManyMappingProvider.instance().getKey(); - } - - public String getAnnotationName() { - return JavaOneToManyMappingProvider.instance().getAnnotationName(); - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return JavaOneToManyMappingProvider.instance().buildMapping(parent, factory); - } - - public boolean defaultApplies(JavaPersistentAttribute persistentAttribute) { - if (!persistentAttribute.getResourcePersistentAttribute().typeIsContainer()) { - return false; - } - String targetEntity = persistentAttribute.getResourcePersistentAttribute().getQualifiedReferenceEntityElementTypeName(); - if (targetEntity == null) { - return false; - } - return persistentAttribute.getPersistenceUnit().getEntity(targetEntity) != null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingImpl.java deleted file mode 100644 index 58490141b9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingImpl.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaOneToOneMappingImpl extends GenericJavaOneToOneMapping implements EclipseLinkOneToOneMapping -{ - protected final EclipseLinkJavaJoinFetch joinFetch; - - protected final EclipseLinkJavaPrivateOwned privateOwned; - - - public EclipseLinkJavaOneToOneMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkJavaJoinFetch(this); - this.privateOwned = new EclipseLinkJavaPrivateOwned(this); - } - - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - public PrivateOwned getPrivateOwned() { - return this.privateOwned; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize(this.resourcePersistentAttribute); - this.privateOwned.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.joinFetch.update(this.resourcePersistentAttribute); - this.privateOwned.update(this.resourcePersistentAttribute); - } - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.joinFetch.validate(messages, astRoot); - this.privateOwned.validate(messages, astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingProvider.java deleted file mode 100644 index 47c6915148..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaOneToOneMappingProvider.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.DefaultJavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.JavaOneToOneMappingProvider; - -public class EclipseLinkJavaOneToOneMappingProvider - implements DefaultJavaAttributeMappingProvider -{ - - // singleton - private static final EclipseLinkJavaOneToOneMappingProvider INSTANCE = new EclipseLinkJavaOneToOneMappingProvider(); - - /** - * Return the singleton. - */ - public static DefaultJavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkJavaOneToOneMappingProvider() { - super(); - } - - public String getKey() { - return JavaOneToOneMappingProvider.instance().getKey(); - } - - public String getAnnotationName() { - return JavaOneToOneMappingProvider.instance().getAnnotationName(); - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return JavaOneToOneMappingProvider.instance().buildMapping(parent, factory); - } - - public boolean defaultApplies(JavaPersistentAttribute persistentAttribute) { - if (persistentAttribute.getResourcePersistentAttribute().typeIsContainer()) { - return false; - } - String targetEntity = persistentAttribute.getResourcePersistentAttribute().getQualifiedReferenceEntityTypeName(); - if (targetEntity == null) { - return false; - } - return persistentAttribute.getPersistenceUnit().getEntity(targetEntity) != null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaPrivateOwned.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaPrivateOwned.java deleted file mode 100644 index 98cf3ec2bb..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaPrivateOwned.java +++ /dev/null @@ -1,94 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.jpt.eclipselink.core.resource.java.PrivateOwnedAnnotation; - -public class EclipseLinkJavaPrivateOwned extends AbstractJavaJpaContextNode implements PrivateOwned -{ - protected boolean privateOwned; - - protected JavaResourcePersistentAttribute resourcePersistentAttribute; - - public EclipseLinkJavaPrivateOwned(JavaAttributeMapping parent) { - super(parent); - } - - protected String getPrivateOwnedAnnotationName() { - return PrivateOwnedAnnotation.ANNOTATION_NAME; - } - - protected PrivateOwnedAnnotation getResourcePrivateOwned() { - return (PrivateOwnedAnnotation) this.resourcePersistentAttribute.getSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - protected void addResourcePrivateOwned() { - this.resourcePersistentAttribute.addSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - protected void removeResourcePrivateOwned() { - this.resourcePersistentAttribute.removeSupportingAnnotation(getPrivateOwnedAnnotationName()); - } - - public boolean isPrivateOwned() { - return this.privateOwned; - } - - public void setPrivateOwned(boolean newPrivateOwned) { - if (this.privateOwned == newPrivateOwned) { - return; - } - boolean oldPrivateOwned = this.privateOwned; - this.privateOwned = newPrivateOwned; - - if (newPrivateOwned) { - addResourcePrivateOwned(); - } - else { - //have to check if annotation exists in case the change is from false to null or vice versa - if (getResourcePrivateOwned() != null) { - removeResourcePrivateOwned(); - } - } - firePropertyChanged(PRIVATE_OWNED_PROPERTY, oldPrivateOwned, newPrivateOwned); - } - - protected void setPrivateOwned_(boolean newPrivateOwned) { - boolean oldPrivateOwned = this.privateOwned; - this.privateOwned = newPrivateOwned; - firePropertyChanged(PRIVATE_OWNED_PROPERTY, oldPrivateOwned, newPrivateOwned); - } - - public void initialize(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - this.privateOwned = privateOwned(); - } - - public void update(JavaResourcePersistentAttribute jrpa) { - this.resourcePersistentAttribute = jrpa; - this.setPrivateOwned_(privateOwned()); - } - - private boolean privateOwned() { - return getResourcePrivateOwned() != null; - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - PrivateOwnedAnnotation resourcePrivateOwned = this.getResourcePrivateOwned(); - return resourcePrivateOwned == null ? null : resourcePrivateOwned.getTextRange(astRoot); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaReadOnly.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaReadOnly.java deleted file mode 100644 index f7caeddb82..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaReadOnly.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaTypeMapping; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.resource.java.ReadOnlyAnnotation; - -public class EclipseLinkJavaReadOnly extends AbstractJavaJpaContextNode implements ReadOnly -{ - protected Boolean specifiedReadOnly; - - protected JavaResourcePersistentType resourcePersistentType; - - - public EclipseLinkJavaReadOnly(JavaTypeMapping parent) { - super(parent); - } - - - protected String getReadOnlyAnnotationName() { - return ReadOnlyAnnotation.ANNOTATION_NAME; - } - - protected ReadOnlyAnnotation getResourceReadOnly() { - return (ReadOnlyAnnotation) this.resourcePersistentType.getSupportingAnnotation(getReadOnlyAnnotationName()); - } - - protected void addResourceReadOnly() { - this.resourcePersistentType.addSupportingAnnotation(getReadOnlyAnnotationName()); - } - - protected void removeResourceReadOnly() { - this.resourcePersistentType.removeSupportingAnnotation(getReadOnlyAnnotationName()); - } - - public boolean isReadOnly() { - return (this.getSpecifiedReadOnly() != null) ? this.getSpecifiedReadOnly().booleanValue() : this.isDefaultReadOnly(); - } - - public boolean isDefaultReadOnly() { - return ReadOnly.DEFAULT_READ_ONLY; - } - - public Boolean getSpecifiedReadOnly() { - return this.specifiedReadOnly; - } - - public void setSpecifiedReadOnly(Boolean newReadOnly) { - if (this.specifiedReadOnly == newReadOnly) { - return; - } - Boolean oldReadOnly = this.specifiedReadOnly; - this.specifiedReadOnly = newReadOnly; - - if (newReadOnly != null && newReadOnly.booleanValue()) { - addResourceReadOnly(); - } - else { - //have to check if annotation exists in case the change is from false to null or vice versa - if (getResourceReadOnly() != null) { - removeResourceReadOnly(); - } - } - firePropertyChanged(SPECIFIED_READ_ONLY_PROPERTY, oldReadOnly, newReadOnly); - } - - protected void setSpecifiedReadOnly_(Boolean newReadOnly) { - Boolean oldReadOnly = this.specifiedReadOnly; - this.specifiedReadOnly = newReadOnly; - firePropertyChanged(SPECIFIED_READ_ONLY_PROPERTY, oldReadOnly, newReadOnly); - } - - public void initialize(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - this.specifiedReadOnly = readOnly(); - } - - public void update(JavaResourcePersistentType jrpt) { - this.resourcePersistentType = jrpt; - this.setSpecifiedReadOnly_(readOnly()); - } - - private Boolean readOnly() { - return getResourceReadOnly() == null ? null : Boolean.TRUE; - } - - public TextRange getValidationTextRange(CompilationUnit astRoot) { - ReadOnlyAnnotation resourceReadOnly = this.getResourceReadOnly(); - return resourceReadOnly == null ? null : resourceReadOnly.getTextRange(astRoot); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaStructConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaStructConverter.java deleted file mode 100644 index 61de8f1150..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaStructConverter.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.resource.java.StructConverterAnnotation; - -public class EclipseLinkJavaStructConverter extends EclipseLinkJavaConverter - implements StructConverter -{ - private String converterClass; - - - public EclipseLinkJavaStructConverter(JavaJpaContextNode parent) { - super(parent); - } - - - public String getType() { - return EclipseLinkConverter.STRUCT_CONVERTER; - } - - @Override - public String getAnnotationName() { - return StructConverterAnnotation.ANNOTATION_NAME; - } - - @Override - protected StructConverterAnnotation getAnnotation() { - return (StructConverterAnnotation) super.getAnnotation(); - } - - - // **************** converter class **************************************** - - public String getConverterClass() { - return this.converterClass; - } - - public void setConverterClass(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - getAnnotation().setConverter(newConverterClass); - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - protected void setConverterClass_(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(JavaResourcePersistentMember jrpm) { - super.initialize(jrpm); - this.converterClass = this.converterClass(getAnnotation()); - } - - @Override - public void update(JavaResourcePersistentMember jrpm) { - super.update(jrpm); - this.setConverterClass_(this.converterClass(getAnnotation())); - } - - protected String converterClass(StructConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getConverter(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaTypeConverter.java deleted file mode 100644 index fecadc7c3e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaTypeConverter.java +++ /dev/null @@ -1,110 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.context.java.JavaJpaContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.java.TypeConverterAnnotation; - -public class EclipseLinkJavaTypeConverter extends EclipseLinkJavaConverter - implements TypeConverter -{ - private String dataType; - - private String objectType; - - - public EclipseLinkJavaTypeConverter(JavaJpaContextNode parent) { - super(parent); - } - - public String getType() { - return EclipseLinkConverter.TYPE_CONVERTER; - } - - @Override - public String getAnnotationName() { - return TypeConverterAnnotation.ANNOTATION_NAME; - } - - @Override - protected TypeConverterAnnotation getAnnotation() { - return (TypeConverterAnnotation) super.getAnnotation(); - } - - - // **************** data type ********************************************** - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - getAnnotation().setDataType(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - protected void setDataType_(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - - // **************** object type ******************************************** - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - getAnnotation().setObjectType(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - protected void setObjectType_(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(JavaResourcePersistentMember jrpm) { - super.initialize(jrpm); - TypeConverterAnnotation resourceConverter = getAnnotation(); - this.dataType = this.dataType(resourceConverter); - this.objectType = this.objectType(resourceConverter); - } - - @Override - public void update(JavaResourcePersistentMember jrpm) { - super.update(jrpm); - TypeConverterAnnotation resourceConverter = getAnnotation(); - this.setDataType_(this.dataType(resourceConverter)); - this.setObjectType_(this.objectType(resourceConverter)); - } - - protected String dataType(TypeConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getDataType(); - } - - protected String objectType(TypeConverterAnnotation resourceConverter) { - return resourceConverter == null ? null : resourceConverter.getObjectType(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaVersionMappingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaVersionMappingImpl.java deleted file mode 100644 index 3c7c4502c5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/EclipseLinkJavaVersionMappingImpl.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.List; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.context.java.JavaConverter; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.GenericJavaVersionMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkVersionMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.java.ConvertAnnotation; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkJavaVersionMappingImpl extends GenericJavaVersionMapping implements EclipseLinkVersionMapping -{ - protected final EclipseLinkJavaMutable mutable; - - public EclipseLinkJavaVersionMappingImpl(JavaPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkJavaMutable(this); - } - - @Override - protected JavaConverter buildSpecifiedConverter(String converterType) { - JavaConverter javaConverter = super.buildSpecifiedConverter(converterType); - if (javaConverter != null) { - return javaConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkJavaConvert(this, this.resourcePersistentAttribute); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (this.resourcePersistentAttribute.getSupportingAnnotation(ConvertAnnotation.ANNOTATION_NAME) != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - - - //************ EclipselinkVersionMapping implementation **************** - - public Mutable getMutable() { - return this.mutable; - } - - - //************ initialization/update **************** - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize(this.resourcePersistentAttribute); - } - - @Override - protected void update() { - super.update(); - this.mutable.update(this.resourcePersistentAttribute); - } - - - //************ validation **************** - - @Override - public void validate(List<IMessage> messages, CompilationUnit astRoot) { - super.validate(messages, astRoot); - this.mutable.validate(messages, astRoot); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMapping.java deleted file mode 100644 index 6f193da06b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMapping.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.BasicCollectionMapping; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicCollectionAnnotation; -import org.eclipse.jpt.utility.internal.iterators.EmptyIterator; - -public class JavaBasicCollectionMapping extends AbstractJavaAttributeMapping<BasicCollectionAnnotation> implements BasicCollectionMapping -{ - - public JavaBasicCollectionMapping(JavaPersistentAttribute parent) { - super(parent); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return BasicCollectionAnnotation.ANNOTATION_NAME; - } - - public Iterator<String> correspondingAnnotationNames() { - return EmptyIterator.instance(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMappingProvider.java deleted file mode 100644 index b2c084cc27..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicCollectionMappingProvider.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicCollectionAnnotation; - -public class JavaBasicCollectionMappingProvider - implements JavaAttributeMappingProvider -{ - - // singleton - private static final JavaBasicCollectionMappingProvider INSTANCE = new JavaBasicCollectionMappingProvider(); - - /** - * Return the singleton. - */ - public static JavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private JavaBasicCollectionMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return BasicCollectionAnnotation.ANNOTATION_NAME; - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildJavaBasicCollectionMapping(parent); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMapping.java deleted file mode 100644 index 0fda365086..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMapping.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.BasicMapMapping; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicMapAnnotation; -import org.eclipse.jpt.utility.internal.iterators.EmptyIterator; - -public class JavaBasicMapMapping extends AbstractJavaAttributeMapping<BasicMapAnnotation> implements BasicMapMapping -{ - - public JavaBasicMapMapping(JavaPersistentAttribute parent) { - super(parent); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_MAP_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return BasicMapAnnotation.ANNOTATION_NAME; - } - - public Iterator<String> correspondingAnnotationNames() { - return EmptyIterator.instance(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMappingProvider.java deleted file mode 100644 index 7c1eadad99..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaBasicMapMappingProvider.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicMapAnnotation; - -public class JavaBasicMapMappingProvider - implements JavaAttributeMappingProvider -{ - - // singleton - private static final JavaBasicMapMappingProvider INSTANCE = new JavaBasicMapMappingProvider(); - - /** - * Return the singleton. - */ - public static JavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private JavaBasicMapMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_MAP_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return BasicMapAnnotation.ANNOTATION_NAME; - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildJavaBasicMapMapping(parent); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMapping.java deleted file mode 100644 index 8e5d78fcd2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMapping.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.TransformationMapping; -import org.eclipse.jpt.eclipselink.core.resource.java.TransformationAnnotation; -import org.eclipse.jpt.utility.internal.iterators.EmptyIterator; - -public class JavaTransformationMapping extends AbstractJavaAttributeMapping<TransformationAnnotation> implements TransformationMapping -{ - - public JavaTransformationMapping(JavaPersistentAttribute parent) { - super(parent); - } - - public String getKey() { - return EclipseLinkMappingKeys.TRANSFORMATION_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return TransformationAnnotation.ANNOTATION_NAME; - } - - public Iterator<String> correspondingAnnotationNames() { - return EmptyIterator.instance(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMappingProvider.java deleted file mode 100644 index ea3f9ee390..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaTransformationMappingProvider.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.java.TransformationAnnotation; - -public class JavaTransformationMappingProvider - implements JavaAttributeMappingProvider -{ - - // singleton - private static final JavaTransformationMappingProvider INSTANCE = new JavaTransformationMappingProvider(); - - /** - * Return the singleton. - */ - public static JavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private JavaTransformationMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.TRANSFORMATION_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return TransformationAnnotation.ANNOTATION_NAME; - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildJavaTransformationMapping(parent); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMapping.java deleted file mode 100644 index 4796b5d28e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMapping.java +++ /dev/null @@ -1,38 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import java.util.Iterator; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.internal.context.java.AbstractJavaAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.VariableOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.resource.java.VariableOneToOneAnnotation; -import org.eclipse.jpt.utility.internal.iterators.EmptyIterator; - -public class JavaVariableOneToOneMapping extends AbstractJavaAttributeMapping<VariableOneToOneAnnotation> implements VariableOneToOneMapping -{ - - public JavaVariableOneToOneMapping(JavaPersistentAttribute parent) { - super(parent); - } - - public String getKey() { - return EclipseLinkMappingKeys.VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return VariableOneToOneAnnotation.ANNOTATION_NAME; - } - - public Iterator<String> correspondingAnnotationNames() { - return EmptyIterator.instance(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMappingProvider.java deleted file mode 100644 index 9f71c2f569..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/java/JavaVariableOneToOneMappingProvider.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.java; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.DefaultJavaAttributeMappingProvider; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.java.VariableOneToOneAnnotation; - -public class JavaVariableOneToOneMappingProvider - implements DefaultJavaAttributeMappingProvider -{ - - // singleton - private static final JavaVariableOneToOneMappingProvider INSTANCE = new JavaVariableOneToOneMappingProvider(); - - /** - * Return the singleton. - */ - public static DefaultJavaAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private JavaVariableOneToOneMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public String getAnnotationName() { - return VariableOneToOneAnnotation.ANNOTATION_NAME; - } - - public JavaAttributeMapping buildMapping(JavaPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildJavaVariableOneToOneMapping(parent); - } - - - public boolean defaultApplies(JavaPersistentAttribute persistentAttribute) { - if (persistentAttribute.getResourcePersistentAttribute().typeIsInterface()) { - if (persistentAttribute.getResourcePersistentAttribute().typeIsContainer()) { - return false; - } - if (persistentAttribute.getResourcePersistentAttribute().typeIsValueHolder()) { - return false; - } - return true; - } - return false; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/ConverterHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/ConverterHolder.java deleted file mode 100644 index b814c8e125..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/ConverterHolder.java +++ /dev/null @@ -1,164 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.ListIterator; -import org.eclipse.jpt.core.context.JpaContextNode; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; - -public interface ConverterHolder extends JpaContextNode -{ - //************ customConverters ********************* - - /** - * Return a list iterator of the custom converters. - * This will not be null. - */ - <T extends CustomConverter> ListIterator<T> customConverters(); - - /** - * Return the number of custom converters. - */ - int customConvertersSize(); - - /** - * Add a custom converter to the converter holder, return the object representing it. - */ - CustomConverter addCustomConverter(int index); - - /** - * Remove the custom converter at the index from the converter holder. - */ - void removeCustomConverter(int index); - - /** - * Remove the custom converter at from the converter holder. - */ - void removeCustomConverter(CustomConverter converter); - - /** - * Move the custom converter from the source index to the target index. - */ - void moveCustomConverter(int targetIndex, int sourceIndex); - - String CUSTOM_CONVERTERS_LIST = "customConvertersList"; //$NON-NLS-1$ - - - //************ object type converters ********************* - - /** - * Return a list iterator of the object type converters. - * This will not be null. - */ - <T extends ObjectTypeConverter> ListIterator<T> objectTypeConverters(); - - /** - * Return the number of object type converters. - */ - int objectTypeConvertersSize(); - - /** - * Add a object type converter to the converter holder, return the object representing it. - */ - ObjectTypeConverter addObjectTypeConverter(int index); - - /** - * Remove the object type converter at the index from the converter holder. - */ - void removeObjectTypeConverter(int index); - - /** - * Remove the object type converter at from the converter holder. - */ - void removeObjectTypeConverter(ObjectTypeConverter converter); - - /** - * Move the object type converter from the source index to the target index. - */ - void moveObjectTypeConverter(int targetIndex, int sourceIndex); - - String OBJECT_TYPE_CONVERTERS_LIST = "objectTypeConvertersList"; //$NON-NLS-1$ - - - //************ struct converters ********************* - - /** - * Return a list iterator of the struct converters. - * This will not be null. - */ - <T extends StructConverter> ListIterator<T> structConverters(); - - /** - * Return the number of struct converters. - */ - int structConvertersSize(); - - /** - * Add a struct converter to the converter holder, return the object representing it. - */ - StructConverter addStructConverter(int index); - - /** - * Remove the struct converter at the index from the converter holder. - */ - void removeStructConverter(int index); - - /** - * Remove the struct converter at from the converter holder. - */ - void removeStructConverter(StructConverter converter); - - /** - * Move the struct converter from the source index to the target index. - */ - void moveStructConverter(int targetIndex, int sourceIndex); - - String STRUCT_CONVERTERS_LIST = "structConvertersList"; //$NON-NLS-1$ - - - //************ type converters ********************* - - /** - * Return a list iterator of the type converters. - * This will not be null. - */ - <T extends TypeConverter> ListIterator<T> typeConverters(); - - /** - * Return the number of type converters. - */ - int typeConvertersSize(); - - /** - * Add a type converter to the converter holder, return the object representing it. - */ - TypeConverter addTypeConverter(int index); - - /** - * Remove the type converter at the index from the converter holder. - */ - void removeTypeConverter(int index); - - /** - * Remove the type converter at from the converter holder. - */ - void removeTypeConverter(TypeConverter converter); - - /** - * Move the type converter from the source index to the target index. - */ - void moveTypeConverter(int targetIndex, int sourceIndex); - - String TYPE_CONVERTERS_LIST = "typeConvertersList"; //$NON-NLS-1$ - -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappings.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappings.java deleted file mode 100644 index e0b0fdc4e2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappings.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.ListIterator; - -import org.eclipse.jpt.core.context.orm.EntityMappings; -import org.eclipse.jpt.core.context.orm.OrmNamedNativeQuery; -import org.eclipse.jpt.core.context.orm.OrmNamedQuery; - -public interface EclipseLinkEntityMappings - extends EntityMappings -{ - - ConverterHolder getConverterHolder(); - - // hmmm - these suppress various warnings in EclipseLinkEntityMappingImpl... - ListIterator<OrmNamedQuery> namedQueries(); - ListIterator<OrmNamedNativeQuery> namedNativeQueries(); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappingsImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappingsImpl.java deleted file mode 100644 index 27c7fc0ce5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkEntityMappingsImpl.java +++ /dev/null @@ -1,74 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.internal.context.orm.GenericEntityMappings; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkEntityMappingsImpl - extends GenericEntityMappings - implements EclipseLinkEntityMappings -{ - - protected final EclipseLinkOrmConverterHolder converterHolder; - - public EclipseLinkEntityMappingsImpl(EclipseLinkOrmXml parent) { - super(parent); - this.converterHolder = new EclipseLinkOrmConverterHolder(this); - } - - @Override - protected OrmPersistentType buildPersistentType(String mappingKey) { - return getJpaFactory().buildEclipseLinkOrmPersistentType(this, mappingKey); - } - - // **************** JpaNode impl ******************************************* - - @Override - protected EclipseLinkJpaFactory getJpaFactory() { - return (EclipseLinkJpaFactory) super.getJpaFactory(); - } - - @Override - public EclipseLinkOrmXml getParent() { - return (EclipseLinkOrmXml) super.getParent(); - } - - - // **************** EclipseLinkEntityMappings impl ********************************** - - public ConverterHolder getConverterHolder() { - return this.converterHolder; - } - - @Override - protected void initialize() { - super.initialize(); - this.converterHolder.initialize((XmlEntityMappings) this.xmlEntityMappings); - } - - @Override - public void update() { - super.update(); - this.converterHolder.update(); - } - - // **************** validation ********************************************* - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - this.converterHolder.validate(messages); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMapping.java deleted file mode 100644 index acf14f9485..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMapping.java +++ /dev/null @@ -1,94 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmConverter; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmBasicMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkBasicMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmBasicMapping extends GenericOrmBasicMapping - implements EclipseLinkBasicMapping -{ - protected EclipseLinkOrmMutable mutable; - - - public EclipseLinkOrmBasicMapping(OrmPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkOrmMutable(this); - } - - - public Mutable getMutable() { - return this.mutable; - } - - @Override - protected OrmConverter buildSpecifiedConverter(String converterType) { - OrmConverter ormConverter = super.buildSpecifiedConverter(converterType); - if (ormConverter != null) { - return ormConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkOrmConvert(this, (XmlBasic) this.resourceAttributeMapping); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (((XmlBasic) this.resourceAttributeMapping).getConvert() != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlBasic addToResourceModel(XmlTypeMapping typeMapping) { - XmlBasic basic = EclipseLinkOrmFactory.eINSTANCE.createXmlBasicImpl(); - getPersistentAttribute().initialize(basic); - typeMapping.getAttributes().getBasics().add(basic); - return basic; - } - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize((XmlMutable) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.mutable.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - mutable validation - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMappingProvider.java deleted file mode 100644 index a3e9bd246c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmBasicMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaBasicMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmBasicMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmBasicMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmBasicMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.BASIC_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmBasicMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlBasic(ormTypeMapping, (JavaBasicMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCaching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCaching.java deleted file mode 100644 index 3713babb96..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCaching.java +++ /dev/null @@ -1,666 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.CacheCoordinationType; -import org.eclipse.jpt.eclipselink.core.context.CacheType; -import org.eclipse.jpt.eclipselink.core.context.ExistenceType; -import org.eclipse.jpt.eclipselink.core.context.ExpiryTimeOfDay; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.context.orm.XmlCaching; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay; - -public class EclipseLinkOrmCaching extends AbstractXmlContextNode - implements XmlCaching -{ - protected XmlCacheHolder resource; - - protected int defaultSize; - protected Integer specifiedSize; - - protected boolean defaultShared; - protected Boolean specifiedShared; - - protected CacheType defaultType; - protected CacheType specifiedType; - - protected boolean defaultAlwaysRefresh; - protected Boolean specifiedAlwaysRefresh; - - protected boolean defaultRefreshOnlyIfNewer; - protected Boolean specifiedRefreshOnlyIfNewer; - - protected boolean defaultDisableHits; - protected Boolean specifiedDisableHits; - - protected CacheCoordinationType defaultCoordinationType; - protected CacheCoordinationType specifiedCoordinationType; - - protected ExistenceType specifiedExistenceType; - protected ExistenceType defaultExistenceType; - - protected Integer expiry; - protected EclipseLinkOrmExpiryTimeOfDay expiryTimeOfDay; - - public EclipseLinkOrmCaching(OrmTypeMapping parent) { - super(parent); - } - - public int getSize() { - return (this.specifiedSize == null) ? this.defaultSize : this.specifiedSize.intValue(); - } - - public int getDefaultSize() { - return this.defaultSize; - } - - protected void setDefaultSize(int newSize) { - int oldSize = this.defaultSize; - this.defaultSize = newSize; - firePropertyChanged(DEFAULT_SIZE_PROPERTY, oldSize, newSize); - } - - public Integer getSpecifiedSize() { - return this.specifiedSize; - } - - public void setSpecifiedSize(Integer newSpecifiedSize) { - Integer oldSpecifiedSize = this.specifiedSize; - this.specifiedSize = newSpecifiedSize; - if (oldSpecifiedSize != newSpecifiedSize) { - if (this.getResourceCache() != null) { - this.getResourceCache().setSize(newSpecifiedSize); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedSize != null) { - addResourceCache(); - getResourceCache().setSize(newSpecifiedSize); - } - } - firePropertyChanged(SPECIFIED_SIZE_PROPERTY, oldSpecifiedSize, newSpecifiedSize); - } - - protected void setSpecifiedSize_(Integer newSpecifiedSize) { - Integer oldSpecifiedSize = this.specifiedSize; - this.specifiedSize = newSpecifiedSize; - firePropertyChanged(SPECIFIED_SIZE_PROPERTY, oldSpecifiedSize, newSpecifiedSize); - } - - - public boolean isShared() { - return (this.specifiedShared == null) ? this.defaultShared : this.specifiedShared.booleanValue(); - } - - public boolean isDefaultShared() { - return this.defaultShared; - } - - protected void setDefaultShared(boolean newDefaultShared) { - boolean oldDefaultShared = this.defaultShared; - this.defaultShared = newDefaultShared; - firePropertyChanged(DEFAULT_SHARED_PROPERTY, oldDefaultShared, newDefaultShared); - } - - public Boolean getSpecifiedShared() { - return this.specifiedShared; - } - - public void setSpecifiedShared(Boolean newSpecifiedShared) { - Boolean oldSpecifiedShared = this.specifiedShared; - this.specifiedShared = newSpecifiedShared; - if (oldSpecifiedShared != newSpecifiedShared) { - if (this.getResourceCache() != null) { - this.getResourceCache().setShared(newSpecifiedShared); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedShared != null) { - addResourceCache(); - getResourceCache().setShared(newSpecifiedShared); - } - } - firePropertyChanged(SPECIFIED_SHARED_PROPERTY, oldSpecifiedShared, newSpecifiedShared); - if (newSpecifiedShared == Boolean.FALSE) { - setSpecifiedType(null); - setSpecifiedSize(null); - setSpecifiedAlwaysRefresh(null); - setSpecifiedRefreshOnlyIfNewer(null); - setSpecifiedDisableHits(null); - setSpecifiedCoordinationType(null); - setExpiry(null); - if (this.expiryTimeOfDay != null) { - removeExpiryTimeOfDay(); - } - } - } - - protected void setSpecifiedShared_(Boolean newSpecifiedShared) { - Boolean oldSpecifiedShared = this.specifiedShared; - this.specifiedShared = newSpecifiedShared; - firePropertyChanged(SPECIFIED_SHARED_PROPERTY, oldSpecifiedShared, newSpecifiedShared); - } - - - public boolean isAlwaysRefresh() { - return (this.specifiedAlwaysRefresh == null) ? this.defaultAlwaysRefresh : this.specifiedAlwaysRefresh.booleanValue(); - } - - public boolean isDefaultAlwaysRefresh() { - return this.defaultAlwaysRefresh; - } - - protected void setDefaultAlwaysRefresh(boolean newDefaultAlwaysRefresh) { - boolean oldDefaultAlwaysRefresh = this.defaultAlwaysRefresh; - this.defaultAlwaysRefresh = newDefaultAlwaysRefresh; - firePropertyChanged(DEFAULT_ALWAYS_REFRESH_PROPERTY, oldDefaultAlwaysRefresh, newDefaultAlwaysRefresh); - } - - public Boolean getSpecifiedAlwaysRefresh() { - return this.specifiedAlwaysRefresh; - } - - public void setSpecifiedAlwaysRefresh(Boolean newSpecifiedAlwaysRefresh) { - Boolean oldSpecifiedAlwaysRefresh = this.specifiedAlwaysRefresh; - this.specifiedAlwaysRefresh = newSpecifiedAlwaysRefresh; - if (oldSpecifiedAlwaysRefresh != newSpecifiedAlwaysRefresh) { - if (this.getResourceCache() != null) { - this.getResourceCache().setAlwaysRefresh(newSpecifiedAlwaysRefresh); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedAlwaysRefresh != null) { - addResourceCache(); - getResourceCache().setAlwaysRefresh(newSpecifiedAlwaysRefresh); - } - } - firePropertyChanged(SPECIFIED_ALWAYS_REFRESH_PROPERTY, oldSpecifiedAlwaysRefresh, newSpecifiedAlwaysRefresh); - } - - protected void setSpecifiedAlwaysRefresh_(Boolean newSpecifiedAlwaysRefresh) { - Boolean oldSpecifiedAlwaysRefresh = this.specifiedAlwaysRefresh; - this.specifiedAlwaysRefresh = newSpecifiedAlwaysRefresh; - firePropertyChanged(SPECIFIED_ALWAYS_REFRESH_PROPERTY, oldSpecifiedAlwaysRefresh, newSpecifiedAlwaysRefresh); - } - - - public boolean isRefreshOnlyIfNewer() { - return (this.specifiedRefreshOnlyIfNewer == null) ? this.defaultRefreshOnlyIfNewer : this.specifiedRefreshOnlyIfNewer.booleanValue(); - } - - public boolean isDefaultRefreshOnlyIfNewer() { - return this.defaultRefreshOnlyIfNewer; - } - - protected void setDefaultRefreshOnlyIfNewer(boolean newDefaultRefreshOnlyIfNewer) { - boolean oldDefaultRefreshOnlyIfNewer = this.defaultRefreshOnlyIfNewer; - this.defaultRefreshOnlyIfNewer = newDefaultRefreshOnlyIfNewer; - firePropertyChanged(DEFAULT_REFRESH_ONLY_IF_NEWER_PROPERTY, oldDefaultRefreshOnlyIfNewer, newDefaultRefreshOnlyIfNewer); - } - - public Boolean getSpecifiedRefreshOnlyIfNewer() { - return this.specifiedRefreshOnlyIfNewer; - } - - public void setSpecifiedRefreshOnlyIfNewer(Boolean newSpecifiedRefreshOnlyIfNewer) { - Boolean oldSpecifiedRefreshOnlyIfNewer = this.specifiedRefreshOnlyIfNewer; - this.specifiedRefreshOnlyIfNewer = newSpecifiedRefreshOnlyIfNewer; - if (oldSpecifiedRefreshOnlyIfNewer != newSpecifiedRefreshOnlyIfNewer) { - if (this.getResourceCache() != null) { - this.getResourceCache().setRefreshOnlyIfNewer(newSpecifiedRefreshOnlyIfNewer); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedRefreshOnlyIfNewer != null) { - addResourceCache(); - getResourceCache().setRefreshOnlyIfNewer(newSpecifiedRefreshOnlyIfNewer); - } - } - firePropertyChanged(SPECIFIED_REFRESH_ONLY_IF_NEWER_PROPERTY, oldSpecifiedRefreshOnlyIfNewer, newSpecifiedRefreshOnlyIfNewer); - } - - protected void setSpecifiedRefreshOnlyIfNewer_(Boolean newSpecifiedRefreshOnlyIfNewer) { - Boolean oldSpecifiedRefreshOnlyIfNewer = this.specifiedRefreshOnlyIfNewer; - this.specifiedRefreshOnlyIfNewer = newSpecifiedRefreshOnlyIfNewer; - firePropertyChanged(SPECIFIED_REFRESH_ONLY_IF_NEWER_PROPERTY, oldSpecifiedRefreshOnlyIfNewer, newSpecifiedRefreshOnlyIfNewer); - } - - - public boolean isDisableHits() { - return (this.specifiedDisableHits == null) ? this.defaultDisableHits : this.specifiedDisableHits.booleanValue(); - } - - public boolean isDefaultDisableHits() { - return this.defaultDisableHits; - } - - protected void setDefaultDisableHits(boolean newDefaultDisableHits) { - boolean oldDefaultDisableHits = this.defaultDisableHits; - this.defaultDisableHits = newDefaultDisableHits; - firePropertyChanged(DEFAULT_DISABLE_HITS_PROPERTY, oldDefaultDisableHits, newDefaultDisableHits); - } - - public Boolean getSpecifiedDisableHits() { - return this.specifiedDisableHits; - } - - public void setSpecifiedDisableHits(Boolean newSpecifiedDisableHits) { - Boolean oldSpecifiedDisableHits = this.specifiedDisableHits; - this.specifiedDisableHits = newSpecifiedDisableHits; - if (oldSpecifiedDisableHits != newSpecifiedDisableHits) { - if (this.getResourceCache() != null) { - this.getResourceCache().setDisableHits(newSpecifiedDisableHits); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedDisableHits != null) { - addResourceCache(); - getResourceCache().setDisableHits(newSpecifiedDisableHits); - } - } - firePropertyChanged(SPECIFIED_DISABLE_HITS_PROPERTY, oldSpecifiedDisableHits, newSpecifiedDisableHits); - } - - protected void setSpecifiedDisableHits_(Boolean newSpecifiedDisableHits) { - Boolean oldSpecifiedDisableHits = this.specifiedDisableHits; - this.specifiedDisableHits = newSpecifiedDisableHits; - firePropertyChanged(SPECIFIED_DISABLE_HITS_PROPERTY, oldSpecifiedDisableHits, newSpecifiedDisableHits); - } - - public CacheType getType() { - return (this.specifiedType == null) ? this.defaultType : this.specifiedType; - } - - public CacheType getDefaultType() { - return this.defaultType; - } - - protected void setDefaultType(CacheType newDefaultType) { - CacheType oldDefaultType= this.defaultType; - this.defaultType = newDefaultType; - firePropertyChanged(DEFAULT_TYPE_PROPERTY, oldDefaultType, newDefaultType); - } - - public CacheType getSpecifiedType() { - return this.specifiedType; - } - - public void setSpecifiedType(CacheType newSpecifiedType) { - CacheType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - if (oldSpecifiedType != newSpecifiedType) { - if (this.getResourceCache() != null) { - this.getResourceCache().setType(CacheType.toOrmResourceModel(newSpecifiedType)); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedType != null) { - addResourceCache(); - getResourceCache().setType(CacheType.toOrmResourceModel(newSpecifiedType)); - } - } - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - protected void setSpecifiedType_(CacheType newSpecifiedType) { - CacheType oldSpecifiedType= this.specifiedType; - this.specifiedType = newSpecifiedType; - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - - public CacheCoordinationType getCoordinationType() { - return (this.specifiedCoordinationType == null) ? this.defaultCoordinationType : this.specifiedCoordinationType; - } - - public CacheCoordinationType getDefaultCoordinationType() { - return this.defaultCoordinationType; - } - - protected void setDefaultCoordinationType(CacheCoordinationType newDefaultcCoordinationType) { - CacheCoordinationType oldDefaultcCoordinationType= this.defaultCoordinationType; - this.defaultCoordinationType = newDefaultcCoordinationType; - firePropertyChanged(DEFAULT_COORDINATION_TYPE_PROPERTY, oldDefaultcCoordinationType, newDefaultcCoordinationType); - } - - public CacheCoordinationType getSpecifiedCoordinationType() { - return this.specifiedCoordinationType; - } - - public void setSpecifiedCoordinationType(CacheCoordinationType newSpecifiedCoordinationType) { - CacheCoordinationType oldSpecifiedCoordinationType = this.specifiedCoordinationType; - this.specifiedCoordinationType = newSpecifiedCoordinationType; - if (oldSpecifiedCoordinationType != newSpecifiedCoordinationType) { - if (this.getResourceCache() != null) { - this.getResourceCache().setCoordinationType(CacheCoordinationType.toOrmResourceModel(newSpecifiedCoordinationType)); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newSpecifiedCoordinationType != null) { - addResourceCache(); - getResourceCache().setCoordinationType(CacheCoordinationType.toOrmResourceModel(newSpecifiedCoordinationType)); - } - } - firePropertyChanged(SPECIFIED_COORDINATION_TYPE_PROPERTY, oldSpecifiedCoordinationType, newSpecifiedCoordinationType); - } - - protected void setSpecifiedCoordinationType_(CacheCoordinationType newSpecifiedCoordinationType) { - CacheCoordinationType oldSpecifiedCoordinationType = this.specifiedCoordinationType; - this.specifiedCoordinationType = newSpecifiedCoordinationType; - firePropertyChanged(SPECIFIED_COORDINATION_TYPE_PROPERTY, oldSpecifiedCoordinationType, newSpecifiedCoordinationType); - } - - public ExistenceType getExistenceType() { - return (this.specifiedExistenceType == null) ? this.defaultExistenceType : this.specifiedExistenceType; - } - - public ExistenceType getDefaultExistenceType() { - return this.defaultExistenceType; - } - - protected void setDefaultExistenceType(ExistenceType newDefaultExistenceType) { - ExistenceType oldDefaultExistenceType = this.defaultExistenceType; - this.defaultExistenceType = newDefaultExistenceType; - firePropertyChanged(DEFAULT_EXISTENCE_TYPE_PROPERTY, oldDefaultExistenceType, newDefaultExistenceType); - } - - public ExistenceType getSpecifiedExistenceType() { - return this.specifiedExistenceType; - } - - public void setSpecifiedExistenceType(ExistenceType newSpecifiedExistenceType) { - ExistenceType oldSpecifiedExistenceType = this.specifiedExistenceType; - this.specifiedExistenceType = newSpecifiedExistenceType; - this.resource.setExistenceChecking(ExistenceType.toOrmResourceModel(newSpecifiedExistenceType)); - firePropertyChanged(SPECIFIED_EXISTENCE_TYPE_PROPERTY, oldSpecifiedExistenceType, newSpecifiedExistenceType); - } - - protected void setSpecifiedExistenceType_(ExistenceType newSpecifiedExistenceType) { - ExistenceType oldSpecifiedExistenceType = this.specifiedExistenceType; - this.specifiedExistenceType = newSpecifiedExistenceType; - firePropertyChanged(SPECIFIED_EXISTENCE_TYPE_PROPERTY, oldSpecifiedExistenceType, newSpecifiedExistenceType); - } - - public Integer getExpiry() { - return this.expiry; - } - - public void setExpiry(Integer newExpiry) { - Integer oldExpiry = this.expiry; - this.expiry = newExpiry; - if (oldExpiry != newExpiry) { - if (this.getResourceCache() != null) { - this.getResourceCache().setExpiry(newExpiry); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - } - else if (newExpiry != null) { - addResourceCache(); - this.getResourceCache().setExpiry(newExpiry); - } - } - firePropertyChanged(EXPIRY_PROPERTY, oldExpiry, newExpiry); - if (newExpiry != null && this.expiryTimeOfDay != null) { - removeExpiryTimeOfDay(); - } - } - - protected void setExpiry_(Integer newExpiry) { - Integer oldExpiry = this.expiry; - this.expiry = newExpiry; - firePropertyChanged(EXPIRY_PROPERTY, oldExpiry, newExpiry); - } - - public ExpiryTimeOfDay getExpiryTimeOfDay() { - return this.expiryTimeOfDay; - } - - public ExpiryTimeOfDay addExpiryTimeOfDay() { - if (this.expiryTimeOfDay != null) { - throw new IllegalStateException("expiryTimeOfDay already exists, use getExpiryTimeOfDay()"); //$NON-NLS-1$ - } - if (getResourceCache() == null) { - addResourceCache(); - } - EclipseLinkOrmExpiryTimeOfDay newExpiryTimeOfDay = new EclipseLinkOrmExpiryTimeOfDay(this); - this.expiryTimeOfDay = newExpiryTimeOfDay; - XmlTimeOfDay resourceTimeOfDay = EclipseLinkOrmFactory.eINSTANCE.createXmlTimeOfDay(); - newExpiryTimeOfDay.initialize(resourceTimeOfDay); - getResourceCache().setExpiryTimeOfDay(resourceTimeOfDay); - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, null, newExpiryTimeOfDay); - setExpiry(null); - return newExpiryTimeOfDay; - } - - public void removeExpiryTimeOfDay() { - if (this.expiryTimeOfDay == null) { - throw new IllegalStateException("timeOfDayExpiry does not exist"); //$NON-NLS-1$ - } - ExpiryTimeOfDay oldExpiryTimeOfDay = this.expiryTimeOfDay; - this.expiryTimeOfDay = null; - getResourceCache().setExpiryTimeOfDay(null); - if (this.getResourceCache().isAllFeaturesUnset()) { - removeResourceCache(); - } - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, oldExpiryTimeOfDay, null); - } - - protected void setExpiryTimeOfDay(EclipseLinkOrmExpiryTimeOfDay newExpiryTimeOfDay) { - EclipseLinkOrmExpiryTimeOfDay oldExpiryTimeOfDay = this.expiryTimeOfDay; - this.expiryTimeOfDay = newExpiryTimeOfDay; - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, oldExpiryTimeOfDay, newExpiryTimeOfDay); - } - - protected XmlCache getResourceCache() { - return this.resource.getCache(); - } - - protected void addResourceCache() { - this.resource.setCache(EclipseLinkOrmFactory.eINSTANCE.createXmlCache()); - } - - protected void removeResourceCache() { - this.resource.setCache(null); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlCacheHolder resource, JavaCaching javaCaching) { - this.resource = resource; - XmlCache resourceCache = getResourceCache(); - this.defaultSize = this.defaultSize(javaCaching); - this.specifiedSize = getResourceSize(resourceCache); - this.defaultShared = this.defaultShared(javaCaching); - this.specifiedShared = this.getResourceShared(resourceCache); - this.defaultAlwaysRefresh = this.defaultAlwaysRefresh(javaCaching); - this.specifiedAlwaysRefresh = this.getResourceAlwaysRefresh(resourceCache); - this.defaultRefreshOnlyIfNewer = this.defaultRefreshOnlyIfNewer(javaCaching); - this.specifiedRefreshOnlyIfNewer = this.getResourceRefreshOnlyIfNewer(resourceCache); - this.defaultDisableHits = this.defaultDisableHits(javaCaching); - this.specifiedDisableHits = this.getResourceDisableHits(resourceCache); - this.defaultType = this.defaultType(javaCaching); - this.specifiedType = this.getResourceType(resourceCache); - this.defaultCoordinationType = this.defaultCoordinationType(javaCaching); - this.specifiedCoordinationType = this.getResourceCoordinationType(resourceCache); - this.defaultExistenceType = this.defaultExistenceType(javaCaching); - this.specifiedExistenceType = this.getResourceExistenceChecking(); - this.initializeExpiry(resourceCache); - } - - protected void initializeExpiry(XmlCache resourceCache) { - if (resourceCache == null) { - return; - } - if (resourceCache.getExpiryTimeOfDay() == null) { - this.expiry = resourceCache.getExpiry(); - } - else { - if (resourceCache.getExpiry() == null) { //handle with validation if both expiry and expiryTimeOfDay are set - this.expiryTimeOfDay = new EclipseLinkOrmExpiryTimeOfDay(this); - this.expiryTimeOfDay.initialize(resourceCache.getExpiryTimeOfDay()); - } - } - } - - protected void update(JavaCaching javaCaching) { - XmlCache resourceCache = getResourceCache(); - setDefaultSize(this.defaultSize(javaCaching)); - setSpecifiedSize_(this.getResourceSize(resourceCache)); - setDefaultShared(this.defaultShared(javaCaching)); - setSpecifiedShared_(this.getResourceShared(resourceCache)); - setDefaultAlwaysRefresh(this.defaultAlwaysRefresh(javaCaching)); - setSpecifiedAlwaysRefresh_(this.getResourceAlwaysRefresh(resourceCache)); - setDefaultRefreshOnlyIfNewer(this.defaultRefreshOnlyIfNewer(javaCaching)); - setSpecifiedRefreshOnlyIfNewer_(this.getResourceRefreshOnlyIfNewer(resourceCache)); - setDefaultDisableHits(this.defaultDisableHits(javaCaching)); - setSpecifiedDisableHits_(this.getResourceDisableHits(resourceCache)); - setDefaultType(this.defaultType(javaCaching)); - setSpecifiedType_(this.getResourceType(resourceCache)); - setDefaultCoordinationType(this.defaultCoordinationType(javaCaching)); - setSpecifiedCoordinationType_(this.getResourceCoordinationType(resourceCache)); - setDefaultExistenceType(this.defaultExistenceType(javaCaching)); - setSpecifiedExistenceType_(this.getResourceExistenceChecking()); - this.updateExpiry(resourceCache); - } - - protected void updateExpiry(XmlCache resourceCache) { - if (resourceCache == null) { - setExpiryTimeOfDay(null); - setExpiry_(null); - return; - } - if (resourceCache.getExpiryTimeOfDay() == null) { - setExpiryTimeOfDay(null); - setExpiry_(resourceCache.getExpiry()); - } - else { - if (this.expiryTimeOfDay != null) { - this.expiryTimeOfDay.update(resourceCache.getExpiryTimeOfDay()); - } - else if (resourceCache.getExpiry() == null){ - setExpiryTimeOfDay(new EclipseLinkOrmExpiryTimeOfDay(this)); - this.expiryTimeOfDay.initialize(resourceCache.getExpiryTimeOfDay()); - } - else { //handle with validation if both expiry and expiryTimeOfDay are set - setExpiryTimeOfDay(null); - } - } - } - - protected int defaultSize(JavaCaching javaCaching) { - return (javaCaching == null) ? DEFAULT_SIZE : javaCaching.getSize(); - } - - protected Integer getResourceSize(XmlCache resource) { - return (resource == null) ? null : resource.getSize(); - } - - protected boolean defaultShared(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_SHARED; - } - return getResourceCache() == null ? javaCaching.isShared() : DEFAULT_SHARED; - } - - protected Boolean getResourceShared(XmlCache resource) { - return (resource == null) ? null : resource.getShared(); - } - - protected boolean defaultAlwaysRefresh(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_ALWAYS_REFRESH; - } - return getResourceCache() == null ? javaCaching.isAlwaysRefresh() : DEFAULT_ALWAYS_REFRESH; - } - - protected Boolean getResourceAlwaysRefresh(XmlCache resource) { - return (resource == null) ? null : resource.getAlwaysRefresh(); - } - - protected boolean defaultRefreshOnlyIfNewer(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_REFRESH_ONLY_IF_NEWER; - } - return getResourceCache() == null ? javaCaching.isRefreshOnlyIfNewer() : DEFAULT_REFRESH_ONLY_IF_NEWER; - } - - protected Boolean getResourceRefreshOnlyIfNewer(XmlCache resource) { - return (resource == null) ? null : resource.getRefreshOnlyIfNewer(); - } - - protected boolean defaultDisableHits(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_DISABLE_HITS; - } - return getResourceCache() == null ? javaCaching.isDisableHits() : DEFAULT_DISABLE_HITS; - } - - protected Boolean getResourceDisableHits(XmlCache resource) { - return (resource == null) ? null : resource.getDisableHits(); - } - - protected CacheType defaultType(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_TYPE; - } - return getResourceCache() == null ? javaCaching.getType() : DEFAULT_TYPE; - } - - protected CacheType getResourceType(XmlCache resource) { - return (resource == null) ? null : CacheType.fromOrmResourceModel(resource.getType()); - } - - protected CacheCoordinationType defaultCoordinationType(JavaCaching javaCaching) { - if (javaCaching == null) { - return DEFAULT_COORDINATION_TYPE; - } - return getResourceCache() == null ? javaCaching.getCoordinationType() : DEFAULT_COORDINATION_TYPE; - } - - protected CacheCoordinationType getResourceCoordinationType(XmlCache resource) { - return (resource == null) ? null : CacheCoordinationType.fromOrmResourceModel(resource.getCoordinationType()); - } - - protected ExistenceType defaultExistenceType(JavaCaching javaCaching) { - return (javaCaching == null) ? DEFAULT_EXISTENCE_TYPE : javaCaching.getExistenceType(); - } - - protected ExistenceType getResourceExistenceChecking() { - return (this.resource == null) ? null : ExistenceType.fromOrmResourceModel(this.resource.getExistenceChecking()); - } - - protected Integer getResourceExpiry(XmlCache resource) { - return (resource == null) ? null : resource.getExpiry(); - } - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - XmlCache resource = getResourceCache(); - return resource == null ? null : resource.getValidationTextRange(); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmChangeTracking.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmChangeTracking.java deleted file mode 100644 index 3dd671cfa0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmChangeTracking.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.ChangeTrackingType; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder; - -public class EclipseLinkOrmChangeTracking extends AbstractXmlContextNode - implements ChangeTracking -{ - protected XmlChangeTrackingHolder resource; - - protected ChangeTrackingType defaultType; - - protected ChangeTrackingType specifiedType; - - - public EclipseLinkOrmChangeTracking(OrmTypeMapping parent) { - super(parent); - } - - - public ChangeTrackingType getType() { - return (getSpecifiedType() != null) ? getSpecifiedType() : getDefaultType(); - } - - public ChangeTrackingType getDefaultType() { - return this.defaultType; - } - - protected void setDefaultType_(ChangeTrackingType newDefaultType) { - ChangeTrackingType oldDefaultType = this.defaultType; - this.defaultType = newDefaultType; - firePropertyChanged(DEFAULT_TYPE_PROPERTY, oldDefaultType, newDefaultType); - } - - public ChangeTrackingType getSpecifiedType() { - return this.specifiedType; - } - - public void setSpecifiedType(ChangeTrackingType newSpecifiedType) { - ChangeTrackingType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - - if (newSpecifiedType == null) { - this.resource.setChangeTracking(null); - } - else { - if (this.resource.getChangeTracking() == null) { - this.resource.setChangeTracking(EclipseLinkOrmFactory.eINSTANCE.createXmlChangeTracking()); - } - this.resource.getChangeTracking().setType(ChangeTrackingType.toOrmResourceModel(newSpecifiedType)); - } - - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - protected void setSpecifiedType_(ChangeTrackingType newSpecifiedType) { - ChangeTrackingType oldSpecifiedType = this.specifiedType; - this.specifiedType = newSpecifiedType; - firePropertyChanged(SPECIFIED_TYPE_PROPERTY, oldSpecifiedType, newSpecifiedType); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlChangeTrackingHolder xmlChangeTrackingHolder, ChangeTracking javaChangeTracking) { - this.resource = xmlChangeTrackingHolder; - this.defaultType = calculateDefaultType(javaChangeTracking); - this.specifiedType = getResourceChangeTracking(); - } - - protected void update(ChangeTracking javaChangeTracking) { - setDefaultType_(calculateDefaultType(javaChangeTracking)); - setSpecifiedType_(getResourceChangeTracking()); - } - - protected ChangeTrackingType calculateDefaultType(ChangeTracking javaChangeTracking) { - return (javaChangeTracking != null) ? javaChangeTracking.getType() : ChangeTracking.DEFAULT_TYPE; - } - - protected ChangeTrackingType getResourceChangeTracking() { - XmlChangeTracking xmlChangeTracking = this.resource.getChangeTracking(); - return (xmlChangeTracking != null) ? ChangeTrackingType.fromOrmResourceModel(xmlChangeTracking.getType()) : null; - } - - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - return this.resource.getValidationTextRange(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConversionValue.java deleted file mode 100644 index 24d7b41b94..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConversionValue.java +++ /dev/null @@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.internal.DefaultEclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaValidationMessages; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmConversionValue extends AbstractXmlContextNode implements ConversionValue -{ - private XmlConversionValue resourceConversionValue; - - private String dataValue; - - private String objectValue; - - public EclipseLinkOrmConversionValue(EclipseLinkOrmObjectTypeConverter parent) { - super(parent); - } - - @Override - public EclipseLinkOrmObjectTypeConverter getParent() { - return (EclipseLinkOrmObjectTypeConverter) super.getParent(); - } - - public TextRange getValidationTextRange() { - return this.resourceConversionValue.getValidationTextRange(); - } - - public String getDataValue() { - return this.dataValue; - } - - public void setDataValue(String newDataValue) { - String oldDataValue = this.dataValue; - this.dataValue = newDataValue; - this.resourceConversionValue.setDataValue(newDataValue); - firePropertyChanged(DATA_VALUE_PROPERTY, oldDataValue, newDataValue); - } - - protected void setDataValue_(String newDataValue) { - String oldDataValue = this.dataValue; - this.dataValue = newDataValue; - firePropertyChanged(DATA_VALUE_PROPERTY, oldDataValue, newDataValue); - } - - public String getObjectValue() { - return this.objectValue; - } - - public void setObjectValue(String newObjectValue) { - String oldObjectValue = this.objectValue; - this.objectValue = newObjectValue; - this.resourceConversionValue.setObjectValue(newObjectValue); - firePropertyChanged(OBJECT_VALUE_PROPERTY, oldObjectValue, newObjectValue); - } - - protected void setObjectValue_(String newObjectValue) { - String oldObjectValue = this.objectValue; - this.objectValue = newObjectValue; - firePropertyChanged(OBJECT_VALUE_PROPERTY, oldObjectValue, newObjectValue); - } - - public void initialize(XmlConversionValue resourceConversionValue) { - this.resourceConversionValue = resourceConversionValue; - this.dataValue = this.getResourceDataValue(); - this.objectValue = this.getResourceObjectValue(); - } - - public void update(XmlConversionValue resourceConversionValue) { - this.resourceConversionValue = resourceConversionValue; - this.setDataValue_(this.getResourceDataValue()); - this.setObjectValue_(this.getResourceObjectValue()); - } - - protected String getResourceDataValue() { - return this.resourceConversionValue.getDataValue(); - } - - protected String getResourceObjectValue() { - return this.resourceConversionValue.getObjectValue(); - } - - public TextRange getDataValueTextRange() { - return this.resourceConversionValue.getDataValueTextRange(); - } - - public TextRange getObjectValueTextRange() { - return this.resourceConversionValue.getObjectValueTextRange(); - } - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - validateDataValuesUnique(messages); - } - - protected void validateDataValuesUnique(List<IMessage> messages) { - List<String> dataValues = CollectionTools.list(getParent().dataValues()); - dataValues.remove(this.dataValue); - if (dataValues.contains(this.dataValue)) { - messages.add( - DefaultEclipseLinkJpaValidationMessages.buildMessage( - IMessage.HIGH_SEVERITY, - EclipseLinkJpaValidationMessages.MULTIPLE_OBJECT_VALUES_FOR_DATA_VALUE, - new String[] {this.dataValue}, - this, - this.getDataValueTextRange() - ) - ); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConvert.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConvert.java deleted file mode 100644 index 4902e68680..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConvert.java +++ /dev/null @@ -1,273 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmConverter; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmConvert extends AbstractXmlContextNode implements Convert, OrmConverter -{ - protected String specifiedConverterName; - - protected XmlConvertibleMapping resourceMapping; - - protected EclipseLinkOrmConverter converter; - - public EclipseLinkOrmConvert(OrmAttributeMapping parent, XmlConvertibleMapping resourceMapping) { - super(parent); - this.initialize(resourceMapping); - } - - @Override - public OrmAttributeMapping getParent() { - return (OrmAttributeMapping) super.getParent(); - } - - public String getType() { - return Convert.ECLIPSE_LINK_CONVERTER; - } - - public void addToResourceModel() { - this.resourceMapping.setConvert(""); //$NON-NLS-1$ - } - - public void removeFromResourceModel() { - this.resourceMapping.setConvert(null); - } - - public TextRange getValidationTextRange() { - return this.resourceMapping.getConvertTextRange(); - } - - public String getConverterName() { - return getSpecifiedConverterName() == null ? getDefaultConverterName() : getSpecifiedConverterName(); - } - - public String getDefaultConverterName() { - return DEFAULT_CONVERTER_NAME; - } - - public String getSpecifiedConverterName() { - return this.specifiedConverterName; - } - - public void setSpecifiedConverterName(String newSpecifiedConverterName) { - String oldSpecifiedConverterName = this.specifiedConverterName; - this.specifiedConverterName = newSpecifiedConverterName; - this.resourceMapping.setConvert(newSpecifiedConverterName); - firePropertyChanged(SPECIFIED_CONVERTER_NAME_PROPERTY, oldSpecifiedConverterName, newSpecifiedConverterName); - } - - protected void setSpecifiedConverterName_(String newSpecifiedConverterName) { - String oldSpecifiedConverterName = this.specifiedConverterName; - this.specifiedConverterName = newSpecifiedConverterName; - firePropertyChanged(SPECIFIED_CONVERTER_NAME_PROPERTY, oldSpecifiedConverterName, newSpecifiedConverterName); - } - - public EclipseLinkOrmConverter getConverter() { - return this.converter; - } - - protected String getConverterType() { - if (this.converter == null) { - return EclipseLinkConverter.NO_CONVERTER; - } - return this.converter.getType(); - } - - public void setConverter(String converterType) { - if (getConverterType() == converterType) { - return; - } - EclipseLinkOrmConverter oldConverter = this.converter; - if (oldConverter != null) { - this.converter = null; //set to null now to avoid update triggering events - removeConverter(oldConverter.getType()); - } - JpaEObject resourceConverter = buildResourceConverter(converterType); - EclipseLinkOrmConverter newConverter = buildConverter(converterType, resourceConverter); - this.converter = newConverter; - if (newConverter != null) { - addConverter(converterType, resourceConverter); - } - firePropertyChanged(CONVERTER_PROPERTY, oldConverter, newConverter); - } - - //TODO yes, i know, many if/else type checks in the methods below. - //will look at factoring this out when I have time after M3! Also EclipseLinkJavaConvert - protected void removeConverter(String converterType) { - if (converterType == EclipseLinkConverter.CUSTOM_CONVERTER) { - this.resourceMapping.setConverter(null); - } - else if (converterType == EclipseLinkConverter.TYPE_CONVERTER) { - this.resourceMapping.setTypeConverter(null); - } - else if (converterType == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - this.resourceMapping.setObjectTypeConverter(null); - } - else if (converterType == EclipseLinkConverter.STRUCT_CONVERTER) { - this.resourceMapping.setStructConverter(null); - } - } - - protected JpaEObject buildResourceConverter(String converterType) { - if (converterType == EclipseLinkConverter.CUSTOM_CONVERTER) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlConverterImpl(); - } - else if (converterType == EclipseLinkConverter.TYPE_CONVERTER) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlTypeConverterImpl(); - } - else if (converterType == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlObjectTypeConverterImpl(); - } - else if (converterType == EclipseLinkConverter.STRUCT_CONVERTER) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlStructConverterImpl(); - } - return null; - } - - protected void addConverter(String converterType, JpaEObject resourceConverter) { - if (converterType == EclipseLinkConverter.CUSTOM_CONVERTER) { - this.resourceMapping.setConverter((XmlConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.TYPE_CONVERTER) { - this.resourceMapping.setTypeConverter((XmlTypeConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - this.resourceMapping.setObjectTypeConverter((XmlObjectTypeConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.STRUCT_CONVERTER) { - this.resourceMapping.setStructConverter((XmlStructConverter) resourceConverter); - } - } - - protected EclipseLinkOrmConverter<?> buildConverter(String converterType, JpaEObject resourceConverter) { - if (converterType == EclipseLinkConverter.NO_CONVERTER) { - return null; - } - if (converterType == EclipseLinkConverter.CUSTOM_CONVERTER) { - return buildCustomConverter((XmlConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.TYPE_CONVERTER) { - return buildTypeConverter((XmlTypeConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return buildObjectTypeConverter((XmlObjectTypeConverter) resourceConverter); - } - else if (converterType == EclipseLinkConverter.STRUCT_CONVERTER) { - return buildStructConverter((XmlStructConverter) resourceConverter); - } - return null; - } - - protected void setConverter(EclipseLinkOrmConverter<?> newConverter) { - EclipseLinkOrmConverter<?> oldConverter = this.converter; - this.converter = newConverter; - firePropertyChanged(CONVERTER_PROPERTY, oldConverter, newConverter); - } - - protected void initialize(XmlConvertibleMapping resourceMapping) { - this.resourceMapping = resourceMapping; - this.specifiedConverterName = this.getResourceConvert(); - this.converter = this.buildConverter(); - } - - public void update() { - this.setSpecifiedConverterName_(this.getResourceConvert()); - if (getResourceConverterType() == getConverterType()) { - this.converter.update(); - } - else { - setConverter(buildConverter()); - } - } - - protected String getResourceConvert() { - return this.resourceMapping == null ? null : this.resourceMapping.getConvert(); - } - - protected String getResourceConverterType() { - if (this.resourceMapping.getConverter() != null) { - return EclipseLinkConverter.CUSTOM_CONVERTER; - } - else if (this.resourceMapping.getTypeConverter() != null) { - return EclipseLinkConverter.TYPE_CONVERTER; - } - else if (this.resourceMapping.getObjectTypeConverter() != null) { - return EclipseLinkConverter.OBJECT_TYPE_CONVERTER; - } - else if (this.resourceMapping.getStructConverter() != null) { - return EclipseLinkConverter.STRUCT_CONVERTER; - } - - return null; - } - protected EclipseLinkOrmConverter<?> buildConverter() { - if (this.resourceMapping.getConverter() != null) { - return buildCustomConverter(this.resourceMapping.getConverter()); - } - else if (this.resourceMapping.getTypeConverter() != null) { - return buildTypeConverter(this.resourceMapping.getTypeConverter()); - } - else if (this.resourceMapping.getObjectTypeConverter() != null) { - return buildObjectTypeConverter(this.resourceMapping.getObjectTypeConverter()); - } - else if (this.resourceMapping.getStructConverter() != null) { - return buildStructConverter(this.resourceMapping.getStructConverter()); - } - - return null; - } - - protected EclipseLinkOrmCustomConverter buildCustomConverter(XmlConverter resourceConverter) { - EclipseLinkOrmCustomConverter contextConverter = new EclipseLinkOrmCustomConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmTypeConverter buildTypeConverter(XmlTypeConverter resourceConverter) { - EclipseLinkOrmTypeConverter contextConverter = new EclipseLinkOrmTypeConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmObjectTypeConverter buildObjectTypeConverter(XmlObjectTypeConverter resourceConverter) { - EclipseLinkOrmObjectTypeConverter contextConverter = new EclipseLinkOrmObjectTypeConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmStructConverter buildStructConverter(XmlStructConverter resourceConverter) { - EclipseLinkOrmStructConverter contextConverter = new EclipseLinkOrmStructConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - if (getConverter() != null) { - getConverter().validate(messages); - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverter.java deleted file mode 100644 index 4f26ef841f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverter.java +++ /dev/null @@ -1,103 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaConverter; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter; -import org.eclipse.jpt.utility.internal.StringTools; - -public abstract class EclipseLinkOrmConverter<T extends XmlNamedConverter> - extends AbstractXmlContextNode implements EclipseLinkConverter -{ - protected T resourceConverter; - - protected String name; - - - protected EclipseLinkOrmConverter(XmlContextNode parent) { - super(parent); - } - - @Override - public EclipseLinkPersistenceUnit getPersistenceUnit() { - return (EclipseLinkPersistenceUnit) super.getPersistenceUnit(); - } - - - protected T getXmlResource() { - return this.resourceConverter; - } - - // **************** name *************************************************** - - public String getName() { - return this.name; - } - - public void setName(String newName) { - String oldName = this.name; - this.name = newName; - this.resourceConverter.setName(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - protected void setName_(String newName) { - String oldName = this.name; - this.name = newName; - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - - // **************** resource interaction *********************************** - - protected void initialize(T resource) { - this.resourceConverter = resource; - this.name = getResourceName(); - getPersistenceUnit().addConverter(this); - } - - public void update() { - this.setName_(getResourceName()); - getPersistenceUnit().addConverter(this); - } - - protected String getResourceName() { - return this.resourceConverter.getName(); - } - - - // **************** validation ********************************************* - - public boolean overrides(EclipseLinkConverter converter) { - if (getName() == null) { - return false; - } - // this isn't ideal, but it will have to do until we have further adopter input - return this.getName().equals(converter.getName()) && converter instanceof EclipseLinkJavaConverter; - } - - public boolean duplicates(EclipseLinkConverter converter) { - return (this != converter) - && ! StringTools.stringIsEmpty(this.name) - && this.name.equals(converter.getName()) - && ! this.overrides(converter) - && ! converter.overrides(this); - } - - public TextRange getValidationTextRange() { - return this.resourceConverter.getValidationTextRange(); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverterHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverterHolder.java deleted file mode 100644 index f31c79a03e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmConverterHolder.java +++ /dev/null @@ -1,456 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.util.ListIterator; -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmConverterHolder extends AbstractXmlContextNode implements ConverterHolder -{ - private XmlConvertersHolder resourceConvertersHolder; - - protected final List<EclipseLinkOrmCustomConverter> customConverters; - protected final List<EclipseLinkOrmObjectTypeConverter> objectTypeConverters; - protected final List<EclipseLinkOrmStructConverter> structConverters; - protected final List<EclipseLinkOrmTypeConverter> typeConverters; - - public EclipseLinkOrmConverterHolder(XmlContextNode parent) { - super(parent); - this.customConverters = new ArrayList<EclipseLinkOrmCustomConverter>(); - this.objectTypeConverters = new ArrayList<EclipseLinkOrmObjectTypeConverter>(); - this.structConverters = new ArrayList<EclipseLinkOrmStructConverter>(); - this.typeConverters = new ArrayList<EclipseLinkOrmTypeConverter>(); - } - - public ListIterator<EclipseLinkOrmCustomConverter> customConverters() { - return this.customConverters.listIterator(); - } - - public int customConvertersSize() { - return this.customConverters.size(); - } - - public CustomConverter addCustomConverter(int index) { - XmlConverter resourceConverter = EclipseLinkOrmFactory.eINSTANCE.createXmlConverterImpl(); - EclipseLinkOrmCustomConverter contextConverter = this.buildCustomConverter(resourceConverter); - this.customConverters.add(index, contextConverter); - this.resourceConvertersHolder.getConverters().add(index, resourceConverter); - this.fireItemAdded(CUSTOM_CONVERTERS_LIST, index, contextConverter); - return contextConverter; - } - - protected void addCustomConverter(int index, EclipseLinkOrmCustomConverter converter) { - addItemToList(index, converter, this.customConverters, CUSTOM_CONVERTERS_LIST); - } - - protected void addCustomConverter(EclipseLinkOrmCustomConverter converter) { - this.addCustomConverter(this.customConverters.size(), converter); - } - - public void removeCustomConverter(int index) { - EclipseLinkOrmCustomConverter removedConverter = this.customConverters.remove(index); - this.resourceConvertersHolder.getConverters().remove(index); - fireItemRemoved(CUSTOM_CONVERTERS_LIST, index, removedConverter); - } - - public void removeCustomConverter(CustomConverter converter) { - this.removeCustomConverter(this.customConverters.indexOf(converter)); - } - - protected void removeConverter_(CustomConverter converter) { - removeItemFromList(converter, this.customConverters, CUSTOM_CONVERTERS_LIST); - } - - public void moveCustomConverter(int targetIndex, int sourceIndex) { - CollectionTools.move(this.customConverters, targetIndex, sourceIndex); - this.resourceConvertersHolder.getConverters().move(targetIndex, sourceIndex); - fireItemMoved(CUSTOM_CONVERTERS_LIST, targetIndex, sourceIndex); - } - - protected void moveCustomConverter_(int index, EclipseLinkOrmCustomConverter converter) { - moveItemInList(index, this.customConverters.indexOf(converter), this.customConverters, CUSTOM_CONVERTERS_LIST); - } - - public ListIterator<EclipseLinkOrmObjectTypeConverter> objectTypeConverters() { - return this.objectTypeConverters.listIterator(); - } - - public int objectTypeConvertersSize() { - return this.objectTypeConverters.size(); - } - - public ObjectTypeConverter addObjectTypeConverter(int index) { - XmlObjectTypeConverter resourceObjectTypeConverter = EclipseLinkOrmFactory.eINSTANCE.createXmlObjectTypeConverterImpl(); - EclipseLinkOrmObjectTypeConverter contextObjectTypeConverter = this.buildObjectTypeConverter(resourceObjectTypeConverter); - this.objectTypeConverters.add(index, contextObjectTypeConverter); - this.resourceConvertersHolder.getObjectTypeConverters().add(index, resourceObjectTypeConverter); - this.fireItemAdded(OBJECT_TYPE_CONVERTERS_LIST, index, contextObjectTypeConverter); - return contextObjectTypeConverter; - } - - protected void addObjectTypeConverter(int index, EclipseLinkOrmObjectTypeConverter converter) { - addItemToList(index, converter, this.objectTypeConverters, OBJECT_TYPE_CONVERTERS_LIST); - } - - protected void addObjectTypeConverter(EclipseLinkOrmObjectTypeConverter converter) { - this.addObjectTypeConverter(this.objectTypeConverters.size(), converter); - } - - public void removeObjectTypeConverter(int index) { - EclipseLinkOrmObjectTypeConverter removedObjectTypeConverter = this.objectTypeConverters.remove(index); - this.resourceConvertersHolder.getObjectTypeConverters().remove(index); - fireItemRemoved(OBJECT_TYPE_CONVERTERS_LIST, index, removedObjectTypeConverter); - } - - public void removeObjectTypeConverter(ObjectTypeConverter converter) { - this.removeObjectTypeConverter(this.objectTypeConverters.indexOf(converter)); - } - - protected void removeObjectTypeConverter_(ObjectTypeConverter converter) { - removeItemFromList(converter, this.objectTypeConverters, OBJECT_TYPE_CONVERTERS_LIST); - } - - public void moveObjectTypeConverter(int targetIndex, int sourceIndex) { - CollectionTools.move(this.objectTypeConverters, targetIndex, sourceIndex); - this.resourceConvertersHolder.getObjectTypeConverters().move(targetIndex, sourceIndex); - fireItemMoved(OBJECT_TYPE_CONVERTERS_LIST, targetIndex, sourceIndex); - } - - protected void moveObjectTypeConverter_(int index, EclipseLinkOrmObjectTypeConverter converter) { - moveItemInList(index, this.objectTypeConverters.indexOf(converter), this.objectTypeConverters, OBJECT_TYPE_CONVERTERS_LIST); - } - - public ListIterator<EclipseLinkOrmStructConverter> structConverters() { - return this.structConverters.listIterator(); - } - - public int structConvertersSize() { - return this.structConverters.size(); - } - - public StructConverter addStructConverter(int index) { - XmlStructConverter resourceStructConverter = EclipseLinkOrmFactory.eINSTANCE.createXmlStructConverterImpl(); - EclipseLinkOrmStructConverter contextStructConverter = this.buildStructConverter(resourceStructConverter); - this.structConverters.add(index, contextStructConverter); - this.resourceConvertersHolder.getStructConverters().add(index, resourceStructConverter); - this.fireItemAdded(STRUCT_CONVERTERS_LIST, index, contextStructConverter); - return contextStructConverter; - } - - protected void addStructConverter(int index, EclipseLinkOrmStructConverter converter) { - addItemToList(index, converter, this.structConverters, STRUCT_CONVERTERS_LIST); - } - - protected void addStructConverter(EclipseLinkOrmStructConverter converter) { - this.addStructConverter(this.structConverters.size(), converter); - } - - public void removeStructConverter(int index) { - EclipseLinkOrmStructConverter removedStructConverter = this.structConverters.remove(index); - this.resourceConvertersHolder.getStructConverters().remove(index); - fireItemRemoved(STRUCT_CONVERTERS_LIST, index, removedStructConverter); - } - - public void removeStructConverter(StructConverter converter) { - this.removeStructConverter(this.structConverters.indexOf(converter)); - } - - protected void removeStructConverter_(StructConverter converter) { - removeItemFromList(converter, this.structConverters, STRUCT_CONVERTERS_LIST); - } - - public void moveStructConverter(int targetIndex, int sourceIndex) { - CollectionTools.move(this.structConverters, targetIndex, sourceIndex); - this.resourceConvertersHolder.getStructConverters().move(targetIndex, sourceIndex); - fireItemMoved(STRUCT_CONVERTERS_LIST, targetIndex, sourceIndex); - } - - protected void moveStructConverter_(int index, EclipseLinkOrmStructConverter converter) { - moveItemInList(index, this.structConverters.indexOf(converter), this.structConverters, STRUCT_CONVERTERS_LIST); - } - - - public ListIterator<EclipseLinkOrmTypeConverter> typeConverters() { - return this.typeConverters.listIterator(); - } - - public int typeConvertersSize() { - return this.typeConverters.size(); - } - - public TypeConverter addTypeConverter(int index) { - XmlTypeConverter resourceTypeConverter = EclipseLinkOrmFactory.eINSTANCE.createXmlTypeConverterImpl(); - EclipseLinkOrmTypeConverter contextTypeConverter = this.buildTypeConverter(resourceTypeConverter); - this.typeConverters.add(index, contextTypeConverter); - this.resourceConvertersHolder.getTypeConverters().add(index, resourceTypeConverter); - this.fireItemAdded(TYPE_CONVERTERS_LIST, index, contextTypeConverter); - return contextTypeConverter; - } - - protected void addTypeConverter(int index, EclipseLinkOrmTypeConverter converter) { - addItemToList(index, converter, this.typeConverters, TYPE_CONVERTERS_LIST); - } - - protected void addTypeConverter(EclipseLinkOrmTypeConverter converter) { - this.addTypeConverter(this.typeConverters.size(), converter); - } - - public void removeTypeConverter(int index) { - EclipseLinkOrmTypeConverter removedTypeConverter = this.typeConverters.remove(index); - this.resourceConvertersHolder.getTypeConverters().remove(index); - fireItemRemoved(TYPE_CONVERTERS_LIST, index, removedTypeConverter); - } - - public void removeTypeConverter(TypeConverter converter) { - this.removeTypeConverter(this.typeConverters.indexOf(converter)); - } - - protected void removeTypeConverter_(TypeConverter converter) { - removeItemFromList(converter, this.typeConverters, TYPE_CONVERTERS_LIST); - } - - public void moveTypeConverter(int targetIndex, int sourceIndex) { - CollectionTools.move(this.typeConverters, targetIndex, sourceIndex); - this.resourceConvertersHolder.getTypeConverters().move(targetIndex, sourceIndex); - fireItemMoved(TYPE_CONVERTERS_LIST, targetIndex, sourceIndex); - } - - protected void moveTypeConverter_(int index, EclipseLinkOrmTypeConverter converter) { - moveItemInList(index, this.typeConverters.indexOf(converter), this.typeConverters, TYPE_CONVERTERS_LIST); - } - - - - public void initialize(XmlConvertersHolder resourceConvertersHolder) { - this.resourceConvertersHolder = resourceConvertersHolder; - this.initializeCustomConverters(); - this.initializeObjectTypeConverters(); - this.initializeStructConverters(); - this.initializeTypeConverters(); - } - - protected void initializeCustomConverters() { - for (XmlConverter resourceConverter : this.resourceConvertersHolder.getConverters()) { - this.customConverters.add(this.buildCustomConverter(resourceConverter)); - } - } - - protected void initializeObjectTypeConverters() { - for (XmlObjectTypeConverter resourceConverter : this.resourceConvertersHolder.getObjectTypeConverters()) { - this.objectTypeConverters.add(this.buildObjectTypeConverter(resourceConverter)); - } - } - - protected void initializeStructConverters() { - for (XmlStructConverter resourceConverter : this.resourceConvertersHolder.getStructConverters()) { - this.structConverters.add(this.buildStructConverter(resourceConverter)); - } - } - - protected void initializeTypeConverters() { - for (XmlTypeConverter resourceConverter : this.resourceConvertersHolder.getTypeConverters()) { - this.typeConverters.add(this.buildTypeConverter(resourceConverter)); - } - } - - protected EclipseLinkOrmCustomConverter buildCustomConverter(XmlConverter resourceConverter) { - EclipseLinkOrmCustomConverter contextConverter = new EclipseLinkOrmCustomConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmTypeConverter buildTypeConverter(XmlTypeConverter resourceConverter) { - EclipseLinkOrmTypeConverter contextConverter = new EclipseLinkOrmTypeConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmObjectTypeConverter buildObjectTypeConverter(XmlObjectTypeConverter resourceConverter) { - EclipseLinkOrmObjectTypeConverter contextConverter = new EclipseLinkOrmObjectTypeConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - protected EclipseLinkOrmStructConverter buildStructConverter(XmlStructConverter resourceConverter) { - EclipseLinkOrmStructConverter contextConverter = new EclipseLinkOrmStructConverter(this); - contextConverter.initialize(resourceConverter); - return contextConverter; - } - - public void update() { - this.updateCustomConverters(); - this.updateObjectTypeConverters(); - this.updateStructConverters(); - this.updateTypeConverters(); - } - - protected void updateCustomConverters() { - Collection<EclipseLinkOrmCustomConverter> contextConvertersToRemove = CollectionTools.collection(customConverters()); - Collection<EclipseLinkOrmCustomConverter> contextConvertersToUpdate = new ArrayList<EclipseLinkOrmCustomConverter>(); - int resourceIndex = 0; - - // make a copy of the XML conversion values (to prevent ConcurrentModificationException) - List<XmlConverter> xmlConverters = this.resourceConvertersHolder.getConverters(); - for (XmlConverter resourceConverter : xmlConverters.toArray(new XmlConverter[xmlConverters.size()])) { - boolean contextConverterFound = false; - for (EclipseLinkOrmCustomConverter contextConverter : contextConvertersToRemove) { - if (contextConverter.getXmlResource() == resourceConverter) { - moveCustomConverter_(resourceIndex, contextConverter); - contextConvertersToRemove.remove(contextConverter); - contextConvertersToUpdate.add(contextConverter); - contextConverterFound = true; - break; - } - } - if (!contextConverterFound) { - addCustomConverter(this.buildCustomConverter(resourceConverter)); - } - resourceIndex++; - } - for (EclipseLinkOrmCustomConverter contextConverter : contextConvertersToRemove) { - removeConverter_(contextConverter); - } - //first handle adding/removing of the converters, then update the others last, - //this causes less churn in the update process - for (EclipseLinkOrmCustomConverter contextConverter : contextConvertersToUpdate) { - contextConverter.update(); - } - } - - protected void updateObjectTypeConverters() { - Collection<EclipseLinkOrmObjectTypeConverter> contextConvertersToRemove = CollectionTools.collection(objectTypeConverters()); - Collection<EclipseLinkOrmObjectTypeConverter> contextConvertersToUpdate = new ArrayList<EclipseLinkOrmObjectTypeConverter>(); - int resourceIndex = 0; - - // make a copy of the XML converters (to prevent ConcurrentModificationException) - List<XmlObjectTypeConverter> xmlConverters = this.resourceConvertersHolder.getObjectTypeConverters(); - for (XmlObjectTypeConverter xmlConverter : xmlConverters.toArray(new XmlObjectTypeConverter[xmlConverters.size()])) { - boolean contextConverterFound = false; - for (EclipseLinkOrmObjectTypeConverter contextObjectTypeConverter : contextConvertersToRemove) { - if (contextObjectTypeConverter.getXmlResource() == xmlConverter) { - moveObjectTypeConverter_(resourceIndex, contextObjectTypeConverter); - contextConvertersToRemove.remove(contextObjectTypeConverter); - contextConvertersToUpdate.add(contextObjectTypeConverter); - contextConverterFound = true; - break; - } - } - if (!contextConverterFound) { - addObjectTypeConverter(this.buildObjectTypeConverter(xmlConverter)); - } - resourceIndex++; - } - for (EclipseLinkOrmObjectTypeConverter contextObjectTypeConverter : contextConvertersToRemove) { - removeObjectTypeConverter_(contextObjectTypeConverter); - } - //first handle adding/removing of the converters, then update the others last, - //this causes less churn in the update process - for (EclipseLinkOrmObjectTypeConverter contextObjectTypeConverter : contextConvertersToUpdate) { - contextObjectTypeConverter.update(); - } - } - - protected void updateTypeConverters() { - Collection<EclipseLinkOrmTypeConverter> contextConvertersToRemove = CollectionTools.collection(typeConverters()); - Collection<EclipseLinkOrmTypeConverter> contextConvertersToUpdate = new ArrayList<EclipseLinkOrmTypeConverter>(); - int resourceIndex = 0; - - List<XmlTypeConverter> xmlConverters = this.resourceConvertersHolder.getTypeConverters(); - for (XmlTypeConverter xmlConverter : xmlConverters.toArray(new XmlTypeConverter[xmlConverters.size()])) { - boolean contextTypeConverterFound = false; - for (EclipseLinkOrmTypeConverter contextTypeConverter : contextConvertersToRemove) { - if (contextTypeConverter.getXmlResource() == xmlConverter) { - moveTypeConverter_(resourceIndex, contextTypeConverter); - contextConvertersToRemove.remove(contextTypeConverter); - contextConvertersToUpdate.add(contextTypeConverter); - contextTypeConverterFound = true; - break; - } - } - if (!contextTypeConverterFound) { - addTypeConverter(this.buildTypeConverter(xmlConverter)); - } - resourceIndex++; - } - for (EclipseLinkOrmTypeConverter contextTypeConverter : contextConvertersToRemove) { - removeTypeConverter_(contextTypeConverter); - } - //first handle adding/removing of the converters, then update the others last, - //this causes less churn in the update process - for (EclipseLinkOrmTypeConverter contextTypeConverter : contextConvertersToUpdate) { - contextTypeConverter.update(); - } - } - - protected void updateStructConverters() { - Collection<EclipseLinkOrmStructConverter> contextConvertersToRemove = CollectionTools.collection(structConverters()); - Collection<EclipseLinkOrmStructConverter> contextConvertersToUpdate = new ArrayList<EclipseLinkOrmStructConverter>(); - int resourceIndex = 0; - - // make a copy of the XML converters (to prevent ConcurrentModificationException) - List<XmlStructConverter> xmlConverters = this.resourceConvertersHolder.getStructConverters(); - for (XmlStructConverter resourceStructConverter : xmlConverters.toArray(new XmlStructConverter[xmlConverters.size()])) { - boolean contextStructConverterFound = false; - for (EclipseLinkOrmStructConverter contextStructConverter : contextConvertersToRemove) { - if (contextStructConverter.getXmlResource() == resourceStructConverter) { - moveStructConverter_(resourceIndex, contextStructConverter); - contextConvertersToRemove.remove(contextStructConverter); - contextConvertersToUpdate.add(contextStructConverter); - contextStructConverterFound = true; - break; - } - } - if (!contextStructConverterFound) { - addStructConverter(this.buildStructConverter(resourceStructConverter)); - } - resourceIndex++; - } - for (EclipseLinkOrmStructConverter contextStructConverter : contextConvertersToRemove) { - removeStructConverter_(contextStructConverter); - } - //first handle adding/removing of the converters, then update the others last, - //this causes less churn in the update process - for (EclipseLinkOrmStructConverter contextStructConverter : contextConvertersToUpdate) { - contextStructConverter.update(); - } - } - - //************ validation *************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - } - - - public TextRange getValidationTextRange() { - return this.resourceConvertersHolder.getValidationTextRange(); - } - - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomConverter.java deleted file mode 100644 index 0f1e895bc4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomConverter.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmCustomConverter extends EclipseLinkOrmConverter<XmlConverter> - implements CustomConverter -{ - private String converterClass; - - - public EclipseLinkOrmCustomConverter(XmlContextNode parent) { - super(parent); - } - - - public String getType() { - return EclipseLinkConverter.CUSTOM_CONVERTER; - } - - - // **************** converter class **************************************** - - public String getConverterClass() { - return this.converterClass; - } - - public void setConverterClass(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - this.resourceConverter.setClassName(newConverterClass); - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - protected void setConverterClass_(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(XmlConverter xmlResource) { - super.initialize(xmlResource); - this.converterClass = getResourceClassName(); - } - - @Override - public void update() { - super.update(); - setConverterClass_(getResourceClassName()); - } - - protected String getResourceClassName() { - return this.resourceConverter.getClassName(); - } - - - // **************** validation ********************************************* - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - validateConverterClass(messages); - } -//TODO validate converter class - protected void validateConverterClass(List<IMessage> messages) { -// if (!getResourceConverter().implementsConverter()) { -// messages.add( -// DefaultEclipseLinkJpaValidationMessages.buildMessage( -// IMessage.HIGH_SEVERITY, -// EclipseLinkJpaValidationMessages.CONVERTER_CLASS_IMPLEMENTS_CONVERTER, -// new String[] {this.converterClass}, -// this, -// getConverterClassTextRange() -// ) -// ); -// } - } - -// public TextRange getConverterClassTextRange() { -// return getResourceConverter().getClassNameTextRange(); -// } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomizer.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomizer.java deleted file mode 100644 index 207ce44950..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmCustomizer.java +++ /dev/null @@ -1,118 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder; - -public class EclipseLinkOrmCustomizer extends AbstractXmlContextNode - implements Customizer -{ - protected XmlCustomizerHolder resource; - - protected String specifiedCustomizerClass; - - protected String defaultCustomizerClass; - - public EclipseLinkOrmCustomizer(OrmTypeMapping parent) { - super(parent); - } - - public String getCustomizerClass() { - return this.specifiedCustomizerClass == null ? this.defaultCustomizerClass : this.specifiedCustomizerClass; - } - - public String getDefaultCustomizerClass() { - return this.defaultCustomizerClass; - } - - protected void setDefaultCustomizerClass(String newDefaultCustomizerClass) { - String oldDefaultCustomizerClass = this.defaultCustomizerClass; - this.defaultCustomizerClass = newDefaultCustomizerClass; - firePropertyChanged(DEFAULT_CUSTOMIZER_CLASS_PROPERTY, oldDefaultCustomizerClass, newDefaultCustomizerClass); - } - - public String getSpecifiedCustomizerClass() { - return this.specifiedCustomizerClass; - } - - public void setSpecifiedCustomizerClass(String newCustomizerClass) { - String oldCustomizerClass = this.specifiedCustomizerClass; - this.specifiedCustomizerClass = newCustomizerClass; - if (oldCustomizerClass != newCustomizerClass) { - if (this.getResourceCustomizer() != null) { - this.getResourceCustomizer().setCustomizerClassName(newCustomizerClass); - if (this.getResourceCustomizer().isAllFeaturesUnset()) { - removeResourceCustomizer(); - } - } - else if (newCustomizerClass != null) { - addResourceCustomizer(); - getResourceCustomizer().setCustomizerClassName(newCustomizerClass); - } - } - firePropertyChanged(SPECIFIED_CUSTOMIZER_CLASS_PROPERTY, oldCustomizerClass, newCustomizerClass); - } - - protected void setSpecifiedCustomizerClass_(String newCustomizerClass) { - String oldCustomizerClass = this.specifiedCustomizerClass; - this.specifiedCustomizerClass = newCustomizerClass; - firePropertyChanged(SPECIFIED_CUSTOMIZER_CLASS_PROPERTY, oldCustomizerClass, newCustomizerClass); - } - - protected XmlCustomizer getResourceCustomizer() { - return this.resource.getCustomizer(); - } - - protected void addResourceCustomizer() { - this.resource.setCustomizer(EclipseLinkOrmFactory.eINSTANCE.createXmlCustomizer()); - } - - protected void removeResourceCustomizer() { - this.resource.setCustomizer(null); - } - - // **************** initialize/update ************************************** - - protected void initialize(XmlCustomizerHolder resource, Customizer javaCustomizer) { - this.resource = resource; - this.defaultCustomizerClass = getJavaCustomizerClass(javaCustomizer); - this.specifiedCustomizerClass = getResourceCustomizerClass(); - } - - protected void update(Customizer javaCustomizer) { - setDefaultCustomizerClass(getJavaCustomizerClass(javaCustomizer)); - setSpecifiedCustomizerClass_(getResourceCustomizerClass()); - } - - protected String getJavaCustomizerClass(Customizer javaCustomizer) { - return (javaCustomizer == null) ? null : javaCustomizer.getCustomizerClass(); - } - - protected String getResourceCustomizerClass() { - XmlCustomizer resource = getResourceCustomizer(); - return (resource == null) ? null : resource.getCustomizerClassName(); - } - - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - XmlCustomizer resource = getResourceCustomizer(); - return resource == null ? null : resource.getCustomizerClassNameTextRange(); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddable.java deleted file mode 100644 index 22811ef27b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddable.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmEmbeddable; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkEmbeddable; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface EclipseLinkOrmEmbeddable extends EclipseLinkEmbeddable, OrmEmbeddable -{ - ConverterHolder getConverterHolder(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableImpl.java deleted file mode 100644 index bb25acf8ab..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableImpl.java +++ /dev/null @@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmEmbeddable; -import org.eclipse.jpt.core.resource.orm.XmlEmbeddable; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaEmbeddable; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmEmbeddableImpl extends GenericOrmEmbeddable - implements EclipseLinkOrmEmbeddable -{ - protected final EclipseLinkOrmCustomizer customizer; - - protected final EclipseLinkOrmChangeTracking changeTracking; - - protected final EclipseLinkOrmConverterHolder converterHolder; - - public EclipseLinkOrmEmbeddableImpl(OrmPersistentType parent) { - super(parent); - this.customizer = new EclipseLinkOrmCustomizer(this); - this.changeTracking = new EclipseLinkOrmChangeTracking(this); - this.converterHolder = new EclipseLinkOrmConverterHolder(this); - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - public ConverterHolder getConverterHolder() { - return this.converterHolder; - } - - - - // **************** resource-context interaction *************************** - - @Override - public XmlEmbeddable addToResourceModel(XmlEntityMappings entityMappings) { - XmlEmbeddable embeddable = EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddable(); - getPersistentType().initialize(embeddable); - entityMappings.getEmbeddables().add(embeddable); - return embeddable; - } - - @Override - public void initialize() { - super.initialize(); - this.customizer.initialize((XmlCustomizerHolder) this.resourceTypeMapping, getJavaCustomizer()); - this.changeTracking.initialize((XmlChangeTrackingHolder) this.resourceTypeMapping, getJavaChangeTracking()); - this.converterHolder.initialize((XmlConvertersHolder) this.resourceTypeMapping); - } - - @Override - public void update() { - super.update(); - this.customizer.update(getJavaCustomizer()); - this.changeTracking.update(getJavaChangeTracking()); - this.converterHolder.update(); - } - - @Override - protected EclipseLinkJavaEmbeddable getJavaEmbeddableForDefaults() { - return (EclipseLinkJavaEmbeddable) super.getJavaEmbeddableForDefaults(); - } - - - protected Customizer getJavaCustomizer() { - EclipseLinkJavaEmbeddable javaEmbeddable = getJavaEmbeddableForDefaults(); - return (javaEmbeddable == null) ? null : javaEmbeddable.getCustomizer(); - } - - protected ChangeTracking getJavaChangeTracking() { - EclipseLinkJavaEmbeddable javaEmbeddable = getJavaEmbeddableForDefaults(); - return (javaEmbeddable == null) ? null : javaEmbeddable.getChangeTracking(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - this.customizer.validate(messages); - this.changeTracking.validate(messages); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableProvider.java deleted file mode 100644 index 206f9ddd8a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddableProvider.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.orm.ExtendedOrmTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -/** - * EclipseLink ORM Embeddable provider - * Allow for EclipseLink extensions to Embeddable - */ -public class EclipseLinkOrmEmbeddableProvider - implements ExtendedOrmTypeMappingProvider -{ - - // singleton - private static final ExtendedOrmTypeMappingProvider INSTANCE = new EclipseLinkOrmEmbeddableProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmTypeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmEmbeddableProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public OrmTypeMapping buildMapping(OrmPersistentType parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmEmbeddable(parent); - } - - public String getKey() { - return MappingKeys.EMBEDDABLE_TYPE_MAPPING_KEY; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMapping.java deleted file mode 100644 index 66f756a830..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMapping.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmEmbeddedIdMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId; - -public class EclipseLinkOrmEmbeddedIdMapping extends GenericOrmEmbeddedIdMapping -{ - - public EclipseLinkOrmEmbeddedIdMapping(OrmPersistentAttribute parent) { - super(parent); - } - - // **************** resource-context interaction *************************** - - @Override - public XmlEmbeddedId addToResourceModel(XmlTypeMapping typeMapping) { - XmlEmbeddedId embeddedId = EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddedIdImpl(); - getPersistentAttribute().initialize(embeddedId); - typeMapping.getAttributes().getEmbeddedIds().add(embeddedId); - return embeddedId; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMappingProvider.java deleted file mode 100644 index cfbf9e534e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedIdMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaEmbeddedIdMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmEmbeddedIdMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmEmbeddedIdMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmEmbeddedIdMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.EMBEDDED_ID_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmEmbeddedIdMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlEmbeddedId(ormTypeMapping, (JavaEmbeddedIdMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMapping.java deleted file mode 100644 index fc53c9e34b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMapping.java +++ /dev/null @@ -1,35 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmEmbeddedMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded; - -public class EclipseLinkOrmEmbeddedMapping extends GenericOrmEmbeddedMapping -{ - - public EclipseLinkOrmEmbeddedMapping(OrmPersistentAttribute parent) { - super(parent); - } - - // **************** resource-context interaction *************************** - - @Override - public XmlEmbedded addToResourceModel(XmlTypeMapping typeMapping) { - XmlEmbedded embedded = EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddedImpl(); - getPersistentAttribute().initialize(embedded); - typeMapping.getAttributes().getEmbeddeds().add(embedded); - return embedded; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMappingProvider.java deleted file mode 100644 index d8821ba23a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEmbeddedMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaEmbeddedMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmEmbeddedMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmEmbeddedMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmEmbeddedMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.EMBEDDED_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmEmbeddedMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlEmbedded(ormTypeMapping, (JavaEmbeddedMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntity.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntity.java deleted file mode 100644 index 43fafde3e3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntity.java +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmEntity; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkEntity; - -public interface EclipseLinkOrmEntity extends EclipseLinkEntity, OrmEntity -{ - ConverterHolder getConverterHolder(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityImpl.java deleted file mode 100644 index 0567b1e511..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityImpl.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmEntity; -import org.eclipse.jpt.core.resource.orm.XmlEntity; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.eclipselink.core.context.Caching; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaEntity; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmEntityImpl extends GenericOrmEntity - implements EclipseLinkOrmEntity -{ - protected final EclipseLinkOrmReadOnly readOnly; - - protected final EclipseLinkOrmCustomizer customizer; - - protected final EclipseLinkOrmChangeTracking changeTracking; - - protected final EclipseLinkOrmCaching caching; - - protected final EclipseLinkOrmConverterHolder converterHolder; - - - public EclipseLinkOrmEntityImpl(OrmPersistentType parent) { - super(parent); - this.readOnly = new EclipseLinkOrmReadOnly(this); - this.customizer = new EclipseLinkOrmCustomizer(this); - this.changeTracking = new EclipseLinkOrmChangeTracking(this); - this.caching = new EclipseLinkOrmCaching(this); - this.converterHolder = new EclipseLinkOrmConverterHolder(this); - } - - public Caching getCaching() { - return this.caching; - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - public EclipseLinkOrmReadOnly getReadOnly() { - return this.readOnly; - } - - public ConverterHolder getConverterHolder() { - return this.converterHolder; - } - - // **************** resource-context interaction *************************** - - @Override - public XmlEntity addToResourceModel(XmlEntityMappings entityMappings) { - XmlEntity entity = EclipseLinkOrmFactory.eINSTANCE.createXmlEntity(); - getPersistentType().initialize(entity); - entityMappings.getEntities().add(entity); - return entity; - } - - @Override - public void initialize() { - super.initialize(); - this.readOnly.initialize((XmlReadOnly) this.resourceTypeMapping, getJavaReadOnly()); - this.customizer.initialize((XmlCustomizerHolder) this.resourceTypeMapping, getJavaCustomizer()); - this.changeTracking.initialize((XmlChangeTrackingHolder) this.resourceTypeMapping, getJavaChangeTracking()); - this.caching.initialize((XmlCacheHolder) this.resourceTypeMapping, getJavaCaching()); - this.converterHolder.initialize((XmlConvertersHolder) this.resourceTypeMapping); - } - - @Override - public void update() { - super.update(); - this.readOnly.update(getJavaReadOnly()); - this.customizer.update(getJavaCustomizer()); - this.changeTracking.update(getJavaChangeTracking()); - this.caching.update(getJavaCaching()); - this.converterHolder.update(); - } - - @Override - protected EclipseLinkJavaEntity getJavaEntityForDefaults() { - return (EclipseLinkJavaEntity) super.getJavaEntityForDefaults(); - } - - protected ReadOnly getJavaReadOnly() { - EclipseLinkJavaEntity javaEntity = getJavaEntityForDefaults(); - return (javaEntity == null) ? null : javaEntity.getReadOnly(); - } - - protected Customizer getJavaCustomizer() { - EclipseLinkJavaEntity javaEntity = getJavaEntityForDefaults(); - return (javaEntity == null) ? null : javaEntity.getCustomizer(); - } - - protected ChangeTracking getJavaChangeTracking() { - EclipseLinkJavaEntity javaEntity = getJavaEntityForDefaults(); - return (javaEntity == null) ? null : javaEntity.getChangeTracking(); - } - - protected JavaCaching getJavaCaching() { - EclipseLinkJavaEntity javaEntity = getJavaEntityForDefaults(); - return (javaEntity == null) ? null : javaEntity.getCaching(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - this.readOnly.validate(messages); - this.customizer.validate(messages); - this.changeTracking.validate(messages); - this.caching.validate(messages); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityProvider.java deleted file mode 100644 index 0d4e734227..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmEntityProvider.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.orm.ExtendedOrmTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -/** - * EclipseLink ORM Entity provider - * Allow for EclipseLink extensions to Entity - */ -public class EclipseLinkOrmEntityProvider - implements ExtendedOrmTypeMappingProvider -{ - // singleton - private static final ExtendedOrmTypeMappingProvider INSTANCE = new EclipseLinkOrmEntityProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmTypeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmEntityProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public OrmTypeMapping buildMapping(OrmPersistentType parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmEntity(parent); - } - - public String getKey() { - return MappingKeys.ENTITY_TYPE_MAPPING_KEY; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmExpiryTimeOfDay.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmExpiryTimeOfDay.java deleted file mode 100644 index d19d18195b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmExpiryTimeOfDay.java +++ /dev/null @@ -1,137 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ExpiryTimeOfDay; -import org.eclipse.jpt.eclipselink.core.context.orm.XmlCaching; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay; - -public class EclipseLinkOrmExpiryTimeOfDay extends AbstractXmlContextNode - implements ExpiryTimeOfDay -{ - - protected Integer hour; - protected Integer minute; - protected Integer second; - protected Integer millisecond; - - protected XmlTimeOfDay resourceTimeOfDay; - - public EclipseLinkOrmExpiryTimeOfDay(XmlCaching parent) { - super(parent); - } - - - public Integer getHour() { - return this.hour; - } - - public void setHour(Integer newHour) { - Integer oldHour = this.hour; - this.hour = newHour; - this.resourceTimeOfDay.setHour(newHour); - firePropertyChanged(HOUR_PROPERTY, oldHour, newHour); - } - - protected void setHour_(Integer newHour) { - Integer oldHour = this.hour; - this.hour = newHour; - firePropertyChanged(HOUR_PROPERTY, oldHour, newHour); - } - - public Integer getMinute() { - return this.minute; - } - - public void setMinute(Integer newMinute) { - Integer oldMinute = this.minute; - this.minute = newMinute; - this.resourceTimeOfDay.setMinute(newMinute); - firePropertyChanged(MINUTE_PROPERTY, oldMinute, newMinute); - } - - protected void setMinute_(Integer newMinute) { - Integer oldMinute = this.minute; - this.minute = newMinute; - firePropertyChanged(MINUTE_PROPERTY, oldMinute, newMinute); - } - - public Integer getSecond() { - return this.second; - } - - public void setSecond(Integer newSecond) { - Integer oldSecond = this.second; - this.second = newSecond; - this.resourceTimeOfDay.setSecond(newSecond); - firePropertyChanged(SECOND_PROPERTY, oldSecond, newSecond); - } - - protected void setSecond_(Integer newSecond) { - Integer oldSecond = this.second; - this.second = newSecond; - firePropertyChanged(SECOND_PROPERTY, oldSecond, newSecond); - } - - public Integer getMillisecond() { - return this.millisecond; - } - - public void setMillisecond(Integer newMillisecond) { - Integer oldMillisecond = this.millisecond; - this.millisecond = newMillisecond; - this.resourceTimeOfDay.setMillisecond(newMillisecond); - firePropertyChanged(MILLISECOND_PROPERTY, oldMillisecond, newMillisecond); - } - - protected void setMillisecond_(Integer newMillisecond) { - Integer oldMillisecond = this.millisecond; - this.millisecond = newMillisecond; - firePropertyChanged(MILLISECOND_PROPERTY, oldMillisecond, newMillisecond); - } - - public TextRange getValidationTextRange() { - return this.resourceTimeOfDay.getValidationTextRange(); - } - - public void initialize(XmlTimeOfDay resource) { - this.resourceTimeOfDay = resource; - this.hour = getResourceHour(); - this.minute = getResourceMinute(); - this.second = getResourceSecond(); - this.millisecond = getResourceMillisecond(); - } - - public void update(XmlTimeOfDay resource) { - this.resourceTimeOfDay = resource; - this.setHour_(getResourceHour()); - this.setMinute_(getResourceMinute()); - this.setSecond_(getResourceSecond()); - this.setMillisecond_(getResourceMillisecond()); - } - - protected Integer getResourceHour() { - return this.resourceTimeOfDay.getHour(); - } - - protected Integer getResourceMinute() { - return this.resourceTimeOfDay.getMinute(); - } - - protected Integer getResourceSecond() { - return this.resourceTimeOfDay.getSecond(); - } - - protected Integer getResourceMillisecond() { - return this.resourceTimeOfDay.getMillisecond(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMapping.java deleted file mode 100644 index 2d754e403d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMapping.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmConverter; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmIdMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkIdMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlId; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmIdMapping extends GenericOrmIdMapping - implements EclipseLinkIdMapping -{ - protected EclipseLinkOrmMutable mutable; - - - public EclipseLinkOrmIdMapping(OrmPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkOrmMutable(this); - } - - - public Mutable getMutable() { - return this.mutable; - } - - @Override - protected OrmConverter buildSpecifiedConverter(String converterType) { - OrmConverter ormConverter = super.buildSpecifiedConverter(converterType); - if (ormConverter != null) { - return ormConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkOrmConvert(this, (XmlId) this.resourceAttributeMapping); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (((XmlId) this.resourceAttributeMapping).getConvert() != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - // **************** resource-context interaction *************************** - - @Override - public XmlId addToResourceModel(XmlTypeMapping typeMapping) { - XmlId id = EclipseLinkOrmFactory.eINSTANCE.createXmlIdImpl(); - getPersistentAttribute().initialize(id); - typeMapping.getAttributes().getIds().add(id); - return id; - } - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize((XmlMutable) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.mutable.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - mutable validation - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMappingProvider.java deleted file mode 100644 index 24bab669cd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmIdMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaIdMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmIdMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmIdMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmIdMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.ID_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmIdMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlId(ormTypeMapping, (JavaIdMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmJoinFetch.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmJoinFetch.java deleted file mode 100644 index eea0d25bb4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmJoinFetch.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch; - -public class EclipseLinkOrmJoinFetch extends AbstractXmlContextNode - implements JoinFetch -{ - protected XmlJoinFetch resource; - - protected JoinFetchType joinFetchValue; - - - public EclipseLinkOrmJoinFetch(OrmAttributeMapping parent) { - super(parent); - } - - - public JoinFetchType getValue() { - return this.joinFetchValue; - } - - public void setValue(JoinFetchType newJoinFetchValue) { - JoinFetchType oldJoinFetchValue = this.joinFetchValue; - this.joinFetchValue = newJoinFetchValue; - this.resource.setJoinFetch(JoinFetchType.toOrmResourceModel(newJoinFetchValue)); - firePropertyChanged(VALUE_PROPERTY, oldJoinFetchValue, newJoinFetchValue); - } - - protected void setValue_(JoinFetchType newJoinFetchValue) { - JoinFetchType oldJoinFetchValue = this.joinFetchValue; - this.joinFetchValue = newJoinFetchValue; - firePropertyChanged(VALUE_PROPERTY, oldJoinFetchValue, newJoinFetchValue); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlJoinFetch xmlJoinFetch) { - this.resource = xmlJoinFetch; - this.joinFetchValue = getResourceJoinFetch(); - } - - protected void update() { - setValue_(getResourceJoinFetch()); - } - - protected JoinFetchType getResourceJoinFetch() { - return JoinFetchType.fromOrmResourceModel(this.resource.getJoinFetch()); - } - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - return this.resource.getJoinFetchTextRange(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMapping.java deleted file mode 100644 index c163b7129e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMapping.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmManyToManyMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkRelationshipMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmManyToManyMapping - extends GenericOrmManyToManyMapping - implements EclipseLinkRelationshipMapping -{ - protected EclipseLinkOrmJoinFetch joinFetch; - - - public EclipseLinkOrmManyToManyMapping(OrmPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkOrmJoinFetch(this); - } - - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlManyToMany addToResourceModel(XmlTypeMapping typeMapping) { - XmlManyToMany manyToMany = EclipseLinkOrmFactory.eINSTANCE.createXmlManyToManyImpl(); - getPersistentAttribute().initialize(manyToMany); - typeMapping.getAttributes().getManyToManys().add(manyToMany); - return manyToMany; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize((XmlJoinFetch) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.joinFetch.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - private owned, join fetch validation - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMappingProvider.java deleted file mode 100644 index 85f4175f7b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToManyMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaManyToManyMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmManyToManyMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmManyToManyMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmManyToManyMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.MANY_TO_MANY_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmManyToManyMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlManyToMany(ormTypeMapping, (JavaManyToManyMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMapping.java deleted file mode 100644 index b663577326..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMapping.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmManyToOneMapping; -import org.eclipse.jpt.core.resource.orm.XmlManyToOne; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkRelationshipMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmManyToOneMapping extends GenericOrmManyToOneMapping - implements EclipseLinkRelationshipMapping -{ - protected EclipseLinkOrmJoinFetch joinFetch; - - - public EclipseLinkOrmManyToOneMapping(OrmPersistentAttribute parent) { - super(parent); - this.joinFetch = new EclipseLinkOrmJoinFetch(this); - } - - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlManyToOne addToResourceModel(XmlTypeMapping typeMapping) { - XmlManyToOne manyToOne = EclipseLinkOrmFactory.eINSTANCE.createXmlManyToOneImpl(); - getPersistentAttribute().initialize(manyToOne); - typeMapping.getAttributes().getManyToOnes().add(manyToOne); - return manyToOne; - } - - @Override - protected void initialize() { - super.initialize(); - this.joinFetch.initialize((XmlJoinFetch) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.joinFetch.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - private owned, join fetch validation - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMappingProvider.java deleted file mode 100644 index f8ba6a5084..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmManyToOneMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaManyToOneMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmManyToOneMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmManyToOneMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmManyToOneMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.MANY_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmManyToOneMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlManyToOne(ormTypeMapping, (JavaManyToOneMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclass.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclass.java deleted file mode 100644 index 09950fc8e3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclass.java +++ /dev/null @@ -1,18 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmMappedSuperclass; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkMappedSuperclass; - -public interface EclipseLinkOrmMappedSuperclass extends EclipseLinkMappedSuperclass, OrmMappedSuperclass -{ - ConverterHolder getConverterHolder(); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassImpl.java deleted file mode 100644 index 509515706b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassImpl.java +++ /dev/null @@ -1,141 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmMappedSuperclass; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.core.resource.orm.XmlMappedSuperclass; -import org.eclipse.jpt.eclipselink.core.context.Caching; -import org.eclipse.jpt.eclipselink.core.context.ChangeTracking; -import org.eclipse.jpt.eclipselink.core.context.Customizer; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.context.java.EclipseLinkJavaMappedSuperclass; -import org.eclipse.jpt.eclipselink.core.context.java.JavaCaching; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmMappedSuperclassImpl extends GenericOrmMappedSuperclass - implements EclipseLinkOrmMappedSuperclass -{ - protected final EclipseLinkOrmReadOnly readOnly; - - protected final EclipseLinkOrmCustomizer customizer; - - protected final EclipseLinkOrmChangeTracking changeTracking; - - protected final EclipseLinkOrmCaching caching; - - protected final EclipseLinkOrmConverterHolder converterHolder; - - - public EclipseLinkOrmMappedSuperclassImpl(OrmPersistentType parent) { - super(parent); - this.readOnly = new EclipseLinkOrmReadOnly(this); - this.customizer = new EclipseLinkOrmCustomizer(this); - this.changeTracking = new EclipseLinkOrmChangeTracking(this); - this.caching = new EclipseLinkOrmCaching(this); - this.converterHolder = new EclipseLinkOrmConverterHolder(this); -} - - public Caching getCaching() { - return this.caching; - } - - public Customizer getCustomizer() { - return this.customizer; - } - - public ChangeTracking getChangeTracking() { - return this.changeTracking; - } - - public EclipseLinkOrmReadOnly getReadOnly() { - return this.readOnly; - } - - public ConverterHolder getConverterHolder() { - return this.converterHolder; - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlMappedSuperclass addToResourceModel(XmlEntityMappings entityMappings) { - XmlMappedSuperclass mappedSuperclass = EclipseLinkOrmFactory.eINSTANCE.createXmlMappedSuperclass(); - getPersistentType().initialize(mappedSuperclass); - entityMappings.getMappedSuperclasses().add(mappedSuperclass); - return mappedSuperclass; - } - - @Override - public void initialize() { - super.initialize(); - this.readOnly.initialize((XmlReadOnly) this.resourceTypeMapping, getJavaReadOnly()); - this.customizer.initialize((XmlCustomizerHolder) this.resourceTypeMapping, getJavaCustomizer()); - this.changeTracking.initialize((XmlChangeTrackingHolder) this.resourceTypeMapping, getJavaChangeTracking()); - this.caching.initialize((XmlCacheHolder) this.resourceTypeMapping, getJavaCaching()); - this.converterHolder.initialize((XmlConvertersHolder) this.resourceTypeMapping); - } - - @Override - public void update() { - super.update(); - this.readOnly.update(getJavaReadOnly()); - this.customizer.update(getJavaCustomizer()); - this.changeTracking.update(getJavaChangeTracking()); - this.caching.update(getJavaCaching()); - this.converterHolder.update(); - } - - @Override - protected EclipseLinkJavaMappedSuperclass getJavaMappedSuperclassForDefaults() { - return (EclipseLinkJavaMappedSuperclass) super.getJavaMappedSuperclassForDefaults(); - } - - protected ReadOnly getJavaReadOnly() { - EclipseLinkJavaMappedSuperclass javaMappedSuperclass = getJavaMappedSuperclassForDefaults(); - return (javaMappedSuperclass == null) ? null : javaMappedSuperclass.getReadOnly(); - } - - protected Customizer getJavaCustomizer() { - EclipseLinkJavaMappedSuperclass javaMappedSuperclass = getJavaMappedSuperclassForDefaults(); - return (javaMappedSuperclass == null) ? null : javaMappedSuperclass.getCustomizer(); - } - - protected ChangeTracking getJavaChangeTracking() { - EclipseLinkJavaMappedSuperclass javaMappedSuperclass = getJavaMappedSuperclassForDefaults(); - return (javaMappedSuperclass == null) ? null : javaMappedSuperclass.getChangeTracking(); - } - - protected JavaCaching getJavaCaching() { - EclipseLinkJavaMappedSuperclass javaMappedSuperclass = getJavaMappedSuperclassForDefaults(); - return (javaMappedSuperclass == null) ? null : javaMappedSuperclass.getCaching(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - this.readOnly.validate(messages); - this.customizer.validate(messages); - this.changeTracking.validate(messages); - this.caching.validate(messages); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassProvider.java deleted file mode 100644 index 6a03fcff5b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMappedSuperclassProvider.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.orm.ExtendedOrmTypeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentType; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -/** - * EclipseLink ORM Mapped Superclass provider - * Allow for EclipseLink extensions to Mapped Superclass - */ -public class EclipseLinkOrmMappedSuperclassProvider - implements ExtendedOrmTypeMappingProvider -{ - // singleton - private static final ExtendedOrmTypeMappingProvider INSTANCE = new EclipseLinkOrmMappedSuperclassProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmTypeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmMappedSuperclassProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public OrmTypeMapping buildMapping(OrmPersistentType parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmMappedSuperclass(parent); - } - - public String getKey() { - return MappingKeys.MAPPED_SUPERCLASS_TYPE_MAPPING_KEY; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMutable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMutable.java deleted file mode 100644 index 5230a852f8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmMutable.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.java.JavaPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable; - -public class EclipseLinkOrmMutable extends AbstractXmlContextNode - implements Mutable -{ - protected XmlMutable resource; - - protected boolean defaultMutable; - - protected Boolean specifiedMutable; - - - public EclipseLinkOrmMutable(OrmAttributeMapping parent) { - super(parent); - } - - @Override - public EclipseLinkPersistenceUnit getPersistenceUnit() { - return (EclipseLinkPersistenceUnit) super.getPersistenceUnit(); - } - - protected OrmAttributeMapping getAttributeMapping() { - return (OrmAttributeMapping) getParent(); - } - - public boolean isMutable() { - return (this.specifiedMutable != null) ? this.specifiedMutable.booleanValue() : this.defaultMutable; - } - - public boolean isDefaultMutable() { - return this.defaultMutable; - } - - protected void setDefaultMutable(boolean newDefaultMutable) { - boolean oldDefaultMutable = this.defaultMutable; - this.defaultMutable = newDefaultMutable; - firePropertyChanged(DEFAULT_MUTABLE_PROPERTY, oldDefaultMutable, newDefaultMutable); - } - - public Boolean getSpecifiedMutable() { - return this.specifiedMutable; - } - - public void setSpecifiedMutable(Boolean newSpecifiedMutable) { - Boolean oldSpecifiedMutable = this.specifiedMutable; - this.specifiedMutable = newSpecifiedMutable; - this.resource.setMutable(newSpecifiedMutable); - firePropertyChanged(SPECIFIED_MUTABLE_PROPERTY, oldSpecifiedMutable, newSpecifiedMutable); - } - - protected void setSpecifiedMutable_(Boolean newSpecifiedMutable) { - Boolean oldSpecifiedMutable = this.specifiedMutable; - this.specifiedMutable = newSpecifiedMutable; - firePropertyChanged(SPECIFIED_MUTABLE_PROPERTY, oldSpecifiedMutable, newSpecifiedMutable); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlMutable resource) { - this.resource = resource; - this.defaultMutable = this.calculateDefaultMutable(); - this.specifiedMutable = this.getResourceMutable(); - } - - protected void update() { - setDefaultMutable(this.calculateDefaultMutable()); - setSpecifiedMutable_(this.getResourceMutable()); - } - - protected Boolean getResourceMutable() { - return this.resource.getMutable(); - } - - protected boolean calculateDefaultMutable() { - JavaPersistentAttribute javaAttribute = getAttributeMapping().getPersistentAttribute().getJavaPersistentAttribute(); - if (javaAttribute == null) { - return false; - } - JavaResourcePersistentAttribute javaResourceAttribute = javaAttribute.getResourcePersistentAttribute(); - if (javaResourceAttribute.typeIsDateOrCalendar()) { - Boolean persistenceUnitDefaultMutable = getPersistenceUnit().getOptions().getTemporalMutable(); - return persistenceUnitDefaultMutable == null ? false : persistenceUnitDefaultMutable.booleanValue(); - } - return javaResourceAttribute.typeIsSerializable(); - } - - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - return this.resource.getMutableTextRange(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmObjectTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmObjectTypeConverter.java deleted file mode 100644 index 0791aea5c7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmObjectTypeConverter.java +++ /dev/null @@ -1,244 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.ListIterator; -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneIterator; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; -import org.eclipse.jpt.utility.internal.iterators.TransformationListIterator; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmObjectTypeConverter extends EclipseLinkOrmConverter<XmlObjectTypeConverter> - implements ObjectTypeConverter -{ - private String dataType; - - private String objectType; - - private final List<EclipseLinkOrmConversionValue> conversionValues; - - private String defaultObjectValue; - - - public EclipseLinkOrmObjectTypeConverter(XmlContextNode parent) { - super(parent); - this.conversionValues = new ArrayList<EclipseLinkOrmConversionValue>(); - } - - public String getType() { - return EclipseLinkConverter.OBJECT_TYPE_CONVERTER; - } - - // **************** data type ********************************************** - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - getXmlResource().setDataType(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - protected void setDataType_(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - - // **************** object type ******************************************** - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - getXmlResource().setObjectType(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - protected void setObjectType_(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - - // **************** conversion values ************************************** - - public ListIterator<EclipseLinkOrmConversionValue> conversionValues() { - return new CloneListIterator<EclipseLinkOrmConversionValue>(this.conversionValues); - } - - public int conversionValuesSize() { - return this.conversionValues.size(); - } - - public EclipseLinkOrmConversionValue addConversionValue(int index) { - XmlConversionValue resourceConversionValue = EclipseLinkOrmFactory.eINSTANCE.createXmlConversionValueImpl(); - EclipseLinkOrmConversionValue contextConversionValue = buildConversionValue(resourceConversionValue); - this.conversionValues.add(index, contextConversionValue); - getXmlResource().getConversionValues().add(index, resourceConversionValue); - fireItemAdded(CONVERSION_VALUES_LIST, index, contextConversionValue); - return contextConversionValue; - } - - public EclipseLinkOrmConversionValue addConversionValue() { - return this.addConversionValue(this.conversionValues.size()); - } - - protected void addConversionValue(int index, EclipseLinkOrmConversionValue conversionValue) { - addItemToList(index, conversionValue, this.conversionValues, CONVERSION_VALUES_LIST); - } - - protected void addConversionValue(EclipseLinkOrmConversionValue conversionValue) { - this.addConversionValue(this.conversionValues.size(), conversionValue); - } - - public void removeConversionValue(int index) { - EclipseLinkOrmConversionValue removedJoinColumn = this.conversionValues.remove(index); - getXmlResource().getConversionValues().remove(index); - fireItemRemoved(CONVERSION_VALUES_LIST, index, removedJoinColumn); - } - - public void removeConversionValue(ConversionValue conversionValue) { - this.removeConversionValue(this.conversionValues.indexOf(conversionValue)); - } - - protected void removeConversionValue_(ConversionValue conversionValue) { - removeItemFromList(conversionValue, this.conversionValues, CONVERSION_VALUES_LIST); - } - - public void moveConversionValue(int targetIndex, int sourceIndex) { - CollectionTools.move(this.conversionValues, targetIndex, sourceIndex); - getXmlResource().getConversionValues().move(targetIndex, sourceIndex); - fireItemMoved(CONVERSION_VALUES_LIST, targetIndex, sourceIndex); - } - - public ListIterator<String> dataValues() { - return new TransformationListIterator<EclipseLinkOrmConversionValue, String>(conversionValues()) { - @Override - protected String transform(EclipseLinkOrmConversionValue next) { - return next.getDataValue(); - } - }; - } - - - // **************** default object value *********************************** - - public String getDefaultObjectValue() { - return this.defaultObjectValue; - } - - public void setDefaultObjectValue(String newDefaultObjectValue) { - String oldDefaultObjectValue = this.defaultObjectValue; - this.defaultObjectValue = newDefaultObjectValue; - getXmlResource().setDefaultObjectValue(newDefaultObjectValue); - firePropertyChanged(DEFAULT_OBJECT_VALUE_PROPERTY, oldDefaultObjectValue, newDefaultObjectValue); - } - - protected void setDefaultObjectValue_(String newDefaultObjectValue) { - String oldDefaultObjectValue = this.defaultObjectValue; - this.defaultObjectValue = newDefaultObjectValue; - firePropertyChanged(DEFAULT_OBJECT_VALUE_PROPERTY, oldDefaultObjectValue, newDefaultObjectValue); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(XmlObjectTypeConverter xmlResource) { - super.initialize(xmlResource); - this.dataType = this.getResourceDataType(); - this.objectType = this.getResourceObjectType(); - this.defaultObjectValue = this.getResourceDefaultObjectValue(); - this.initializeConversionValues(); - } - - protected void initializeConversionValues() { - for (XmlConversionValue resourceConversionValue : getXmlResource().getConversionValues()) { - this.conversionValues.add(buildConversionValue(resourceConversionValue)); - } - } - - @Override - public void update() { - super.update(); - setDataType_(getResourceDataType()); - setObjectType_(getResourceObjectType()); - setDefaultObjectValue_(getResourceDefaultObjectValue()); - updateConversionValues(); - } - - protected void updateConversionValues( ) { - // make a copy of the XML conversion values (to prevent ConcurrentModificationException) - Iterator<XmlConversionValue> xmlConversionValues = new CloneIterator<XmlConversionValue>(this.getXmlResource().getConversionValues()); - - for (Iterator<EclipseLinkOrmConversionValue> contextConversionValues = this.conversionValues(); contextConversionValues.hasNext(); ) { - EclipseLinkOrmConversionValue contextConversionValue = contextConversionValues.next(); - if (xmlConversionValues.hasNext()) { - contextConversionValue.update(xmlConversionValues.next()); - } - else { - removeConversionValue_(contextConversionValue); - } - } - - while (xmlConversionValues.hasNext()) { - addConversionValue(buildConversionValue(xmlConversionValues.next())); - } - } - - protected EclipseLinkOrmConversionValue buildConversionValue(XmlConversionValue resourceConversionValue) { - EclipseLinkOrmConversionValue conversionValue = new EclipseLinkOrmConversionValue(this); - conversionValue.initialize(resourceConversionValue); - return conversionValue; - } - - protected String getResourceDataType() { - return this.resourceConverter.getDataType(); - } - - protected String getResourceObjectType() { - return this.resourceConverter.getObjectType(); - } - - protected String getResourceDefaultObjectValue() { - return this.resourceConverter.getDefaultObjectValue(); - } - - - // **************** validation ********************************************* - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - for (Iterator<EclipseLinkOrmConversionValue> stream = conversionValues(); stream.hasNext();) { - stream.next().validate(messages); - } - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMapping.java deleted file mode 100644 index 503e861793..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMapping.java +++ /dev/null @@ -1,90 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.AttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmOneToManyMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkOneToManyMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmOneToManyMapping extends GenericOrmOneToManyMapping - implements EclipseLinkOneToManyMapping -{ - protected EclipseLinkOrmPrivateOwned privateOwned; - - protected EclipseLinkOrmJoinFetch joinFetch; - - - public EclipseLinkOrmOneToManyMapping(OrmPersistentAttribute parent) { - super(parent); - this.privateOwned = new EclipseLinkOrmPrivateOwned(this); - this.joinFetch = new EclipseLinkOrmJoinFetch(this); - } - - // ********** NonOwningMapping implementation ********** - @Override - public boolean mappedByIsValid(AttributeMapping mappedByMapping) { - return super.mappedByIsValid(mappedByMapping) || (mappedByMapping.getKey() == MappingKeys.ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY); - } - - - public PrivateOwned getPrivateOwned() { - return this.privateOwned; - } - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlOneToMany addToResourceModel(XmlTypeMapping typeMapping) { - XmlOneToMany oneToMany = EclipseLinkOrmFactory.eINSTANCE.createXmlOneToManyImpl(); - getPersistentAttribute().initialize(oneToMany); - typeMapping.getAttributes().getOneToManys().add(oneToMany); - return oneToMany; - } - - @Override - protected void initialize() { - super.initialize(); - this.privateOwned.initialize((XmlPrivateOwned) this.resourceAttributeMapping); - this.joinFetch.initialize((XmlJoinFetch) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.privateOwned.update(); - this.joinFetch.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - private owned, join fetch validation - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMappingProvider.java deleted file mode 100644 index a3e6965e76..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToManyMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaOneToManyMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmOneToManyMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmOneToManyMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmOneToManyMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.ONE_TO_MANY_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmOneToManyMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlOneToMany(ormTypeMapping, (JavaOneToManyMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMapping.java deleted file mode 100644 index fddc228f78..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMapping.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmOneToOneMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmOneToOneMapping extends GenericOrmOneToOneMapping - implements EclipseLinkOneToOneMapping -{ - protected EclipseLinkOrmPrivateOwned privateOwned; - - protected EclipseLinkOrmJoinFetch joinFetch; - - - public EclipseLinkOrmOneToOneMapping(OrmPersistentAttribute parent) { - super(parent); - this.privateOwned = new EclipseLinkOrmPrivateOwned(this); - this.joinFetch = new EclipseLinkOrmJoinFetch(this); - } - - - public PrivateOwned getPrivateOwned() { - return this.privateOwned; - } - - public JoinFetch getJoinFetch() { - return this.joinFetch; - } - - - // **************** resource-context interaction *************************** - - @Override - public XmlOneToOne addToResourceModel(XmlTypeMapping typeMapping) { - XmlOneToOne oneToOne = EclipseLinkOrmFactory.eINSTANCE.createXmlOneToOneImpl(); - getPersistentAttribute().initialize(oneToOne); - typeMapping.getAttributes().getOneToOnes().add(oneToOne); - return oneToOne; - } - - @Override - protected void initialize() { - super.initialize(); - this.privateOwned.initialize((XmlPrivateOwned) this.resourceAttributeMapping); - this.joinFetch.initialize((XmlJoinFetch) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.privateOwned.update(); - this.joinFetch.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - private owned, join fetch validation - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMappingProvider.java deleted file mode 100644 index 58a652a4b7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmOneToOneMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaOneToOneMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmOneToOneMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmOneToOneMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmOneToOneMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmOneToOneMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlOneToOne(ormTypeMapping, (JavaOneToOneMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPersistentType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPersistentType.java deleted file mode 100644 index 1956b397f5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPersistentType.java +++ /dev/null @@ -1,27 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.internal.context.orm.AbstractOrmPersistentType; -import org.eclipse.jpt.core.resource.orm.Attributes; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; - -public class EclipseLinkOrmPersistentType extends AbstractOrmPersistentType -{ - - public EclipseLinkOrmPersistentType(EclipseLinkEntityMappings parent, String mappingKey) { - super(parent, mappingKey); - } - - @Override - protected Attributes createAttributesResource() { - return EclipseLinkOrmFactory.eINSTANCE.createAttributes(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPrivateOwned.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPrivateOwned.java deleted file mode 100644 index 82ba1321bf..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmPrivateOwned.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.PrivateOwned; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned; - -public class EclipseLinkOrmPrivateOwned extends AbstractXmlContextNode - implements PrivateOwned -{ - protected XmlPrivateOwned resource; - - protected boolean privateOwned; - - - public EclipseLinkOrmPrivateOwned(OrmAttributeMapping parent) { - super(parent); - } - - - public boolean isPrivateOwned() { - return this.privateOwned; - } - - public void setPrivateOwned(boolean newPrivateOwned) { - boolean oldPrivateOwned = this.privateOwned; - this.privateOwned = newPrivateOwned; - this.resource.setPrivateOwned(newPrivateOwned); - firePropertyChanged(PRIVATE_OWNED_PROPERTY, oldPrivateOwned, newPrivateOwned); - } - - protected void setPrivateOwned_(boolean newPrivateOwned) { - boolean oldPrivateOwned = this.privateOwned; - this.privateOwned = newPrivateOwned; - firePropertyChanged(PRIVATE_OWNED_PROPERTY, oldPrivateOwned, newPrivateOwned); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlPrivateOwned xmlPrivateOwned) { - this.resource = xmlPrivateOwned; - this.privateOwned = this.getResourcePrivateOwned(); - } - - protected void update() { - setPrivateOwned_(this.getResourcePrivateOwned()); - } - - protected boolean getResourcePrivateOwned() { - return this.resource.isPrivateOwned(); - } - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - return this.resource.getPrivateOwnedTextRange(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmReadOnly.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmReadOnly.java deleted file mode 100644 index b21277a288..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmReadOnly.java +++ /dev/null @@ -1,86 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.AbstractXmlContextNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ReadOnly; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly; - -public class EclipseLinkOrmReadOnly extends AbstractXmlContextNode - implements ReadOnly -{ - protected XmlReadOnly resource; - - protected boolean defaultReadOnly; - - protected Boolean specifiedReadOnly; - - - public EclipseLinkOrmReadOnly(OrmTypeMapping parent) { - super(parent); - } - - - public boolean isReadOnly() { - return (this.specifiedReadOnly == null) ? this.defaultReadOnly : this.specifiedReadOnly.booleanValue(); - } - - public boolean isDefaultReadOnly() { - return this.defaultReadOnly; - } - - public void setDefaultReadOnly(boolean newValue) { - boolean oldValue = this.defaultReadOnly; - this.defaultReadOnly = newValue; - firePropertyChanged(DEFAULT_READ_ONLY_PROPERTY, oldValue, newValue); - } - - public Boolean getSpecifiedReadOnly() { - return this.specifiedReadOnly; - } - - public void setSpecifiedReadOnly(Boolean newSpecifiedReadOnly) { - Boolean oldSpecifiedReadOnly = this.specifiedReadOnly; - this.specifiedReadOnly = newSpecifiedReadOnly; - this.resource.setReadOnly(newSpecifiedReadOnly); - firePropertyChanged(SPECIFIED_READ_ONLY_PROPERTY, oldSpecifiedReadOnly, newSpecifiedReadOnly); - } - - - // **************** initialize/update ************************************** - - protected void initialize(XmlReadOnly resource, ReadOnly javaReadOnly) { - this.resource = resource; - this.defaultReadOnly = this.getJavaReadOnly(javaReadOnly); - this.specifiedReadOnly = this.getResourceReadOnly(); - } - - protected void update(ReadOnly javaReadOnly) { - setDefaultReadOnly(this.getJavaReadOnly(javaReadOnly)); - setSpecifiedReadOnly(this.getResourceReadOnly()); - } - - protected boolean getJavaReadOnly(ReadOnly javaReadOnly) { - return (javaReadOnly == null) ? false : javaReadOnly.isReadOnly(); - } - - protected Boolean getResourceReadOnly() { - return this.resource.getReadOnly(); - } - - // **************** validation ************************************** - - public TextRange getValidationTextRange() { - return this.resource.getReadOnlyTextRange(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmStructConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmStructConverter.java deleted file mode 100644 index bbbc42622b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmStructConverter.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmStructConverter extends EclipseLinkOrmConverter<XmlStructConverter> - implements StructConverter -{ - private String converterClass; - - - public EclipseLinkOrmStructConverter(XmlContextNode parent) { - super(parent); - } - - public String getType() { - return EclipseLinkConverter.STRUCT_CONVERTER; - } - - - // **************** converter class **************************************** - - public String getConverterClass() { - return this.converterClass; - } - - public void setConverterClass(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - getXmlResource().setConverter(newConverterClass); - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - protected void setConverterClass_(String newConverterClass) { - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(XmlStructConverter xmlResource) { - super.initialize(xmlResource); - this.converterClass = getResourceConverterClass(); - } - - @Override - public void update() { - super.update(); - setConverterClass_(getResourceConverterClass()); - } - - protected String getResourceConverterClass() { - return this.resourceConverter.getConverter(); - } - - - // **************** validation ********************************************* - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - validateConverterClass(messages); - } - -//TODO validate converter class - protected void validateConverterClass(List<IMessage> messages) { -// if (!getResourceConverter().implementsConverter()) { -// messages.add( -// DefaultEclipseLinkJpaValidationMessages.buildMessage( -// IMessage.HIGH_SEVERITY, -// EclipseLinkJpaValidationMessages.CONVERTER_CLASS_IMPLEMENTS_CONVERTER, -// new String[] {this.converterClass}, -// this, -// getConverterClassTextRange() -// ) -// ); -// } - } - -// public TextRange getConverterClassTextRange() { -// return getResourceConverter().getClassNameTextRange(); -// } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmTypeConverter.java deleted file mode 100644 index 3ea6279bf7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmTypeConverter.java +++ /dev/null @@ -1,96 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.XmlContextNode; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; - -public class EclipseLinkOrmTypeConverter extends EclipseLinkOrmConverter<XmlTypeConverter> - implements TypeConverter -{ - private String dataType; - - private String objectType; - - - public EclipseLinkOrmTypeConverter(XmlContextNode parent) { - super(parent); - } - - public String getType() { - return EclipseLinkConverter.TYPE_CONVERTER; - } - - // **************** data type ********************************************** - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - getXmlResource().setDataType(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - protected void setDataType_(String newDataType) { - String oldDataType = this.dataType; - this.dataType = newDataType; - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - - // **************** object type ******************************************** - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - getXmlResource().setObjectType(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - protected void setObjectType_(String newObjectType) { - String oldObjectType = this.objectType; - this.objectType = newObjectType; - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - - // **************** resource interaction *********************************** - - @Override - protected void initialize(XmlTypeConverter xmlResource) { - super.initialize(xmlResource); - this.dataType = getResourceDataType(); - this.objectType = getResourceObjectType(); - } - - @Override - public void update() { - super.update(); - setDataType_(getResourceDataType()); - setObjectType_(getResourceObjectType()); - } - - protected String getResourceDataType() { - return this.resourceConverter.getDataType(); - } - - protected String getResourceObjectType() { - return this.resourceConverter.getObjectType(); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMapping.java deleted file mode 100644 index 2a1204322d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMapping.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import java.util.List; -import org.eclipse.jpt.core.context.orm.OrmConverter; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmVersionMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkVersionMapping; -import org.eclipse.jpt.eclipselink.core.context.Mutable; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion; -import org.eclipse.wst.validation.internal.provisional.core.IMessage; - -public class EclipseLinkOrmVersionMapping extends GenericOrmVersionMapping - implements EclipseLinkVersionMapping -{ - protected EclipseLinkOrmMutable mutable; - - - public EclipseLinkOrmVersionMapping(OrmPersistentAttribute parent) { - super(parent); - this.mutable = new EclipseLinkOrmMutable(this); - } - - - public Mutable getMutable() { - return this.mutable; - } - - @Override - protected OrmConverter buildSpecifiedConverter(String converterType) { - OrmConverter ormConverter = super.buildSpecifiedConverter(converterType); - if (ormConverter != null) { - return ormConverter; - } - if (converterType == Convert.ECLIPSE_LINK_CONVERTER) { - return new EclipseLinkOrmConvert(this, (XmlVersion) this.resourceAttributeMapping); - } - return null; - } - - @Override - protected String getResourceConverterType() { - //check @Convert first, this is the order that EclipseLink searches - if (((XmlVersion) this.resourceAttributeMapping).getConvert() != null) { - return Convert.ECLIPSE_LINK_CONVERTER; - } - return super.getResourceConverterType(); - } - - // **************** resource-context interaction *************************** - - @Override - public XmlVersion addToResourceModel(XmlTypeMapping typeMapping) { - XmlVersion version = EclipseLinkOrmFactory.eINSTANCE.createXmlVersionImpl(); - getPersistentAttribute().initialize(version); - typeMapping.getAttributes().getVersions().add(version); - return version; - } - - @Override - protected void initialize() { - super.initialize(); - this.mutable.initialize((XmlMutable) this.resourceAttributeMapping); - } - - @Override - public void update() { - super.update(); - this.mutable.update(); - } - - - // **************** validation ************************************** - - @Override - public void validate(List<IMessage> messages) { - super.validate(messages); - // TODO - mutable validation - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMappingProvider.java deleted file mode 100644 index 8bd7d16522..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmVersionMappingProvider.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.MappingKeys; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.java.JavaVersionMapping; -import org.eclipse.jpt.core.context.orm.ExtendedOrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmVersionMappingProvider - implements ExtendedOrmAttributeMappingProvider -{ - // singleton - private static final ExtendedOrmAttributeMappingProvider INSTANCE = new EclipseLinkOrmVersionMappingProvider(); - - /** - * Return the singleton. - */ - public static ExtendedOrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private EclipseLinkOrmVersionMappingProvider() { - super(); - } - - public String getOrmType() { - return EclipseLinkOrmXmlResource.TYPE; - } - - public String getKey() { - return MappingKeys.VERSION_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkOrmVersionMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildEclipseLinkVirtualXmlVersion(ormTypeMapping, (JavaVersionMapping) javaAttributeMapping); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmXml.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmXml.java deleted file mode 100644 index 81a4984892..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkOrmXml.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.EntityMappings; -import org.eclipse.jpt.core.context.persistence.MappingFileRef; -import org.eclipse.jpt.core.internal.context.orm.GenericOrmXml; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; - -public class EclipseLinkOrmXml extends GenericOrmXml -{ - public EclipseLinkOrmXml(MappingFileRef parent) { - super(parent); - } - - @Override - protected EclipseLinkJpaFactory getJpaFactory() { - return (EclipseLinkJpaFactory) super.getJpaFactory(); - } - - @Override - protected XmlEntityMappings buildEntityMappingsResource() { - return EclipseLinkOrmFactory.eINSTANCE.createXmlEntityMappings(); - } - - - @Override - protected EntityMappings buildEntityMappings(XmlEntityMappings xmlEntityMappings) { - return getJpaFactory().buildEclipseLinkEntityMappings(this, (org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings) xmlEntityMappings); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlBasic.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlBasic.java deleted file mode 100644 index c218bd7e4a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlBasic.java +++ /dev/null @@ -1,156 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaBasicMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlBasic; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkBasicMapping; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlBasic extends VirtualXmlBasic implements XmlBasic -{ - - public EclipseLinkVirtualXmlBasic(OrmTypeMapping ormTypeMapping, JavaBasicMapping javaBasicMapping) { - super(ormTypeMapping, javaBasicMapping); - } - - public Boolean getMutable() { - if (isOrmMetadataComplete()) { - return Boolean.valueOf(((EclipseLinkBasicMapping) this.javaAttributeMapping).getMutable().isDefaultMutable()); - } - return Boolean.valueOf(((EclipseLinkBasicMapping) this.javaAttributeMapping).getMutable().isMutable()); - } - - public void setMutable(@SuppressWarnings("unused") Boolean value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getConvert() { - if (isOrmMetadataComplete()) { - return null; - } - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - return ((Convert) this.javaAttributeMapping.getConverter()).getConverterName(); - } - return null; - } - - public void setConvert(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public TextRange getMutableTextRange() { - return null; - } - - public TextRange getConvertTextRange() { - return null; - } - - public XmlConverter getConverter() { - if (isOrmMetadataComplete()) { - return null; - } - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.CUSTOM_CONVERTER) { - return new EclipseLinkVirtualXmlConverter(this.ormTypeMapping, (CustomConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setConverter(@SuppressWarnings("unused") XmlConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlObjectTypeConverter getObjectTypeConverter() { - if (isOrmMetadataComplete()) { - return null; - } - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlObjectTypeConverter(this.ormTypeMapping, (ObjectTypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setObjectTypeConverter(@SuppressWarnings("unused") XmlObjectTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlStructConverter getStructConverter() { - if (isOrmMetadataComplete()) { - return null; - } - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.STRUCT_CONVERTER) { - return new EclipseLinkVirtualXmlStructConverter(this.ormTypeMapping, (StructConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setStructConverter(@SuppressWarnings("unused") XmlStructConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlTypeConverter getTypeConverter() { - if (isOrmMetadataComplete()) { - return null; - } - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlTypeConverter(this.ormTypeMapping, (TypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setTypeConverter(@SuppressWarnings("unused") XmlTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConversionValue.java deleted file mode 100644 index 38675d53fd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConversionValue.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlConversionValue extends AbstractJpaEObject implements XmlConversionValue -{ - protected OrmTypeMapping ormTypeMapping; - - protected ConversionValue javaConversionValue; - - public EclipseLinkVirtualXmlConversionValue(OrmTypeMapping ormTypeMapping, ConversionValue javaConversionValue) { - super(); - this.ormTypeMapping = ormTypeMapping; - this.javaConversionValue = javaConversionValue; - } - - protected boolean isOrmMetadataComplete() { - return this.ormTypeMapping.isMetadataComplete(); - } - - public String getDataValue() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConversionValue.getDataValue(); - } - - public void setDataValue(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getObjectValue() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConversionValue.getObjectValue(); - } - - public void setObjectValue(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public TextRange getDataValueTextRange() { - return null; - } - - public TextRange getObjectValueTextRange() { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConverter.java deleted file mode 100644 index d0a0f047af..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlConverter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlConverter extends AbstractJpaEObject implements XmlConverter -{ - protected OrmTypeMapping ormTypeMapping; - - protected CustomConverter javaConverter; - - public EclipseLinkVirtualXmlConverter(OrmTypeMapping ormTypeMapping, CustomConverter javaConverter) { - super(); - this.ormTypeMapping = ormTypeMapping; - this.javaConverter = javaConverter; - } - - protected boolean isOrmMetadataComplete() { - return this.ormTypeMapping.isMetadataComplete(); - } - - public String getClassName() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getConverterClass(); - } - - public void setClassName(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getName() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getName(); - } - - public void setName(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbedded.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbedded.java deleted file mode 100644 index 8ce8a65e2c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbedded.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaEmbeddedMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlEmbedded; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlEmbedded extends VirtualXmlEmbedded implements XmlEmbedded -{ - - public EclipseLinkVirtualXmlEmbedded(OrmTypeMapping ormTypeMapping, JavaEmbeddedMapping javaEmbeddedMapping) { - super(ormTypeMapping, javaEmbeddedMapping); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbeddedId.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbeddedId.java deleted file mode 100644 index dda40aacf9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlEmbeddedId.java +++ /dev/null @@ -1,43 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaEmbeddedIdMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlEmbeddedId; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlEmbeddedId extends VirtualXmlEmbeddedId implements XmlEmbeddedId -{ - - public EclipseLinkVirtualXmlEmbeddedId(OrmTypeMapping ormTypeMapping, JavaEmbeddedIdMapping javaEmbeddedIdMapping) { - super(ormTypeMapping, javaEmbeddedIdMapping); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlId.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlId.java deleted file mode 100644 index 2f7abd7564..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlId.java +++ /dev/null @@ -1,145 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaIdMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlId; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkIdMapping; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlId; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlId extends VirtualXmlId implements XmlId -{ - - public EclipseLinkVirtualXmlId(OrmTypeMapping ormTypeMapping, JavaIdMapping javaIdMapping) { - super(ormTypeMapping, javaIdMapping); - } - - public Boolean getMutable() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - return Boolean.valueOf(((EclipseLinkIdMapping) this.javaAttributeMapping).getMutable().isMutable()); - } - - public void setMutable(@SuppressWarnings("unused") Boolean value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getConvert() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - return ((Convert) this.javaAttributeMapping.getConverter()).getConverterName(); - } - return null; - } - - public void setConvert(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlConverter getConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.CUSTOM_CONVERTER) { - return new EclipseLinkVirtualXmlConverter(this.ormTypeMapping, (CustomConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setConverter(@SuppressWarnings("unused") XmlConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlObjectTypeConverter getObjectTypeConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlObjectTypeConverter(this.ormTypeMapping, (ObjectTypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setObjectTypeConverter(@SuppressWarnings("unused") XmlObjectTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlStructConverter getStructConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.STRUCT_CONVERTER) { - return new EclipseLinkVirtualXmlStructConverter(this.ormTypeMapping, (StructConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setStructConverter(@SuppressWarnings("unused") XmlStructConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlTypeConverter getTypeConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlTypeConverter(this.ormTypeMapping, (TypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setTypeConverter(@SuppressWarnings("unused") XmlTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - - public TextRange getMutableTextRange() { - return null; - } - - public TextRange getConvertTextRange() { - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToMany.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToMany.java deleted file mode 100644 index 59ea2fa260..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToMany.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaManyToManyMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlManyToMany; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaManyToManyMappingImpl; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlManyToMany extends VirtualXmlManyToMany implements XmlManyToMany -{ - - public EclipseLinkVirtualXmlManyToMany(OrmTypeMapping ormTypeMapping, JavaManyToManyMapping javaManyToManyMapping) { - super(ormTypeMapping, javaManyToManyMapping); - } - - public XmlJoinFetchType getJoinFetch() { - if (isOrmMetadataComplete()) { - return JoinFetchType.toOrmResourceModel(JoinFetch.DEFAULT_VALUE); - } - return JoinFetchType.toOrmResourceModel(((EclipseLinkJavaManyToManyMappingImpl) this.javaAttributeMapping).getJoinFetch().getValue()); - } - - public void setJoinFetch(@SuppressWarnings("unused") XmlJoinFetchType value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - - public TextRange getJoinFetchTextRange() { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToOne.java deleted file mode 100644 index db004888d2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlManyToOne.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaManyToOneMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlManyToOne; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaManyToOneMappingImpl; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlManyToOne extends VirtualXmlManyToOne implements XmlManyToOne -{ - - public EclipseLinkVirtualXmlManyToOne(OrmTypeMapping ormTypeMapping, JavaManyToOneMapping javaManyToOneMapping) { - super(ormTypeMapping, javaManyToOneMapping); - } - - public XmlJoinFetchType getJoinFetch() { - if (isOrmMetadataComplete()) { - return JoinFetchType.toOrmResourceModel(JoinFetch.DEFAULT_VALUE); - } - return JoinFetchType.toOrmResourceModel(((EclipseLinkJavaManyToOneMappingImpl) this.javaAttributeMapping).getJoinFetch().getValue()); - } - - public void setJoinFetch(@SuppressWarnings("unused") XmlJoinFetchType value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - - public TextRange getJoinFetchTextRange() { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlObjectTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlObjectTypeConverter.java deleted file mode 100644 index 902c4599c3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlObjectTypeConverter.java +++ /dev/null @@ -1,99 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.eclipselink.core.context.ConversionValue; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.utility.internal.CollectionTools; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlObjectTypeConverter extends AbstractJpaEObject implements XmlObjectTypeConverter -{ - protected OrmTypeMapping ormTypeMapping; - - protected ObjectTypeConverter javaConverter; - - public EclipseLinkVirtualXmlObjectTypeConverter(OrmTypeMapping ormTypeMapping, ObjectTypeConverter javaConverter) { - super(); - this.ormTypeMapping = ormTypeMapping; - this.javaConverter = javaConverter; - } - - protected boolean isOrmMetadataComplete() { - return this.ormTypeMapping.isMetadataComplete(); - } - - public String getName() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getName(); - } - - public void setName(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getDataType() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getDataType(); - } - - public void setDataType(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getObjectType() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getObjectType(); - } - - public void setObjectType(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getDefaultObjectValue() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getDefaultObjectValue(); - } - - public void setDefaultObjectValue(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlConversionValue> getConversionValues() { - EList<XmlConversionValue> conversionValues = new EObjectContainmentEList<XmlConversionValue>(XmlConversionValue.class, this, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER__CONVERSION_VALUES); - if (isOrmMetadataComplete()) { - return conversionValues; - } - for (ConversionValue javaConversionValue : CollectionTools.iterable(this.javaConverter.conversionValues())) { - XmlConversionValue xmlConversionValue = new EclipseLinkVirtualXmlConversionValue(this.ormTypeMapping, javaConversionValue); - conversionValues.add(xmlConversionValue); - } - return conversionValues; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToMany.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToMany.java deleted file mode 100644 index 61d543c861..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToMany.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaOneToManyMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlOneToMany; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToManyMappingImpl; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlOneToMany extends VirtualXmlOneToMany implements XmlOneToMany -{ - - public EclipseLinkVirtualXmlOneToMany(OrmTypeMapping ormTypeMapping, JavaOneToManyMapping javaOneToManyMapping) { - super(ormTypeMapping, javaOneToManyMapping); - } - - public XmlJoinFetchType getJoinFetch() { - if (isOrmMetadataComplete()) { - return JoinFetchType.toOrmResourceModel(JoinFetch.DEFAULT_VALUE); - } - return JoinFetchType.toOrmResourceModel(((EclipseLinkJavaOneToManyMappingImpl) this.javaAttributeMapping).getJoinFetch().getValue()); - } - - public void setJoinFetch(@SuppressWarnings("unused") XmlJoinFetchType value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public boolean isPrivateOwned() { - if (isOrmMetadataComplete()) { - return false; - } - return ((EclipseLinkJavaOneToManyMappingImpl) this.javaAttributeMapping).getPrivateOwned().isPrivateOwned(); - } - - public void setPrivateOwned(@SuppressWarnings("unused") boolean value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - - public TextRange getJoinFetchTextRange() { - return null; - } - - public TextRange getPrivateOwnedTextRange() { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToOne.java deleted file mode 100644 index ecae88bf41..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlOneToOne.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaOneToOneMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlOneToOne; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.JoinFetch; -import org.eclipse.jpt.eclipselink.core.context.JoinFetchType; -import org.eclipse.jpt.eclipselink.core.internal.context.java.EclipseLinkJavaOneToOneMappingImpl; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlOneToOne extends VirtualXmlOneToOne implements XmlOneToOne -{ - - public EclipseLinkVirtualXmlOneToOne(OrmTypeMapping ormTypeMapping, JavaOneToOneMapping javaOneToOneMapping) { - super(ormTypeMapping, javaOneToOneMapping); - } - - public XmlJoinFetchType getJoinFetch() { - if (isOrmMetadataComplete()) { - return JoinFetchType.toOrmResourceModel(JoinFetch.DEFAULT_VALUE); - } - return JoinFetchType.toOrmResourceModel(((EclipseLinkJavaOneToOneMappingImpl) this.javaAttributeMapping).getJoinFetch().getValue()); - } - - public void setJoinFetch(@SuppressWarnings("unused") XmlJoinFetchType value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public boolean isPrivateOwned() { - if (isOrmMetadataComplete()) { - return false; - } - return ((EclipseLinkJavaOneToOneMappingImpl) this.javaAttributeMapping).getPrivateOwned().isPrivateOwned(); - } - - public void setPrivateOwned(@SuppressWarnings("unused") boolean value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - - public TextRange getJoinFetchTextRange() { - return null; - } - - public TextRange getPrivateOwnedTextRange() { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlStructConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlStructConverter.java deleted file mode 100644 index 037bb746c1..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlStructConverter.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlStructConverter extends AbstractJpaEObject implements XmlStructConverter -{ - protected OrmTypeMapping ormTypeMapping; - - protected StructConverter javaConverter; - - public EclipseLinkVirtualXmlStructConverter(OrmTypeMapping ormTypeMapping, StructConverter javaConverter) { - super(); - this.ormTypeMapping = ormTypeMapping; - this.javaConverter = javaConverter; - } - - protected boolean isOrmMetadataComplete() { - return this.ormTypeMapping.isMetadataComplete(); - } - - public String getConverter() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getConverterClass(); - } - - public void setConverter(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getName() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getName(); - } - - public void setName(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlTypeConverter.java deleted file mode 100644 index f7ec01a1a9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlTypeConverter.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlTypeConverter extends AbstractJpaEObject implements XmlTypeConverter -{ - protected OrmTypeMapping ormTypeMapping; - - protected TypeConverter javaConverter; - - public EclipseLinkVirtualXmlTypeConverter(OrmTypeMapping ormTypeMapping, TypeConverter javaConverter) { - super(); - this.ormTypeMapping = ormTypeMapping; - this.javaConverter = javaConverter; - } - - protected boolean isOrmMetadataComplete() { - return this.ormTypeMapping.isMetadataComplete(); - } - - public String getName() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getName(); - } - - public void setName(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getDataType() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getDataType(); - } - - public void setDataType(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getObjectType() { - if (isOrmMetadataComplete()) { - return null; - } - return this.javaConverter.getObjectType(); - } - - public void setObjectType(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlVersion.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlVersion.java deleted file mode 100644 index 887bfceb19..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/EclipseLinkVirtualXmlVersion.java +++ /dev/null @@ -1,146 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.java.JavaVersionMapping; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlVersion; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.context.Convert; -import org.eclipse.jpt.eclipselink.core.context.CustomConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkVersionMapping; -import org.eclipse.jpt.eclipselink.core.context.ObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.context.StructConverter; -import org.eclipse.jpt.eclipselink.core.context.TypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class EclipseLinkVirtualXmlVersion extends VirtualXmlVersion implements XmlVersion -{ - - public EclipseLinkVirtualXmlVersion(OrmTypeMapping ormTypeMapping, JavaVersionMapping javaVersionMapping) { - super(ormTypeMapping, javaVersionMapping); - } - - public Boolean getMutable() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - return Boolean.valueOf(((EclipseLinkVersionMapping) this.javaAttributeMapping).getMutable().isMutable()); - } - - public void setMutable(@SuppressWarnings("unused") Boolean value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public String getConvert() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - return ((Convert) this.javaAttributeMapping.getConverter()).getConverterName(); - } - return null; - } - - public void setConvert(@SuppressWarnings("unused") String value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public TextRange getMutableTextRange() { - return null; - } - - public TextRange getConvertTextRange() { - return null; - } - - public XmlConverter getConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.CUSTOM_CONVERTER) { - return new EclipseLinkVirtualXmlConverter(this.ormTypeMapping, (CustomConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setConverter(@SuppressWarnings("unused") XmlConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlObjectTypeConverter getObjectTypeConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.OBJECT_TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlObjectTypeConverter(this.ormTypeMapping, (ObjectTypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setObjectTypeConverter(@SuppressWarnings("unused") XmlObjectTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlStructConverter getStructConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.STRUCT_CONVERTER) { - return new EclipseLinkVirtualXmlStructConverter(this.ormTypeMapping, (StructConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setStructConverter(@SuppressWarnings("unused") XmlStructConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public XmlTypeConverter getTypeConverter() { - //don't need isOrmMetadataComplete() check because there is no default Id mapping - if (this.javaAttributeMapping.getConverter().getType() == Convert.ECLIPSE_LINK_CONVERTER) { - EclipseLinkConverter converter = ((Convert) this.javaAttributeMapping.getConverter()).getConverter(); - if (converter != null && converter.getType() == EclipseLinkConverter.TYPE_CONVERTER) { - return new EclipseLinkVirtualXmlTypeConverter(this.ormTypeMapping, (TypeConverter) ((Convert) this.javaAttributeMapping.getConverter()).getConverter()); - } - } - return null; - } - - public void setTypeConverter(@SuppressWarnings("unused") XmlTypeConverter value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMapping.java deleted file mode 100644 index ca0ba50ab4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMapping.java +++ /dev/null @@ -1,51 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.AbstractOrmAttributeMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.BasicCollectionMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.Attributes; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection; - -public class OrmBasicCollectionMapping extends AbstractOrmAttributeMapping<XmlBasicCollection> implements BasicCollectionMapping -{ - - public OrmBasicCollectionMapping(OrmPersistentAttribute parent) { - super(parent); - } - - public void initializeOn(OrmAttributeMapping newMapping) { - newMapping.initializeFromOrmAttributeMapping(this); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY; - } - - public XmlBasicCollection addToResourceModel(XmlTypeMapping typeMapping) { - XmlBasicCollection basicCollection = EclipseLinkOrmFactory.eINSTANCE.createXmlBasicCollectionImpl(); - getPersistentAttribute().initialize(basicCollection); - ((Attributes) typeMapping.getAttributes()).getBasicCollections().add(basicCollection); - return basicCollection; - } - - public void removeFromResourceModel(XmlTypeMapping typeMapping) { - ((Attributes) typeMapping.getAttributes()).getBasicCollections().remove(this.resourceAttributeMapping); - } - - public int getXmlSequence() { - return 23; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMappingProvider.java deleted file mode 100644 index 69f3f638cb..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicCollectionMappingProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicCollectionMapping; - -public class OrmBasicCollectionMappingProvider - implements OrmAttributeMappingProvider -{ - - // singleton - private static final OrmBasicCollectionMappingProvider INSTANCE = new OrmBasicCollectionMappingProvider(); - - /** - * Return the singleton. - */ - public static OrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private OrmBasicCollectionMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildOrmBasicCollectionMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildVirtualXmlBasicCollection(ormTypeMapping, (JavaBasicCollectionMapping) javaAttributeMapping); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMapping.java deleted file mode 100644 index 4a953b6673..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMapping.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.AbstractOrmAttributeMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.BasicMapMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.Attributes; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap; - -public class OrmBasicMapMapping extends AbstractOrmAttributeMapping<XmlBasicMap> implements BasicMapMapping -{ - - public OrmBasicMapMapping(OrmPersistentAttribute parent) { - super(parent); - } - - public void initializeOn(OrmAttributeMapping newMapping) { - newMapping.initializeFromOrmAttributeMapping(this); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_MAP_ATTRIBUTE_MAPPING_KEY; - } - - public XmlBasicMap addToResourceModel(XmlTypeMapping typeMapping) { - XmlBasicMap basicMap = EclipseLinkOrmFactory.eINSTANCE.createXmlBasicMapImpl(); - getPersistentAttribute().initialize(basicMap); - ((Attributes) typeMapping.getAttributes()).getBasicMaps().add(basicMap); - return basicMap; - } - - public void removeFromResourceModel(XmlTypeMapping typeMapping) { - ((Attributes) typeMapping.getAttributes()).getBasicMaps().remove(this.resourceAttributeMapping); - } - - - public int getXmlSequence() { - return 27; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMappingProvider.java deleted file mode 100644 index 087f5c9cfc..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmBasicMapMappingProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicMapMapping; - -public class OrmBasicMapMappingProvider - implements OrmAttributeMappingProvider -{ - - // singleton - private static final OrmBasicMapMappingProvider INSTANCE = new OrmBasicMapMappingProvider(); - - /** - * Return the singleton. - */ - public static OrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private OrmBasicMapMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.BASIC_MAP_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildOrmBasicMapMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildVirtualXmlBasicMap(ormTypeMapping, (JavaBasicMapMapping) javaAttributeMapping); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMapping.java deleted file mode 100644 index 2f3719a29f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMapping.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.AbstractOrmAttributeMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.TransformationMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.Attributes; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation; - -public class OrmTransformationMapping extends AbstractOrmAttributeMapping<XmlTransformation> implements TransformationMapping -{ - - public OrmTransformationMapping(OrmPersistentAttribute parent) { - super(parent); - } - - public void initializeOn(OrmAttributeMapping newMapping) { - newMapping.initializeFromOrmAttributeMapping(this); - } - - public String getKey() { - return EclipseLinkMappingKeys.TRANSFORMATION_ATTRIBUTE_MAPPING_KEY; - } - - public XmlTransformation addToResourceModel(XmlTypeMapping typeMapping) { - XmlTransformation transformation = EclipseLinkOrmFactory.eINSTANCE.createXmlTransformationImpl(); - getPersistentAttribute().initialize(transformation); - ((Attributes) typeMapping.getAttributes()).getTransformations().add(transformation); - return transformation; - } - - public void removeFromResourceModel(XmlTypeMapping typeMapping) { - ((Attributes) typeMapping.getAttributes()).getTransformations().remove(this.resourceAttributeMapping); - } - - - public int getXmlSequence() { - return 85; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMappingProvider.java deleted file mode 100644 index f156c2ca37..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmTransformationMappingProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaTransformationMapping; - -public class OrmTransformationMappingProvider - implements OrmAttributeMappingProvider -{ - - // singleton - private static final OrmTransformationMappingProvider INSTANCE = new OrmTransformationMappingProvider(); - - /** - * Return the singleton. - */ - public static OrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private OrmTransformationMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.TRANSFORMATION_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildOrmTransformationMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildVirtualXmlTransformation(ormTypeMapping, (JavaTransformationMapping) javaAttributeMapping); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMapping.java deleted file mode 100644 index 760b6146a9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMapping.java +++ /dev/null @@ -1,51 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.internal.context.orm.AbstractOrmAttributeMapping; -import org.eclipse.jpt.core.resource.orm.XmlTypeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.context.VariableOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.Attributes; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne; - -public class OrmVariableOneToOneMapping extends AbstractOrmAttributeMapping<XmlVariableOneToOne> implements VariableOneToOneMapping -{ - - public OrmVariableOneToOneMapping(OrmPersistentAttribute parent) { - super(parent); - } - - public void initializeOn(OrmAttributeMapping newMapping) { - newMapping.initializeFromOrmAttributeMapping(this); - } - - public String getKey() { - return EclipseLinkMappingKeys.VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public XmlVariableOneToOne addToResourceModel(XmlTypeMapping typeMapping) { - XmlVariableOneToOne xmlVariableOneToOne = EclipseLinkOrmFactory.eINSTANCE.createXmlVariableOneToOneImpl(); - getPersistentAttribute().initialize(xmlVariableOneToOne); - ((Attributes) typeMapping.getAttributes()).getVariableOneToOnes().add(xmlVariableOneToOne); - return xmlVariableOneToOne; - } - - public void removeFromResourceModel(XmlTypeMapping typeMapping) { - ((Attributes) typeMapping.getAttributes()).getVariableOneToOnes().remove(this.resourceAttributeMapping); - } - - public int getXmlSequence() { - return 65; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMappingProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMappingProvider.java deleted file mode 100644 index 5c39fd04c6..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/OrmVariableOneToOneMappingProvider.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.jpt.core.JpaFactory; -import org.eclipse.jpt.core.context.java.JavaAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMapping; -import org.eclipse.jpt.core.context.orm.OrmAttributeMappingProvider; -import org.eclipse.jpt.core.context.orm.OrmPersistentAttribute; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaFactory; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaVariableOneToOneMapping; - -public class OrmVariableOneToOneMappingProvider - implements OrmAttributeMappingProvider -{ - - // singleton - private static final OrmVariableOneToOneMappingProvider INSTANCE = new OrmVariableOneToOneMappingProvider(); - - /** - * Return the singleton. - */ - public static OrmAttributeMappingProvider instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private OrmVariableOneToOneMappingProvider() { - super(); - } - - public String getKey() { - return EclipseLinkMappingKeys.VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } - - public OrmAttributeMapping buildMapping(OrmPersistentAttribute parent, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildOrmVariableOneToOneMapping(parent); - } - - public XmlAttributeMapping buildVirtualResourceMapping(OrmTypeMapping ormTypeMapping, JavaAttributeMapping javaAttributeMapping, JpaFactory factory) { - return ((EclipseLinkJpaFactory) factory).buildVirtualXmlVariableOneToOne(ormTypeMapping, (JavaVariableOneToOneMapping) javaAttributeMapping); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicCollection.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicCollection.java deleted file mode 100644 index b1b69457d5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicCollection.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicCollectionMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class VirtualXmlBasicCollection extends VirtualXmlAttributeMapping<JavaBasicCollectionMapping> implements XmlBasicCollection -{ - - public VirtualXmlBasicCollection(OrmTypeMapping ormTypeMapping, JavaBasicCollectionMapping javaBasicCollectionMapping) { - super(ormTypeMapping, javaBasicCollectionMapping); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicMap.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicMap.java deleted file mode 100644 index 657af71eef..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlBasicMap.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaBasicMapMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class VirtualXmlBasicMap extends VirtualXmlAttributeMapping<JavaBasicMapMapping> implements XmlBasicMap -{ - - public VirtualXmlBasicMap(OrmTypeMapping ormTypeMapping, JavaBasicMapMapping javaBasicMapMappingg) { - super(ormTypeMapping, javaBasicMapMappingg); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlTransformation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlTransformation.java deleted file mode 100644 index 3460a801b3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlTransformation.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaTransformationMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class VirtualXmlTransformation extends VirtualXmlAttributeMapping<JavaTransformationMapping> implements XmlTransformation -{ - - public VirtualXmlTransformation(OrmTypeMapping ormTypeMapping, JavaTransformationMapping javaTransformationMapping) { - super(ormTypeMapping, javaTransformationMapping); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlVariableOneToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlVariableOneToOne.java deleted file mode 100644 index 48487a9c5b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/orm/VirtualXmlVariableOneToOne.java +++ /dev/null @@ -1,45 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.context.orm.OrmTypeMapping; -import org.eclipse.jpt.core.internal.context.orm.VirtualXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.internal.context.java.JavaVariableOneToOneMapping; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne; - -/** - * VirtualBasic is an implementation of Basic used when there is - * no tag in the orm.xml and an underlying javaBasicMapping exists. - */ -public class VirtualXmlVariableOneToOne extends VirtualXmlAttributeMapping<JavaVariableOneToOneMapping> implements XmlVariableOneToOne -{ - - public VirtualXmlVariableOneToOne(OrmTypeMapping ormTypeMapping, JavaVariableOneToOneMapping javaVariableOneToOneMapping) { - super(ormTypeMapping, javaVariableOneToOneMapping); - } - - public XmlAccessMethods getAccessMethods() { - return null; - } - - public void setAccessMethods(XmlAccessMethods value) { - throw new UnsupportedOperationException("cannot set values on a virtual mapping"); //$NON-NLS-1$ - } - - - public EList<XmlProperty> getProperties() { - // TODO get from java annotations - return null; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkImpliedMappingFileRef.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkImpliedMappingFileRef.java deleted file mode 100644 index e47e8c4e81..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkImpliedMappingFileRef.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence; - -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.core.internal.context.persistence.GenericMappingFileRef; -import org.eclipse.jpt.eclipselink.core.internal.JptEclipseLinkCorePlugin; - -/** - * Currently, this class is only used for implied eclipselink mapping files - */ -public class EclipseLinkImpliedMappingFileRef - extends GenericMappingFileRef -{ - public EclipseLinkImpliedMappingFileRef(PersistenceUnit parent) { - super(parent, null); - } - - @Override - protected String buildFileName() { - return JptEclipseLinkCorePlugin.DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnit.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnit.java deleted file mode 100644 index 4baa879ed4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnit.java +++ /dev/null @@ -1,326 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence; - -import java.util.ArrayList; -import java.util.HashSet; -import java.util.Iterator; -import java.util.List; -import java.util.ListIterator; -import java.util.Set; -import org.eclipse.jpt.core.context.persistence.MappingFileRef; -import org.eclipse.jpt.core.context.persistence.Persistence; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.core.internal.context.persistence.AbstractPersistenceUnit; -import org.eclipse.jpt.core.resource.persistence.XmlPersistenceUnit; -import org.eclipse.jpt.eclipselink.core.context.EclipseLinkConverter; -import org.eclipse.jpt.eclipselink.core.internal.JptEclipseLinkCorePlugin; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching.Caching; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching.EclipseLinkCaching; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection.Connection; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection.EclipseLinkConnection; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization.Customization; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization.EclipseLinkCustomization; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.general.EclipseLinkGeneralProperties; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.general.GeneralProperties; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging.EclipseLinkLogging; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging.Logging; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.options.EclipseLinkOptions; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.options.Options; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation.EclipseLinkSchemaGeneration; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation.SchemaGeneration; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.EclipseLinkOrmXmlResourceProvider; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; -import org.eclipse.jpt.utility.internal.iterators.FilteringIterator; -import org.eclipse.jpt.utility.internal.iterators.ReadOnlyCompositeListIterator; -import org.eclipse.jpt.utility.internal.iterators.TransformationIterator; -import org.eclipse.jpt.utility.internal.model.value.ItemPropertyListValueModelAdapter; -import org.eclipse.jpt.utility.internal.model.value.ListAspectAdapter; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLink persistence unit - */ -public class EclipseLinkPersistenceUnit - extends AbstractPersistenceUnit -{ - protected MappingFileRef impliedEclipseLinkMappingFileRef; - - private GeneralProperties generalProperties; - private Connection connection; - private Customization customization; - private Caching caching; - private Logging logging; - private Options options; - private SchemaGeneration schemaGeneration; - - /* global converter definitions, defined elsewhere in model */ - protected final List<EclipseLinkConverter> converters = new ArrayList<EclipseLinkConverter>(); - - - public EclipseLinkPersistenceUnit(Persistence parent, XmlPersistenceUnit xmlPersistenceUnit) { - super(parent, xmlPersistenceUnit); - } - - @Override - protected void initializeProperties() { - super.initializeProperties(); - ListValueModel<Property> propertyListAdapter = this.buildPropertyListAdapter(); - - this.generalProperties = new EclipseLinkGeneralProperties(this, propertyListAdapter); - this.connection = new EclipseLinkConnection(this, propertyListAdapter); - this.customization = new EclipseLinkCustomization(this, propertyListAdapter); - this.caching = new EclipseLinkCaching(this, propertyListAdapter); - this.logging = new EclipseLinkLogging(this, propertyListAdapter); - this.options = new EclipseLinkOptions(this, propertyListAdapter); - this.schemaGeneration = new EclipseLinkSchemaGeneration(this, propertyListAdapter); - } - - private ListValueModel<Property> buildPropertyListAdapter() { - return new ItemPropertyListValueModelAdapter<Property>(this.buildPropertiesAdapter(), Property.VALUE_PROPERTY); - } - - private ListValueModel<Property> buildPropertiesAdapter() { - return new ListAspectAdapter<PersistenceUnit, Property>(PROPERTIES_LIST, this) { - @Override - protected ListIterator<Property> listIterator_() { - return this.subject.properties(); - } - @Override - protected int size_() { - return this.subject.propertiesSize(); - } - }; - } - - @Override - protected void addNonUpdateAspectNamesTo(Set<String> nonUpdateAspectNames) { - super.addNonUpdateAspectNamesTo(nonUpdateAspectNames); - nonUpdateAspectNames.add(CONVERTERS_LIST); - } - - - // **************** mapping file refs ************************************** - - @Override - public ListIterator<MappingFileRef> mappingFileRefs() { - if (impliedEclipseLinkMappingFileRef == null) { - return super.mappingFileRefs(); - } - return new ReadOnlyCompositeListIterator<MappingFileRef>( - super.mappingFileRefs(), impliedEclipseLinkMappingFileRef); - } - - @Override - public int mappingFileRefsSize() { - if (impliedEclipseLinkMappingFileRef == null) { - return super.mappingFileRefsSize(); - } - return 1 + super.mappingFileRefsSize(); - } - - - // **************** implied eclipselink mapping file ref ******************* - - /** - * String constant associated with changes to the implied eclipselink mapping file ref - */ - public final static String IMPLIED_ECLIPSELINK_MAPPING_FILE_REF_PROPERTY = "impliedEclipseLinkMappingFileRef"; //$NON-NLS-1$ - - - public MappingFileRef getImpliedEclipseLinkMappingFileRef() { - return impliedEclipseLinkMappingFileRef; - } - - protected MappingFileRef setImpliedEclipseLinkMappingFileRef() { - if (impliedEclipseLinkMappingFileRef != null) { - throw new IllegalStateException("The implied eclipselink mapping file ref is already set."); //$NON-NLS-1$ - } - MappingFileRef mappingFileRef = new EclipseLinkImpliedMappingFileRef(this); - impliedEclipseLinkMappingFileRef = mappingFileRef; - firePropertyChanged(IMPLIED_ECLIPSELINK_MAPPING_FILE_REF_PROPERTY, null, mappingFileRef); - return mappingFileRef; - } - - protected void unsetImpliedEclipseLinkMappingFileRef() { - if (impliedEclipseLinkMappingFileRef == null) { - throw new IllegalStateException("The implied eclipselink mapping file ref is already unset."); //$NON-NLS-1$ - } - MappingFileRef mappingFileRef = impliedEclipseLinkMappingFileRef; - impliedEclipseLinkMappingFileRef.dispose(); - impliedEclipseLinkMappingFileRef = null; - firePropertyChanged(IMPLIED_ECLIPSELINK_MAPPING_FILE_REF_PROPERTY, mappingFileRef, null); - } - - - // **************** properties ********************************************* - - public GeneralProperties getGeneralProperties() { - return this.generalProperties; - } - - public Connection getConnection() { - return this.connection; - } - - public Customization getCustomization() { - return this.customization; - } - - public Caching getCaching() { - return this.caching; - } - - public Logging getLogging() { - return this.logging; - } - - public Options getOptions() { - return this.options; - } - - public SchemaGeneration getSchemaGeneration() { - return this.schemaGeneration; - } - - - // **************** converters ********************************************* - - /** - * Identifier for changes to the list of global converter definitions. - * Note that there are no granular changes to this list. There is only - * notification that the entire list has changed. - */ - public static final String CONVERTERS_LIST = "converters"; //$NON-NLS-1$ - - /** - * Add the converter definition (defined elsewhere) to the list of converters - * defined within this persistence unit. - * Note that this should only be called during the process of updating the - * local converter definition. - * No change notification accompanies this action specifically. - */ - public void addConverter(EclipseLinkConverter converter) { - this.converters.add(converter); - } - - /** - * Return an iterator on all converters defined within this persistence unit, - * included duplicately named converters definitions. - */ - public ListIterator<EclipseLinkConverter> allConverters() { - return new CloneListIterator<EclipseLinkConverter>(this.converters); - } - - /** - * Return an array of the names of the converters defined in the persistence - * unit, with duplicates removed. - */ - public String[] uniqueConverterNames() { - HashSet<String> names = CollectionTools.set(this.allNonNullConverterNames()); - return names.toArray(new String[names.size()]); - } - - protected Iterator<String> allNonNullConverterNames() { - return new FilteringIterator<String, String>(this.allConverterNames()) { - @Override - protected boolean accept(String converterName) { - return converterName != null; - } - }; - } - - protected Iterator<String> allConverterNames() { - return new TransformationIterator<EclipseLinkConverter, String>(this.allConverters()) { - @Override - protected String transform(EclipseLinkConverter converter) { - return converter.getName(); - } - }; - } - - - // **************** updating *********************************************** - - @Override - public void update(XmlPersistenceUnit persistenceUnit) { - this.converters.clear(); - super.update(persistenceUnit); - convertersUpdated(); - } - - @Override - protected void initializeMappingFileRefs() { - super.initializeMappingFileRefs(); - - // use implied mapping file if - // a) properties does not exclude it - // b) it isn't otherwise specified - // c) the file actually exists - if (! impliedEclipseLinkMappingFileIsExcluded() - && ! impliedEclipseLinkMappingFileIsSpecified() - && impliedEclipseLinkMappingFileExists()) { - - impliedEclipseLinkMappingFileRef = new EclipseLinkImpliedMappingFileRef(this); - } - } - - @Override - protected void updateMappingFileRefs() { - super.updateMappingFileRefs(); - - // use implied mapping file if - // a) properties does not exclude it - // b) it isn't otherwise specified - // c) the file actually exists - if (! impliedEclipseLinkMappingFileIsExcluded() - && ! impliedEclipseLinkMappingFileIsSpecified() - && impliedEclipseLinkMappingFileExists()) { - - if (impliedEclipseLinkMappingFileRef == null) { - setImpliedEclipseLinkMappingFileRef(); - } - getImpliedEclipseLinkMappingFileRef().update(null); - } - else if (impliedEclipseLinkMappingFileRef != null) { - unsetImpliedEclipseLinkMappingFileRef(); - } - } - - protected boolean impliedEclipseLinkMappingFileIsExcluded() { - return getGeneralProperties().getExcludeEclipselinkOrm() == Boolean.TRUE; - } - - protected boolean impliedEclipseLinkMappingFileIsSpecified() { - String impliedMappingFile = JptEclipseLinkCorePlugin.DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH; - for (Iterator<MappingFileRef> stream = specifiedMappingFileRefs(); stream.hasNext(); ) { - if (impliedMappingFile.equals(stream.next().getFileName())) { - return true; - } - } - return false; - } - - protected boolean impliedEclipseLinkMappingFileExists() { - EclipseLinkOrmXmlResourceProvider modelProvider = - EclipseLinkOrmXmlResourceProvider.getDefaultXmlResourceProvider(getJpaProject().getProject()); - EclipseLinkOrmXmlResource resource = modelProvider.getXmlResource(); - return resource != null && resource.exists(); - } - - // This is called after the persistence unit has been updated to ensure - // we catch all added converters - protected void convertersUpdated() { - fireListChanged(CONVERTERS_LIST); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnitProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnitProperties.java deleted file mode 100644 index 567bfc888c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/EclipseLinkPersistenceUnitProperties.java +++ /dev/null @@ -1,424 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence; - -import java.util.HashMap; -import java.util.Map; -import java.util.Set; -import org.eclipse.jpt.core.JpaProject; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.utility.internal.ClassTools; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.model.AbstractModel; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkPersistenceUnitProperties - * - * Listens to the propertyListAdapter - */ -public abstract class EclipseLinkPersistenceUnitProperties extends AbstractModel - implements PersistenceUnitProperties -{ - private PersistenceUnit persistenceUnit; - - private PersistenceUnitPropertyListListener propertyListListener; - - // key = EclipseLink property key; value = property id - private Map<String, String> propertyNames; - - private static final long serialVersionUID = 1L; - - // ********** constructors / initialization ********** - protected EclipseLinkPersistenceUnitProperties( - PersistenceUnit parent, - ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(); - this.initialize(parent, propertyListAdapter); - } - - protected void initialize( - PersistenceUnit parent, - ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - this.persistenceUnit = parent; - - this.propertyListListener = new PersistenceUnitPropertyListListener(this); - propertyListAdapter.addListChangeListener(ListValueModel.LIST_VALUES, this.propertyListListener); - - this.initializePropertyNames(); - this.initializeProperties(); - } - - protected void initializePropertyNames() { - this.propertyNames = new HashMap<String, String>(); - this.addPropertyNames(this.propertyNames); - } - - /** - * Initializes properties with values from the persistence unit. - */ - protected abstract void initializeProperties(); - - // ********** behavior ********** - public PersistenceUnit getPersistenceUnit() { - return this.persistenceUnit; - } - - public JpaProject getJpaProject() { - return this.persistenceUnit.getJpaProject(); - } - - public PersistenceUnitPropertyListListener propertyListListener() { - return this.propertyListListener; - } - - private Map<String, String> propertyNames() { - return this.propertyNames; - } - - /** - * Adds property names key/value pairs, used by the methods: itemIsProperty - * and propertyIdFor. - * - * key = EclipseLink property key; value = property id - */ - protected abstract void addPropertyNames(Map<String, String> pNames); - - /** - * Method used for identifying the given property. - */ - public boolean itemIsProperty(PersistenceUnit.Property item) { - if (item == null) { - throw new NullPointerException(); - } - return this.propertyNames().keySet().contains(item.getName()); - } - - /** - * Returns the property name used for change notification of the given - * property. - */ - public String propertyIdFor(PersistenceUnit.Property property) { - String propertyId = this.propertyNames().get(property.getName()); - if (propertyId == null) { - throw new IllegalArgumentException("Illegal property: " + property); //$NON-NLS-1$ - } - return propertyId; - } - - protected String eclipseLinkKeyFor(String propertyId) { - for (String eclipseLinkKey : this.propertyNames().keySet()) { - if (this.propertyNames().get(eclipseLinkKey).equals(propertyId)) { - return eclipseLinkKey; - } - } - throw new IllegalArgumentException("Illegal property ID: " + propertyId); //$NON-NLS-1$ - } - - // ****** get/set String convenience methods ******* - /** - * Returns the String value of the given Property from the PersistenceXml. - */ - // TOREVIEW - handle incorrect String in persistence.xml - protected String getStringValue(String elKey) { - PersistenceUnit.Property p = this.getPersistenceUnit().getProperty(elKey); - return (p == null) ? null : p.getValue(); - } - - protected String getStringValue(String key, String keySuffix) { - return this.getStringValue((keySuffix == null) ? key : key + keySuffix); - } - - /** - * Put the given String value into the PersistenceXml. - * @param key - - * EclipseLink Key - * @param newValue - * value to be associated with the key - */ - protected void putStringValue(String key, String newValue) { - this.putStringValue(key, null, newValue, false); - } - - /** - * Put the given String value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putStringValue(String key, String newValue, boolean allowDuplicate) { - this.putStringValue(key, null, newValue, allowDuplicate); - } - - /** - * Put the given String value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param keySuffix - * e.g. entity name - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putStringValue(String key, String keySuffix, String newValue, boolean allowDuplicate) { - String elKey = (keySuffix == null) ? key : key + keySuffix; - this.getPersistenceUnit().setProperty(elKey, newValue, allowDuplicate); - } - - // ****** Integer convenience methods ******* - /** - * Returns the Integer value of the given Property from the PersistenceXml. - */ - // TOREVIEW - handle incorrect eclipseLinkValue String in - // persistence.xml - protected Integer getIntegerValue(String elKey) { - PersistenceUnit.Property p = this.getPersistenceUnit().getProperty(elKey); - return (p == null) ? null : getIntegerValueOf(p.getValue()); - } - - protected Integer getIntegerValue(String key, String keySuffix) { - return this.getIntegerValue((keySuffix == null) ? key : key + keySuffix); - } - - /** - * Put the given Integer value into the PersistenceXml. - * @param key - - * EclipseLink Key - * @param newValue - * value to be associated with the key - */ - protected void putIntegerValue(String key, Integer newValue) { - this.putIntegerValue(key, null, newValue, false); - } - - /** - * Put the given Integer value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putIntegerValue(String key, Integer newValue, boolean allowDuplicate) { - this.putIntegerValue(key, null, newValue, allowDuplicate); - } - - /** - * Put the given Integer value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param keySuffix - * e.g. entity name - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putIntegerValue(String key, String keySuffix, Integer newValue, boolean allowDuplicate) { - String elKey = (keySuffix == null) ? key : key + keySuffix; - String elValue = (newValue == null) ? null : newValue.toString(); - this.getPersistenceUnit().setProperty(elKey, elValue, allowDuplicate); - } - - // ****** Boolean convenience methods ******* - /** - * Returns the Boolean value of the given Property from the PersistenceXml. - */ - // TOREVIEW - handle incorrect eclipseLinkValue String in - // persistence.xml - protected Boolean getBooleanValue(String elKey) { - PersistenceUnit.Property p = this.getPersistenceUnit().getProperty(elKey); - return (p == null) ? null : getBooleanValueOf(p.getValue()); - } - - protected Boolean getBooleanValue(String key, String keySuffix) { - return this.getBooleanValue((keySuffix == null) ? key : key + keySuffix); - } - - /** - * Put the given Boolean value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param newValue - * value to be associated with the key - */ - protected void putBooleanValue(String key, Boolean newValue) { - this.putBooleanValue(key, null, newValue, false); - } - - /** - * Put the given Boolean value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putBooleanValue(String key, Boolean newValue, boolean allowDuplicate) { - this.putBooleanValue(key, null, newValue, allowDuplicate); - } - - /** - * Put the given Boolean value into the PersistenceXml. - * @param key - * EclipseLink Key - * @param keySuffix - * e.g. entity name - * @param newValue - * value to be associated with the key - * @param allowDuplicate - */ - protected void putBooleanValue(String key, String keySuffix, Boolean newValue, boolean allowDuplicate) { - String elKey = (keySuffix == null) ? key : key + keySuffix; - String elValue = (newValue == null) ? null : newValue.toString(); - this.getPersistenceUnit().setProperty(elKey, elValue, allowDuplicate); - } - - // ****** Enum convenience methods ******* - /** - * Returns the Enum value of the given Property from the PersistenceXml. - */ - // TOREVIEW - handle incorrect eclipseLinkValue String in persistence.xml - protected <T extends Enum<T>> T getEnumValue(String elKey, T[] enumValues) { - PersistenceUnit.Property p = this.getPersistenceUnit().getProperty(elKey); - return (p == null) ? null : getEnumValueOf(p.getValue(), enumValues); - } - - protected <T extends Enum<T>> T getEnumValue(String key, String keySuffix, T[] enumValues) { - return this.getEnumValue((keySuffix == null) ? key : key + keySuffix, enumValues); - } - - /** - * Put the given Enum value into the PersistenceXml. - * - * @param key - - * EclipseLink Key - */ - protected <T extends Enum<T>> void putEnumValue(String key, T newValue) { - this.putEnumValue(key, null, newValue, false); - } - - protected <T extends Enum<T>> void putEnumValue(String key, T newValue, boolean allowDuplicate) { - this.putEnumValue(key, null, newValue, allowDuplicate); - } - - protected <T extends Enum<T>> void putEnumValue(String key, String keySuffix, T newValue, boolean allowDuplicate) { - String elKey = (keySuffix == null) ? key : key + keySuffix; - this.getPersistenceUnit().setProperty(elKey, getEclipseLinkStringValueOf(newValue), allowDuplicate); - } - - // ******** Convenience methods ******** - /** - * Put into persistenceUnit properties. - * - * @param key - - * property name - * @param value - - * property value - */ - protected void putProperty(String key, Object value) { - putProperty(key, value, false); - } - - @SuppressWarnings("unchecked") - protected void putProperty(String key, Object value, boolean allowDuplicates) { - String elKey = this.eclipseLinkKeyFor(key); - if ((value != null) && value.getClass().isEnum()) { - this.putEnumValue(elKey, (Enum) value, allowDuplicates); - } else { - this.putEclipseLinkProperty(elKey, value, allowDuplicates); - } - } - - private void putEclipseLinkProperty(String key, Object value, boolean allowDuplicates) { - String string = (value == null) ? null : value.toString(); - this.getPersistenceUnit().setProperty(key, string, allowDuplicates); - } - - /** - * Removes a persistenceUnit property. - * - * @param key - - * property name - * @param value - - * property value - */ - protected void removeProperty(String key, String value) { - String elKey = this.eclipseLinkKeyFor(key); - - this.getPersistenceUnit().removeProperty(elKey, value); - } - - protected Set<PersistenceUnit.Property> getPropertiesSetWithPrefix(String keyPrefix) { - return CollectionTools.set(this.getPersistenceUnit().propertiesWithNamePrefix(keyPrefix)); - } - - /** - * Extracts the entityName of the specified property name. If the property name - * has no suffix, return an empty string. - */ - protected String getEntityName(PersistenceUnit.Property property) { - return getEntityName(property.getName()); - } - - /** - * Extracts the entityName of the specified string. If the string - * has no suffix, return an empty string. - */ - protected String getEntityName(String propertyName) { - int index = propertyName.lastIndexOf('.'); - if (index == -1) { - return ""; //$NON-NLS-1$ - } - return propertyName.substring(index + 1); - } - - // ****** Static methods ******* - /** - * Returns the EclipseLink string value for the given property value. - */ - public static String getEclipseLinkStringValueOf(Object value) { - if (value == null) { - return null; - } - if (value.getClass().isEnum()) { - return (String) ClassTools.staticFieldValue(value.getClass(), value.toString().toUpperCase()); - } - return value.toString(); - } - - /** - * Returns the enum constant of the specified enum type with the specified - * EclipseLink value string. - */ - public static <T extends Enum<T>> T getEnumValueOf(String elStringValue, T[] enumValues) { - for (T enumValue : enumValues) { - if (getEclipseLinkStringValueOf(enumValue).equals(elStringValue)) { - return enumValue; - } - } - return null; - } - - public static Boolean getBooleanValueOf(String elStringValue) { - if (elStringValue == null) { - return null; - } - return Boolean.valueOf(elStringValue); - } - - public static Integer getIntegerValueOf(String elStringValue) { - if (elStringValue == null) { - return null; - } - return Integer.valueOf(elStringValue); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitProperties.java deleted file mode 100644 index 91da757676..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitProperties.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2007, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence; - -import org.eclipse.jpt.core.JpaProject; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.utility.model.Model; -import org.eclipse.jpt.utility.model.listener.PropertyChangeListener; - -/** - * PersistenceUnitProperties - */ -public interface PersistenceUnitProperties extends Model, PropertyChangeListener -{ - /** - * Method used for identifying the given property. - */ - boolean itemIsProperty(PersistenceUnit.Property item); - - /** - * Returns the property name used for change notification of the given property. - */ - String propertyIdFor(PersistenceUnit.Property property); - - /** - * Return the PersistenceUnit of this Properties. - */ - PersistenceUnit getPersistenceUnit(); - - /** - * Return the JPA project the PersistenceUnit belongs to. - */ - JpaProject getJpaProject(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitPropertyListListener.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitPropertyListListener.java deleted file mode 100644 index d59816b5d1..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/PersistenceUnitPropertyListListener.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence; - -import java.util.Iterator; - -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.utility.model.Model; -import org.eclipse.jpt.utility.model.event.ListChangeEvent; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.listener.ListChangeListener; - -/** - * PersistenceUnitPropertyListListener Notifies the given parent when a change - * occured in JPT PersistenceUnit properties - */ -public class PersistenceUnitPropertyListListener implements ListChangeListener -{ - private PersistenceUnitProperties parent; - - // ********** constructors / initialization ********** - public PersistenceUnitPropertyListListener(PersistenceUnitProperties parent) { - this.parent = parent; - } - - // ********** Behavior ********** - protected boolean add(PersistenceUnit.Property newItem, Model source) { - if (this.model().itemIsProperty(newItem)) { - String propertyName = this.model().propertyIdFor(newItem); - this.model().propertyChanged( - new PropertyChangeEvent(source, propertyName, null, newItem)); - return true; - } - return false; - } - - protected boolean remove(PersistenceUnit.Property item, Model source) { - if (this.model().itemIsProperty(item)) { - String propertyName = this.model().propertyIdFor(item); - this.model().propertyChanged( - new PropertyChangeEvent(source, propertyName, item, null)); // oldItem is the removed property - return true; - } - return false; - } - - // replace - protected PersistenceUnit.Property set(PersistenceUnit.Property newItem, Model source) { - if (this.model().itemIsProperty(newItem)) { - String propertyName = this.model().propertyIdFor(newItem); - this.model().propertyChanged( - new PropertyChangeEvent(source, propertyName, null, newItem)); // oldItem unknown - return newItem; - } - return null; - } - - // ********** ListChangeListener implementation ********** - public void itemsAdded(ListChangeEvent e) { - for (Iterator<PersistenceUnit.Property> stream = this.items(e); stream.hasNext();) { - this.add(stream.next(), e.getSource()); - } - } - - public void itemsRemoved(ListChangeEvent e) { - for (Iterator<PersistenceUnit.Property> stream = this.items(e); stream.hasNext();) { - this.remove(stream.next(), e.getSource()); - } - } - - public void itemsReplaced(ListChangeEvent e) { - // ItemAspectListValueModelAdapter(270) does not provide old value - for (Iterator<PersistenceUnit.Property> newStream = this.items(e); newStream.hasNext();) { - this.set(newStream.next(), e.getSource()); - } - } - - public void itemsMoved(ListChangeEvent e) { - throw new UnsupportedOperationException("source: " + e.getSource() + " - aspect: " + e.getAspectName()); - } - - public void listCleared(ListChangeEvent e) { - throw new UnsupportedOperationException("source: " + e.getSource() + " - aspect: " + e.getAspectName()); - } - - public void listChanged(ListChangeEvent e) { - throw new UnsupportedOperationException("source: " + e.getSource() + " - aspect: " + e.getAspectName()); - } - - // ********** standard methods ********** - @Override - public String toString() { - return this.getClass().getSimpleName() + "( " + this.model().getClass().getSimpleName() + ")"; - } - - // ********** internal methods ********** - private PersistenceUnitProperties model() { - return this.parent; - } - - @SuppressWarnings("unchecked") - private Iterator<PersistenceUnit.Property> items(ListChangeEvent event) { - return (Iterator<PersistenceUnit.Property>) event.items(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheProperties.java deleted file mode 100644 index c06dec92e8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheProperties.java +++ /dev/null @@ -1,115 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching; - -import java.io.Serializable; -import org.eclipse.jpt.utility.internal.StringTools; - -/** - * CacheProperties - */ -public class CacheProperties implements Cloneable, Serializable -{ - private String entityName; - - // ********** EclipseLink properties ********** - private CacheType type; - private Integer size; - private Boolean isShared; - - private static final long serialVersionUID = 1L; - - // ********** constructors ********** - public CacheProperties(String entityName) { - this.entityName = entityName; - } - - // ********** behaviors ********** - @Override - public boolean equals(Object o) { - if(o == null) { - return false; - } - CacheProperties cache = (CacheProperties) o; - return ( - (this.type == null ? - cache.type == null : this.type.equals(cache.type)) && - (this.isShared == null ? - cache.isShared == null : this.isShared.equals(cache.isShared)) && - (this.size == null ? - cache.size == null : this.size.equals(cache.size))); - } - - @Override - public synchronized CacheProperties clone() { - try { - return (CacheProperties)super.clone(); - } - catch (CloneNotSupportedException ex) { - throw new InternalError(); - } - } - - public boolean isEmpty() { - return (this.type == null) && - (this.size == null) && - (this.isShared == null); - } - - // ********** getter/setter ********** - public String getEntityName() { - return entityName; - } - - public CacheType getType() { - return this.type; - } - - public void setType(CacheType cacheType) { - this.type = cacheType; - } - - public Integer getSize() { - return this.size; - } - - public void setSize(Integer cacheSize) { - this.size = cacheSize; - } - - public Boolean isShared() { - return this.isShared; - } - - public void setShared(Boolean isShared) { - this.isShared = isShared; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - StringTools.buildSimpleToStringOn(this, sb); - sb.append(" ("); - this.toString(sb); - sb.append(')'); - return sb.toString(); - } - - public void toString(StringBuilder sb) { - sb.append("type: "); - sb.append(this.type); - sb.append(", size: "); - sb.append(this.size); - sb.append(", isShared: "); - sb.append(this.isShared); - sb.append(", entityName: "); - sb.append(this.entityName); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheType.java deleted file mode 100644 index 0c66da4968..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/CacheType.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching; - -/** - * CacheType - */ -public enum CacheType { - soft_weak, - hard_weak, - weak, - soft, - full, - none; - - // EclipseLink value string - public static final String FULL = "Full"; - public static final String HARD_WEAK = "HardWeak"; - public static final String NONE = "NONE"; - public static final String SOFT = "Soft"; - public static final String SOFT_WEAK = "SoftWeak"; - public static final String WEAK = "Weak"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/Caching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/Caching.java deleted file mode 100644 index 820a530938..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/Caching.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching; - -import java.util.ListIterator; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * Caching - */ -public interface Caching extends PersistenceUnitProperties -{ - CacheType getDefaultCacheTypeDefault(); - CacheType getCacheTypeDefault(); - void setCacheTypeDefault(CacheType cacheTypeDefault); - static final String CACHE_TYPE_DEFAULT_PROPERTY = "cacheTypeDefault"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_TYPE_DEFAULT = "eclipselink.cache.type.default"; //$NON-NLS-1$ - static final CacheType DEFAULT_CACHE_TYPE_DEFAULT = CacheType.soft_weak; - - Integer getDefaultCacheSizeDefault(); - Integer getCacheSizeDefault(); - void setCacheSizeDefault(Integer cacheSizeDefault); - static final String CACHE_SIZE_DEFAULT_PROPERTY = "cacheSizeDefault"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_SIZE_DEFAULT = "eclipselink.cache.size.default"; //$NON-NLS-1$ - static final Integer DEFAULT_CACHE_SIZE_DEFAULT = Integer.valueOf(100); - - Boolean getDefaultSharedCacheDefault(); - Boolean getSharedCacheDefault(); - void setSharedCacheDefault(Boolean sharedCacheDefault); - static final String SHARED_CACHE_DEFAULT_PROPERTY = "sharedCacheDefault"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_SHARED_DEFAULT = "eclipselink.cache.shared.default"; //$NON-NLS-1$ - static final Boolean DEFAULT_SHARED_CACHE_DEFAULT = Boolean.TRUE; - - - CacheType getDefaultCacheType(); - CacheType getCacheType(String entityName); - void setCacheType(CacheType cacheType, String entityName); - static final String CACHE_TYPE_PROPERTY = "cacheType"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_TYPE = "eclipselink.cache.type."; //$NON-NLS-1$ - static final CacheType DEFAULT_CACHE_TYPE = CacheType.soft_weak; - - Integer getDefaultCacheSize(); - Integer getCacheSize(String entityName); - void setCacheSize(Integer cacheSize, String entityName); - static final String CACHE_SIZE_PROPERTY = "cacheSize"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_SIZE = "eclipselink.cache.size."; //$NON-NLS-1$ - static final Integer DEFAULT_CACHE_SIZE = Integer.valueOf(100); - - Boolean getDefaultSharedCache(); - Boolean getSharedCache(String entityName); - void setSharedCache(Boolean sharedCache, String entityName); - static final String SHARED_CACHE_PROPERTY = "sharedCache"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SHARED_CACHE = "eclipselink.cache.shared."; //$NON-NLS-1$ - static final Boolean DEFAULT_SHARED_CACHE = Boolean.TRUE; - - FlushClearCache getDefaultFlushClearCache(); - FlushClearCache getFlushClearCache(); - void setFlushClearCache(FlushClearCache newFlushClearCache); - static final String FLUSH_CLEAR_CACHE_PROPERTY = "flushClearCache"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_FLUSH_CLEAR_CACHE = "eclipselink.flush-clear.cache"; //$NON-NLS-1$ - static final FlushClearCache DEFAULT_FLUSH_CLEAR_CACHE = FlushClearCache.drop_invalidate; - - - ListIterator<String> entities(); - int entitiesSize(); - boolean entityExists(String entity); - String addEntity(String entity); - void removeEntity(String entity); - String ENTITIES_LIST_PROPERTY = "entities"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/EclipseLinkCaching.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/EclipseLinkCaching.java deleted file mode 100644 index c1fd79a847..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/EclipseLinkCaching.java +++ /dev/null @@ -1,523 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching; - -import java.util.HashMap; -import java.util.ListIterator; -import java.util.Map; -import java.util.Set; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkCaching encapsulates EclipseLink Caching properties. - */ -public class EclipseLinkCaching extends EclipseLinkPersistenceUnitProperties - implements Caching -{ - // ********** EclipseLink properties ********** - private CacheType cacheTypeDefault; - private Integer cacheSizeDefault; - private Boolean sharedCacheDefault; - private FlushClearCache flushClearCache; - - // key = Entity name ; value = Cache properties - private Map<String, CacheProperties> entitiesCacheProperties; - - // ********** constructors ********** - public EclipseLinkCaching(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - // TOREVIEW - handle incorrect String in persistence.xml - this.entitiesCacheProperties = - new HashMap<String, CacheProperties>(); - this.cacheTypeDefault = - this.getEnumValue(ECLIPSELINK_CACHE_TYPE_DEFAULT, CacheType.values()); - this.cacheSizeDefault = - this.getIntegerValue(ECLIPSELINK_CACHE_SIZE_DEFAULT); - this.sharedCacheDefault = - this.getBooleanValue(ECLIPSELINK_CACHE_SHARED_DEFAULT); - this.flushClearCache = - this.getEnumValue(ECLIPSELINK_FLUSH_CLEAR_CACHE, FlushClearCache.values()); - - Set<PersistenceUnit.Property> cacheTypeProperties = - this.getPropertiesSetWithPrefix(ECLIPSELINK_CACHE_TYPE); - Set<PersistenceUnit.Property> cacheSizeProperties = - this.getPropertiesSetWithPrefix(ECLIPSELINK_CACHE_SIZE); - Set<PersistenceUnit.Property> sharedCacheProperties = - this.getPropertiesSetWithPrefix(ECLIPSELINK_SHARED_CACHE); - - this.initializeEntitiesCacheType(cacheTypeProperties); - this.initializeEntitiesCacheSize(cacheSizeProperties); - this.initializeEntitiesSharedCache(sharedCacheProperties); - } - - private void initializeEntitiesCacheType(Set<PersistenceUnit.Property> properties) { - for (PersistenceUnit.Property property : properties) { - String entityName = this.getEntityName(property); - CacheType cacheType = getEnumValueOf(property.getValue(), CacheType.values()); - this.setCacheType_(cacheType, entityName); - } - } - - private void initializeEntitiesCacheSize(Set<PersistenceUnit.Property> properties) { - for (PersistenceUnit.Property property : properties) { - String entityName = this.getEntityName(property); - this.setCacheSize_(property, entityName); - } - } - - private void initializeEntitiesSharedCache(Set<PersistenceUnit.Property> properties) { - for (PersistenceUnit.Property property : properties) { - String entityName = this.getEntityName(property); - this.setSharedCache_(property, entityName); - } - } - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key; - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_CACHE_TYPE_DEFAULT, - CACHE_TYPE_DEFAULT_PROPERTY); - propertyNames.put( - ECLIPSELINK_CACHE_SIZE_DEFAULT, - CACHE_SIZE_DEFAULT_PROPERTY); - propertyNames.put( - ECLIPSELINK_CACHE_SHARED_DEFAULT, - SHARED_CACHE_DEFAULT_PROPERTY); - propertyNames.put( - ECLIPSELINK_FLUSH_CLEAR_CACHE, - FLUSH_CLEAR_CACHE_PROPERTY); - - // Don't need to initialize propertyNames for: - // cacheType, sharedCache, cacheSize - } - - /** - * Method used for identifying the given property. - */ - @Override - public boolean itemIsProperty(PersistenceUnit.Property item) { - boolean isProperty = super.itemIsProperty(item); - - if ( ! isProperty && item.getName() != null) { - if (item.getName().startsWith(ECLIPSELINK_CACHE_TYPE) || - item.getName().startsWith(ECLIPSELINK_CACHE_SIZE) || - item.getName().startsWith(ECLIPSELINK_SHARED_CACHE)) { - return true; - } - } - return isProperty; - } - - /** - * Returns the property name used for change notification of the given - * property. - */ - @Override - public String propertyIdFor(PersistenceUnit.Property property) { - try { - return super.propertyIdFor(property); - } - catch (IllegalArgumentException e) { - if (property.getName().startsWith(ECLIPSELINK_CACHE_TYPE)) { - return CACHE_TYPE_PROPERTY; - } - else if (property.getName().startsWith(ECLIPSELINK_CACHE_SIZE)) { - return CACHE_SIZE_PROPERTY; - } - else if (property.getName().startsWith(ECLIPSELINK_SHARED_CACHE)) { - return SHARED_CACHE_PROPERTY; - } - } - throw new IllegalArgumentException("Illegal property: " + property.toString()); - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(CACHE_TYPE_DEFAULT_PROPERTY)) { - this.cacheTypeDefaultChanged(event); - } - else if (aspectName.equals(CACHE_SIZE_DEFAULT_PROPERTY)) { - this.cacheSizeDefaultChanged(event); - } - else if (aspectName.equals(SHARED_CACHE_DEFAULT_PROPERTY)) { - this.sharedCacheDefaultChanged(event); - } - else if (aspectName.equals(CACHE_TYPE_PROPERTY)) { - this.cacheTypeChanged(event); - } - else if (aspectName.equals(CACHE_SIZE_PROPERTY)) { - this.cacheSizeChanged(event); - } - else if (aspectName.equals(SHARED_CACHE_PROPERTY)) { - this.sharedCacheChanged(event); - } - else if (aspectName.equals(FLUSH_CLEAR_CACHE_PROPERTY)) { - this.flushClearCacheChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); - } - return; - } - - // ********** CacheType ********** - public CacheType getCacheType(String entityName) { - CacheProperties cache = this.cachePropertiesOf(entityName); - return (cache == null) ? null : cache.getType(); - } - - public void setCacheType(CacheType newCacheType, String entityName) { - CacheProperties old = this.setCacheType_(newCacheType, entityName); - this.putEnumValue(ECLIPSELINK_CACHE_TYPE, entityName, newCacheType, false); - this.firePropertyChanged(CACHE_TYPE_PROPERTY, old, this.cachePropertiesOf(entityName)); - } - - private void cacheTypeChanged(PropertyChangeEvent event) { - PersistenceUnit.Property property = (PersistenceUnit.Property) event.getNewValue(); - // property == null when removed - String entityName = (property == null) ? this.getEntityName((PersistenceUnit.Property) event.getOldValue()) : this.getEntityName(property); - CacheProperties old = this.setCacheType_(property, entityName); - this.firePropertyChanged(event.getAspectName(), old, this.cachePropertiesOf(entityName)); - } - - public CacheType getDefaultCacheType() { - return (this.cacheTypeDefault == null) ? DEFAULT_CACHE_TYPE : this.cacheTypeDefault; - } - - // ********** CacheSize ********** - public Integer getCacheSize(String entityName) { - CacheProperties cache = this.cachePropertiesOf(entityName); - return (cache == null) ? null : cache.getSize(); - } - - public void setCacheSize(Integer newCacheSize, String entityName) { - CacheProperties old = this.setCacheSize_(newCacheSize, entityName); - this.putIntegerValue(ECLIPSELINK_CACHE_SIZE + entityName, newCacheSize); - this.firePropertyChanged(CACHE_SIZE_PROPERTY, old, this.cachePropertiesOf(entityName)); - } - - private void cacheSizeChanged(PropertyChangeEvent event) { - PersistenceUnit.Property property = (PersistenceUnit.Property) event.getNewValue(); - // property == null when removed - String entityName = (property == null) ? this.getEntityName((PersistenceUnit.Property) event.getOldValue()) : this.getEntityName(property); - CacheProperties old = this.setCacheSize_(property, entityName); - this.firePropertyChanged(event.getAspectName(), old, this.cachePropertiesOf(entityName)); - } - - public Integer getDefaultCacheSize() { - return (this.cacheSizeDefault == null) ? DEFAULT_CACHE_SIZE : this.cacheSizeDefault; - } - - // ********** SharedCache ********** - public Boolean getSharedCache(String entityName) { - CacheProperties cache = this.cachePropertiesOf(entityName); - return (cache == null) ? null : cache.isShared(); - } - - public void setSharedCache(Boolean newSharedCache, String entityName) { - CacheProperties old = this.setSharedCache_(newSharedCache, entityName); - this.putBooleanValue(ECLIPSELINK_SHARED_CACHE, entityName, newSharedCache, false); - this.firePropertyChanged(SHARED_CACHE_PROPERTY, old, this.cachePropertiesOf(entityName)); - } - - private void sharedCacheChanged(PropertyChangeEvent event) { - String entityName; - PersistenceUnit.Property newProperty = (PersistenceUnit.Property) event.getNewValue(); - // property == null when removed - entityName = (newProperty == null) ? - this.getEntityName((PersistenceUnit.Property) event.getOldValue()) : this.getEntityName(newProperty); - CacheProperties old = this.setSharedCache_(newProperty, entityName); - this.firePropertyChanged(event.getAspectName(), old, this.cachePropertiesOf(entityName)); - } - - public Boolean getDefaultSharedCache() { - return (this.sharedCacheDefault == null) ? DEFAULT_SHARED_CACHE : this.sharedCacheDefault; - } - - // ********** CacheTypeDefault ********** - public CacheType getCacheTypeDefault() { - return this.cacheTypeDefault; - } - - public void setCacheTypeDefault(CacheType newCacheTypeDefault) { - CacheType old = this.cacheTypeDefault; - this.cacheTypeDefault = newCacheTypeDefault; - this.putProperty(CACHE_TYPE_DEFAULT_PROPERTY, newCacheTypeDefault); - this.firePropertyChanged(CACHE_TYPE_DEFAULT_PROPERTY, old, newCacheTypeDefault); - } - - private void cacheTypeDefaultChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - CacheType newValue = getEnumValueOf(stringValue, CacheType.values()); - CacheType old = this.cacheTypeDefault; - this.cacheTypeDefault = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public CacheType getDefaultCacheTypeDefault() { - return DEFAULT_CACHE_TYPE_DEFAULT; - } - - // ********** CacheSizeDefault ********** - public Integer getCacheSizeDefault() { - return this.cacheSizeDefault; - } - - public void setCacheSizeDefault(Integer newCacheSizeDefault) { - Integer old = this.cacheSizeDefault; - this.cacheSizeDefault = newCacheSizeDefault; - this.putProperty(CACHE_SIZE_DEFAULT_PROPERTY, newCacheSizeDefault); - this.firePropertyChanged(CACHE_SIZE_DEFAULT_PROPERTY, old, newCacheSizeDefault); - } - - private void cacheSizeDefaultChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - Integer old = this.cacheSizeDefault; - this.cacheSizeDefault = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultCacheSizeDefault() { - return DEFAULT_CACHE_SIZE_DEFAULT; - } - - // ********** SharedCacheDefault ********** - public Boolean getSharedCacheDefault() { - return this.sharedCacheDefault; - } - - public void setSharedCacheDefault(Boolean newSharedCacheDefault) { - Boolean old = this.sharedCacheDefault; - this.sharedCacheDefault = newSharedCacheDefault; - this.putProperty(SHARED_CACHE_DEFAULT_PROPERTY, newSharedCacheDefault); - this.firePropertyChanged(SHARED_CACHE_DEFAULT_PROPERTY, old, newSharedCacheDefault); - } - - private void sharedCacheDefaultChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.sharedCacheDefault; - this.sharedCacheDefault = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultSharedCacheDefault() { - return DEFAULT_SHARED_CACHE_DEFAULT; - } - - // ********** FlushClearCache ********** - - public FlushClearCache getFlushClearCache() { - return this.flushClearCache; - } - - public void setFlushClearCache(FlushClearCache newFlushClearCache) { - FlushClearCache old = this.flushClearCache; - this.flushClearCache = newFlushClearCache; - this.putProperty(FLUSH_CLEAR_CACHE_PROPERTY, newFlushClearCache); - this.firePropertyChanged(FLUSH_CLEAR_CACHE_PROPERTY, old, newFlushClearCache); - } - - private void flushClearCacheChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - FlushClearCache newValue = getEnumValueOf(stringValue, FlushClearCache.values()); - FlushClearCache old = this.flushClearCache; - this.flushClearCache = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public FlushClearCache getDefaultFlushClearCache() { - return DEFAULT_FLUSH_CLEAR_CACHE; - } - - // ****** CacheProperties ******* - /** - * Convenience method to update the CacheType in entitiesCache map. Returns - * the old value of CacheProperties - */ - private CacheProperties setCacheType_(PersistenceUnit.Property newProperty, String entityName) { - String stringValue = (newProperty == null) ? null : newProperty.getValue(); - CacheType newValue = getEnumValueOf(stringValue, CacheType.values()); - return this.setCacheType_(newValue, entityName); - } - - private CacheProperties setCacheType_(CacheType newValue, String entityName) { - CacheProperties properties = this.cachePropertiesOf(entityName); - CacheProperties old = properties.clone(); - properties.setType(newValue); - this.putEntityCacheProperties(entityName, properties); - return old; - } - - /** - * Convenience method to update the CacheSize in entitiesCache map. Returns - * the old value of CacheProperties - */ - private CacheProperties setCacheSize_(PersistenceUnit.Property newProperty, String entityName) { - String stringValue = (newProperty == null) ? null : newProperty.getValue(); - Integer newValue = getIntegerValueOf(stringValue); - return this.setCacheSize_(newValue, entityName); - } - - private CacheProperties setCacheSize_(Integer newValue, String entityName) { - CacheProperties properties = this.cachePropertiesOf(entityName); - CacheProperties old = properties.clone(); - properties.setSize(newValue); - this.putEntityCacheProperties(entityName, properties); - return old; - } - - /** - * Convenience method to update the SharedCache in entitiesCacheProperties map. - * Returns the old value of CacheProperties - */ - private CacheProperties setSharedCache_(PersistenceUnit.Property newProperty, String entityName) { - String newValue = (newProperty == null) ? null : newProperty.getValue(); - return this.setSharedCache_(newValue, entityName); - } - - private CacheProperties setSharedCache_(String newString, String entityName) { - Boolean newValue = getBooleanValueOf(newString); - return setSharedCache_(newValue, entityName); - } - - private CacheProperties setSharedCache_(Boolean newValue, String entityName) { - CacheProperties properties = this.cachePropertiesOf(entityName); - CacheProperties old = properties.clone(); - properties.setShared(newValue); - this.putEntityCacheProperties(entityName, properties); - return old; - } - - /** - * Returns the CacheProperties of the Entity with the given name. - */ - private CacheProperties cachePropertiesOf(String entityName) { - CacheProperties properties = this.entitiesCacheProperties.get(entityName); - if (properties == null) { - properties = new CacheProperties(entityName); - } - return properties; - } - - /** - * Set all CacheProperties to default. - */ - private void clearCacheProperties(String entityName) { - this.setCacheType(null, entityName); - this.setCacheSize(null, entityName); - this.setSharedCache(null, entityName); - } - - // ****** convenience methods ******* - - /** - * Put the given Entity CacheProperties in this entitiesCacheProperties map. - * @param entityName - Entity name. The entity may be a new or an existing entity. - * @param properties - Entity CacheProperties - */ - private void putEntityCacheProperties(String entityName, CacheProperties properties) { - this.addOrReplacePropertiesForEntity(entityName, properties); - } - - // ****** entities list ******* - - public ListIterator<String> entities() { - return CollectionTools.list(this.entitiesCacheProperties.keySet()).listIterator(); - } - - public int entitiesSize() { - return this.entitiesCacheProperties.size(); - } - - /* - * Verifies if this entitiesCacheProperties map contains the given Entity. - */ - public boolean entityExists(String entity) { - return this.entitiesCacheProperties.containsKey(entity); - } - - public String addEntity(String entity) { - if (entityExists(entity)) { - throw new IllegalStateException("Entity " + entity + " already exist."); - } - return this.addOrReplacePropertiesForEntity(entity, new CacheProperties(entity)); - } - - /** - * Adds or replaces the given Entity CacheProperties in this - * entitiesCacheProperties map. - * If the specified Entity exists and the given CacheProperties is empty - * (i.e. all properties are null) the mapping will be removed from the map. - * - * @param entity - Entity name - * @param properties - Entity CacheProperties - * @return Entity name added - */ - private String addOrReplacePropertiesForEntity(String entity, CacheProperties properties) { - if (this.entityExists(entity)) { - this.replaceEntity_(entity, properties); - return null; - } - this.entitiesCacheProperties.put(entity, properties); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - return entity; - } - - /** - * Replaces the given Entity CacheProperties in this - * entitiesCacheProperties map. - * If the given Entity CacheProperties is empty (i.e. all properties are null) the - * mapping will be removed from the map. - * @param entity - Entity name - * @param properties - Entity CacheProperties - * @return Entity name replaced - */ - private CacheProperties replaceEntity_(String entity, CacheProperties properties) { - CacheProperties old = this.entitiesCacheProperties.get(entity); - if (properties.isEmpty()) { - this.entitiesCacheProperties.remove(entity); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - } - else { - this.entitiesCacheProperties.put(entity, properties); - } - return old; - } - - public void removeEntity(String entity) { - if ( ! this.entityExists(entity)) { - return; - } - this.clearCacheProperties(entity); - this.entitiesCacheProperties.remove(entity); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/FlushClearCache.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/FlushClearCache.java deleted file mode 100644 index c29a27f718..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/caching/FlushClearCache.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.caching; - -/** - * FlushClearCache - */ -public enum FlushClearCache { - drop, - drop_invalidate, - merge; - - // EclipseLink value string - public static final String DROP = "Drop"; - public static final String DROP_INVALIDATE = "DropInvalidate"; - public static final String MERGE = "Merge"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/BatchWriting.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/BatchWriting.java deleted file mode 100644 index 5494a1a31f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/BatchWriting.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection; - -/** - * BatchWriting - */ -public enum BatchWriting { - none, - jdbc, - buffered, - oracle_jdbc; - - // EclipseLink value string - static final String NONE = "None"; - static final String JDBC = "JDBC"; - static final String BUFFERED = "Buffered"; - static final String ORACLE_JDBC = "Oracle-JDBC"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/Connection.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/Connection.java deleted file mode 100644 index 22de7dacab..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/Connection.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection; - -import org.eclipse.jpt.core.context.persistence.PersistenceUnitTransactionType; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * Connection - */ -public interface Connection extends PersistenceUnitProperties -{ - PersistenceUnitTransactionType getDefaultTransactionType(); - PersistenceUnitTransactionType getTransactionType(); - void setTransactionType(PersistenceUnitTransactionType newTransactionType); - // PersistenceUnit property - static final String TRANSACTION_TYPE_PROPERTY = "transactionType"; //$NON-NLS-1$ - static final PersistenceUnitTransactionType DEFAULT_TRANSACTION_TYPE = PersistenceUnitTransactionType.JTA; - - String getDefaultJtaDataSource(); - String getJtaDataSource(); - void setJtaDataSource(String newJtaDataSource); - // PersistenceUnit property - static final String JTA_DATA_SOURCE_PROPERTY = "jtaDataSource"; //$NON-NLS-1$ - static final String DEFAULT_JTA_DATA_SOURCE = ""; //$NON-NLS-1$ - - String getDefaultNonJtaDataSource(); - String getNonJtaDataSource(); - void setNonJtaDataSource(String newNonJtaDataSource); - // PersistenceUnit property - static final String NON_JTA_DATA_SOURCE_PROPERTY = "nonJtaDataSource"; //$NON-NLS-1$ - static final String DEFAULT_NON_JTA_DATA_SOURCE = ""; //$NON-NLS-1$ - - Boolean getDefaultNativeSql(); - Boolean getNativeSql(); - void setNativeSql(Boolean newNativeSql); - static final String NATIVE_SQL_PROPERTY = "nativeSql"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_NATIVE_SQL = "eclipselink.jdbc.native-sql"; //$NON-NLS-1$ - static final Boolean DEFAULT_NATIVE_SQL = Boolean.FALSE; - - BatchWriting getDefaultBatchWriting(); - BatchWriting getBatchWriting(); - void setBatchWriting(BatchWriting newBatchWriting); - static final String BATCH_WRITING_PROPERTY = "batchWriting"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_BATCH_WRITING = "eclipselink.jdbc.batch-writing"; //$NON-NLS-1$ - static final BatchWriting DEFAULT_BATCH_WRITING = BatchWriting.none; - - Boolean getDefaultCacheStatements(); - Boolean getCacheStatements(); - void setCacheStatements(Boolean newCacheStatements); - static final String CACHE_STATEMENTS_PROPERTY = "cacheStatements"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_STATEMENTS = "eclipselink.jdbc.cache-statements"; //$NON-NLS-1$ - static final Boolean DEFAULT_CACHE_STATEMENTS = Boolean.FALSE; - - Integer getDefaultCacheStatementsSize(); - Integer getCacheStatementsSize(); - void setCacheStatementsSize(Integer newCacheStatementsSize); - static final String CACHE_STATEMENTS_SIZE_PROPERTY = "cacheStatementsSize"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CACHE_STATEMENTS_SIZE = "eclipselink.jdbc.cache-statements.size"; //$NON-NLS-1$ - static final Integer DEFAULT_CACHE_STATEMENTS_SIZE = Integer.valueOf(50); - - String getDefaultDriver(); - String getDriver(); - void setDriver(String newDriver); - static final String DRIVER_PROPERTY = "driver"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_DRIVER = "eclipselink.jdbc.driver"; //$NON-NLS-1$ - static final String DEFAULT_DRIVER = ""; //$NON-NLS-1$ - - String getDefaultUrl(); - String getUrl(); - void setUrl(String newUrl); - static final String URL_PROPERTY = "url"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_URL = "eclipselink.jdbc.url"; //$NON-NLS-1$ - static final String DEFAULT_URL = ""; //$NON-NLS-1$ - - String getDefaultUser(); - String getUser(); - void setUser(String newUser); - static final String USER_PROPERTY = "user"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_USER = "eclipselink.jdbc.user"; //$NON-NLS-1$ - static final String DEFAULT_USER = ""; //$NON-NLS-1$ - - String getDefaultPassword(); - String getPassword(); - void setPassword(String newPassword); - static final String PASSWORD_PROPERTY = "password"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_PASSWORD = "eclipselink.jdbc.password"; //$NON-NLS-1$ - static final String DEFAULT_PASSWORD = ""; //$NON-NLS-1$ - - Boolean getDefaultBindParameters(); - Boolean getBindParameters(); - void setBindParameters(Boolean newBindParameters); - static final String BIND_PARAMETERS_PROPERTY = "bindParameters"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_BIND_PARAMETERS = "eclipselink.jdbc.bind-parameters"; //$NON-NLS-1$ - static final Boolean DEFAULT_BIND_PARAMETERS = Boolean.TRUE; - - Boolean getDefaultReadConnectionsShared(); - Boolean getReadConnectionsShared(); - void setReadConnectionsShared(Boolean newReadConnectionsShared); - static final String READ_CONNECTIONS_SHARED_PROPERTY = "readConnectionsShared"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_READ_CONNECTIONS_SHARED = "eclipselink.jdbc.read-connections.shared"; //$NON-NLS-1$ - static final Boolean DEFAULT_READ_CONNECTIONS_SHARED = Boolean.FALSE; - - Integer getDefaultReadConnectionsMin(); - Integer getReadConnectionsMin(); - void setReadConnectionsMin(Integer newReadConnectionsMin); - static final String READ_CONNECTIONS_MIN_PROPERTY = "readConnectionsMin"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_READ_CONNECTIONS_MIN = "eclipselink.jdbc.read-connections.min"; //$NON-NLS-1$ - static final Integer DEFAULT_READ_CONNECTIONS_MIN = Integer.valueOf(2); - - Integer getDefaultReadConnectionsMax(); - Integer getReadConnectionsMax(); - void setReadConnectionsMax(Integer newReadConnectionsMax); - static final String READ_CONNECTIONS_MAX_PROPERTY = "readConnectionsMax"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_READ_CONNECTIONS_MAX = "eclipselink.jdbc.read-connections.max"; //$NON-NLS-1$ - static final Integer DEFAULT_READ_CONNECTIONS_MAX = Integer.valueOf(2); - - Integer getDefaultWriteConnectionsMin(); - Integer getWriteConnectionsMin(); - void setWriteConnectionsMin(Integer newWriteConnectionsMin); - static final String WRITE_CONNECTIONS_MIN_PROPERTY = "writeConnectionsMin"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WRITE_CONNECTIONS_MIN = "eclipselink.jdbc.write-connections.min"; //$NON-NLS-1$ - static final Integer DEFAULT_WRITE_CONNECTIONS_MIN = Integer.valueOf(5); - - Integer getDefaultWriteConnectionsMax(); - Integer getWriteConnectionsMax(); - void setWriteConnectionsMax(Integer newWriteConnectionsMax); - static final String WRITE_CONNECTIONS_MAX_PROPERTY = "writeConnectionsMax"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WRITE_CONNECTIONS_MAX = "eclipselink.jdbc.write-connections.max"; //$NON-NLS-1$ - static final Integer DEFAULT_WRITE_CONNECTIONS_MAX = Integer.valueOf(10); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/EclipseLinkConnection.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/EclipseLinkConnection.java deleted file mode 100644 index bbe7b49c0a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/connection/EclipseLinkConnection.java +++ /dev/null @@ -1,654 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection; - -import java.util.Map; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.core.context.persistence.PersistenceUnitTransactionType; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.listener.PropertyChangeListener; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkConnection - */ -public class EclipseLinkConnection extends EclipseLinkPersistenceUnitProperties - implements Connection -{ - // ********** PersistenceUnit properties ********** - private PersistenceUnitTransactionType transactionType; - private String jtaDataSource; - private String nonJtaDataSource; - - // ********** EclipseLink properties ********** - private BatchWriting batchWriting; - private Boolean nativeSql; - private Boolean cacheStatements; - private Integer cacheStatementsSize; - private String driver; - private String url; - private String user; - private String password; - private Boolean bindParameters; - private Boolean readConnectionsShared; - private Integer readConnectionsMin; - private Integer readConnectionsMax; - private Integer writeConnectionsMin; - private Integer writeConnectionsMax; - - - // ********** constructors ********** - public EclipseLinkConnection(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - // TOREVIEW - handle incorrect String in persistence.xml - this.transactionType = - this.getPersistenceUnit().getSpecifiedTransactionType(); - this.jtaDataSource = - this.getPersistenceUnit().getJtaDataSource(); - this.nonJtaDataSource = - this.getPersistenceUnit().getNonJtaDataSource(); - this.batchWriting = - this.getEnumValue(ECLIPSELINK_BATCH_WRITING, BatchWriting.values()); - this.nativeSql = - this.getBooleanValue(ECLIPSELINK_NATIVE_SQL); - this.cacheStatements = - this.getBooleanValue(ECLIPSELINK_CACHE_STATEMENTS); - this.cacheStatementsSize = - this.getIntegerValue(ECLIPSELINK_CACHE_STATEMENTS_SIZE); - this.driver = - this.getStringValue(ECLIPSELINK_DRIVER); - this.url = - this.getStringValue(ECLIPSELINK_URL); - this.user = - this.getStringValue(ECLIPSELINK_USER); - this.password = - this.getStringValue(ECLIPSELINK_PASSWORD); - this.bindParameters = - this.getBooleanValue(ECLIPSELINK_BIND_PARAMETERS); - this.readConnectionsShared = - this.getBooleanValue(ECLIPSELINK_READ_CONNECTIONS_SHARED); - this.readConnectionsMin = - this.getIntegerValue(ECLIPSELINK_READ_CONNECTIONS_MIN); - this.readConnectionsMax = - this.getIntegerValue(ECLIPSELINK_READ_CONNECTIONS_MAX); - this.writeConnectionsMin = - this.getIntegerValue(ECLIPSELINK_WRITE_CONNECTIONS_MIN); - this.writeConnectionsMax = - this.getIntegerValue(ECLIPSELINK_WRITE_CONNECTIONS_MAX); - - } - - /** - * Initialize and add listeners to the persistence unit. - */ - @Override - protected void initialize(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super.initialize(parent, propertyListAdapter); - - this.getPersistenceUnit().addPropertyChangeListener( - PersistenceUnit.SPECIFIED_TRANSACTION_TYPE_PROPERTY, - this.buildTransactionTypeChangeListener()); - this.getPersistenceUnit().addPropertyChangeListener( - PersistenceUnit.JTA_DATA_SOURCE_PROPERTY, - this.buildJtaDataSourceChangeListener()); - this.getPersistenceUnit().addPropertyChangeListener( - PersistenceUnit.NON_JTA_DATA_SOURCE_PROPERTY, - this.buildNonJtaDataSourceChangeListener()); - } - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_NATIVE_SQL, - NATIVE_SQL_PROPERTY); - propertyNames.put( - ECLIPSELINK_BATCH_WRITING, - BATCH_WRITING_PROPERTY); - propertyNames.put( - ECLIPSELINK_CACHE_STATEMENTS, - CACHE_STATEMENTS_PROPERTY); - propertyNames.put( - ECLIPSELINK_CACHE_STATEMENTS_SIZE, - CACHE_STATEMENTS_SIZE_PROPERTY); - propertyNames.put( - ECLIPSELINK_DRIVER, - DRIVER_PROPERTY); - propertyNames.put( - ECLIPSELINK_URL, - URL_PROPERTY); - propertyNames.put( - ECLIPSELINK_USER, - USER_PROPERTY); - propertyNames.put( - ECLIPSELINK_PASSWORD, - PASSWORD_PROPERTY); - propertyNames.put( - ECLIPSELINK_BIND_PARAMETERS, - BIND_PARAMETERS_PROPERTY); - propertyNames.put( - ECLIPSELINK_READ_CONNECTIONS_SHARED, - READ_CONNECTIONS_SHARED_PROPERTY); - propertyNames.put( - ECLIPSELINK_READ_CONNECTIONS_MIN, - READ_CONNECTIONS_MIN_PROPERTY); - propertyNames.put( - ECLIPSELINK_READ_CONNECTIONS_MAX, - READ_CONNECTIONS_MAX_PROPERTY); - propertyNames.put( - ECLIPSELINK_WRITE_CONNECTIONS_MIN, - WRITE_CONNECTIONS_MIN_PROPERTY); - propertyNames.put( - ECLIPSELINK_WRITE_CONNECTIONS_MAX, - WRITE_CONNECTIONS_MAX_PROPERTY); - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(NATIVE_SQL_PROPERTY)) { - this.nativeSqlChanged(event); - } - else if (aspectName.equals(BATCH_WRITING_PROPERTY)) { - this.batchWritingChanged(event); - } - else if (aspectName.equals(CACHE_STATEMENTS_PROPERTY)) { - this.cacheStatementsChanged(event); - } - else if (aspectName.equals(DRIVER_PROPERTY)) { - this.driverChanged(event); - } - else if (aspectName.equals(URL_PROPERTY)) { - this.urlChanged(event); - } - else if (aspectName.equals(USER_PROPERTY)) { - this.userChanged(event); - } - else if (aspectName.equals(PASSWORD_PROPERTY)) { - this.passwordChanged(event); - } - else if (aspectName.equals(BIND_PARAMETERS_PROPERTY)) { - this.bindParametersChanged(event); - } - else if (aspectName.equals(READ_CONNECTIONS_SHARED_PROPERTY)) { - this.readConnectionsSharedChanged(event); - } - else if (aspectName.equals(CACHE_STATEMENTS_SIZE_PROPERTY)) { - this.cacheStatementsSizeChanged(event); - } - else if (aspectName.equals(READ_CONNECTIONS_MIN_PROPERTY)) { - this.readConnectionsMinChanged(event); - } - else if (aspectName.equals(READ_CONNECTIONS_MAX_PROPERTY)) { - this.readConnectionsMaxChanged(event); - } - else if (aspectName.equals(WRITE_CONNECTIONS_MIN_PROPERTY)) { - this.writeConnectionsMinChanged(event); - } - else if (aspectName.equals(WRITE_CONNECTIONS_MAX_PROPERTY)) { - this.writeConnectionsMaxChanged(event); - } - } - - // ********** TransactionType ********** - - public PersistenceUnitTransactionType getTransactionType() { - return this.transactionType; - } - - public void setTransactionType(PersistenceUnitTransactionType newTransactionType) { - PersistenceUnitTransactionType old = this.transactionType; - this.transactionType = newTransactionType; - - this.getPersistenceUnit().setSpecifiedTransactionType( newTransactionType); - this.firePropertyChanged(TRANSACTION_TYPE_PROPERTY, old, newTransactionType); - } - - private void transactionTypeChanged(PropertyChangeEvent event) { - PersistenceUnitTransactionType newValue = (PersistenceUnitTransactionType) event.getNewValue(); - PersistenceUnitTransactionType old = this.transactionType; - this.transactionType = newValue; - this.firePropertyChanged(TRANSACTION_TYPE_PROPERTY, old, newValue); - } - - public PersistenceUnitTransactionType getDefaultTransactionType() { - return DEFAULT_TRANSACTION_TYPE; - } - - protected PropertyChangeListener buildTransactionTypeChangeListener() { - return new PropertyChangeListener() { - public void propertyChanged(PropertyChangeEvent event) { - EclipseLinkConnection.this.transactionTypeChanged(event); - } - }; - } - - // ********** JtaDataSource ********** - - public String getJtaDataSource() { - return this.jtaDataSource; - } - - public void setJtaDataSource(String newJtaDataSource) { - String old = this.jtaDataSource; - this.jtaDataSource = newJtaDataSource; - - this.getPersistenceUnit().setJtaDataSource( newJtaDataSource); - this.firePropertyChanged(JTA_DATA_SOURCE_PROPERTY, old, newJtaDataSource); - } - - private void jtaDataSourceChanged(PropertyChangeEvent event) { - String newValue = (String) event.getNewValue(); - String old = this.jtaDataSource; - this.jtaDataSource = newValue; - this.firePropertyChanged(JTA_DATA_SOURCE_PROPERTY, old, newValue); - } - - public String getDefaultJtaDataSource() { - return DEFAULT_JTA_DATA_SOURCE; - } - - protected PropertyChangeListener buildJtaDataSourceChangeListener() { - return new PropertyChangeListener() { - public void propertyChanged(PropertyChangeEvent event) { - EclipseLinkConnection.this.jtaDataSourceChanged(event); - } - }; - } - - // ********** NonJtaDataSource ********** - - public String getNonJtaDataSource() { - return this.nonJtaDataSource; - } - - public void setNonJtaDataSource(String newNonJtaDataSource) { - String old = this.nonJtaDataSource; - this.nonJtaDataSource = newNonJtaDataSource; - - this.getPersistenceUnit().setNonJtaDataSource( newNonJtaDataSource); - this.firePropertyChanged(NON_JTA_DATA_SOURCE_PROPERTY, old, newNonJtaDataSource); - } - - private void nonJtaDataSourceChanged(PropertyChangeEvent event) { - String newValue = (String) event.getNewValue(); - String old = this.nonJtaDataSource; - this.nonJtaDataSource = newValue; - this.firePropertyChanged(NON_JTA_DATA_SOURCE_PROPERTY, old, newValue); - } - - public String getDefaultNonJtaDataSource() { - return DEFAULT_NON_JTA_DATA_SOURCE; - } - - protected PropertyChangeListener buildNonJtaDataSourceChangeListener() { - return new PropertyChangeListener() { - public void propertyChanged(PropertyChangeEvent event) { - EclipseLinkConnection.this.nonJtaDataSourceChanged(event); - } - }; - } - - // ********** NativeSql ********** - public Boolean getNativeSql() { - return this.nativeSql; - } - - public void setNativeSql(Boolean newNativeSql) { - Boolean old = this.nativeSql; - this.nativeSql = newNativeSql; - this.putProperty(NATIVE_SQL_PROPERTY, newNativeSql); - this.firePropertyChanged(NATIVE_SQL_PROPERTY, old, newNativeSql); - } - - private void nativeSqlChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.nativeSql; - this.nativeSql = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultNativeSql() { - return DEFAULT_NATIVE_SQL; - } - - // ********** BatchWriting ********** - - public BatchWriting getBatchWriting() { - return this.batchWriting; - } - - public void setBatchWriting(BatchWriting newBatchWriting) { - BatchWriting old = this.batchWriting; - this.batchWriting = newBatchWriting; - this.putProperty(BATCH_WRITING_PROPERTY, newBatchWriting); - this.firePropertyChanged(BATCH_WRITING_PROPERTY, old, newBatchWriting); - } - - private void batchWritingChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - BatchWriting newValue = getEnumValueOf(stringValue, BatchWriting.values()); - BatchWriting old = this.batchWriting; - this.batchWriting = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public BatchWriting getDefaultBatchWriting() { - return DEFAULT_BATCH_WRITING; - } - - // ********** CacheStatements ********** - public Boolean getCacheStatements() { - return this.cacheStatements; - } - - public void setCacheStatements(Boolean newCacheStatements) { - Boolean old = this.cacheStatements; - this.cacheStatements = newCacheStatements; - this.putProperty(CACHE_STATEMENTS_PROPERTY, newCacheStatements); - this.firePropertyChanged(CACHE_STATEMENTS_PROPERTY, old, newCacheStatements); - } - - private void cacheStatementsChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.cacheStatements; - this.cacheStatements = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultCacheStatements() { - return DEFAULT_CACHE_STATEMENTS; - } - - // ********** CacheStatementsSize ********** - public Integer getCacheStatementsSize() { - return this.cacheStatementsSize; - } - - public void setCacheStatementsSize(Integer newCacheStatementsSize) { - Integer old = this.cacheStatementsSize; - this.cacheStatementsSize = newCacheStatementsSize; - this.putProperty(CACHE_STATEMENTS_SIZE_PROPERTY, newCacheStatementsSize); - this.firePropertyChanged(CACHE_STATEMENTS_SIZE_PROPERTY, old, newCacheStatementsSize); - } - - private void cacheStatementsSizeChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - - Integer old = this.cacheStatementsSize; - this.cacheStatementsSize = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultCacheStatementsSize() { - return DEFAULT_CACHE_STATEMENTS_SIZE; - } - - // ********** Driver ********** - public String getDriver() { - return this.driver; - } - - public void setDriver(String newDriver) { - String old = this.driver; - this.driver = newDriver; - this.putProperty(DRIVER_PROPERTY, newDriver); - this.firePropertyChanged(DRIVER_PROPERTY, old, newDriver); - } - - private void driverChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.driver; - this.driver = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultDriver() { - return DEFAULT_DRIVER; - } - - // ********** URL ********** - public String getUrl() { - return this.url; - } - - public void setUrl(String newUrl) { - String old = this.url; - this.url = newUrl; - this.putProperty(URL_PROPERTY, newUrl); - this.firePropertyChanged(URL_PROPERTY, old, newUrl); - } - - private void urlChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.url; - this.url = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultUrl() { - return DEFAULT_URL; - } - - // ********** User ********** - public String getUser() { - return this.user; - } - - public void setUser(String newUser) { - String old = this.user; - this.user = newUser; - this.putProperty(USER_PROPERTY, newUser); - this.firePropertyChanged(USER_PROPERTY, old, newUser); - } - - private void userChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.user; - this.user = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultUser() { - return DEFAULT_USER; - } - - // ********** Password ********** - public String getPassword() { - return this.password; - } - - public void setPassword(String newPassword) { - String old = this.password; - this.password = newPassword; - this.putProperty(PASSWORD_PROPERTY, newPassword); - this.firePropertyChanged(PASSWORD_PROPERTY, old, newPassword); - } - - private void passwordChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.password; - this.password = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultPassword() { - return DEFAULT_PASSWORD; - } - - // ********** BindParameters ********** - public Boolean getBindParameters() { - return this.bindParameters; - } - - public void setBindParameters(Boolean newBindParameters) { - Boolean old = this.bindParameters; - this.bindParameters = newBindParameters; - this.putProperty(BIND_PARAMETERS_PROPERTY, newBindParameters); - this.firePropertyChanged(BIND_PARAMETERS_PROPERTY, old, newBindParameters); - } - - private void bindParametersChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.bindParameters; - this.bindParameters = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultBindParameters() { - return DEFAULT_BIND_PARAMETERS; - } - - // ********** ReadConnectionsShared ********** - public Boolean getReadConnectionsShared() { - return this.readConnectionsShared; - } - - public void setReadConnectionsShared(Boolean newReadConnectionsShared) { - Boolean old = this.readConnectionsShared; - this.readConnectionsShared = newReadConnectionsShared; - this.putProperty(READ_CONNECTIONS_SHARED_PROPERTY, newReadConnectionsShared); - this.firePropertyChanged(READ_CONNECTIONS_SHARED_PROPERTY, old, newReadConnectionsShared); - } - - private void readConnectionsSharedChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.readConnectionsShared; - this.readConnectionsShared = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultReadConnectionsShared() { - return DEFAULT_READ_CONNECTIONS_SHARED; - } - - // ********** ReadConnectionsMin ********** - public Integer getReadConnectionsMin() { - return this.readConnectionsMin; - } - - public void setReadConnectionsMin(Integer newReadConnectionsMin) { - Integer old = this.readConnectionsMin; - this.readConnectionsMin = newReadConnectionsMin; - this.putProperty(READ_CONNECTIONS_MIN_PROPERTY, newReadConnectionsMin); - this.firePropertyChanged(READ_CONNECTIONS_MIN_PROPERTY, old, newReadConnectionsMin); - } - - private void readConnectionsMinChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - - Integer old = this.readConnectionsMin; - this.readConnectionsMin = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultReadConnectionsMin() { - return DEFAULT_READ_CONNECTIONS_MIN; - } - - // ********** ReadConnectionsMax ********** - public Integer getReadConnectionsMax() { - return this.readConnectionsMax; - } - - public void setReadConnectionsMax(Integer newReadConnectionsMax) { - Integer old = this.readConnectionsMax; - this.readConnectionsMax = newReadConnectionsMax; - this.putProperty(READ_CONNECTIONS_MAX_PROPERTY, newReadConnectionsMax); - this.firePropertyChanged(READ_CONNECTIONS_MAX_PROPERTY, old, newReadConnectionsMax); - } - - private void readConnectionsMaxChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - - Integer old = this.readConnectionsMax; - this.readConnectionsMax = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultReadConnectionsMax() { - return DEFAULT_READ_CONNECTIONS_MAX; - } - - // ********** WriteConnectionsMin ********** - public Integer getWriteConnectionsMin() { - return this.writeConnectionsMin; - } - - public void setWriteConnectionsMin(Integer newWriteConnectionsMin) { - Integer old = this.writeConnectionsMin; - this.writeConnectionsMin = newWriteConnectionsMin; - this.putProperty(WRITE_CONNECTIONS_MIN_PROPERTY, newWriteConnectionsMin); - this.firePropertyChanged(WRITE_CONNECTIONS_MIN_PROPERTY, old, newWriteConnectionsMin); - } - - private void writeConnectionsMinChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - - Integer old = this.writeConnectionsMin; - this.writeConnectionsMin = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultWriteConnectionsMin() { - return DEFAULT_WRITE_CONNECTIONS_MIN; - } - - // ********** WriteConnectionsMax ********** - public Integer getWriteConnectionsMax() { - return this.writeConnectionsMax; - } - - public void setWriteConnectionsMax(Integer newWriteConnectionsMax) { - Integer old = this.writeConnectionsMax; - this.writeConnectionsMax = newWriteConnectionsMax; - this.putProperty(WRITE_CONNECTIONS_MAX_PROPERTY, newWriteConnectionsMax); - this.firePropertyChanged(WRITE_CONNECTIONS_MAX_PROPERTY, old, newWriteConnectionsMax); - } - - private void writeConnectionsMaxChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Integer newValue = getIntegerValueOf(stringValue); - - Integer old = this.writeConnectionsMax; - this.writeConnectionsMax = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Integer getDefaultWriteConnectionsMax() { - return DEFAULT_WRITE_CONNECTIONS_MAX; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Customization.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Customization.java deleted file mode 100644 index 9b16b72172..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Customization.java +++ /dev/null @@ -1,131 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization; - -import java.util.ListIterator; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * Customization - */ -public interface Customization extends PersistenceUnitProperties -{ - Boolean getDefaultThrowExceptions(); - Boolean getThrowExceptions(); - void setThrowExceptions(Boolean newThrowExceptions); - static final String THROW_EXCEPTIONS_PROPERTY = "throwExceptions"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_THROW_EXCEPTIONS = "eclipselink.orm.throw.exceptions"; //$NON-NLS-1$ - static final Boolean DEFAULT_THROW_EXCEPTIONS = Boolean.TRUE; - - Weaving getDefaultWeaving(); - Weaving getWeaving(); - void setWeaving(Weaving newWeaving); - static final String WEAVING_PROPERTY = "weaving"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING = "eclipselink.weaving"; //$NON-NLS-1$ - static final Weaving DEFAULT_WEAVING = Weaving.true_; - - Boolean getDefaultWeavingLazy(); - Boolean getWeavingLazy(); - void setWeavingLazy(Boolean newWeavingLazy); - static final String WEAVING_LAZY_PROPERTY = "weavingLazy"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING_LAZY = "eclipselink.weaving.lazy"; //$NON-NLS-1$ - static final Boolean DEFAULT_WEAVING_LAZY = Boolean.TRUE; - - Boolean getDefaultWeavingChangeTracking(); - Boolean getWeavingChangeTracking(); - void setWeavingChangeTracking(Boolean newWeavingChangeTracking); - static final String WEAVING_CHANGE_TRACKING_PROPERTY = "weavingChangeTracking"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING_CHANGE_TRACKING = "eclipselink.weaving.changetracking"; //$NON-NLS-1$ - static final Boolean DEFAULT_WEAVING_CHANGE_TRACKING = Boolean.TRUE; - - Boolean getDefaultWeavingFetchGroups(); - Boolean getWeavingFetchGroups(); - void setWeavingFetchGroups(Boolean newWeavingFetchGroups); - static final String WEAVING_FETCH_GROUPS_PROPERTY = "weavingFetchGroups"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING_FETCH_GROUPS = "eclipselink.weaving.fetchgroups"; //$NON-NLS-1$ - static final Boolean DEFAULT_WEAVING_FETCH_GROUPS = Boolean.TRUE; - - Boolean getDefaultWeavingInternal(); - Boolean getWeavingInternal(); - void setWeavingInternal(Boolean newWeavingInternal); - static final String WEAVING_INTERNAL_PROPERTY = "weavingInternal"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING_INTERNAL = "eclipselink.weaving.internal"; //$NON-NLS-1$ - static final Boolean DEFAULT_WEAVING_INTERNAL = Boolean.TRUE; - - Boolean getDefaultWeavingEager(); - Boolean getWeavingEager(); - void setWeavingEager(Boolean newWeavingEager); - static final String WEAVING_EAGER_PROPERTY = "weavingEager"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_WEAVING_EAGER = "eclipselink.weaving.eager"; //$NON-NLS-1$ - static final Boolean DEFAULT_WEAVING_EAGER = Boolean.FALSE; - - String getDefaultDescriptorCustomizer(); - String getDescriptorCustomizer(String entityName); - void setDescriptorCustomizer(String newDescriptorCustomizer, String entityName); - static final String DESCRIPTOR_CUSTOMIZER_PROPERTY = "descriptorCustomizer"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_DESCRIPTOR_CUSTOMIZER = "eclipselink.descriptor.customizer."; //$NON-NLS-1$ - static final String DEFAULT_DESCRIPTOR_CUSTOMIZER = null; // no default - - ListIterator<String> sessionCustomizers(); - int sessionCustomizersSize(); - boolean sessionCustomizerExists(String sessionCustomizerClassName); - String addSessionCustomizer(String newSessionCustomizerClassName); - void removeSessionCustomizer(String sessionCustomizerClassName); - static final String SESSION_CUSTOMIZER_LIST_PROPERTY = "sessionCustomizers"; //$NON-NLS-1$ - static final String SESSION_CUSTOMIZER_PROPERTY = "sessionCustomizer"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSION_CUSTOMIZER = "eclipselink.session.customizer"; //$NON-NLS-1$ - - ListIterator<String> entities(); - int entitiesSize(); - boolean entityExists(String entity); - String addEntity(String entity); - void removeEntity(String entity); - static final String ENTITIES_LIST_PROPERTY = "entities"; //$NON-NLS-1$ - - String getDefaultProfiler(); - String getProfiler(); - void setProfiler(String newProfiler); - void setProfiler(Profiler newProfiler); - static final String PROFILER_PROPERTY = "profiler"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_PROFILER = "eclipselink.profiler"; //$NON-NLS-1$ - static final String DEFAULT_PROFILER = - EclipseLinkPersistenceUnitProperties.getEclipseLinkStringValueOf(Profiler.no_profiler); - String ECLIPSELINK_SESSION_PROFILER_CLASS_NAME = "org.eclipse.persistence.sessions.SessionProfiler"; //$NON-NLS-1$ - - Boolean getDefaultValidationOnly(); - Boolean getValidationOnly(); - void setValidationOnly(Boolean newValidationOnly); - static final String VALIDATION_ONLY_PROPERTY = "validationOnly"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_VALIDATION_ONLY = "eclipselink.validation-only"; //$NON-NLS-1$ - static final Boolean DEFAULT_VALIDATION_ONLY = Boolean.TRUE; - - String getDefaultExceptionHandler(); - String getExceptionHandler(); - void setExceptionHandler(String newExceptionHandler); - static final String EXCEPTION_HANDLER_PROPERTY = "exceptionHandler"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_EXCEPTION_HANDLER = "eclipselink.exception-handler"; //$NON-NLS-1$ - static final String DEFAULT_EXCEPTION_HANDLER = null; // no default - - String ECLIPSELINK_EXCEPTION_HANDLER_CLASS_NAME = "org.eclipse.persistence.exceptions.ExceptionHandler"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/CustomizerProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/CustomizerProperties.java deleted file mode 100644 index def82d949d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/CustomizerProperties.java +++ /dev/null @@ -1,87 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization; - -import java.io.Serializable; -import org.eclipse.jpt.utility.internal.StringTools; - -/** - * CustomizerProperties - */ -public class CustomizerProperties implements Cloneable, Serializable -{ - private String entityName; - - // ********** EclipseLink properties ********** - private String className; - - private static final long serialVersionUID = 1L; - - // ********** constructors ********** - public CustomizerProperties(String entityName) { - this.entityName = entityName; - } - - // ********** behaviors ********** - @Override - public boolean equals(Object o) { - if(o == null) { - return false; - } - CustomizerProperties customizer = (CustomizerProperties) o; - return ( - (this.className == null ? - customizer.className == null : this.className.equals(customizer.className))); - } - - @Override - public synchronized CustomizerProperties clone() { - try { - return (CustomizerProperties)super.clone(); - } - catch (CloneNotSupportedException ex) { - throw new InternalError(); - } - } - - public boolean isEmpty() { - return this.className == null; - } - - // ********** getter/setter ********** - public String getEntityName() { - return this.entityName; - } - - public String getClassName() { - return this.className; - } - - public void setClassName(String newClassName) { - this.className = newClassName; - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder(); - StringTools.buildSimpleToStringOn(this, sb); - sb.append(" ("); - this.toString(sb); - sb.append(')'); - return sb.toString(); - } - - public void toString(StringBuilder sb) { - sb.append(" class: "); - sb.append(this.className); - sb.append(", entityName: "); - sb.append(this.entityName); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/EclipseLinkCustomization.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/EclipseLinkCustomization.java deleted file mode 100644 index a3949376ef..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/EclipseLinkCustomization.java +++ /dev/null @@ -1,736 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization; - -import java.util.ArrayList; -import java.util.HashMap; -import java.util.ListIterator; -import java.util.Map; -import java.util.Set; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkCustomization - */ -public class EclipseLinkCustomization extends EclipseLinkPersistenceUnitProperties - implements Customization -{ - // ********** EclipseLink properties ********** - private Boolean throwExceptions; - private Weaving weaving; - private Boolean weavingLazy; - private Boolean weavingChangeTracking; - private Boolean weavingFetchGroups; - private Boolean weavingInternal; - private Boolean weavingEager; - private Boolean validationOnly; - private ArrayList<String> sessionCustomizers; - private String profiler; // storing EclipseLinkStringValue since value can be Profiler or custom class - private String exceptionHandler; - - // key = Entity name ; value = Customizer properties - private Map<String, CustomizerProperties> entitiesCustomizerProperties; - - // ********** constructors ********** - public EclipseLinkCustomization(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - // TOREVIEW - handle incorrect String in persistence.xml - this.entitiesCustomizerProperties = - new HashMap<String, CustomizerProperties>(); - - this.throwExceptions = - this.getBooleanValue(ECLIPSELINK_THROW_EXCEPTIONS); - this.weaving = - this.getEnumValue(ECLIPSELINK_WEAVING, Weaving.values()); - this.weavingLazy = - this.getBooleanValue(ECLIPSELINK_WEAVING_LAZY); - this.weavingChangeTracking = - this.getBooleanValue(ECLIPSELINK_WEAVING_CHANGE_TRACKING); - this.weavingFetchGroups = - this.getBooleanValue(ECLIPSELINK_WEAVING_FETCH_GROUPS); - this.weavingInternal = - this.getBooleanValue(ECLIPSELINK_WEAVING_INTERNAL); - this.weavingEager = - this.getBooleanValue(ECLIPSELINK_WEAVING_EAGER); - this.validationOnly = - this.getBooleanValue(ECLIPSELINK_VALIDATION_ONLY); - this.initializeSessionCustomizersFromPersistenceUnit(); - - Set<PersistenceUnit.Property> properties = - this.getPropertiesSetWithPrefix(ECLIPSELINK_DESCRIPTOR_CUSTOMIZER); - this.initializeEntitiesCustomizerClass(properties); - - this.profiler = this.getProfilerPropertyValue(); - this.exceptionHandler = - this.getStringValue(ECLIPSELINK_EXCEPTION_HANDLER); - } - - private void initializeSessionCustomizersFromPersistenceUnit() { - Set<PersistenceUnit.Property> properties = - this.getPropertiesSetWithPrefix(ECLIPSELINK_SESSION_CUSTOMIZER); - - this.sessionCustomizers = new ArrayList<String>(properties.size()); - this.initializeSessionCustomizersWith(properties); - } - - private void initializeSessionCustomizersWith(Set<PersistenceUnit.Property> properties) { - for (PersistenceUnit.Property property : properties) { - this.sessionCustomizers.add(property.getValue()); - } - } - - private void initializeEntitiesCustomizerClass(Set<PersistenceUnit.Property> properties) { - for (PersistenceUnit.Property property : properties) { - String entityName = this.getEntityName(property); - this.setCustomizerClass_(property, entityName); - } - } - - /** - * Gets the Profiler property from the persistence unit. - */ - private String getProfilerPropertyValue() { - - String value = this.getStringValue(ECLIPSELINK_PROFILER); - if (value == null) { - return null; // no property found - } - Profiler standardProfiler = this.getEnumValue(ECLIPSELINK_PROFILER, Profiler.values()); - return (standardProfiler == null) ? value : getEclipseLinkStringValueOf(standardProfiler); - } - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_THROW_EXCEPTIONS, - THROW_EXCEPTIONS_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING, - WEAVING_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING_LAZY, - WEAVING_LAZY_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING_CHANGE_TRACKING, - WEAVING_CHANGE_TRACKING_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING_FETCH_GROUPS, - WEAVING_FETCH_GROUPS_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING_INTERNAL, - WEAVING_INTERNAL_PROPERTY); - propertyNames.put( - ECLIPSELINK_WEAVING_EAGER, - WEAVING_EAGER_PROPERTY); - propertyNames.put( - ECLIPSELINK_VALIDATION_ONLY, - VALIDATION_ONLY_PROPERTY); - propertyNames.put( - ECLIPSELINK_SESSION_CUSTOMIZER, - SESSION_CUSTOMIZER_PROPERTY); - propertyNames.put( - ECLIPSELINK_PROFILER, - PROFILER_PROPERTY); - propertyNames.put( - ECLIPSELINK_EXCEPTION_HANDLER, - EXCEPTION_HANDLER_PROPERTY); - - // Don't need to initialize propertyNames for: - // descriptorCustomizerProperty - } - - /** - * Method used for identifying the given property. - */ - @Override - public boolean itemIsProperty(PersistenceUnit.Property item) { - boolean isProperty = super.itemIsProperty(item); - - if ( ! isProperty && item.getName() != null) { - if (item.getName().startsWith(ECLIPSELINK_DESCRIPTOR_CUSTOMIZER)) { - return true; - } - } - return isProperty; - } - - /** - * Returns the property name used for change notification of the given - * property. - */ - @Override - public String propertyIdFor(PersistenceUnit.Property property) { - try { - return super.propertyIdFor(property); - } - catch (IllegalArgumentException e) { - if (property.getName().startsWith(ECLIPSELINK_DESCRIPTOR_CUSTOMIZER)) { - return DESCRIPTOR_CUSTOMIZER_PROPERTY; - } - } - throw new IllegalArgumentException("Illegal property: " + property); //$NON-NLS-1$ - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(THROW_EXCEPTIONS_PROPERTY)) { - this.throwExceptionsChanged(event); - } - else if (aspectName.equals(WEAVING_PROPERTY)) { - this.weavingChanged(event); - } - else if (aspectName.equals(WEAVING_LAZY_PROPERTY)) { - this.weavingLazyChanged(event); - } - else if (aspectName.equals(WEAVING_CHANGE_TRACKING_PROPERTY)) { - this.weavingChangeTrackingChanged(event); - } - else if (aspectName.equals(WEAVING_FETCH_GROUPS_PROPERTY)) { - this.weavingFetchGroupsChanged(event); - } - else if (aspectName.equals(WEAVING_INTERNAL_PROPERTY)) { - this.weavingInternalChanged(event); - } - else if (aspectName.equals(WEAVING_EAGER_PROPERTY)) { - this.weavingEagerChanged(event); - } - else if (aspectName.equals(VALIDATION_ONLY_PROPERTY)) { - this.validationOnlyChanged(event); - } - else if (aspectName.equals(SESSION_CUSTOMIZER_PROPERTY)) { - this.sessionCustomizersChanged(event); - } - else if (aspectName.equals(DESCRIPTOR_CUSTOMIZER_PROPERTY)) { - this.descriptorCustomizerChanged(event); - } - else if (aspectName.equals(PROFILER_PROPERTY)) { - this.profilerChanged(event); - } - else if (aspectName.equals(EXCEPTION_HANDLER_PROPERTY)) { - this.exceptionHandlerChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); //$NON-NLS-1$ - } - return; - } - - - // ********** ThrowExceptions ********** - public Boolean getThrowExceptions() { - return this.throwExceptions; - } - - public void setThrowExceptions(Boolean newThrowExceptions) { - Boolean old = this.throwExceptions; - this.throwExceptions = newThrowExceptions; - this.putProperty(THROW_EXCEPTIONS_PROPERTY, newThrowExceptions); - this.firePropertyChanged(THROW_EXCEPTIONS_PROPERTY, old, newThrowExceptions); - } - - private void throwExceptionsChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.throwExceptions; - this.throwExceptions = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultThrowExceptions() { - return DEFAULT_THROW_EXCEPTIONS; - } - - // ********** WeavingLazy ********** - public Boolean getWeavingLazy() { - return this.weavingLazy; - } - - public void setWeavingLazy(Boolean newWeavingLazy) { - Boolean old = this.weavingLazy; - this.weavingLazy = newWeavingLazy; - this.putProperty(WEAVING_LAZY_PROPERTY, newWeavingLazy); - this.firePropertyChanged(WEAVING_LAZY_PROPERTY, old, newWeavingLazy); - } - - private void weavingLazyChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.weavingLazy; - this.weavingLazy = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultWeavingLazy() { - return DEFAULT_WEAVING_LAZY; - } - - // ********** WeavingChangeTracking ********** - public Boolean getWeavingChangeTracking() { - return this.weavingChangeTracking; - } - - public void setWeavingChangeTracking(Boolean newWeavingChangeTracking) { - Boolean old = this.weavingChangeTracking; - this.weavingChangeTracking = newWeavingChangeTracking; - this.putProperty(WEAVING_CHANGE_TRACKING_PROPERTY, newWeavingChangeTracking); - this.firePropertyChanged(WEAVING_CHANGE_TRACKING_PROPERTY, old, newWeavingChangeTracking); - } - - private void weavingChangeTrackingChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.weavingChangeTracking; - this.weavingChangeTracking = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultWeavingChangeTracking() { - return DEFAULT_WEAVING_CHANGE_TRACKING; - } - - // ********** WeavingFetchGroups ********** - public Boolean getWeavingFetchGroups() { - return this.weavingFetchGroups; - } - - public void setWeavingFetchGroups(Boolean newWeavingFetchGroups) { - Boolean old = this.weavingFetchGroups; - this.weavingFetchGroups = newWeavingFetchGroups; - this.putProperty(WEAVING_FETCH_GROUPS_PROPERTY, newWeavingFetchGroups); - this.firePropertyChanged(WEAVING_FETCH_GROUPS_PROPERTY, old, newWeavingFetchGroups); - } - - private void weavingFetchGroupsChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.weavingFetchGroups; - this.weavingFetchGroups = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultWeavingFetchGroups() { - return DEFAULT_WEAVING_FETCH_GROUPS; - } - - // ********** WeavingInternal ********** - public Boolean getWeavingInternal() { - return this.weavingInternal; - } - - public void setWeavingInternal(Boolean newWeavingInternal) { - Boolean old = this.weavingInternal; - this.weavingInternal = newWeavingInternal; - this.putProperty(WEAVING_INTERNAL_PROPERTY, newWeavingInternal); - this.firePropertyChanged(WEAVING_INTERNAL_PROPERTY, old, newWeavingInternal); - } - - private void weavingInternalChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.weavingInternal; - this.weavingInternal = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultWeavingInternal() { - return DEFAULT_WEAVING_INTERNAL; - } - - // ********** WeavingEager ********** - public Boolean getWeavingEager() { - return this.weavingEager; - } - - public void setWeavingEager(Boolean newWeavingEager) { - Boolean old = this.weavingEager; - this.weavingEager = newWeavingEager; - this.putProperty(WEAVING_EAGER_PROPERTY, newWeavingEager); - this.firePropertyChanged(WEAVING_EAGER_PROPERTY, old, newWeavingEager); - } - - private void weavingEagerChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.weavingEager; - this.weavingEager = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultWeavingEager() { - return DEFAULT_WEAVING_EAGER; - } - - // ********** ValidationOnly ********** - public Boolean getValidationOnly() { - return this.validationOnly; - } - - public void setValidationOnly(Boolean newValidationOnly) { - Boolean old = this.validationOnly; - this.validationOnly = newValidationOnly; - this.putProperty(VALIDATION_ONLY_PROPERTY, newValidationOnly); - this.firePropertyChanged(VALIDATION_ONLY_PROPERTY, old, newValidationOnly); - } - - private void validationOnlyChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.validationOnly; - this.validationOnly = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultValidationOnly() { - return DEFAULT_VALIDATION_ONLY; - } - - // ********** SessionCustomizers ********** - public ListIterator<String> sessionCustomizers(){ - return new CloneListIterator<String>(this.sessionCustomizers); - } - - public int sessionCustomizersSize(){ - return this.sessionCustomizers.size(); - } - - public boolean sessionCustomizerExists(String sessionCustomizerClassName) { - - for (String sessionCustomizer : this.sessionCustomizers) { - if(sessionCustomizer.equals(sessionCustomizerClassName)) { - return true; - } - } - return false; - } - - public String addSessionCustomizer(String newSessionCustomizerClassName){ - - if( ! this.sessionCustomizerExists(newSessionCustomizerClassName)) { - this.sessionCustomizers.add(newSessionCustomizerClassName); - this.putProperty(SESSION_CUSTOMIZER_PROPERTY, newSessionCustomizerClassName, true); - this.fireListChanged(SESSION_CUSTOMIZER_LIST_PROPERTY); - return newSessionCustomizerClassName; - } - return null; - } - - public void removeSessionCustomizer(String className){ - - if(this.removeSessionCustomizer_(className) != null) { - this.removeProperty(SESSION_CUSTOMIZER_PROPERTY, className); - this.fireListChanged(SESSION_CUSTOMIZER_LIST_PROPERTY); - } - } - - private String removeSessionCustomizer_(String className){ - - for ( ListIterator<String> i = this.sessionCustomizers(); i.hasNext();) { - String sessionCustomizer = i.next(); - if(sessionCustomizer.equals(className)) { - this.sessionCustomizers.remove(sessionCustomizer); - return sessionCustomizer; - } - } - return null; - } - - private void sessionCustomizersChanged(@SuppressWarnings("unused") PropertyChangeEvent event) { - - this.initializeSessionCustomizersFromPersistenceUnit(); - this.fireListChanged(SESSION_CUSTOMIZER_LIST_PROPERTY); - } - - // ********** Weaving ********** - - public Weaving getWeaving() { - return this.weaving; - } - - public void setWeaving(Weaving newWeaving) { - Weaving old = this.weaving; - this.weaving = newWeaving; - this.putProperty(WEAVING_PROPERTY, newWeaving); - this.firePropertyChanged(WEAVING_PROPERTY, old, newWeaving); - } - - private void weavingChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Weaving newValue = getEnumValueOf(stringValue, Weaving.values()); - Weaving old = this.weaving; - this.weaving = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Weaving getDefaultWeaving() { - return DEFAULT_WEAVING; - } - - // ********** ExceptionHandler ********** - public String getExceptionHandler() { - return this.exceptionHandler; - } - - public void setExceptionHandler(String newExceptionHandler) { - String old = this.exceptionHandler; - this.exceptionHandler = newExceptionHandler; - this.putProperty(EXCEPTION_HANDLER_PROPERTY, newExceptionHandler); - this.firePropertyChanged(EXCEPTION_HANDLER_PROPERTY, old, newExceptionHandler); - } - - private void exceptionHandlerChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.exceptionHandler; - this.exceptionHandler = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultExceptionHandler() { - return DEFAULT_EXCEPTION_HANDLER; - } - - // ********** DescriptorCustomizer ********** - - public String getDescriptorCustomizer(String entityName) { - CustomizerProperties customizer = this.customizerPropertiesOf(entityName); - return (customizer == null) ? null : customizer.getClassName(); - } - - public void setDescriptorCustomizer(String newDescriptorCustomizer, String entityName) { - CustomizerProperties old = this.setCustomizerClass_(newDescriptorCustomizer, entityName); - this.putStringValue(ECLIPSELINK_DESCRIPTOR_CUSTOMIZER, entityName, newDescriptorCustomizer, false); - this.firePropertyChanged(DESCRIPTOR_CUSTOMIZER_PROPERTY, old, this.customizerPropertiesOf(entityName)); - } - - private void descriptorCustomizerChanged(PropertyChangeEvent event) { - String entityName; - PersistenceUnit.Property newProperty = (PersistenceUnit.Property) event.getNewValue(); - // property == null when removed - entityName = (newProperty == null) ? - this.getEntityName((PersistenceUnit.Property) event.getOldValue()) : this.getEntityName(newProperty); - CustomizerProperties old = this.setCustomizerClass_(newProperty, entityName); - this.firePropertyChanged(event.getAspectName(), old, this.customizerPropertiesOf(entityName)); - } - - public String getDefaultDescriptorCustomizer() { - return DEFAULT_DESCRIPTOR_CUSTOMIZER; - } - - - // ****** CustomizerProperties ******* - - /** - * Convenience method to update the CustomizerClass in entitiesCustomizerProperties map. - * Returns the old value of CustomizerProperties - */ - private CustomizerProperties setCustomizerClass_(PersistenceUnit.Property newProperty, String entityName) { - String newValue = (newProperty == null) ? null : newProperty.getValue(); - return this.setCustomizerClass_(newValue, entityName); - } - - private CustomizerProperties setCustomizerClass_(String newValue, String entityName) { - CustomizerProperties properties = this.customizerPropertiesOf(entityName); - CustomizerProperties old = properties.clone(); - properties.setClassName(newValue); - this.putEntityCustomizerProperties(entityName, properties); - return old; - } - - /** - * Returns the CustomizerProperties of the Entity with the given name. - */ - private CustomizerProperties customizerPropertiesOf(String entityName) { - CustomizerProperties properties = this.entitiesCustomizerProperties.get(entityName); - if (properties == null) { - properties = new CustomizerProperties(entityName); - } - return properties; - } - - /** - * Set all CustomizerProperties to default. - */ - private void clearCustomizerProperties(String entityName) { - this.setDescriptorCustomizer(null, entityName); - } - - // ****** convenience methods ******* - /** - * Put the given Entity CustomizerProperties in this entitiesCustomizerProperties map. - * @param entityName - Entity name. The entity may be a new or an existing entity. - * @param properties - Entity CustomizerProperties - */ - private void putEntityCustomizerProperties(String entityName, CustomizerProperties properties) { - this.addOrReplacePropertiesForEntity(entityName, properties); - } - - - - // ****** entities list ******* - - public ListIterator<String> entities() { - return CollectionTools.list(this.entitiesCustomizerProperties.keySet()).listIterator(); - } - - public int entitiesSize() { - return this.entitiesCustomizerProperties.size(); - } - - /* - * Verifies if this entitiesCacheProperties map contains the given Entity. - */ - public boolean entityExists(String entity) { - return this.entitiesCustomizerProperties.containsKey(entity); - } - - public String addEntity(String entity) { - if (entityExists(entity)) { - throw new IllegalStateException("Entity already exists: " + entity); //$NON-NLS-1$ - } - return this.addOrReplacePropertiesForEntity(entity, new CustomizerProperties(entity)); - } - - /** - * Adds or Replaces the given Entity CustomizerProperties in - * this entitiesCustomizerProperties map. - * If the specified Entity exists and the given CustomizerProperties is empty - * (i.e. all properties are null) the mapping will be removed from the map. - * @param entity - Entity name - * @param properties - Entity CustomizerProperties - * @return - */ - private String addOrReplacePropertiesForEntity(String entity, CustomizerProperties properties) { - if (entityExists(entity)) { - this.replaceEntity_(entity, properties); - return null; - } - this.entitiesCustomizerProperties.put(entity, properties); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - return entity; - } - - /** - * Replaces the given Entity CustomizerProperties in this - * entitiesCustomizerProperties map. - * If the Entity CustomizerProperties is empty (i.e. all properties is null) the - * mapping will be removed from the map. - * @param entity - Entity name - * @param properties - Entity CustomizerProperties - * @return - */ - private CustomizerProperties replaceEntity_(String entity, CustomizerProperties properties) { - CustomizerProperties old = this.entitiesCustomizerProperties.get(entity); - if (properties.isEmpty()) { - this.entitiesCustomizerProperties.remove(entity); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - } - else { - this.entitiesCustomizerProperties.put(entity, properties); - } - return old; - } - - public void removeEntity(String entity) { - if ( ! entityExists(entity)) { - return; - } - this.clearCustomizerProperties(entity); - this.entitiesCustomizerProperties.remove(entity); - this.fireListChanged(ENTITIES_LIST_PROPERTY); - } - - // ********** Profiler ********** - /** - * Returns Profiler or custom profiler class. - * - * @return EclipseLink string value for Profiler enum or custom profiler class - */ - public String getProfiler() { - return this.profiler; - } - - /** - * Sets EclipseLink profiler. - * - * @param newProfiler - Profiler - */ - public void setProfiler(Profiler newProfiler) { - if( newProfiler == null) { - this.setProfiler_((String) null); - return; - } - this.setProfiler_(getEclipseLinkStringValueOf(newProfiler)); - } - - /** - * Sets EclipseLink profiler or custom profiler. - * - * @param newProfiler - - * Can be a EclipseLink profiler literal or - * a fully qualified class name of a custom profiler. - */ - public void setProfiler(String newProfiler) { - if( newProfiler == null) { - this.setProfiler_((String) null); - return; - } - Profiler p = Profiler.getProfilerFor(newProfiler); - if(p == null) { // custom profiler class - this.setProfiler_(newProfiler); - } - else { - this.setProfiler(p); - } - } - - private void setProfiler_(String newProfiler) { - String old = this.profiler; - this.profiler = newProfiler; - this.putProperty(PROFILER_PROPERTY, newProfiler); - this.firePropertyChanged(PROFILER_PROPERTY, old, newProfiler); - } - - private void profilerChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.profiler; - this.profiler = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultProfiler() { - return DEFAULT_PROFILER; - } - -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Profiler.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Profiler.java deleted file mode 100644 index 903b09ac97..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Profiler.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization; - -/** - * Profiler - */ -public enum Profiler { - performance_profiler, - query_monitor, - no_profiler; - - // EclipseLink value string - public static final String PERFORMANCE_PROFILER = "PerformanceProfiler"; //$NON-NLS-1$ - public static final String QUERY_MONITOR = "QueryMonitor"; //$NON-NLS-1$ - public static final String NO_PROFILER = "NoProfiler"; //$NON-NLS-1$ - - // EclipseLink profiler class names - public static final String PERFORMANCE_PROFILER_CLASS_NAME = "org.eclipse.persistence.tools.profiler.PerformanceProfiler"; //$NON-NLS-1$ - public static final String QUERY_MONITOR_CLASS_NAME = "org.eclipse.persistence.tools.profiler.QueryMonitor"; //$NON-NLS-1$ - - /** - * Return the Profiler value corresponding to the given literal. - */ - public static Profiler getProfilerFor(String literal) { - - for( Profiler profiler : Profiler.values()) { - if(profiler.toString().equals(literal)) { - return profiler; - } - } - return null; - } - - - public static String getProfilerClassName(String profilerValue) { - if (profilerValue == PERFORMANCE_PROFILER) { - return PERFORMANCE_PROFILER_CLASS_NAME; - } - if (profilerValue == QUERY_MONITOR) { - return QUERY_MONITOR_CLASS_NAME; - } - return profilerValue; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Weaving.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Weaving.java deleted file mode 100644 index 0ecfedfdd2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/customization/Weaving.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization; - -/** - * Weaving - */ -public enum Weaving { - true_, - false_, - static_; - - // EclipseLink value string - public static final String TRUE_ = "true"; - public static final String FALSE_ = "false"; - public static final String STATIC_ = "static"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/EclipseLinkGeneralProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/EclipseLinkGeneralProperties.java deleted file mode 100644 index dbcf4bfb3a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/EclipseLinkGeneralProperties.java +++ /dev/null @@ -1,95 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.general; - -import java.util.Map; - -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkGeneralProperties - */ -public class EclipseLinkGeneralProperties extends EclipseLinkPersistenceUnitProperties - implements GeneralProperties -{ - // ********** EclipseLink properties ********** - private Boolean excludeEclipselinkOrm; - - // ********** constructors ********** - public EclipseLinkGeneralProperties(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - - this.excludeEclipselinkOrm = - this.getBooleanValue(ECLIPSELINK_EXCLUDE_ECLIPSELINK_ORM); - } - - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_EXCLUDE_ECLIPSELINK_ORM, - EXCLUDE_ECLIPSELINK_ORM_PROPERTY); - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(EXCLUDE_ECLIPSELINK_ORM_PROPERTY)) { - this.excludeEclipselinkOrmChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); //$NON-NLS-1$ - } - return; - } - - - // ********** ExcludeEclipselinkOrm ********** - public Boolean getExcludeEclipselinkOrm() { - return this.excludeEclipselinkOrm; - } - - public void setExcludeEclipselinkOrm(Boolean newExcludeEclipselinkOrm) { - Boolean old = this.excludeEclipselinkOrm; - this.excludeEclipselinkOrm = newExcludeEclipselinkOrm; - this.putProperty(EXCLUDE_ECLIPSELINK_ORM_PROPERTY, newExcludeEclipselinkOrm); - this.firePropertyChanged(EXCLUDE_ECLIPSELINK_ORM_PROPERTY, old, newExcludeEclipselinkOrm); - } - - private void excludeEclipselinkOrmChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.excludeEclipselinkOrm; - this.excludeEclipselinkOrm = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultExcludeEclipselinkOrm() { - return DEFAULT_EXCLUDE_ECLIPSELINK_ORM; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/GeneralProperties.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/GeneralProperties.java deleted file mode 100644 index ebc2927942..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/general/GeneralProperties.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.general; - -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * GeneralProperties - */ -public interface GeneralProperties extends PersistenceUnitProperties -{ - - Boolean getDefaultExcludeEclipselinkOrm(); - Boolean getExcludeEclipselinkOrm(); - void setExcludeEclipselinkOrm(Boolean newExcludeEclipselinkOrm); - static final String EXCLUDE_ECLIPSELINK_ORM_PROPERTY = "excludeEclipselinkOrm"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_EXCLUDE_ECLIPSELINK_ORM = "eclipselink.exclude-eclipselink-orm"; //$NON-NLS-1$ - static final Boolean DEFAULT_EXCLUDE_ECLIPSELINK_ORM = Boolean.FALSE; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/EclipseLinkLogging.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/EclipseLinkLogging.java deleted file mode 100644 index 3a3cf744e8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/EclipseLinkLogging.java +++ /dev/null @@ -1,344 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging; - -import java.util.Map; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkLogging - */ -public class EclipseLinkLogging extends EclipseLinkPersistenceUnitProperties - implements Logging -{ - // ********** EclipseLink properties ********** - private LoggingLevel level; - private Boolean timestamp; - private Boolean thread; - private Boolean session; - private Boolean exceptions; - private String logFileLocation; - private String logger; // storing EclipseLinkStringValue since value can be Logger or custom class - - // ********** constructors ********** - public EclipseLinkLogging(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - // TOREVIEW - handle incorrect String in persistence.xml - this.level = - this.getEnumValue(ECLIPSELINK_LEVEL, LoggingLevel.values()); - this.timestamp = - this.getBooleanValue(ECLIPSELINK_TIMESTAMP); - this.thread = - this.getBooleanValue(ECLIPSELINK_THREAD); - this.session = - this.getBooleanValue(ECLIPSELINK_SESSION); - this.exceptions = - this.getBooleanValue(ECLIPSELINK_EXCEPTIONS); - this.logFileLocation = - this.getStringValue(ECLIPSELINK_LOG_FILE_LOCATION); - - this.logger = this.getLoggerProtertyValue(); - } - - /** - * Gets the Logger property from the persistence unit. - */ - private String getLoggerProtertyValue() { - - String value = this.getStringValue(ECLIPSELINK_LOGGER); - if (value == null) { - return null; // no property found - } - Logger standardLogger = this.getEnumValue(ECLIPSELINK_LOGGER, Logger.values()); - return (standardLogger == null) ? value : getEclipseLinkStringValueOf(standardLogger); - } - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_LEVEL, - LEVEL_PROPERTY); - propertyNames.put( - ECLIPSELINK_TIMESTAMP, - TIMESTAMP_PROPERTY); - propertyNames.put( - ECLIPSELINK_THREAD, - THREAD_PROPERTY); - propertyNames.put( - ECLIPSELINK_SESSION, - SESSION_PROPERTY); - propertyNames.put( - ECLIPSELINK_EXCEPTIONS, - EXCEPTIONS_PROPERTY); - propertyNames.put( - ECLIPSELINK_LOG_FILE_LOCATION, - LOG_FILE_LOCATION_PROPERTY); - propertyNames.put( - ECLIPSELINK_LOGGER, - LOGGER_PROPERTY); - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(LEVEL_PROPERTY)) { - this.levelChanged(event); - } - else if (aspectName.equals(TIMESTAMP_PROPERTY)) { - this.timestampChanged(event); - } - else if (aspectName.equals(THREAD_PROPERTY)) { - this.threadChanged(event); - } - else if (aspectName.equals(SESSION_PROPERTY)) { - this.sessionChanged(event); - } - else if (aspectName.equals(EXCEPTIONS_PROPERTY)) { - this.exceptionsChanged(event); - } - else if (aspectName.equals(LOG_FILE_LOCATION_PROPERTY)) { - this.logFileLocationChanged(event); - } - else if (aspectName.equals(LOGGER_PROPERTY)) { - this.loggerChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); //$NON-NLS-1$ - } - return; - } - - // ********** LoggingLevel ********** - - public LoggingLevel getLevel() { - return this.level; - } - - public void setLevel(LoggingLevel newLevel) { - LoggingLevel old = this.level; - this.level = newLevel; - this.putProperty(LEVEL_PROPERTY, newLevel); - this.firePropertyChanged(LEVEL_PROPERTY, old, newLevel); - } - - private void levelChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - LoggingLevel newValue = getEnumValueOf(stringValue, LoggingLevel.values()); - LoggingLevel old = this.level; - this.level = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public LoggingLevel getDefaultLevel() { - return DEFAULT_LEVEL; - } - - // ********** Timestamp ********** - public Boolean getTimestamp() { - return this.timestamp; - } - - public void setTimestamp(Boolean newTimestamp) { - Boolean old = this.timestamp; - this.timestamp = newTimestamp; - this.putProperty(TIMESTAMP_PROPERTY, newTimestamp); - this.firePropertyChanged(TIMESTAMP_PROPERTY, old, newTimestamp); - } - - private void timestampChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.timestamp; - this.timestamp = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultTimestamp() { - return DEFAULT_TIMESTAMP; - } - - // ********** Thread ********** - public Boolean getThread() { - return this.thread; - } - - public void setThread(Boolean newThread) { - Boolean old = this.thread; - this.thread = newThread; - this.putProperty(THREAD_PROPERTY, newThread); - this.firePropertyChanged(THREAD_PROPERTY, old, newThread); - } - - private void threadChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.thread; - this.thread = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultThread() { - return DEFAULT_THREAD; - } - - // ********** Session ********** - public Boolean getSession() { - return this.session; - } - - public void setSession(Boolean newSession) { - Boolean old = this.session; - this.session = newSession; - this.putProperty(SESSION_PROPERTY, newSession); - this.firePropertyChanged(SESSION_PROPERTY, old, newSession); - } - - private void sessionChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.session; - this.session = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultSession() { - return DEFAULT_SESSION; - } - - // ********** Exceptions ********** - public Boolean getExceptions() { - return this.exceptions; - } - - public void setExceptions(Boolean newExceptions) { - Boolean old = this.exceptions; - this.exceptions = newExceptions; - this.putProperty(EXCEPTIONS_PROPERTY, newExceptions); - this.firePropertyChanged(EXCEPTIONS_PROPERTY, old, newExceptions); - } - - private void exceptionsChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.exceptions; - this.exceptions = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultExceptions() { - return DEFAULT_EXCEPTIONS; - } - - // ********** logFileLocation ********** - public String getLogFileLocation() { - return this.logFileLocation; - } - - public void setLogFileLocation(String newLogFileLocation) { - String old = this.logFileLocation; - this.logFileLocation = newLogFileLocation; - this.putProperty(LOG_FILE_LOCATION_PROPERTY, newLogFileLocation); - this.firePropertyChanged(LOG_FILE_LOCATION_PROPERTY, old, newLogFileLocation); - } - - private void logFileLocationChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.logFileLocation; - this.logFileLocation = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultLogFileLocation() { - return DEFAULT_LOG_FILE_LOCATION; - } - - // ********** Logger ********** - /** - * Returns Logger or custom logger class. - * - * @return EclipseLink string value for Logger enum or custom logger class - */ - public String getLogger() { - return this.logger; - } - - /** - * Sets EclipseLink logger. - * - * @param newLogger - Logger - */ - public void setLogger(Logger newLogger) { - if( newLogger == null) { - this.setLogger_((String) null); - return; - } - this.setLogger_(getEclipseLinkStringValueOf(newLogger)); - } - - /** - * Sets EclipseLink logger or custom logger. - * - * @param newLogger - - * Can be a EclipseLink logger literal or - * a fully qualified class name of a custom logger. - */ - public void setLogger(String newLogger) { - if( newLogger == null) { - this.setLogger_(null); - return; - } - Logger l = Logger.getLoggerFor(newLogger); - if(l == null) { // custom Logger class - this.setLogger_(newLogger); - } - else { - this.setLogger(l); - } - } - - private void setLogger_(String newLogger) { - String old = this.logger; - this.logger = newLogger; - this.putProperty(LOGGER_PROPERTY, newLogger); - this.firePropertyChanged(LOGGER_PROPERTY, old, newLogger); - } - - private void loggerChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.logger; - this.logger = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultLogger() { - return DEFAULT_LOGGER; - } - -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logger.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logger.java deleted file mode 100644 index 63b2c6065e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logger.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging; - -/** - * Logger - */ -public enum Logger { - default_logger, - java_logger, - server_logger; - - // EclipseLink value string - public static final String DEFAULT_LOGGER = "DefaultLogger"; //$NON-NLS-1$ - public static final String JAVA_LOGGER = "JavaLogger"; //$NON-NLS-1$ - public static final String SERVER_LOGGER = "ServerLogger"; //$NON-NLS-1$ - - // EclipseLink logger class names - public static final String DEFAULT_LOGGER_CLASS_NAME = "org.eclipse.persistence.logging.DefaultSessionLog"; //$NON-NLS-1$ - public static final String JAVA_LOGGER_CLASS_NAME = "org.eclipse.persistence.logging.JavaLog"; //$NON-NLS-1$ - public static final String SERVER_LOGGER_CLASS_NAME = "org.eclipse.persistence.platform.server.ServerLog"; //$NON-NLS-1$ - - /** - * Return the Logger value corresponding to the given literal. - */ - public static Logger getLoggerFor(String literal) { - - for( Logger logger : Logger.values()) { - if(logger.toString().equals(literal)) { - return logger; - } - } - return null; - } - - public static String getLoggerClassName(String loggerValue) { - if (loggerValue == DEFAULT_LOGGER) { - return DEFAULT_LOGGER_CLASS_NAME; - } - if (loggerValue == JAVA_LOGGER) { - return JAVA_LOGGER_CLASS_NAME; - } - if (loggerValue == SERVER_LOGGER) { - return SERVER_LOGGER_CLASS_NAME; - } - return loggerValue; - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logging.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logging.java deleted file mode 100644 index 45084c8826..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/Logging.java +++ /dev/null @@ -1,78 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging; - -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * Logging - */ -public interface Logging extends PersistenceUnitProperties -{ - LoggingLevel getDefaultLevel(); - LoggingLevel getLevel(); - void setLevel(LoggingLevel level); - static final String LEVEL_PROPERTY = "level"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_LEVEL = "eclipselink.logging.level"; //$NON-NLS-1$ - static final LoggingLevel DEFAULT_LEVEL = LoggingLevel.info; - - Boolean getDefaultTimestamp(); - Boolean getTimestamp(); - void setTimestamp(Boolean timestamp); - static final String TIMESTAMP_PROPERTY = "timestamp"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_TIMESTAMP = "eclipselink.logging.timestamp"; //$NON-NLS-1$ - static final Boolean DEFAULT_TIMESTAMP = Boolean.TRUE; - - Boolean getDefaultThread(); - Boolean getThread(); - void setThread(Boolean thread); - static final String THREAD_PROPERTY = "thread"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_THREAD = "eclipselink.logging.thread"; //$NON-NLS-1$ - static final Boolean DEFAULT_THREAD = Boolean.TRUE; - - Boolean getDefaultSession(); - Boolean getSession(); - void setSession(Boolean session); - static final String SESSION_PROPERTY = "session"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSION = "eclipselink.logging.session"; //$NON-NLS-1$ - static final Boolean DEFAULT_SESSION = Boolean.TRUE; - - Boolean getDefaultExceptions(); - Boolean getExceptions(); - void setExceptions(Boolean exceptions); - static final String EXCEPTIONS_PROPERTY = "exceptions"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_EXCEPTIONS = "eclipselink.logging.exceptions"; //$NON-NLS-1$ - static final Boolean DEFAULT_EXCEPTIONS = Boolean.FALSE; - - String getDefaultLogFileLocation(); - String getLogFileLocation(); - void setLogFileLocation(String newLogFileLocation); - static final String LOG_FILE_LOCATION_PROPERTY = "logFileLocation"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_LOG_FILE_LOCATION = "eclipselink.logging.file"; //$NON-NLS-1$ - static final String DEFAULT_LOG_FILE_LOCATION = null; // No Default - - String getDefaultLogger(); - String getLogger(); - void setLogger(String newLogger); - void setLogger(Logger newLogger); - static final String LOGGER_PROPERTY = "logger"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_LOGGER = "eclipselink.logging.logger"; //$NON-NLS-1$ - static final String DEFAULT_LOGGER = - EclipseLinkPersistenceUnitProperties.getEclipseLinkStringValueOf(Logger.default_logger); - String ECLIPSELINK_LOGGER_CLASS_NAME = "org.eclipse.persistence.logging.SessionLog"; //$NON-NLS-1$ -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/LoggingLevel.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/LoggingLevel.java deleted file mode 100644 index 015885836b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/logging/LoggingLevel.java +++ /dev/null @@ -1,36 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging; - -/** - * LoggingLevel - */ -public enum LoggingLevel { - off, - severe, - warning, - info, - config, - fine, - finer, - finest, - all; - - // EclipseLink value string - public static final String OFF = "OFF"; - public static final String SEVERE = "SEVERE"; - public static final String WARNING = "WARNING"; - public static final String INFO = "INFO"; - public static final String CONFIG = "CONFIG"; - public static final String FINE = "FINE"; - public static final String FINER = "FINER"; - public static final String FINEST = "FINEST"; - public static final String ALL = "ALL"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/EclipseLinkOptions.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/EclipseLinkOptions.java deleted file mode 100644 index 2a805c6103..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/EclipseLinkOptions.java +++ /dev/null @@ -1,384 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008, 2009 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.options; - -import java.util.Map; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkOptions - */ -public class EclipseLinkOptions extends EclipseLinkPersistenceUnitProperties - implements Options -{ - // ********** EclipseLink properties ********** - private String sessionName; - private String sessionsXml; - private Boolean includeDescriptorQueries; - private String targetDatabase; // storing EclipseLinkStringValue since value can be TargetDatabase or custom class - private String targetServer; // storing EclipseLinkStringValue since value can be TargetServer or custom class - private String eventListener; - private Boolean temporalMutable; - - - // ********** constructors ********** - public EclipseLinkOptions(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - // ********** initialization ********** - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - // TOREVIEW - handle incorrect String in persistence.xml - this.sessionName = - this.getStringValue(ECLIPSELINK_SESSION_NAME); - this.sessionsXml = - this.getStringValue(ECLIPSELINK_SESSIONS_XML); - this.includeDescriptorQueries = - this.getBooleanValue(ECLIPSELINK_SESSION_INCLUDE_DESCRIPTOR_QUERIES); - this.targetDatabase = this.getTargetDatabaseFromPersistenceXml(); - this.targetServer = this.getTargetServerFromPersistenceXml(); - this.eventListener = - this.getStringValue(ECLIPSELINK_SESSION_EVENT_LISTENER); - this.temporalMutable = - this.getBooleanValue(ECLIPSELINK_TEMPORAL_MUTABLE); - } - - protected String getTargetDatabaseFromPersistenceXml() { - - String value = this.getStringValue(ECLIPSELINK_TARGET_DATABASE); - if (value == null) { - return null; - } - TargetDatabase standardTargetDatabase = this.getEnumValue(ECLIPSELINK_TARGET_DATABASE, TargetDatabase.values()); - return (standardTargetDatabase == null) ? value : getEclipseLinkStringValueOf(standardTargetDatabase); - } - - protected String getTargetServerFromPersistenceXml() { - - String value = this.getStringValue(ECLIPSELINK_TARGET_SERVER); - if (value == null) { - return null; - } - TargetServer standardTargetServer = this.getEnumValue(ECLIPSELINK_TARGET_SERVER, TargetServer.values()); - return (standardTargetServer == null) ? value : getEclipseLinkStringValueOf(standardTargetServer); - } - - // ********** behavior ********** - /** - * Adds property names key/value pairs, where: - * key = EclipseLink property key - * value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_SESSION_NAME, - SESSION_NAME_PROPERTY); - propertyNames.put( - ECLIPSELINK_SESSIONS_XML, - SESSIONS_XML_PROPERTY); - propertyNames.put( - ECLIPSELINK_SESSION_INCLUDE_DESCRIPTOR_QUERIES, - SESSION_INCLUDE_DESCRIPTOR_QUERIES_PROPERTY); - propertyNames.put( - ECLIPSELINK_TARGET_DATABASE, - TARGET_DATABASE_PROPERTY); - propertyNames.put( - ECLIPSELINK_TARGET_SERVER, - TARGET_SERVER_PROPERTY); - propertyNames.put( - ECLIPSELINK_SESSION_EVENT_LISTENER, - SESSION_EVENT_LISTENER_PROPERTY); - propertyNames.put( - ECLIPSELINK_TEMPORAL_MUTABLE, - TEMPORAL_MUTABLE_PROPERTY); - } - - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - if (aspectName.equals(SESSION_NAME_PROPERTY)) { - this.sessionNameChanged(event); - } - else if (aspectName.equals(SESSIONS_XML_PROPERTY)) { - this.sessionsXmlChanged(event); - } - else if (aspectName.equals(TARGET_DATABASE_PROPERTY)) { - this.targetDatabaseChanged(event); - } - else if (aspectName.equals(TARGET_SERVER_PROPERTY)) { - this.targetServerChanged(event); - } - else if (aspectName.equals(SESSION_INCLUDE_DESCRIPTOR_QUERIES_PROPERTY)) { - this.includeDescriptorQueriesChanged(event); - } - else if (aspectName.equals(SESSION_EVENT_LISTENER_PROPERTY)) { - this.eventListenerChanged(event); - } - else if (aspectName.equals(TEMPORAL_MUTABLE_PROPERTY)) { - this.temporalMutableChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); //$NON-NLS-1$ - } - return; - } - - // ********** SessionName ********** - public String getSessionName() { - return this.sessionName; - } - - public void setSessionName(String newSessionName) { - String old = this.sessionName; - this.sessionName = newSessionName; - this.putProperty(SESSION_NAME_PROPERTY, newSessionName); - this.firePropertyChanged(SESSION_NAME_PROPERTY, old, newSessionName); - } - - private void sessionNameChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.sessionName; - this.sessionName = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultSessionName() { - return DEFAULT_SESSION_NAME; - } - - // ********** SessionsXml ********** - public String getSessionsXml() { - return this.sessionsXml; - } - - public void setSessionsXml(String newSessionsXml) { - String old = this.sessionsXml; - this.sessionsXml = newSessionsXml; - this.putProperty(SESSIONS_XML_PROPERTY, newSessionsXml); - this.firePropertyChanged(SESSIONS_XML_PROPERTY, old, newSessionsXml); - } - - private void sessionsXmlChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.sessionsXml; - this.sessionsXml = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultSessionsXml() { - return DEFAULT_SESSIONS_XML; - } - - // ********** IncludeDescriptorQueries ********** - public Boolean getIncludeDescriptorQueries() { - return this.includeDescriptorQueries; - } - - public void setIncludeDescriptorQueries(Boolean newIncludeDescriptorQueries) { - Boolean old = this.includeDescriptorQueries; - this.includeDescriptorQueries = newIncludeDescriptorQueries; - this.putProperty(SESSION_INCLUDE_DESCRIPTOR_QUERIES_PROPERTY, newIncludeDescriptorQueries); - this.firePropertyChanged(SESSION_INCLUDE_DESCRIPTOR_QUERIES_PROPERTY, old, newIncludeDescriptorQueries); - } - - private void includeDescriptorQueriesChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.includeDescriptorQueries; - this.includeDescriptorQueries = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultIncludeDescriptorQueries() { - return DEFAULT_SESSION_INCLUDE_DESCRIPTOR_QUERIES; - } - - // ********** TargetDatabase ********** - /** - * Returns TargetDatabase or custom targetDatabase class. - * - * @return EclipseLink string value for TargetDatabase enum or custom targetDatabase class - */ - public String getTargetDatabase() { - return this.targetDatabase; - } - - /** - * Sets EclipseLink targetDatabase. - * - * @param newTargetDatabase - TargetDatabase - */ - public void setTargetDatabase(TargetDatabase newTargetDatabase) { - if( newTargetDatabase == null) { - this.setTargetDatabase_((String) null); - return; - } - this.setTargetDatabase_(getEclipseLinkStringValueOf(newTargetDatabase)); - } - - /** - * Sets EclipseLink targetDatabase or custom targetDatabase. - * - * @param newTargetDatabase - - * Can be a EclipseLink TargetDatabase literal or - * a fully qualified class name of a custom targetDatabase. - */ - public void setTargetDatabase(String newTargetDatabase) { - if( newTargetDatabase == null) { - this.setTargetDatabase_((String) null); - return; - } - TargetDatabase customTargetDatabase = TargetDatabase.getTargetDatabaseFor(newTargetDatabase); - if(customTargetDatabase == null) { // custom TargetDatabase class - this.setTargetDatabase_(newTargetDatabase); - } - else { - this.setTargetDatabase(customTargetDatabase); - } - } - - private void setTargetDatabase_(String newTargetDatabase) { - String old = this.targetDatabase; - this.targetDatabase = newTargetDatabase; - this.putProperty(TARGET_DATABASE_PROPERTY, newTargetDatabase); - this.firePropertyChanged(TARGET_DATABASE_PROPERTY, old, newTargetDatabase); - } - - private void targetDatabaseChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.targetDatabase; - this.targetDatabase = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultTargetDatabase() { - return DEFAULT_TARGET_DATABASE; - } - - // ********** TargetServer ********** - /** - * Returns TargetServer or custom targetServer class. - * - * @return EclipseLink string value for TargetServer enum or custom targetServer class - */ - public String getTargetServer() { - return this.targetServer; - } - - /** - * Sets EclipseLink targetServer. - * - * @param newTargetServer - TargetServer - */ - public void setTargetServer(TargetServer newTargetServer) { - if( newTargetServer == null) { - this.setTargetServer_((String) null); - return; - } - this.setTargetServer_(getEclipseLinkStringValueOf(newTargetServer)); - } - - /** - * Sets EclipseLink targetServer or custom targetServer. - * - * @param newTargetServer - - * Can be a EclipseLink TargetServer literal or - * a fully qualified class name of a custom targetServer. - */ - public void setTargetServer(String newTargetServer) { - if( newTargetServer == null) { - this.setTargetServer_((String) null); - return; - } - TargetServer customTargetServer = TargetServer.getTargetServerFor(newTargetServer); - if(customTargetServer == null) { // custom TargetServer class - this.setTargetServer_(newTargetServer); - } - else { - this.setTargetServer(customTargetServer); - } - } - - private void setTargetServer_(String newTargetServer) { - String old = this.targetServer; - this.targetServer = newTargetServer; - this.putProperty(TARGET_SERVER_PROPERTY, newTargetServer); - this.firePropertyChanged(TARGET_SERVER_PROPERTY, old, newTargetServer); - } - - private void targetServerChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.targetServer; - this.targetServer = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultTargetServer() { - return DEFAULT_TARGET_SERVER; - } - - // ********** EventListener ********** - public String getEventListener() { - return this.eventListener; - } - - public void setEventListener(String newEventListener) { - String old = this.eventListener; - this.eventListener = newEventListener; - this.putProperty(SESSION_EVENT_LISTENER_PROPERTY, newEventListener); - this.firePropertyChanged(SESSION_EVENT_LISTENER_PROPERTY, old, newEventListener); - } - - private void eventListenerChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.eventListener; - this.eventListener = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultEventListener() { - return DEFAULT_SESSION_EVENT_LISTENER; - } - - // ********** TemporalMutable ********** - - public Boolean getTemporalMutable() { - return this.temporalMutable; - } - - public void setTemporalMutable(Boolean newTemporalMutable) { - Boolean old = this.temporalMutable; - this.temporalMutable = newTemporalMutable; - this.putProperty(TEMPORAL_MUTABLE_PROPERTY, newTemporalMutable); - this.firePropertyChanged(TEMPORAL_MUTABLE_PROPERTY, old, newTemporalMutable); - } - - private void temporalMutableChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - Boolean newValue = getBooleanValueOf(stringValue); - - Boolean old = this.temporalMutable; - this.temporalMutable = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public Boolean getDefaultTemporalMutable() { - return DEFAULT_TEMPORAL_MUTABLE; - } - -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/Options.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/Options.java deleted file mode 100644 index 3b74a255af..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/Options.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.options; - -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * Session Options - */ -public interface Options extends PersistenceUnitProperties -{ - String getDefaultSessionName(); - String getSessionName(); - void setSessionName(String newSessionName); - static final String SESSION_NAME_PROPERTY = "sessionName"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSION_NAME = "eclipselink.session-name"; //$NON-NLS-1$ - static final String DEFAULT_SESSION_NAME = ""; // no default //$NON-NLS-1$ - - String getDefaultSessionsXml(); - String getSessionsXml(); - void setSessionsXml(String newSessionsXml); - static final String SESSIONS_XML_PROPERTY = "sessionsXml"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSIONS_XML = "eclipselink.sessions-xml"; //$NON-NLS-1$ - static final String DEFAULT_SESSIONS_XML = ""; // no default //$NON-NLS-1$ - - Boolean getDefaultIncludeDescriptorQueries(); - Boolean getIncludeDescriptorQueries(); - void setIncludeDescriptorQueries(Boolean newIncludeDescriptorQueries); - static final String SESSION_INCLUDE_DESCRIPTOR_QUERIES_PROPERTY = "includeDescriptorQueriesy"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSION_INCLUDE_DESCRIPTOR_QUERIES = "eclipselink.session.include.descriptor.queries"; //$NON-NLS-1$ - static final Boolean DEFAULT_SESSION_INCLUDE_DESCRIPTOR_QUERIES = Boolean.TRUE; - - String getDefaultTargetDatabase(); - String getTargetDatabase(); - void setTargetDatabase(String newTargetDatabase); - void setTargetDatabase(TargetDatabase newTargetDatabase); - static final String TARGET_DATABASE_PROPERTY = "targetDatabase"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_TARGET_DATABASE = "eclipselink.target-database"; //$NON-NLS-1$ - static final String DEFAULT_TARGET_DATABASE = - EclipseLinkPersistenceUnitProperties.getEclipseLinkStringValueOf(TargetDatabase.auto); - - String getDefaultTargetServer(); - String getTargetServer(); - void setTargetServer(String newTargetServer); - void setTargetServer(TargetServer newTargetServer); - static final String TARGET_SERVER_PROPERTY = "targetServer"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_TARGET_SERVER = "eclipselink.target-server"; //$NON-NLS-1$ - static final String DEFAULT_TARGET_SERVER = - EclipseLinkPersistenceUnitProperties.getEclipseLinkStringValueOf(TargetServer.none); - - String getDefaultEventListener(); - String getEventListener(); - void setEventListener(String newEventListener); - static final String SESSION_EVENT_LISTENER_PROPERTY = "eventListener"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_SESSION_EVENT_LISTENER = "eclipselink.session-event-listener"; //$NON-NLS-1$ - static final String DEFAULT_SESSION_EVENT_LISTENER = null; // no default - String ECLIPSELINK_EVENT_LISTENER_CLASS_NAME = "org.eclipse.persistence.sessions.SessionEventListener"; //$NON-NLS-1$ - - Boolean getDefaultTemporalMutable(); - Boolean getTemporalMutable(); - void setTemporalMutable(Boolean temporalMutable); - static final String TEMPORAL_MUTABLE_PROPERTY = "temporalMutable"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_TEMPORAL_MUTABLE = "eclipselink.temporal.mutable"; //$NON-NLS-1$ - static final Boolean DEFAULT_TEMPORAL_MUTABLE = Boolean.FALSE; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetDatabase.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetDatabase.java deleted file mode 100644 index 9b7c64ee73..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetDatabase.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.options; - -/** - * TargetDatabase - */ -public enum TargetDatabase { - attunity, - auto, - cloudscape, - database, - db2, - db2mainframe, - dbase, - derby, - hsql, - informix, - javadb, - mysql, - oracle, - oracle11, - oracle10, - oracle9, - oracle8, - pointbase, - postgresql, - sqlanywhere, - sqlserver, - sybase, - timesten; - - // EclipseLink value string - static final String ATTUNITY = "Attunity"; - static final String AUTO = "Auto"; - static final String CLOUDSCAPE = "Cloudscape"; - static final String DATABASE = "Database"; - static final String DB2 = "DB2"; - static final String DB2MAINFRAME = "DB2Mainframe"; - static final String DBASE = "DBase"; - static final String DERBY = "Derby"; - static final String HSQL = "HSQL"; - static final String INFORMIX = "Informix"; - static final String JAVADB = "JavaDB"; - static final String MYSQL = "MySQL"; - static final String ORACLE = "Oracle"; - static final String ORACLE11 = "Oracle11"; - static final String ORACLE10 = "Oracle10g"; - static final String ORACLE9 = "Oracle9i"; - static final String ORACLE8 = "Oracle8i"; - static final String POINTBASE = "PointBase"; - static final String POSTGRESQL = "PostgreSQL"; - static final String SQLANYWHERE = "SQLAnywhere"; - static final String SQLSERVER = "SQLServer"; - static final String SYBASE = "Sybase"; - static final String TIMESTEN = "TimesTen"; - - /** - * Return the TargetDatabase value corresponding to the given literal. - */ - public static TargetDatabase getTargetDatabaseFor(String literal) { - - for( TargetDatabase targetDatabase : TargetDatabase.values()) { - if(targetDatabase.toString().equals(literal)) { - return targetDatabase; - } - } - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetServer.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetServer.java deleted file mode 100644 index e0ea2a033d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/options/TargetServer.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.options; - -/** - * TargetServer - */ -public enum TargetServer { - none, - oc4j, - sunas9, - websphere, - websphere_6_1, - weblogic, - weblogic_9, - weblogic_10, - jboss; - - // EclipseLink value string - static final String NONE = "None"; - static final String OC4J = "OC4J"; - static final String SUNAS9 = "SunAS9"; - static final String WEBSPHERE = "WebSphere"; - static final String WEBSPHERE_6_1 = "WebSphere_6_1"; - static final String WEBLOGIC = "WebLogic"; - static final String WEBLOGIC_9 = "WebLogic_9"; - static final String WEBLOGIC_10 = "WebLogic_10"; - static final String JBOSS = "JBoss"; - - /** - * Return the TargetServer value corresponding to the given literal. - */ - public static TargetServer getTargetServerFor(String literal) { - - for( TargetServer targetServer : TargetServer.values()) { - if(targetServer.toString().equals(literal)) { - return targetServer; - } - } - return null; - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/DdlGenerationType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/DdlGenerationType.java deleted file mode 100644 index 6abdfc3f83..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/DdlGenerationType.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation; - -/** - * DdlGenerationType - */ -public enum DdlGenerationType { - none, - create_tables, - drop_and_create_tables; - - // EclipseLink value string - public static final String NONE = "none"; - public static final String CREATE_TABLES = "create-tables"; - public static final String DROP_AND_CREATE_TABLES = "drop-and-create-tables"; -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/EclipseLinkSchemaGeneration.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/EclipseLinkSchemaGeneration.java deleted file mode 100644 index 24d4ef042f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/EclipseLinkSchemaGeneration.java +++ /dev/null @@ -1,220 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation; - -import java.util.Map; -import org.eclipse.jpt.core.context.persistence.PersistenceUnit; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.EclipseLinkPersistenceUnitProperties; -import org.eclipse.jpt.utility.model.event.PropertyChangeEvent; -import org.eclipse.jpt.utility.model.value.ListValueModel; - -/** - * EclipseLinkSchemaGeneration encapsulates EclipseLink SchemaGeneration - * properties. - */ -public class EclipseLinkSchemaGeneration - extends EclipseLinkPersistenceUnitProperties implements SchemaGeneration -{ - // ********** EclipseLink properties ********** - - private OutputMode outputMode; - private DdlGenerationType ddlGenerationType; - private String createFileName; - private String dropFileName; - private String applicationLocation; - - // ********** constructors/initialization ********** - - public EclipseLinkSchemaGeneration(PersistenceUnit parent, ListValueModel<PersistenceUnit.Property> propertyListAdapter) { - super(parent, propertyListAdapter); - } - - /** - * Initializes properties with values from the persistence unit. - */ - @Override - protected void initializeProperties() { - this.outputMode = - this.getEnumValue(ECLIPSELINK_DDL_GENERATION_OUTPUT_MODE, OutputMode.values()); - this.ddlGenerationType = - this.getEnumValue(ECLIPSELINK_DDL_GENERATION_TYPE, DdlGenerationType.values()); - this.createFileName = - this.getStringValue(ECLIPSELINK_CREATE_FILE_NAME); - this.dropFileName = - this.getStringValue(ECLIPSELINK_DROP_FILE_NAME); - this.applicationLocation = - this.getStringValue(ECLIPSELINK_APPLICATION_LOCATION); - } - - /** - * Adds property names key/value pairs, where: key = EclipseLink property - * key; value = property id - */ - @Override - protected void addPropertyNames(Map<String, String> propertyNames) { - propertyNames.put( - ECLIPSELINK_DDL_GENERATION_OUTPUT_MODE, - OUTPUT_MODE_PROPERTY); - propertyNames.put( - ECLIPSELINK_DDL_GENERATION_TYPE, - DDL_GENERATION_TYPE_PROPERTY); - propertyNames.put( - ECLIPSELINK_CREATE_FILE_NAME, - CREATE_FILE_NAME_PROPERTY); - propertyNames.put( - ECLIPSELINK_DROP_FILE_NAME, - DROP_FILE_NAME_PROPERTY); - propertyNames.put( - ECLIPSELINK_APPLICATION_LOCATION, - APPLICATION_LOCATION_PROPERTY); - } - - // ********** behavior ********** - public void propertyChanged(PropertyChangeEvent event) { - String aspectName = event.getAspectName(); - - if (aspectName.equals(OUTPUT_MODE_PROPERTY)) { - this.outputModeChanged(event); - } - else if (aspectName.equals(DDL_GENERATION_TYPE_PROPERTY)) { - this.ddlGenerationTypeChanged(event); - } - else if (aspectName.equals(CREATE_FILE_NAME_PROPERTY)) { - this.createFileNameChanged(event); - } - else if (aspectName.equals(DROP_FILE_NAME_PROPERTY)) { - this.dropFileNameChanged(event); - } - else if (aspectName.equals(APPLICATION_LOCATION_PROPERTY)) { - this.applicationLocationChanged(event); - } - else { - throw new IllegalArgumentException("Illegal event received - property not applicable: " + aspectName); - } - return; - } - - // ********** DdlGenerationType ********** - public DdlGenerationType getDdlGenerationType() { - return this.ddlGenerationType; - } - - public void setDdlGenerationType(DdlGenerationType newDdlGenType) { - DdlGenerationType old = this.ddlGenerationType; - this.ddlGenerationType = newDdlGenType; - this.putProperty(DDL_GENERATION_TYPE_PROPERTY, newDdlGenType); - this.firePropertyChanged(DDL_GENERATION_TYPE_PROPERTY, old, newDdlGenType); - } - - private void ddlGenerationTypeChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - DdlGenerationType newValue = getEnumValueOf(stringValue, DdlGenerationType.values()); - DdlGenerationType old = this.ddlGenerationType; - this.ddlGenerationType = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public DdlGenerationType getDefaultDdlGenerationType() { - return DEFAULT_SCHEMA_GENERATION_DDL_GENERATION_TYPE; - } - - // ********** OutputMode ********** - public OutputMode getOutputMode() { - return this.outputMode; - } - - public void setOutputMode(OutputMode newOutputMode) { - OutputMode old = this.outputMode; - this.outputMode = newOutputMode; - this.putProperty(OUTPUT_MODE_PROPERTY, newOutputMode); - this.firePropertyChanged(OUTPUT_MODE_PROPERTY, old, newOutputMode); - } - - private void outputModeChanged(PropertyChangeEvent event) { - String stringValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - OutputMode newValue = getEnumValueOf(stringValue, OutputMode.values()); - OutputMode old = this.outputMode; - this.outputMode = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public OutputMode getDefaultOutputMode() { - return DEFAULT_SCHEMA_GENERATION_OUTPUT_MODE; - } - - // ********** CreateFileName ********** - public String getCreateFileName() { - return this.createFileName; - } - - public void setCreateFileName(String newCreateFileName) { - String old = this.createFileName; - this.createFileName = newCreateFileName; - this.putProperty(CREATE_FILE_NAME_PROPERTY, newCreateFileName); - this.firePropertyChanged(CREATE_FILE_NAME_PROPERTY, old, newCreateFileName); - } - - private void createFileNameChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.createFileName; - this.createFileName = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultCreateFileName() { - return DEFAULT_SCHEMA_GENERATION_CREATE_FILE_NAME; - } - - // ********** dropFileName ********** - public String getDropFileName() { - return this.dropFileName; - } - - public void setDropFileName(String newDropFileName) { - String old = this.dropFileName; - this.dropFileName = newDropFileName; - this.putProperty(DROP_FILE_NAME_PROPERTY, newDropFileName); - this.firePropertyChanged(DROP_FILE_NAME_PROPERTY, old, newDropFileName); - } - - private void dropFileNameChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.dropFileName; - this.dropFileName = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultDropFileName() { - return DEFAULT_SCHEMA_GENERATION_DROP_FILE_NAME; - } - - // ********** applicationLocation ********** - public String getApplicationLocation() { - return this.applicationLocation; - } - - public void setApplicationLocation(String newApplicationLocation) { - String old = this.applicationLocation; - this.applicationLocation = newApplicationLocation; - this.putProperty(APPLICATION_LOCATION_PROPERTY, newApplicationLocation); - this.firePropertyChanged(APPLICATION_LOCATION_PROPERTY, old, newApplicationLocation); - } - - private void applicationLocationChanged(PropertyChangeEvent event) { - String newValue = (event.getNewValue() == null) ? null : ((PersistenceUnit.Property) event.getNewValue()).getValue(); - String old = this.applicationLocation; - this.applicationLocation = newValue; - this.firePropertyChanged(event.getAspectName(), old, newValue); - } - - public String getDefaultApplicationLocation() { - return DEFAULT_SCHEMA_GENERATION_APPLICATION_LOCATION; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/OutputMode.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/OutputMode.java deleted file mode 100644 index a8617da839..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/OutputMode.java +++ /dev/null @@ -1,24 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation; - -/** - * OutputMode - */ -public enum OutputMode { - both, - sql_script, - database; - - // EclipseLink value string - public static final String BOTH = "both"; - public static final String DATABASE = "database"; - public static final String SQL_SCRIPT = "sql-script"; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/SchemaGeneration.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/SchemaGeneration.java deleted file mode 100644 index 71604ba7e9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/context/persistence/schema/generation/SchemaGeneration.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation; - -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.PersistenceUnitProperties; - -/** - * SchemaGeneration - */ -public interface SchemaGeneration extends PersistenceUnitProperties -{ - DdlGenerationType getDefaultDdlGenerationType(); - DdlGenerationType getDdlGenerationType(); - void setDdlGenerationType(DdlGenerationType ddlGenerationType); - static final String DDL_GENERATION_TYPE_PROPERTY = "ddlGenerationType"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_DDL_GENERATION_TYPE = "eclipselink.ddl-generation"; //$NON-NLS-1$ - static final DdlGenerationType DEFAULT_SCHEMA_GENERATION_DDL_GENERATION_TYPE = DdlGenerationType.none; - - OutputMode getDefaultOutputMode(); - OutputMode getOutputMode(); - void setOutputMode(OutputMode outputMode); // put - static final String OUTPUT_MODE_PROPERTY = "outputMode"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_DDL_GENERATION_OUTPUT_MODE = "eclipselink.ddl-generation.output-mode"; //$NON-NLS-1$ - static final OutputMode DEFAULT_SCHEMA_GENERATION_OUTPUT_MODE = null; // No Default - - String getDefaultCreateFileName(); - String getCreateFileName(); - void setCreateFileName(String createFileName); - static final String CREATE_FILE_NAME_PROPERTY = "createFileName"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_CREATE_FILE_NAME = "eclipselink.create-ddl-jdbc-file-name"; //$NON-NLS-1$ - static final String DEFAULT_SCHEMA_GENERATION_CREATE_FILE_NAME = "createDDL.jdbc"; //$NON-NLS-1$ - - String getDefaultDropFileName(); - String getDropFileName(); - void setDropFileName(String dropFileName); - static final String DROP_FILE_NAME_PROPERTY = "dropFileName"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_DROP_FILE_NAME = "eclipselink.drop-ddl-jdbc-file-name"; //$NON-NLS-1$ - static final String DEFAULT_SCHEMA_GENERATION_DROP_FILE_NAME = "dropDDL.jdbc"; //$NON-NLS-1$ - - String getDefaultApplicationLocation(); - String getApplicationLocation(); - void setApplicationLocation(String applicationLocation); - static final String APPLICATION_LOCATION_PROPERTY = "applicationLocation"; //$NON-NLS-1$ - // EclipseLink key string - static final String ECLIPSELINK_APPLICATION_LOCATION = "eclipselink.application-location"; //$NON-NLS-1$ - static final String DEFAULT_SCHEMA_GENERATION_APPLICATION_LOCATION = "."; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/ddlgen/EclipseLinkDDLGenerator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/ddlgen/EclipseLinkDDLGenerator.java deleted file mode 100644 index 3d61e00c66..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/ddlgen/EclipseLinkDDLGenerator.java +++ /dev/null @@ -1,494 +0,0 @@ -/******************************************************************************* -* Copyright (c) 2008 Oracle. All rights reserved. -* This program and the accompanying materials are made available under the -* terms of the Eclipse Public License v1.0, which accompanies this distribution -* and is available at http://www.eclipse.org/legal/epl-v10.html. -* -* Contributors: -* Oracle - initial API and implementation -*******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.ddlgen; - -import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; -import java.util.Properties; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.IProgressMonitor; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.Status; -import org.eclipse.core.runtime.jobs.Job; -import org.eclipse.debug.core.DebugPlugin; -import org.eclipse.debug.core.ILaunch; -import org.eclipse.debug.core.ILaunchConfiguration; -import org.eclipse.debug.core.ILaunchConfigurationType; -import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy; -import org.eclipse.debug.core.ILaunchManager; -import org.eclipse.debug.core.ILaunchesListener2; -import org.eclipse.jdt.core.JavaCore; -import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants; -import org.eclipse.jdt.launching.IRuntimeClasspathEntry; -import org.eclipse.jdt.launching.IVMInstall; -import org.eclipse.jdt.launching.JavaRuntime; -import org.eclipse.jpt.core.JpaPlatform; -import org.eclipse.jpt.core.JpaProject; -import org.eclipse.jpt.core.internal.JptCoreMessages; -import org.eclipse.jpt.db.ConnectionProfile; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.connection.Connection; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.customization.Customization; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging.Logging; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.logging.LoggingLevel; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation.DdlGenerationType; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation.OutputMode; -import org.eclipse.jpt.eclipselink.core.internal.context.persistence.schema.generation.SchemaGeneration; -import org.eclipse.wst.validation.ValidationFramework; - -/** - * EclipseLinkDLLGenerator launches the EclipseLink DDL generator in a separate VM. - * For this it will create a Java Configuration named "EclipseLink" - * in the target workspace (note: the configuration will be overridden at each run). - * It will than launch the configuration created with the login information from - * the current Dali project, and passes it to EclipseLink. - * - * Pre-req: - * org.eclipse.jpt.eclipselink.core.ddlgen.jar in ECLIPSE_HOME/plugins - */ -public class EclipseLinkDDLGenerator -{ - static public String ECLIPSELINK_DDL_GEN_JAR_VERSION = "1.0.100"; //$NON-NLS-1$ - static public String LAUNCH_CONFIG_NAME = "EclipseLink"; //$NON-NLS-1$ - static public String DDL_GEN_PACKAGE_NAME = "org.eclipse.jpt.eclipselink.core.ddlgen"; //$NON-NLS-1$ - static public String ECLIPSELINK_DDL_GEN_CLASS = DDL_GEN_PACKAGE_NAME + ".Main"; //$NON-NLS-1$ - static public String ECLIPSELINK_DDL_GEN_JAR = DDL_GEN_PACKAGE_NAME + "_"; //$NON-NLS-1$ - static public String PROPERTIES_FILE_NAME = "login.properties"; //$NON-NLS-1$ - static public String ECLIPSE_HOME = "ECLIPSE_HOME"; //$NON-NLS-1$ - static public String PLUGINS_DIR = "plugins"; //$NON-NLS-1$ - private IVMInstall jre; - private ILaunchConfigurationWorkingCopy launchConfig; - private ILaunch launch; - - private String puName; - private JpaProject jpaProject; - private String projectLocation; - private boolean isDebug = false; - - // ********** constructors ********** - - public static void generate(String puName, JpaProject project, String projectLocation, IProgressMonitor monitor) { - if (puName == null || puName.length() == 0 || project == null) { - throw new NullPointerException(); - } - new EclipseLinkDDLGenerator(puName, project, projectLocation, monitor).generate(); - } - - private EclipseLinkDDLGenerator(String puName, JpaProject jpaProject, String projectLocation, IProgressMonitor monitor) { - super(); - this.puName = puName; - this.jpaProject = jpaProject; - this.projectLocation = projectLocation; - this.initialize(); - } - - // ********** Queries ********** - - protected JpaPlatform getPlatform() { - return this.jpaProject.getJpaPlatform(); - } - - protected ILaunch getLaunch() { - return this.launch; - } - - protected ILaunchManager getLaunchManager() { - return DebugPlugin.getDefault().getLaunchManager(); - } - - private IVMInstall getProjectJRE() throws CoreException { - - return JavaRuntime.getVMInstall(this.jpaProject.getJavaProject()); - } - - // ********** behavior ********** - - protected void initialize() { - try { - this.jre = this.getProjectJRE(); - if(this.jre == null) { - String message = "Could not identify the VM."; - throw new RuntimeException(message); - } - this.launchConfig = this.buildLaunchConfiguration(); - } - catch (CoreException e) { - throw new RuntimeException(e); - } - } - - protected void generate() { - this.preGenerate(); - String propertiesFile = this.projectLocation + "/" + PROPERTIES_FILE_NAME; - try { - this.initializeLaunchConfiguration(this.projectLocation, propertiesFile); - - this.saveLoginProperties(this.projectLocation, propertiesFile); - - this.launch = this.saveAndLaunchConfig(); - this.addLaunchListener(); - } - catch (CoreException e) { - throw new RuntimeException(e); - } - } - - private void initializeLaunchConfiguration(String projectLocation, String propertiesFile) throws CoreException { - - this.specifyJRE(this.jre.getName(), this.jre.getVMInstallType().getId()); - - this.specifyProject(this.jpaProject.getProject().getName()); - this.specifyMainType(ECLIPSELINK_DDL_GEN_CLASS); - - this.specifyProgramArguments(this.puName, propertiesFile); - this.specifyWorkingDir(projectLocation); - - this.specifyClasspathProperties(this.jpaProject, this.buildJdbcJarPath(), this.buildBootstrapJarPath()); - } - - private void addLaunchListener() { - - this.getLaunchManager().addLaunchListener(this.buildLaunchListener()); - } - - protected void preGenerate() { - ConnectionProfile cp = this.jpaProject.getConnectionProfile(); - if (cp != null) { - cp.disconnect(); - } - } - - protected void postGenerate() { - try { - if(! this.isDebug) { - this.removeLaunchConfiguration(LAUNCH_CONFIG_NAME); - } - } - catch ( CoreException e) { - throw new RuntimeException(e); - } - ConnectionProfile cp = this.jpaProject.getConnectionProfile(); - if (cp != null) { - cp.connect(); - } - - this.validateProject(); - } - - protected void validateProject() { - IProject project = this.jpaProject.getProject(); - ValidateJob job = new ValidateJob(project); - job.setRule(project); - job.schedule(); - } - - private IPath buildJdbcJarPath() { - return new Path(this.getJpaProjectConnectionDriverJarList()); - } - - private String getJpaProjectConnectionDriverJarList() { - ConnectionProfile cp = this.jpaProject.getConnectionProfile(); - return (cp == null) ? "" : cp.getDriverJarList(); //$NON-NLS-1$ - } - - private IPath buildBootstrapJarPath() { - - IPath path = JavaCore.getClasspathVariable(ECLIPSE_HOME).append(PLUGINS_DIR); - File eclipseHome = path.toFile(); - - List<File> result = new ArrayList<File>(); - this.findFile(ECLIPSELINK_DDL_GEN_JAR, eclipseHome, result); - - File ddlGenJarFile = result.get(0); - try { - String ddlGenJarPath = ddlGenJarFile.getCanonicalPath(); - return new Path(ddlGenJarPath); - } - catch (IOException e) { - throw new RuntimeException(e); - } - } - - private void findFile(String fileName, File directory, List<? super File> list) { - for (File file : directory.listFiles()) { - if (file.getName().startsWith(fileName)) { - list.add(file); - } - if (file.isDirectory()) { - findFile(fileName, file, list); - } - } - } - - private ILaunchesListener2 buildLaunchListener() { - return new ILaunchesListener2() { - - public void launchesTerminated(ILaunch[] launches) { - for (int i = 0; i < launches.length; i++) { - ILaunch launch = launches[i]; - if (launch.equals(EclipseLinkDDLGenerator.this.getLaunch())) { - - EclipseLinkDDLGenerator.this.postGenerate(); - return; - } - } - } - - public void launchesAdded(ILaunch[] launches) { - // not interested to this event - } - - public void launchesChanged(ILaunch[] launches) { - // not interested to this event - } - - public void launchesRemoved(ILaunch[] launches) { - // not interested to this event - } - }; - } - - // ********** launch configuration ********** - - private void specifyJRE(String jreName, String vmId) { - - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_JRE_CONTAINER_PATH, jreName); - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_JRE_CONTAINER_PATH, vmId); - } - - private void specifyProject(String projectName) { - - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, projectName); - } - - private void specifyMainType(String mainType) { - - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME, mainType); - } - - private void specifyProgramArguments(String puName, String propertiesPath) { - - StringBuffer programArguments = new StringBuffer(); - programArguments.append(this.buildPuNameArgument(puName)); - programArguments.append(this.buildPropertiesPathArgument(propertiesPath)); - programArguments.append(this.buildDebugArgument()); - - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROGRAM_ARGUMENTS, programArguments.toString()); - } - - private void specifyClasspathProperties(JpaProject project, IPath jdbcJar, IPath bootstrapJar) throws CoreException { - // DDL_GEN jar - IRuntimeClasspathEntry bootstrapEntry = JavaRuntime.newArchiveRuntimeClasspathEntry(bootstrapJar); - bootstrapEntry.setClasspathProperty(IRuntimeClasspathEntry.USER_CLASSES); - // Default Project classpath - IRuntimeClasspathEntry defaultEntry = JavaRuntime.newDefaultProjectClasspathEntry(project.getJavaProject()); - defaultEntry.setClasspathProperty(IRuntimeClasspathEntry.USER_CLASSES); - // JDBC jar - IRuntimeClasspathEntry jdbcEntry = JavaRuntime.newArchiveRuntimeClasspathEntry(jdbcJar); - jdbcEntry.setClasspathProperty(IRuntimeClasspathEntry.USER_CLASSES); - // System Library - IPath systemLibsPath = new Path(JavaRuntime.JRE_CONTAINER); - IRuntimeClasspathEntry systemLibsEntry = JavaRuntime.newRuntimeContainerClasspathEntry(systemLibsPath, IRuntimeClasspathEntry.STANDARD_CLASSES); - - List<String> classpath = new ArrayList<String>(); - classpath.add(bootstrapEntry.getMemento()); - classpath.add(defaultEntry.getMemento()); - classpath.add(jdbcEntry.getMemento()); - classpath.add(systemLibsEntry.getMemento()); - - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_CLASSPATH, classpath); - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_DEFAULT_CLASSPATH, false); - } - - private void specifyWorkingDir(String projectLocation) { - - File workingDir = new Path(projectLocation).toFile(); - this.launchConfig.setAttribute(IJavaLaunchConfigurationConstants.ATTR_WORKING_DIRECTORY, workingDir.getAbsolutePath()); - } - - private ILaunch saveAndLaunchConfig() throws CoreException { - ILaunchConfiguration configuration = this.launchConfig.doSave(); - - return configuration.launch(ILaunchManager.RUN_MODE, new NullProgressMonitor()); - } - - private ILaunchConfigurationWorkingCopy buildLaunchConfiguration() throws CoreException { - ILaunchConfigurationWorkingCopy launchConfig = null; - this.removeLaunchConfiguration( LAUNCH_CONFIG_NAME); - - ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager(); - ILaunchConfigurationType type = manager.getLaunchConfigurationType(IJavaLaunchConfigurationConstants.ID_JAVA_APPLICATION); - - launchConfig = type.newInstance(null, LAUNCH_CONFIG_NAME); - return launchConfig; - } - - private void removeLaunchConfiguration(String launchConfigurationName) throws CoreException { - - ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager(); - ILaunchConfigurationType type = manager.getLaunchConfigurationType(IJavaLaunchConfigurationConstants.ID_JAVA_APPLICATION); - - ILaunchConfiguration[] configurations = manager.getLaunchConfigurations(type); - for (int i = 0; i < configurations.length; i++) { - ILaunchConfiguration configuration = configurations[i]; - if (configuration.getName().equals(launchConfigurationName)) { - configuration.delete(); - break; - } - } - } - - // ********** EclipseLink properties ********** - - private void buildProjectLocationProperty(Properties properties, String location) { - this.putProperty(properties, - SchemaGeneration.ECLIPSELINK_APPLICATION_LOCATION, - location); - } - - private void buildDDLModeProperties(Properties properties) { - this.putProperty(properties, - SchemaGeneration.ECLIPSELINK_DDL_GENERATION_TYPE, - DdlGenerationType.DROP_AND_CREATE_TABLES); - this.putProperty(properties, - SchemaGeneration.ECLIPSELINK_DDL_GENERATION_OUTPUT_MODE, - OutputMode.DATABASE); - } - - private void buildConnectionProperties(Properties properties) { - ConnectionProfile cp = this.jpaProject.getConnectionProfile(); - - this.putProperty(properties, - Connection.ECLIPSELINK_BIND_PARAMETERS, - "false"); - this.putProperty(properties, - Connection.ECLIPSELINK_DRIVER, - (cp == null) ? "" : cp.getDriverClassName()); - this.putProperty(properties, - Connection.ECLIPSELINK_URL, - (cp == null) ? "" : cp.getURL()); - this.putProperty(properties, - Connection.ECLIPSELINK_USER, - (cp == null) ? "" : cp.getUserName()); - this.putProperty(properties, - Connection.ECLIPSELINK_PASSWORD, - (cp == null) ? "" : cp.getUserPassword()); - } - - private void buildConnectionPoolingProperties(Properties properties) { - this.putProperty(properties, - Connection.ECLIPSELINK_READ_CONNECTIONS_SHARED, - "true"); - } - - private void buildLoggingProperties(Properties properties) { - this.putProperty(properties, - Logging.ECLIPSELINK_LEVEL, - LoggingLevel.FINE); - this.putProperty(properties, - Logging.ECLIPSELINK_TIMESTAMP, - "false"); - this.putProperty(properties, - Logging.ECLIPSELINK_THREAD, - "false"); - this.putProperty(properties, - Logging.ECLIPSELINK_SESSION, - "false"); - this.putProperty(properties, - Logging.ECLIPSELINK_EXCEPTIONS, - "true"); - } - - private void buildCustomizationProperties(Properties properties) { - this.putProperty(properties, - Customization.ECLIPSELINK_THROW_EXCEPTIONS, - "true"); - } - - private void putProperty(Properties properties, String key, String value) { - properties.put(key, (value == null) ? "" : value); - } - - private void saveLoginProperties(String projectLocation, String propertiesFile) { - Properties elProperties = new Properties(); - - this.buildConnectionProperties(elProperties); - - this.buildConnectionPoolingProperties(elProperties); - - this.buildLoggingProperties(elProperties); - - this.buildCustomizationProperties(elProperties); - - this.buildDDLModeProperties(elProperties); - - this.buildProjectLocationProperty(elProperties, projectLocation); - try { - File file = new File(propertiesFile); - file.createNewFile(); - FileOutputStream stream = new FileOutputStream(file); - elProperties.store(stream, null); - stream.close(); - } - catch (Exception e) { - String message = "Error saving: " + propertiesFile; - throw new RuntimeException(message, e); - } - } - - // ********** Main arguments ********** - - private String buildPuNameArgument(String puName) { - return " -pu \"" + puName + "\""; - } - - private String buildPropertiesPathArgument(String propertiesFile) { - return " -p \"" + propertiesFile + "\""; - } - - private String buildDebugArgument() { - return (this.isDebug) ? " -debug" : ""; - } - - - /** - * Performs validation after tables have been generated - */ - private class ValidateJob extends Job - { - private IProject project; - - - public ValidateJob(IProject project) { - super(JptCoreMessages.VALIDATE_JOB); - this.project = project; - } - - - @Override - protected IStatus run(IProgressMonitor monitor) { - IStatus status = Status.OK_STATUS; - try { - ValidationFramework.getDefault().validate( - new IProject[] {this.project}, true, false, monitor); - } - catch (CoreException ce) { - status = Status.CANCEL_STATUS; - } - return status; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationDataModelProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationDataModelProvider.java deleted file mode 100644 index aca4702945..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationDataModelProvider.java +++ /dev/null @@ -1,63 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.operations; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.Path; -import org.eclipse.jpt.core.JpaProject; -import org.eclipse.jpt.core.JptCorePlugin; -import org.eclipse.jpt.core.internal.operations.OrmFileCreationDataModelProvider; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkJpaPlatformProvider; -import org.eclipse.jpt.eclipselink.core.internal.JptEclipseLinkCorePlugin; -import org.eclipse.jpt.utility.Filter; -import org.eclipse.wst.common.frameworks.datamodel.IDataModelOperation; - -public class EclipseLinkOrmFileCreationDataModelProvider extends OrmFileCreationDataModelProvider -{ - /** - * required default constructor - */ - public EclipseLinkOrmFileCreationDataModelProvider() { - super(); - } - - - @Override - public IDataModelOperation getDefaultOperation() { - return new EclipseLinkOrmFileCreationOperation(getDataModel()); - } - - @Override - public Object getDefaultProperty(String propertyName) { - if (propertyName.equals(FILE_PATH)) { - return new Path(JptEclipseLinkCorePlugin.DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH).toPortableString(); - } - return super.getDefaultProperty(propertyName); - } - - @Override - protected Filter<IProject> buildJpaIProjectsFilter() { - return new EclipseLinkJpaIProjectsFilter(); - } - - protected class EclipseLinkJpaIProjectsFilter extends JpaIProjectsFilter { - @Override - protected boolean accept_(IProject project) throws CoreException { - if (super.accept_(project)) { - JpaProject jpaProject = JptCorePlugin.getJpaProject(project); - return (jpaProject != null) && jpaProject.getJpaPlatform().getId().equals(EclipseLinkJpaPlatformProvider.ID); - } - return false; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationOperation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationOperation.java deleted file mode 100644 index 41dca0d7e7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/operations/EclipseLinkOrmFileCreationOperation.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.operations; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IFolder; -import org.eclipse.core.runtime.Path; -import org.eclipse.jpt.core.internal.operations.OrmFileCreationOperation; -import org.eclipse.jpt.core.resource.orm.AccessType; -import org.eclipse.jpt.core.resource.orm.OrmFactory; -import org.eclipse.jpt.core.resource.orm.XmlPersistenceUnitDefaults; -import org.eclipse.jpt.core.resource.orm.XmlPersistenceUnitMetadata; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.EclipseLinkOrmXmlResourceProvider; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; -import org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings; -import org.eclipse.wst.common.frameworks.datamodel.IDataModel; - -public class EclipseLinkOrmFileCreationOperation extends OrmFileCreationOperation -{ - public EclipseLinkOrmFileCreationOperation(IDataModel dataModel) { - super(dataModel); - } - - - @Override - protected void createMappingFile(IFolder folder) { - String filePath = getDataModel().getStringProperty(FILE_PATH); - IFile file = folder.getFile(new Path(filePath)); - final EclipseLinkOrmXmlResourceProvider modelProvider = - EclipseLinkOrmXmlResourceProvider.getXmlResourceProvider(file); - - modelProvider.modify(new Runnable() { - public void run() { - EclipseLinkOrmXmlResource ormResource = modelProvider.getXmlResource(); - - XmlEntityMappings entityMappings = EclipseLinkOrmFactory.eINSTANCE.createXmlEntityMappings(); - entityMappings.setVersion("1.0"); //$NON-NLS-1$ - ormResource.getContents().add(entityMappings); - - AccessType defaultAccess = (AccessType) getDataModel().getProperty(DEFAULT_ACCESS); - if (defaultAccess != null) { - XmlPersistenceUnitMetadata puMetadata = OrmFactory.eINSTANCE.createXmlPersistenceUnitMetadata(); - entityMappings.setPersistenceUnitMetadata(puMetadata); - XmlPersistenceUnitDefaults puDefaults = OrmFactory.eINSTANCE.createXmlPersistenceUnitDefaults(); - puMetadata.setPersistenceUnitDefaults(puDefaults); - puDefaults.setAccess(defaultAccess); - } - } - }); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicCollectionImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicCollectionImpl.java deleted file mode 100644 index 7c1b219557..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicCollectionImpl.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicCollectionAnnotation; - - -public class BasicCollectionImpl extends AbstractResourceAnnotation<Attribute> implements BasicCollectionAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - - protected BasicCollectionImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - public void update(CompilationUnit astRoot) { - } - - public static class BasicCollectionAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final BasicCollectionAnnotationDefinition INSTANCE = new BasicCollectionAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static BasicCollectionAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private BasicCollectionAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new BasicCollectionImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicMapImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicMapImpl.java deleted file mode 100644 index 3fd7d631ea..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/BasicMapImpl.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.BasicMapAnnotation; - - -public class BasicMapImpl extends AbstractResourceAnnotation<Attribute> implements BasicMapAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - - protected BasicMapImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - public void update(CompilationUnit astRoot) { - } - - public static class BasicMapAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final BasicMapAnnotationDefinition INSTANCE = new BasicMapAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static BasicMapAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private BasicMapAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new BasicMapImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CacheImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CacheImpl.java deleted file mode 100644 index 9347356538..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CacheImpl.java +++ /dev/null @@ -1,423 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.BooleanExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.EnumDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.MemberAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.NestedDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.NumberIntegerExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheType; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.TimeOfDayAnnotation; - - -public class CacheImpl extends AbstractResourceAnnotation<Type> implements CacheAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> typeAdapter; - private final AnnotationElementAdapter<Integer> sizeAdapter; - private final AnnotationElementAdapter<Boolean> sharedAdapter; - private final AnnotationElementAdapter<Integer> expiryAdapter; - private final AnnotationElementAdapter<Boolean> alwaysRefreshAdapter; - private final AnnotationElementAdapter<Boolean> refreshOnlyIfNewerAdapter; - private final AnnotationElementAdapter<Boolean> disableHitsAdapter; - private final AnnotationElementAdapter<String> coordinationTypeAdapter; - private final MemberAnnotationAdapter expiryTimeOfDayAdapter; - - private static final DeclarationAnnotationElementAdapter<String> TYPE_ADAPTER = buildTypeAdapter(); - private static final DeclarationAnnotationElementAdapter<Integer> SIZE_ADAPTER = buildSizeAdapter(); - private static final DeclarationAnnotationElementAdapter<Boolean> SHARED_ADAPTER = buildSharedAdapter(); - private static final DeclarationAnnotationElementAdapter<Integer> EXPIRY_ADAPTER = buildExpiryAdapter(); - private static final DeclarationAnnotationElementAdapter<Boolean> ALWAYS_REFRESH_ADAPTER = buildAlwaysRefreshAdapter(); - private static final DeclarationAnnotationElementAdapter<Boolean> REFRESH_ONLY_IF_NEWER_ADAPTER = buildRefreshOnlyIfNewerAdapter(); - private static final DeclarationAnnotationElementAdapter<Boolean> DISABLE_HITS_ADAPTER = buildDisableHitsAdapter(); - private static final DeclarationAnnotationElementAdapter<String> COORDINATION_TYPE_ADAPTER = buildCoordinationTypeAdapter(); - private static final NestedDeclarationAnnotationAdapter EXPIRY_TIME_OF_DAY_ADAPTER = buildExpiryTimeOfDayAnnotationAdapter(); - - - private CacheType type; - private Integer size; - private Boolean shared; - private Integer expiry; - private TimeOfDayAnnotation expiryTimeOfDay; - private Boolean alwaysRefresh; - private Boolean refreshOnlyIfNewer; - private Boolean disableHits; - private CacheCoordinationType coordinationType; - - protected CacheImpl(JavaResourcePersistentType parent, Type type) { - super(parent, type, DECLARATION_ANNOTATION_ADAPTER); - this.typeAdapter = new ShortCircuitAnnotationElementAdapter<String>(type, TYPE_ADAPTER); - this.sizeAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, SIZE_ADAPTER); - this.sharedAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(type, SHARED_ADAPTER); - this.expiryAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, EXPIRY_ADAPTER); - this.alwaysRefreshAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(type, ALWAYS_REFRESH_ADAPTER); - this.refreshOnlyIfNewerAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(type, REFRESH_ONLY_IF_NEWER_ADAPTER); - this.disableHitsAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(type, DISABLE_HITS_ADAPTER); - this.coordinationTypeAdapter = new ShortCircuitAnnotationElementAdapter<String>(type, COORDINATION_TYPE_ADAPTER); - this.expiryTimeOfDayAdapter = new MemberAnnotationAdapter(type, EXPIRY_TIME_OF_DAY_ADAPTER); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CacheAnnotation implementation **************** - - public CacheType getType() { - return this.type; - } - - public void setType(CacheType newType) { - if (attributeValueHasNotChanged(this.type, newType)) { - return; - } - CacheType oldType = this.type; - this.type = newType; - this.typeAdapter.setValue(CacheType.toJavaAnnotationValue(newType)); - firePropertyChanged(TYPE_PROPERTY, oldType, newType); - } - - public Integer getSize() { - return this.size; - } - - public void setSize(Integer newSize) { - if (attributeValueHasNotChanged(this.size, newSize)) { - return; - } - Integer oldSize = this.size; - this.size = newSize; - this.sizeAdapter.setValue(newSize); - firePropertyChanged(SIZE_PROPERTY, oldSize, newSize); - } - - public Boolean getShared() { - return this.shared; - } - - public void setShared(Boolean newShared) { - if (attributeValueHasNotChanged(this.shared, newShared)) { - return; - } - Boolean oldShared = this.shared; - this.shared = newShared; - this.sharedAdapter.setValue(newShared); - firePropertyChanged(SHARED_PROPERTY, oldShared, newShared); - } - - public Integer getExpiry() { - return this.expiry; - } - - public void setExpiry(Integer newExpiry) { - if (attributeValueHasNotChanged(this.expiry, newExpiry)) { - return; - } - Integer oldExpiry = this.expiry; - this.expiry = newExpiry; - this.expiryAdapter.setValue(newExpiry); - firePropertyChanged(EXPIRY_PROPERTY, oldExpiry, newExpiry); - } - - public TimeOfDayAnnotation getExpiryTimeOfDay() { - return this.expiryTimeOfDay; - } - - public TimeOfDayAnnotation addExpiryTimeOfDay() { - if (this.expiryTimeOfDay != null) { - throw new IllegalStateException("ExpiryTimeOfDay element already exists"); //$NON-NLS-1$ - } - this.expiryTimeOfDay = createTimeOfDayAnnotation(); - this.expiryTimeOfDayAdapter.newMarkerAnnotation(); - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, null, this.expiryTimeOfDay); - return this.expiryTimeOfDay; - } - - public void removeExpiryTimeOfDay() { - if (this.expiryTimeOfDay == null) { - throw new IllegalStateException("No expiryTimeOfDay element exists"); //$NON-NLS-1$ - } - this.expiryTimeOfDay = null; - this.expiryTimeOfDayAdapter.removeAnnotation(); - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, this.expiryTimeOfDay, null); - } - - protected void setExpiryTimeOfDay(TimeOfDayAnnotation newExpiryTimeOfDay) { - TimeOfDayAnnotation oldExpiryTimeOfDay = this.expiryTimeOfDay; - this.expiryTimeOfDay = newExpiryTimeOfDay; - firePropertyChanged(EXPIRY_TIME_OF_DAY_PROPERTY, oldExpiryTimeOfDay, newExpiryTimeOfDay); - } - - public Boolean getAlwaysRefresh() { - return this.alwaysRefresh; - } - - public void setAlwaysRefresh(Boolean newAlwaysRefresh) { - if (attributeValueHasNotChanged(this.alwaysRefresh, newAlwaysRefresh)) { - return; - } - Boolean oldAlwaysRefresh = this.alwaysRefresh; - this.alwaysRefresh = newAlwaysRefresh; - this.alwaysRefreshAdapter.setValue(newAlwaysRefresh); - firePropertyChanged(ALWAYS_REFRESH_PROPERTY, oldAlwaysRefresh, newAlwaysRefresh); - } - - public Boolean getRefreshOnlyIfNewer() { - return this.refreshOnlyIfNewer; - } - - public void setRefreshOnlyIfNewer(Boolean newRefreshOnlyIfNewer) { - if (attributeValueHasNotChanged(this.refreshOnlyIfNewer, newRefreshOnlyIfNewer)) { - return; - } - Boolean oldRefreshOnlyIfNewer = this.refreshOnlyIfNewer; - this.refreshOnlyIfNewer = newRefreshOnlyIfNewer; - this.refreshOnlyIfNewerAdapter.setValue(newRefreshOnlyIfNewer); - firePropertyChanged(REFRESH_ONLY_IF_NEWER_PROPERTY, oldRefreshOnlyIfNewer, newRefreshOnlyIfNewer); - } - - public Boolean getDisableHits() { - return this.disableHits; - } - - public void setDisableHits(Boolean newDisableHits) { - if (attributeValueHasNotChanged(this.disableHits, newDisableHits)) { - return; - } - Boolean oldDisableHits = this.disableHits; - this.disableHits = newDisableHits; - this.disableHitsAdapter.setValue(newDisableHits); - firePropertyChanged(DISABLE_HITS_PROPERTY, oldDisableHits, newDisableHits); - } - - public CacheCoordinationType getCoordinationType() { - return this.coordinationType; - } - - public void setCoordinationType(CacheCoordinationType newCoordinationType) { - if (attributeValueHasNotChanged(this.coordinationType, newCoordinationType)) { - return; - } - CacheCoordinationType oldCoordinationType = this.coordinationType; - this.coordinationType = newCoordinationType; - this.coordinationTypeAdapter.setValue(CacheCoordinationType.toJavaAnnotationValue(newCoordinationType)); - firePropertyChanged(TYPE_PROPERTY, oldCoordinationType, newCoordinationType); - } - - public TextRange getTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(TYPE_ADAPTER, astRoot); - } - - public TextRange getSizeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(SIZE_ADAPTER, astRoot); - } - - public TextRange getSharedTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(SHARED_ADAPTER, astRoot); - } - - public TextRange getExpiryTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(EXPIRY_ADAPTER, astRoot); - } - - public TextRange getExpiryTimeOfDayTextRange(CompilationUnit astRoot) { - return null;//TODO return this.getElementTextRange(EXPIRY_TIME_OF_DAY_ADAPTER, astRoot); - } - - public TextRange getAlwaysRefreshTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(ALWAYS_REFRESH_ADAPTER, astRoot); - } - - public TextRange getRefreshOnlyIfNewerTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(REFRESH_ONLY_IF_NEWER_ADAPTER, astRoot); - } - - public TextRange getDisablesHitsTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(DISABLE_HITS_ADAPTER, astRoot); - } - - public TextRange getCoordinationTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(COORDINATION_TYPE_ADAPTER, astRoot); - } - - public void initialize(CompilationUnit astRoot) { - this.type = this.type(astRoot); - this.size = this.size(astRoot); - this.shared = this.shared(astRoot); - this.expiry = this.expiry(astRoot); - this.initializeExpiryTimeOfDay(astRoot); - this.alwaysRefresh = this.alwaysRefresh(astRoot); - this.refreshOnlyIfNewer = this.refreshOnlyIfNewer(astRoot); - this.disableHits = this.disableHits(astRoot); - this.coordinationType = this.coordinationType(astRoot); - } - - protected void initializeExpiryTimeOfDay(CompilationUnit astRoot) { - if (this.expiryTimeOfDayAdapter.getAnnotation(astRoot) != null) { - this.expiryTimeOfDay = createTimeOfDayAnnotation(); - this.expiryTimeOfDay.initialize(astRoot); - } - } - - public void update(CompilationUnit astRoot) { - this.setType(this.type(astRoot)); - this.setSize(this.size(astRoot)); - this.setShared(this.shared(astRoot)); - this.setExpiry(this.expiry(astRoot)); - this.updateExpiryTimeOfDay(astRoot); - this.setAlwaysRefresh(this.alwaysRefresh(astRoot)); - this.setRefreshOnlyIfNewer(this.refreshOnlyIfNewer(astRoot)); - this.setDisableHits(this.disableHits(astRoot)); - this.setCoordinationType(this.coordinationType(astRoot)); - } - - protected void updateExpiryTimeOfDay(CompilationUnit astRoot) { - if (this.expiryTimeOfDayAdapter.getAnnotation(astRoot) == null) { - this.setExpiryTimeOfDay(null); - } - else { - if (getExpiryTimeOfDay() != null) { - getExpiryTimeOfDay().update(astRoot); - } - else { - TimeOfDayAnnotation expiryTimeOfDay = createTimeOfDayAnnotation(); - expiryTimeOfDay.initialize(astRoot); - setExpiryTimeOfDay(expiryTimeOfDay); - } - } - } - - protected CacheType type(CompilationUnit astRoot) { - return CacheType.fromJavaAnnotationValue(this.typeAdapter.getValue(astRoot)); - } - - protected Integer size(CompilationUnit astRoot) { - return this.sizeAdapter.getValue(astRoot); - } - - protected Boolean shared(CompilationUnit astRoot) { - return this.sharedAdapter.getValue(astRoot); - } - - protected Integer expiry(CompilationUnit astRoot) { - return this.expiryAdapter.getValue(astRoot); - } - - protected TimeOfDayAnnotation createTimeOfDayAnnotation() { - return new TimeOfDayImpl(this, getMember(), EXPIRY_TIME_OF_DAY_ADAPTER); - } - - protected Boolean alwaysRefresh(CompilationUnit astRoot) { - return this.alwaysRefreshAdapter.getValue(astRoot); - } - - protected Boolean refreshOnlyIfNewer(CompilationUnit astRoot) { - return this.refreshOnlyIfNewerAdapter.getValue(astRoot); - } - - protected Boolean disableHits(CompilationUnit astRoot) { - return this.disableHitsAdapter.getValue(astRoot); - } - - protected CacheCoordinationType coordinationType(CompilationUnit astRoot) { - return CacheCoordinationType.fromJavaAnnotationValue(this.coordinationTypeAdapter.getValue(astRoot)); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<String> buildTypeAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__TYPE); - } - - private static DeclarationAnnotationElementAdapter<Integer> buildSizeAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__SIZE, NumberIntegerExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Boolean> buildSharedAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__SHARED, BooleanExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Integer> buildExpiryAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__EXPIRY, NumberIntegerExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Boolean> buildAlwaysRefreshAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__ALWAYS_REFRESH, BooleanExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Boolean> buildRefreshOnlyIfNewerAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__REFRESH_ONLY_IF_NEWER, BooleanExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Boolean> buildDisableHitsAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__DISABLE_HITS, BooleanExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildCoordinationTypeAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__COORDINATION_TYPE); - } - - private static NestedDeclarationAnnotationAdapter buildExpiryTimeOfDayAnnotationAdapter() { - return new NestedDeclarationAnnotationAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CACHE__EXPIRY_TIME_OF_DAY, EclipseLinkJPA.TIME_OF_DAY); - } - - public static class CacheAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final CacheAnnotationDefinition INSTANCE = new CacheAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static CacheAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private CacheAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new CacheImpl((JavaResourcePersistentType) parent, (Type) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return new NullCacheAnnotation((JavaResourcePersistentType) parent); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ChangeTrackingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ChangeTrackingImpl.java deleted file mode 100644 index 8a17d8eed4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ChangeTrackingImpl.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.EnumDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ChangeTrackingType; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; - - -public class ChangeTrackingImpl extends AbstractResourceAnnotation<Type> implements ChangeTrackingAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> VALUE_ADAPTER = buildValueAdapter(); - - - private ChangeTrackingType value; - - protected ChangeTrackingImpl(JavaResourcePersistentType parent, Type type) { - super(parent, type, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<String>(type, VALUE_ADAPTER); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CacheAnnotation implementation **************** - - public ChangeTrackingType getValue() { - return this.value; - } - - public void setValue(ChangeTrackingType newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - ChangeTrackingType oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(ChangeTrackingType.toJavaAnnotationValue(newValue)); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected ChangeTrackingType value(CompilationUnit astRoot) { - return ChangeTrackingType.fromJavaAnnotationValue(this.valueAdapter.getValue(astRoot)); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<String> buildValueAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CHANGE_TRACKING__VALUE, false); - } - - public static class ChangeTrackingAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ChangeTrackingAnnotationDefinition INSTANCE = new ChangeTrackingAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ChangeTrackingAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ChangeTrackingAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ChangeTrackingImpl((JavaResourcePersistentType) parent, (Type) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConversionValueImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConversionValueImpl.java deleted file mode 100644 index fb09fb8f15..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConversionValueImpl.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.MemberIndexedAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.NestedIndexedDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.resource.java.NestableAnnotation; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.IndexedAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.IndexedDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.ConversionValueAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.NestableConversionValue; -import org.eclipse.jpt.eclipselink.core.resource.java.ObjectTypeConverterAnnotation; - - -public class ConversionValueImpl extends AbstractResourceAnnotation<Member> implements ConversionValueAnnotation, NestableConversionValue -{ - // hold this so we can get the 'dataValue' text range - private final DeclarationAnnotationElementAdapter<String> dataValueDeclarationAdapter; - // hold this so we can get the 'objectValue' text range - private final DeclarationAnnotationElementAdapter<String> objectValueDeclarationAdapter; - - private final AnnotationElementAdapter<String> dataValueAdapter; - private final AnnotationElementAdapter<String> objectValueAdapter; - - - private String dataValue; - private String objectValue; - - public ConversionValueImpl(ObjectTypeConverterAnnotation parent, Member member, IndexedDeclarationAnnotationAdapter idaa) { - super(parent, member, idaa, new MemberIndexedAnnotationAdapter(member, idaa)); - this.dataValueDeclarationAdapter = this.dataValueAdapter(idaa); - this.dataValueAdapter = this.buildAdapter(this.dataValueDeclarationAdapter); - this.objectValueDeclarationAdapter = this.objectValueAdapter(idaa); - this.objectValueAdapter = this.buildAdapter(this.objectValueDeclarationAdapter); - } - - // ********** initialization ********** - protected AnnotationElementAdapter<String> buildAdapter(DeclarationAnnotationElementAdapter<String> daea) { - return new ShortCircuitAnnotationElementAdapter<String>(getMember(), daea); - } - - protected DeclarationAnnotationElementAdapter<String> dataValueAdapter(DeclarationAnnotationAdapter daa) { - return ConversionDeclarationAnnotationElementAdapter.forStrings(daa, EclipseLinkJPA.CONVERSION_VALUE__DATA_VALUE, false); - } - - protected DeclarationAnnotationElementAdapter<String> objectValueAdapter(DeclarationAnnotationAdapter daa) { - return ConversionDeclarationAnnotationElementAdapter.forStrings(daa, EclipseLinkJPA.CONVERSION_VALUE__OBJECT_VALUE, false); - } - - public void initialize(CompilationUnit astRoot) { - this.dataValue = this.dataValue(astRoot); - this.objectValue = this.objectValue(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - @Override - public IndexedAnnotationAdapter getAnnotationAdapter() { - return (IndexedAnnotationAdapter) super.getAnnotationAdapter(); - } - - //*************** ConversionValue implementation **************** - public String getDataValue() { - return this.dataValue; - } - - public void setDataValue(String newDataValue) { - if (attributeValueHasNotChanged(this.dataValue, newDataValue)) { - return; - } - String oldDataValue = this.dataValue; - this.dataValue = newDataValue; - this.dataValueAdapter.setValue(newDataValue); - firePropertyChanged(DATA_VALUE_PROPERTY, oldDataValue, newDataValue); - } - - public String getObjectValue() { - return this.objectValue; - } - - public void setObjectValue(String newObjectValue) { - if (attributeValueHasNotChanged(this.objectValue, newObjectValue)) { - return; - } - String oldObjectValue = this.objectValue; - this.objectValue = newObjectValue; - this.objectValueAdapter.setValue(newObjectValue); - firePropertyChanged(OBJECT_VALUE_PROPERTY, oldObjectValue, newObjectValue); - } - - public TextRange getDataValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.dataValueDeclarationAdapter, astRoot); - } - - public TextRange getObjectValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.objectValueDeclarationAdapter, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setDataValue(this.dataValue(astRoot)); - this.setObjectValue(this.objectValue(astRoot)); - } - - protected String dataValue(CompilationUnit astRoot) { - return this.dataValueAdapter.getValue(astRoot); - } - - protected String objectValue(CompilationUnit astRoot) { - return this.objectValueAdapter.getValue(astRoot); - } - - //************ NestableAnnotation implementation - public void moveAnnotation(int newIndex) { - getAnnotationAdapter().moveAnnotation(newIndex); - } - - public void initializeFrom(NestableAnnotation oldAnnotation) { - ConversionValueAnnotation oldConversionValue = (ConversionValueAnnotation) oldAnnotation; - setDataValue(oldConversionValue.getDataValue()); - setObjectValue(oldConversionValue.getObjectValue()); - } - - // ********** static methods ********** - - static ConversionValueImpl createConversionValue(ObjectTypeConverterAnnotation parent, Member member, DeclarationAnnotationAdapter daa, int index) { - return new ConversionValueImpl(parent, member, buildConversionValueAnnotationAdapter(daa, index)); - } - - private static IndexedDeclarationAnnotationAdapter buildConversionValueAnnotationAdapter(DeclarationAnnotationAdapter daa, int index) { - return new NestedIndexedDeclarationAnnotationAdapter(daa, EclipseLinkJPA.OBJECT_TYPE_CONVERTER__CONVERSION_VALUES, index, EclipseLinkJPA.CONVERSION_VALUE, false); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConvertImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConvertImpl.java deleted file mode 100644 index 0d146c8486..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConvertImpl.java +++ /dev/null @@ -1,121 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.StringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.ConvertAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; - - -public class ConvertImpl extends AbstractResourceAnnotation<Attribute> implements ConvertAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> VALUE_ADAPTER = buildValueAdapter(); - - - private String value; - - protected ConvertImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, VALUE_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** Convert implementation **************** - public String getValue() { - return this.value; - } - - public void setValue(String newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - String oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(newValue); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected String value(CompilationUnit astRoot) { - return this.valueAdapter.getValue(astRoot); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildValueAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CONVERT__VALUE, false, StringExpressionConverter.instance()); - } - - - public static class ConvertAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ConvertAnnotationDefinition INSTANCE = new ConvertAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ConvertAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ConvertAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ConvertImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConverterImpl.java deleted file mode 100644 index 651fd9f6ba..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ConverterImpl.java +++ /dev/null @@ -1,165 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.JDTTools; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleTypeStringExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.StringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.ConverterAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; - - -public class ConverterImpl extends AbstractResourceAnnotation<Member> implements ConverterAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> nameAdapter; - private final AnnotationElementAdapter<String> converterClassAdapter; - - private static final DeclarationAnnotationElementAdapter<String> NAME_ADAPTER = buildNameAdapter(); - private static final DeclarationAnnotationElementAdapter<String> CONVERTER_CLASS_ADAPTER = buildConverterClassAdapter(); - - - private String name; - private String converterClass; - - protected ConverterImpl(JavaResourcePersistentMember parent, Member member) { - super(parent, member, DECLARATION_ANNOTATION_ADAPTER); - this.nameAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, NAME_ADAPTER); - this.converterClassAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, CONVERTER_CLASS_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.name = this.name(astRoot); - this.converterClass = this.converterClass(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** ConverterAnnotation implementation **************** - - public boolean converterClassImplementsInterface(String interfaceName, CompilationUnit astRoot) { - if (this.converterClass == null) { - return false; - } - return JDTTools.findTypeInHierarchy(this.converterClassAdapter.getExpression(astRoot), interfaceName) != null; - } - - public String getName() { - return this.name; - } - - public void setName(String newName) { - if (attributeValueHasNotChanged(this.name, newName)) { - return; - } - String oldName = this.name; - this.name = newName; - this.nameAdapter.setValue(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - public String getConverterClass() { - return this.converterClass; - } - - public void setConverterClass(String newConverterClass) { - if (attributeValueHasNotChanged(this.converterClass, newConverterClass)) { - return; - } - String oldConverterClass = this.converterClass; - this.converterClass = newConverterClass; - this.converterClassAdapter.setValue(newConverterClass); - firePropertyChanged(CONVERTER_CLASS_PROPERTY, oldConverterClass, newConverterClass); - } - - public TextRange getNameTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(NAME_ADAPTER, astRoot); - } - - public TextRange getConverterClassTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(CONVERTER_CLASS_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setName(this.name(astRoot)); - this.setConverterClass(this.converterClass(astRoot)); - } - - protected String name(CompilationUnit astRoot) { - return this.nameAdapter.getValue(astRoot); - } - - protected String converterClass(CompilationUnit astRoot) { - return this.converterClassAdapter.getValue(astRoot); - } - - @Override - public void toString(StringBuilder sb) { - sb.append(this.name); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildNameAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CONVERTER__NAME, false, StringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildConverterClassAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CONVERTER__CONVERTER_CLASS, false, SimpleTypeStringExpressionConverter.instance()); - } - - public static class ConverterAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ConverterAnnotationDefinition INSTANCE = new ConverterAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ConverterAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ConverterAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ConverterImpl(parent, member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CustomizerImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CustomizerImpl.java deleted file mode 100644 index c8ce7e9b76..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/CustomizerImpl.java +++ /dev/null @@ -1,129 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.JDTTools; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleTypeStringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.CustomizerAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; - - -public class CustomizerImpl extends AbstractResourceAnnotation<Type> implements CustomizerAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> VALUE_ADAPTER = buildValueAdapter(); - - - private String value; - - protected CustomizerImpl(JavaResourcePersistentMember parent, Type type) { - super(parent, type, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<String>(type, VALUE_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CustomizerAnnotation implementation **************** - - public boolean customizerClassImplementsInterface(String interfaceName, CompilationUnit astRoot) { - if (this.value == null) { - return false; - } - return JDTTools.findTypeInHierarchy(this.valueAdapter.getExpression(astRoot), interfaceName) != null; - } - - public String getValue() { - return this.value; - } - - public void setValue(String newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - String oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(newValue); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected String value(CompilationUnit astRoot) { - return this.valueAdapter.getValue(astRoot); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<String> buildValueAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.CUSTOMIZER__VALUE, false, SimpleTypeStringExpressionConverter.instance()); - } - - public static class CustomizerAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final CustomizerAnnotationDefinition INSTANCE = new CustomizerAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static CustomizerAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private CustomizerAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new CustomizerImpl(parent, (Type) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ExistenceCheckingImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ExistenceCheckingImpl.java deleted file mode 100644 index 546e54b400..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ExistenceCheckingImpl.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.EnumDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.ExistenceCheckingAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.ExistenceType; - - -public class ExistenceCheckingImpl extends AbstractResourceAnnotation<Type> implements ExistenceCheckingAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> VALUE_ADAPTER = buildValueAdapter(); - - - private ExistenceType value; - - protected ExistenceCheckingImpl(JavaResourcePersistentType parent, Type type) { - super(parent, type, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<String>(type, VALUE_ADAPTER); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CacheAnnotation implementation **************** - - public ExistenceType getValue() { - return this.value; - } - - public void setValue(ExistenceType newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - ExistenceType oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(ExistenceType.toJavaAnnotationValue(newValue)); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected ExistenceType value(CompilationUnit astRoot) { - return ExistenceType.fromJavaAnnotationValue(this.valueAdapter.getValue(astRoot)); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<String> buildValueAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.EXISTENCE_CHECKING__VALUE, false); - } - - public static class ExistenceCheckingAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ExistenceCheckingAnnotationDefinition INSTANCE = new ExistenceCheckingAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ExistenceCheckingAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ExistenceCheckingAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ExistenceCheckingImpl((JavaResourcePersistentType) parent, (Type) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/JoinFetchImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/JoinFetchImpl.java deleted file mode 100644 index eb1f2d5f79..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/JoinFetchImpl.java +++ /dev/null @@ -1,123 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.EnumDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType; - - -public class JoinFetchImpl extends AbstractResourceAnnotation<Attribute> implements JoinFetchAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> VALUE_ADAPTER = buildValueAdapter(); - - - private JoinFetchType value; - - protected JoinFetchImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, VALUE_ADAPTER); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CacheAnnotation implementation **************** - - public JoinFetchType getValue() { - return this.value; - } - - public void setValue(JoinFetchType newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - JoinFetchType oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(JoinFetchType.toJavaAnnotationValue(newValue)); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected JoinFetchType value(CompilationUnit astRoot) { - return JoinFetchType.fromJavaAnnotationValue(this.valueAdapter.getValue(astRoot)); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<String> buildValueAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.JOIN_FETCH_VALUE, false); - } - - public static class JoinFetchAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final JoinFetchAnnotationDefinition INSTANCE = new JoinFetchAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static JoinFetchAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private JoinFetchAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new JoinFetchImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return new NullJoinFetchAnnotation((JavaResourcePersistentAttribute) parent); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/MutableImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/MutableImpl.java deleted file mode 100644 index 1759c4944b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/MutableImpl.java +++ /dev/null @@ -1,121 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.BooleanExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.MutableAnnotation; - - -public class MutableImpl extends AbstractResourceAnnotation<Attribute> implements MutableAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<Boolean> valueAdapter; - - private static final DeclarationAnnotationElementAdapter<Boolean> VALUE_ADAPTER = buildValueAdapter(); - - - private Boolean value; - - protected MutableImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.valueAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(attribute, VALUE_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.value = this.value(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** Mutable implementation **************** - public Boolean getValue() { - return this.value; - } - - public void setValue(Boolean newValue) { - if (attributeValueHasNotChanged(this.value, newValue)) { - return; - } - Boolean oldValue = this.value; - this.value = newValue; - this.valueAdapter.setValue(newValue); - firePropertyChanged(VALUE_PROPERTY, oldValue, newValue); - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(VALUE_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setValue(this.value(astRoot)); - } - - protected Boolean value(CompilationUnit astRoot) { - return this.valueAdapter.getValue(astRoot); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<Boolean> buildValueAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.MUTABLE__VALUE, false, BooleanExpressionConverter.instance()); - } - - - public static class MutableAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final MutableAnnotationDefinition INSTANCE = new MutableAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static MutableAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private MutableAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new MutableImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullCacheAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullCacheAnnotation.java deleted file mode 100644 index fb68500af7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullCacheAnnotation.java +++ /dev/null @@ -1,193 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractJavaResourceNode; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheCoordinationType; -import org.eclipse.jpt.eclipselink.core.resource.java.CacheType; -import org.eclipse.jpt.eclipselink.core.resource.java.TimeOfDayAnnotation; - -public class NullCacheAnnotation extends AbstractJavaResourceNode implements CacheAnnotation, Annotation -{ - protected NullCacheAnnotation(JavaResourcePersistentType parent) { - super(parent); - } - - @Override - public JavaResourcePersistentType getParent() { - return (JavaResourcePersistentType) super.getParent(); - } - - public String getAnnotationName() { - return CacheAnnotation.ANNOTATION_NAME; - } - - public void initialize(CompilationUnit astRoot) { - //null, nothing to initialize - } - - public org.eclipse.jdt.core.dom.Annotation getJdtAnnotation(CompilationUnit astRoot) { - return null; - } - - public void newAnnotation() { - throw new UnsupportedOperationException(); - } - - public void removeAnnotation() { - throw new UnsupportedOperationException(); - } - - protected CacheAnnotation createCacheResource() { - return (CacheAnnotation) getParent().addSupportingAnnotation(getAnnotationName()); - } - - public CacheType getType() { - return null; - } - - public void setType(CacheType type) { - if (type != null) { - createCacheResource().setType(type); - } - } - - public Integer getSize() { - return null; - } - - public void setSize(Integer size) { - if (size != null) { - createCacheResource().setSize(size); - } - } - - public Boolean getShared() { - return null; - } - - public void setShared(Boolean shared) { - if (shared != null) { - createCacheResource().setShared(shared); - } - } - - public Integer getExpiry() { - return null; - } - - public void setExpiry(Integer expiry) { - if (expiry != null) { - createCacheResource().setExpiry(expiry); - } - } - - public TimeOfDayAnnotation getExpiryTimeOfDay() { - return null; - } - - public TimeOfDayAnnotation addExpiryTimeOfDay() { - return createCacheResource().addExpiryTimeOfDay(); - } - - public void removeExpiryTimeOfDay() { - - } - - public Boolean getAlwaysRefresh() { - return null; - } - - public void setAlwaysRefresh(Boolean alwaysRefresh) { - if (alwaysRefresh != null) { - createCacheResource().setAlwaysRefresh(alwaysRefresh); - } - } - - public Boolean getRefreshOnlyIfNewer() { - return null; - } - - public void setRefreshOnlyIfNewer(Boolean refreshOnlyIfNewer) { - if (refreshOnlyIfNewer != null) { - createCacheResource().setRefreshOnlyIfNewer(refreshOnlyIfNewer); - } - } - - public Boolean getDisableHits() { - return null; - } - - public void setDisableHits(Boolean disableHits) { - if (disableHits != null) { - createCacheResource().setDisableHits(disableHits); - } - } - - public CacheCoordinationType getCoordinationType() { - return null; - } - - public void setCoordinationType(CacheCoordinationType coordinationType) { - if (coordinationType != null) { - createCacheResource().setCoordinationType(coordinationType); - } - } - - public TextRange getTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getTypeTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getSizeTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getSharedTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getExpiryTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getExpiryTimeOfDayTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getAlwaysRefreshTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getRefreshOnlyIfNewerTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getDisablesHitsTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getCoordinationTypeTextRange(CompilationUnit astRoot) { - return null; - } - - public void update(CompilationUnit astRoot) { - throw new UnsupportedOperationException(); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullJoinFetchAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullJoinFetchAnnotation.java deleted file mode 100644 index 53da2c52df..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullJoinFetchAnnotation.java +++ /dev/null @@ -1,79 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractJavaResourceNode; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentType; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.resource.java.ExistenceCheckingAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.JoinFetchType; - -public class NullJoinFetchAnnotation extends AbstractJavaResourceNode implements JoinFetchAnnotation, Annotation -{ - protected NullJoinFetchAnnotation(JavaResourcePersistentAttribute parent) { - super(parent); - } - - @Override - public JavaResourcePersistentType getParent() { - return (JavaResourcePersistentType) super.getParent(); - } - - public String getAnnotationName() { - return ExistenceCheckingAnnotation.ANNOTATION_NAME; - } - - public void initialize(CompilationUnit astRoot) { - //null, nothing to initialize - } - - public org.eclipse.jdt.core.dom.Annotation getJdtAnnotation(CompilationUnit astRoot) { - return null; - } - - public void newAnnotation() { - throw new UnsupportedOperationException(); - } - - public void removeAnnotation() { - throw new UnsupportedOperationException(); - } - - protected JoinFetchAnnotation createJoinFetchAnnotation() { - return (JoinFetchAnnotation) getParent().addSupportingAnnotation(getAnnotationName()); - } - - public JoinFetchType getValue() { - return null; - } - - public void setValue(JoinFetchType value) { - if (value != null) { - createJoinFetchAnnotation().setValue(value); - } - } - - public TextRange getTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getValueTextRange(CompilationUnit astRoot) { - return null; - } - - public void update(CompilationUnit astRoot) { - throw new UnsupportedOperationException(); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullTransformation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullTransformation.java deleted file mode 100644 index cd04bf925d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullTransformation.java +++ /dev/null @@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractJavaResourceNode; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.BasicAnnotation; -import org.eclipse.jpt.core.resource.java.FetchType; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.resource.java.TransformationAnnotation; - - -public class NullTransformation extends AbstractJavaResourceNode implements BasicAnnotation, Annotation -{ - protected NullTransformation(JavaResourcePersistentMember parent) { - super(parent); - } - - public void initialize(CompilationUnit astRoot) { - //null, nothing to initialize - } - - public org.eclipse.jdt.core.dom.Annotation getJdtAnnotation(CompilationUnit astRoot) { - return null; - } - - public void newAnnotation() { - throw new UnsupportedOperationException(); - } - - public void removeAnnotation() { - throw new UnsupportedOperationException(); - } - - public String getAnnotationName() { - return TransformationAnnotation.ANNOTATION_NAME; - } - - @Override - public JavaResourcePersistentMember getParent() { - return (JavaResourcePersistentMember) super.getParent(); - } - - protected TransformationAnnotation createTransformationResource() { - getParent().setMappingAnnotation(getAnnotationName()); - return (TransformationAnnotation) getParent().getMappingAnnotation(); - } - - public FetchType getFetch() { - return null; - } - - public void setFetch(FetchType fetch) { - if (fetch != null) { - createTransformationResource().setFetch(fetch); - } - } - - public Boolean getOptional() { - return null; - } - - public void setOptional(Boolean optional) { - if (optional != null) { - createTransformationResource().setOptional(optional); - } - } - - public void update(CompilationUnit astRoot) { - throw new UnsupportedOperationException(); - } - - public TextRange getTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getFetchTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getOptionalTextRange(CompilationUnit astRoot) { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullWriteTransformerColumn.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullWriteTransformerColumn.java deleted file mode 100644 index 4b88b4cb4b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/NullWriteTransformerColumn.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.NullBaseColumn; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.ColumnAnnotation; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.resource.java.WriteTransformerAnnotation; - - -public class NullWriteTransformerColumn extends NullBaseColumn implements ColumnAnnotation, Annotation -{ - public NullWriteTransformerColumn(WriteTransformerAnnotation parent) { - super(parent); - } - - @Override - public WriteTransformerAnnotation getParent() { - return (WriteTransformerAnnotation) super.getParent(); - } - - public String getAnnotationName() { - return ColumnAnnotation.ANNOTATION_NAME; - } - - @Override - protected ColumnAnnotation createResourceColumn() { - return getParent().addColumn(); - } - - public Integer getLength() { - return null; - } - - public void setLength(Integer length) { - if (length != null) { - createResourceColumn().setLength(length); - } - } - - public Integer getScale() { - return null; - } - - public void setScale(Integer scale) { - if (scale != null) { - createResourceColumn().setScale(scale); - } - } - - public Integer getPrecision() { - return null; - } - - public void setPrecision(Integer precision) { - if (precision != null) { - createResourceColumn().setPrecision(precision); - } - } - - public TextRange getScaleTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getLengthTextRange(CompilationUnit astRoot) { - return null; - } - - public TextRange getPrecisionTextRange(CompilationUnit astRoot) { - return null; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ObjectTypeConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ObjectTypeConverterImpl.java deleted file mode 100644 index a149ae9fa1..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ObjectTypeConverterImpl.java +++ /dev/null @@ -1,392 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import java.util.ArrayList; -import java.util.List; -import java.util.ListIterator; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractJavaResourceNode; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.resource.java.ContainerAnnotationTools; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.StringExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.TypeStringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.AssociationOverrideAnnotation; -import org.eclipse.jpt.core.resource.java.ContainerAnnotation; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.ConversionValueAnnotation; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.NestableConversionValue; -import org.eclipse.jpt.eclipselink.core.resource.java.ObjectTypeConverterAnnotation; -import org.eclipse.jpt.utility.internal.CollectionTools; -import org.eclipse.jpt.utility.internal.iterators.CloneListIterator; - - -public class ObjectTypeConverterImpl extends AbstractResourceAnnotation<Member> implements ObjectTypeConverterAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> nameAdapter; - private final AnnotationElementAdapter<String> dataTypeAdapter; - private final AnnotationElementAdapter<String> objectTypeAdapter; - private final AnnotationElementAdapter<String> defaultObjectValueAdapter; - - private static final DeclarationAnnotationElementAdapter<String> NAME_ADAPTER = buildNameAdapter(); - private static final DeclarationAnnotationElementAdapter<String> DATA_TYPE_ADAPTER = buildDataTypeAdapter(); - private static final DeclarationAnnotationElementAdapter<String> OBJECT_TYPE_ADAPTER = buildObjectTypeAdapter(); - private static final DeclarationAnnotationElementAdapter<String> DEFAULT_OBJECT_VALUE_ADAPTER = buildDefaultObjectValueAdapter(); - - - private String name; - private String dataType; - private String objectType; - private String defaultObjectValue; - - protected final List<NestableConversionValue> conversionValues; - private final ConversionValuesContainerAnnotation conversionValuesContainerAnnotation; - - protected ObjectTypeConverterImpl(JavaResourcePersistentMember parent, Member member) { - super(parent, member, DECLARATION_ANNOTATION_ADAPTER); - this.nameAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, NAME_ADAPTER); - this.dataTypeAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, DATA_TYPE_ADAPTER); - this.objectTypeAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, OBJECT_TYPE_ADAPTER); - this.defaultObjectValueAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, DEFAULT_OBJECT_VALUE_ADAPTER); - this.conversionValues = new ArrayList<NestableConversionValue>(); - this.conversionValuesContainerAnnotation = new ConversionValuesContainerAnnotation(); - } - - public void initialize(CompilationUnit astRoot) { - this.name = this.name(astRoot); - this.dataType = this.dataType(astRoot); - this.objectType = this.objectType(astRoot); - this.defaultObjectValue = this.defaultObjectValue(astRoot); - ContainerAnnotationTools.initializeNestedAnnotations(astRoot, this.conversionValuesContainerAnnotation); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** ObjectTypeConverter implementation **************** - public String getName() { - return this.name; - } - - public void setName(String newName) { - if (attributeValueHasNotChanged(this.name, newName)) { - return; - } - String oldName = this.name; - this.name = newName; - this.nameAdapter.setValue(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - if (attributeValueHasNotChanged(this.dataType, newDataType)) { - return; - } - String oldDataType = this.dataType; - this.dataType = newDataType; - this.dataTypeAdapter.setValue(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - if (attributeValueHasNotChanged(this.objectType, newObjectType)) { - return; - } - String oldObjectType = this.objectType; - this.objectType = newObjectType; - this.objectTypeAdapter.setValue(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - public String getDefaultObjectValue() { - return this.defaultObjectValue; - } - - public void setDefaultObjectValue(String newDefaultObjectValue) { - if (attributeValueHasNotChanged(this.defaultObjectValue, newDefaultObjectValue)) { - return; - } - String oldDefaultObjectValue = this.defaultObjectValue; - this.defaultObjectValue = newDefaultObjectValue; - this.defaultObjectValueAdapter.setValue(newDefaultObjectValue); - firePropertyChanged(DEFAULT_OBJECT_VALUE_PROPERTY, oldDefaultObjectValue, newDefaultObjectValue); - } - - public ListIterator<ConversionValueAnnotation> conversionValues() { - return new CloneListIterator<ConversionValueAnnotation>(this.conversionValues); - } - - public int conversionValuesSize() { - return this.conversionValues.size(); - } - - public NestableConversionValue conversionValueAt(int index) { - return this.conversionValues.get(index); - } - - public int indexOfConversionValue(ConversionValueAnnotation conversionValue) { - return this.conversionValues.indexOf(conversionValue); - } - - public NestableConversionValue addConversionValue(int index) { - NestableConversionValue conversionValue = (NestableConversionValue) ContainerAnnotationTools.addNestedAnnotation(index, this.conversionValuesContainerAnnotation); - fireItemAdded(AssociationOverrideAnnotation.JOIN_COLUMNS_LIST, index, conversionValue); - return conversionValue; - } - - protected void addConversionValue(int index, NestableConversionValue conversionValue) { - addItemToList(index, conversionValue, this.conversionValues, AssociationOverrideAnnotation.JOIN_COLUMNS_LIST); - } - - public void removeConversionValue(int index) { - NestableConversionValue conversionValue = this.conversionValues.get(index); - removeConversionValue(conversionValue); - conversionValue.removeAnnotation(); - ContainerAnnotationTools.synchAnnotationsAfterRemove(index, this.conversionValuesContainerAnnotation); - } - - protected void removeConversionValue(NestableConversionValue conversionValue) { - removeItemFromList(conversionValue, this.conversionValues, AssociationOverrideAnnotation.JOIN_COLUMNS_LIST); - } - - public void moveConversionValue(int targetIndex, int sourceIndex) { - moveConversionValueInternal(targetIndex, sourceIndex); - ContainerAnnotationTools.synchAnnotationsAfterMove(targetIndex, sourceIndex, this.conversionValuesContainerAnnotation); - fireItemMoved(AssociationOverrideAnnotation.JOIN_COLUMNS_LIST, targetIndex, sourceIndex); - } - - protected void moveConversionValueInternal(int targetIndex, int sourceIndex) { - CollectionTools.move(this.conversionValues, targetIndex, sourceIndex); - } - - protected NestableConversionValue createConversionValue(int index) { - return ConversionValueImpl.createConversionValue(this, getMember(), getDeclarationAnnotationAdapter(), index); - } - - - public TextRange getNameTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(NAME_ADAPTER, astRoot); - } - - public TextRange getDataTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(DATA_TYPE_ADAPTER, astRoot); - } - - public TextRange getObjectTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(OBJECT_TYPE_ADAPTER, astRoot); - } - - public TextRange getDefaultObjectValueTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(DEFAULT_OBJECT_VALUE_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setName(this.name(astRoot)); - this.setDataType(this.dataType(astRoot)); - this.setObjectType(this.objectType(astRoot)); - this.setDefaultObjectValue(this.defaultObjectValue(astRoot)); - ContainerAnnotationTools.updateNestedAnnotationsFromJava(astRoot, this.conversionValuesContainerAnnotation); - } - - protected String name(CompilationUnit astRoot) { - return this.nameAdapter.getValue(astRoot); - } - - protected String dataType(CompilationUnit astRoot) { - return this.dataTypeAdapter.getValue(astRoot); - } - - protected String objectType(CompilationUnit astRoot) { - return this.objectTypeAdapter.getValue(astRoot); - } - - protected String defaultObjectValue(CompilationUnit astRoot) { - return this.defaultObjectValueAdapter.getValue(astRoot); - } - - @Override - public void toString(StringBuilder sb) { - sb.append(this.name); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildNameAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.OBJECT_TYPE_CONVERTER__NAME, false, StringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildDataTypeAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.OBJECT_TYPE_CONVERTER__DATE_TYPE, false, TypeStringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildObjectTypeAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.OBJECT_TYPE_CONVERTER__OBJECT_TYPE, false, TypeStringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildDefaultObjectValueAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE, false, StringExpressionConverter.instance()); - } - - public static class ObjectTypeConverterAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ObjectTypeConverterAnnotationDefinition INSTANCE = new ObjectTypeConverterAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ObjectTypeConverterAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ObjectTypeConverterAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ObjectTypeConverterImpl(parent, member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - private class ConversionValuesContainerAnnotation extends AbstractJavaResourceNode - implements ContainerAnnotation<NestableConversionValue> - { - public ConversionValuesContainerAnnotation() { - super(ObjectTypeConverterImpl.this); - } - - public void initialize(CompilationUnit astRoot) { - //nothing to initialize - } - - public NestableConversionValue addInternal(int index) { - NestableConversionValue conversionValue = ObjectTypeConverterImpl.this.createConversionValue(index); - ObjectTypeConverterImpl.this.conversionValues.add(index, conversionValue); - return conversionValue; - } - - public NestableConversionValue add(int index) { - NestableConversionValue conversionValue = ObjectTypeConverterImpl.this.createConversionValue(index); - ObjectTypeConverterImpl.this.addConversionValue(index, conversionValue); - return conversionValue; - } - - public int indexOf(NestableConversionValue conversionValue) { - return ObjectTypeConverterImpl.this.indexOfConversionValue(conversionValue); - } - - public void move(int targetIndex, int sourceIndex) { - ObjectTypeConverterImpl.this.moveConversionValue(targetIndex, sourceIndex); - } - - public void moveInternal(int targetIndex, int sourceIndex) { - ObjectTypeConverterImpl.this.moveConversionValueInternal(targetIndex, sourceIndex); - } - - public NestableConversionValue nestedAnnotationAt(int index) { - return ObjectTypeConverterImpl.this.conversionValueAt(index); - } - - public ListIterator<NestableConversionValue> nestedAnnotations() { - return new CloneListIterator<NestableConversionValue>(ObjectTypeConverterImpl.this.conversionValues); - } - - public int nestedAnnotationsSize() { - return conversionValuesSize(); - } - - public void remove(int index) { - this.remove(nestedAnnotationAt(index)); - } - - public void remove(NestableConversionValue conversionValue) { - ObjectTypeConverterImpl.this.removeConversionValue(conversionValue); - } - - public String getAnnotationName() { - return ObjectTypeConverterImpl.this.getAnnotationName(); - } - - public String getNestableAnnotationName() { - return EclipseLinkJPA.CONVERSION_VALUE; - } - - public NestableConversionValue nestedAnnotationFor(org.eclipse.jdt.core.dom.Annotation jdtAnnotation) { - for (NestableConversionValue conversionValue : CollectionTools.iterable(nestedAnnotations())) { - if (jdtAnnotation == conversionValue.getJdtAnnotation((CompilationUnit) jdtAnnotation.getRoot())) { - return conversionValue; - } - } - return null; - } - - public org.eclipse.jdt.core.dom.Annotation getJdtAnnotation(CompilationUnit astRoot) { - return ObjectTypeConverterImpl.this.getJdtAnnotation(astRoot); - } - - public void newAnnotation() { - ObjectTypeConverterImpl.this.newAnnotation(); - } - - public void removeAnnotation() { - ObjectTypeConverterImpl.this.removeAnnotation(); - } - - public void update(CompilationUnit astRoot) { - ObjectTypeConverterImpl.this.update(astRoot); - } - - public TextRange getTextRange(CompilationUnit astRoot) { - return ObjectTypeConverterImpl.this.getTextRange(astRoot); - } - - public String getElementName() { - return EclipseLinkJPA.OBJECT_TYPE_CONVERTER__CONVERSION_VALUES; - } - - @Override - public void toString(StringBuilder sb) { - sb.append(this.getAnnotationName()); - } - - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/PrivateOwnedImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/PrivateOwnedImpl.java deleted file mode 100644 index 2ecaeb2c56..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/PrivateOwnedImpl.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.PrivateOwnedAnnotation; - - -public class PrivateOwnedImpl extends AbstractResourceAnnotation<Attribute> implements PrivateOwnedAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - protected PrivateOwnedImpl(JavaResourceNode parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - //nothing to initialize - } - - public void update(CompilationUnit astRoot) { - //nothing to update - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - - public static class PrivateOwnedAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final PrivateOwnedAnnotationDefinition INSTANCE = new PrivateOwnedAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static AnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private PrivateOwnedAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new PrivateOwnedImpl(parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadOnlyImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadOnlyImpl.java deleted file mode 100644 index 7a6057ced3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadOnlyImpl.java +++ /dev/null @@ -1,77 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.ReadOnlyAnnotation; - - -public class ReadOnlyImpl extends AbstractResourceAnnotation<Type> implements ReadOnlyAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - protected ReadOnlyImpl(JavaResourceNode parent, Type type) { - super(parent, type, DECLARATION_ANNOTATION_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - //nothing to initialize - } - - public void update(CompilationUnit astRoot) { - //nothing to update - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - - public static class ReadOnlyAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ReadOnlyAnnotationDefinition INSTANCE = new ReadOnlyAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static AnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ReadOnlyAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ReadOnlyImpl(parent, (Type) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadTransformerImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadTransformerImpl.java deleted file mode 100644 index 20a66c1ebf..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/ReadTransformerImpl.java +++ /dev/null @@ -1,152 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleTypeStringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.ReadTransformerAnnotation; - - -public class ReadTransformerImpl extends AbstractResourceAnnotation<Attribute> implements ReadTransformerAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> transformerClassAdapter; - private final AnnotationElementAdapter<String> methodAdapter; - - private static final DeclarationAnnotationElementAdapter<String> TRANSFORMER_CLASS_ADAPTER = buildTransformerClassAdapter(); - private static final DeclarationAnnotationElementAdapter<String> METHOD_ADAPTER = buildMethodAdapter(); - - - private String transformerClass; - private String method; - - protected ReadTransformerImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.transformerClassAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, TRANSFORMER_CLASS_ADAPTER); - this.methodAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, METHOD_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.transformerClass = this.transformerClass(astRoot); - this.method = this.method(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** ReadTransformer implementation **************** - public String getTransformerClass() { - return this.transformerClass; - } - - public void setTransformerClass(String newTransformerClass) { - if (attributeValueHasNotChanged(this.transformerClass, newTransformerClass)) { - return; - } - String oldTransformerClass = this.transformerClass; - this.transformerClass = newTransformerClass; - this.transformerClassAdapter.setValue(newTransformerClass); - firePropertyChanged(TRANSFORMER_CLASS_PROPERTY, oldTransformerClass, newTransformerClass); - } - - public String getMethod() { - return this.method; - } - - public void setMethod(String newMethod) { - if (attributeValueHasNotChanged(this.method, newMethod)) { - return; - } - String oldMethod = this.method; - this.method = newMethod; - this.methodAdapter.setValue(newMethod); - firePropertyChanged(METHOD_PROPERTY, oldMethod, newMethod); - } - - public TextRange getTransformerClassTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(TRANSFORMER_CLASS_ADAPTER, astRoot); - } - - public TextRange getMethodTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(METHOD_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setTransformerClass(this.transformerClass(astRoot)); - this.setMethod(this.method(astRoot)); - } - - protected String transformerClass(CompilationUnit astRoot) { - return this.transformerClassAdapter.getValue(astRoot); - } - - protected String method(CompilationUnit astRoot) { - return this.methodAdapter.getValue(astRoot); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildTransformerClassAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.READ_TRANSFORMER__TRANSFORMER_CLASS, false, SimpleTypeStringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildMethodAdapter() { - return ConversionDeclarationAnnotationElementAdapter.forStrings(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.READ_TRANSFORMER__METHOD, false); - } - - public static class ReadTransformerAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final ReadTransformerAnnotationDefinition INSTANCE = new ReadTransformerAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static ReadTransformerAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private ReadTransformerAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new ReadTransformerImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/StructConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/StructConverterImpl.java deleted file mode 100644 index 3f08cdcf6b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/StructConverterImpl.java +++ /dev/null @@ -1,155 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.StringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.StructConverterAnnotation; - - -public class StructConverterImpl extends AbstractResourceAnnotation<Member> implements StructConverterAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> nameAdapter; - private final AnnotationElementAdapter<String> converterAdapter; - - private static final DeclarationAnnotationElementAdapter<String> NAME_ADAPTER = buildNameAdapter(); - private static final DeclarationAnnotationElementAdapter<String> CONVERTER_ADAPTER = buildConverterAdapter(); - - - private String name; - private String converter; - - protected StructConverterImpl(JavaResourcePersistentMember parent, Member member) { - super(parent, member, DECLARATION_ANNOTATION_ADAPTER); - this.nameAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, NAME_ADAPTER); - this.converterAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, CONVERTER_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.name = this.name(astRoot); - this.converter = this.converter(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** CustomConverter implementation **************** - public String getName() { - return this.name; - } - - public void setName(String newName) { - if (attributeValueHasNotChanged(this.name, newName)) { - return; - } - String oldName = this.name; - this.name = newName; - this.nameAdapter.setValue(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - public String getConverter() { - return this.converter; - } - - public void setConverter(String newConverter) { - if (attributeValueHasNotChanged(this.converter, newConverter)) { - return; - } - String oldConverter = this.converter; - this.converter = newConverter; - this.converterAdapter.setValue(newConverter); - firePropertyChanged(CONVERTER_PROPERTY, oldConverter, newConverter); - } - - public TextRange getNameTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(NAME_ADAPTER, astRoot); - } - - public TextRange getConverterTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(CONVERTER_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setName(this.name(astRoot)); - this.setConverter(this.converter(astRoot)); - } - - protected String name(CompilationUnit astRoot) { - return this.nameAdapter.getValue(astRoot); - } - - protected String converter(CompilationUnit astRoot) { - return this.converterAdapter.getValue(astRoot); - } - - @Override - public void toString(StringBuilder sb) { - sb.append(this.name); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildNameAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.STRUCT_CONVERTER__NAME, false, StringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildConverterAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.STRUCT_CONVERTER__CONVERTER, false, StringExpressionConverter.instance()); - } - - public static class StructConverterAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final StructConverterAnnotationDefinition INSTANCE = new StructConverterAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static StructConverterAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private StructConverterAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new StructConverterImpl(parent, member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TimeOfDayImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TimeOfDayImpl.java deleted file mode 100644 index 080e85d7b8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TimeOfDayImpl.java +++ /dev/null @@ -1,183 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.NumberIntegerExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Type; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.TimeOfDayAnnotation; - - -public class TimeOfDayImpl extends AbstractResourceAnnotation<Type> implements TimeOfDayAnnotation -{ - private final AnnotationElementAdapter<Integer> hourAdapter; - private final AnnotationElementAdapter<Integer> minuteAdapter; - private final AnnotationElementAdapter<Integer> secondAdapter; - private final AnnotationElementAdapter<Integer> millisecondAdapter; - - private final DeclarationAnnotationElementAdapter<Integer> hourDeclarationAdapter; - private final DeclarationAnnotationElementAdapter<Integer> minuteDeclarationAdapter; - private final DeclarationAnnotationElementAdapter<Integer> secondDeclarationAdapter; - private final DeclarationAnnotationElementAdapter<Integer> millisecondDeclarationAdapter; - - - private Integer hour; - private Integer minute; - private Integer second; - private Integer millisecond; - - protected TimeOfDayImpl(JavaResourceNode parent, Type type, DeclarationAnnotationAdapter daa) { - super(parent, type, daa); - this.hourDeclarationAdapter = buildHourAdapter(daa); - this.hourAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, this.hourDeclarationAdapter); - this.minuteDeclarationAdapter = buildMinuteAdapter(daa); - this.minuteAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, this.minuteDeclarationAdapter); - this.secondDeclarationAdapter = buildSecondAdapter(daa); - this.secondAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, this.secondDeclarationAdapter); - this.millisecondDeclarationAdapter = buildMillisecondAdapter(daa); - this.millisecondAdapter = new ShortCircuitAnnotationElementAdapter<Integer>(type, this.millisecondDeclarationAdapter); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** TimeOfDayAnnotation implementation **************** - - public Integer getHour() { - return this.hour; - } - - public void setHour(Integer newHour) { - if (attributeValueHasNotChanged(this.hour, newHour)) { - return; - } - Integer oldHour = this.hour; - this.hour = newHour; - this.hourAdapter.setValue(newHour); - firePropertyChanged(HOUR_PROPERTY, oldHour, newHour); - } - - public Integer getMinute() { - return this.minute; - } - - public void setMinute(Integer newMinute) { - if (attributeValueHasNotChanged(this.minute, newMinute)) { - return; - } - Integer oldMinute = this.minute; - this.minute = newMinute; - this.minuteAdapter.setValue(newMinute); - firePropertyChanged(MINUTE_PROPERTY, oldMinute, newMinute); - } - - public Integer getSecond() { - return this.second; - } - - public void setSecond(Integer newSecond) { - if (attributeValueHasNotChanged(this.second, newSecond)) { - return; - } - Integer oldSecond = this.second; - this.second = newSecond; - this.secondAdapter.setValue(newSecond); - firePropertyChanged(SECOND_PROPERTY, oldSecond, newSecond); - } - - public Integer getMillisecond() { - return this.millisecond; - } - - public void setMillisecond(Integer newMillisecond) { - if (attributeValueHasNotChanged(this.millisecond, newMillisecond)) { - return; - } - Integer oldMillisecond = this.millisecond; - this.millisecond = newMillisecond; - this.millisecondAdapter.setValue(newMillisecond); - firePropertyChanged(MILLISECOND_PROPERTY, oldMillisecond, newMillisecond); - } - - public TextRange getHourTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.hourDeclarationAdapter, astRoot); - } - - public TextRange getMinuteTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.minuteDeclarationAdapter, astRoot); - } - - public TextRange getSecondTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.secondDeclarationAdapter, astRoot); - } - - public TextRange getMillisecondTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(this.millisecondDeclarationAdapter, astRoot); - } - - public void initialize(CompilationUnit astRoot) { - this.hour = this.hour(astRoot); - this.minute = this.minute(astRoot); - this.second = this.second(astRoot); - this.millisecond = this.millisecond(astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setHour(this.hour(astRoot)); - this.setMinute(this.minute(astRoot)); - this.setSecond(this.second(astRoot)); - this.setMillisecond(this.millisecond(astRoot)); - } - - protected Integer hour(CompilationUnit astRoot) { - return this.hourAdapter.getValue(astRoot); - } - - protected Integer minute(CompilationUnit astRoot) { - return this.minuteAdapter.getValue(astRoot); - } - - protected Integer second(CompilationUnit astRoot) { - return this.secondAdapter.getValue(astRoot); - } - - protected Integer millisecond(CompilationUnit astRoot) { - return this.millisecondAdapter.getValue(astRoot); - } - - // ********** static methods ********** - - private static DeclarationAnnotationElementAdapter<Integer> buildHourAdapter(DeclarationAnnotationAdapter daa) { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(daa, EclipseLinkJPA.TIME_OF_DAY__HOUR, false, NumberIntegerExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Integer> buildMinuteAdapter(DeclarationAnnotationAdapter daa) { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(daa, EclipseLinkJPA.TIME_OF_DAY__MINUTE, false, NumberIntegerExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Integer> buildSecondAdapter(DeclarationAnnotationAdapter daa) { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(daa, EclipseLinkJPA.TIME_OF_DAY__SECOND, false, NumberIntegerExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<Integer> buildMillisecondAdapter(DeclarationAnnotationAdapter daa) { - return new ConversionDeclarationAnnotationElementAdapter<Integer>(daa, EclipseLinkJPA.TIME_OF_DAY__MILLISECOND, false, NumberIntegerExpressionConverter.instance()); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TransformationImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TransformationImpl.java deleted file mode 100644 index b5b4f85571..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TransformationImpl.java +++ /dev/null @@ -1,156 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.BooleanExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.EnumDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.FetchType; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.TransformationAnnotation; - - -public class TransformationImpl extends AbstractResourceAnnotation<Attribute> implements TransformationAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<Boolean> optionalAdapter; - - private final AnnotationElementAdapter<String> fetchAdapter; - - private static final DeclarationAnnotationElementAdapter<Boolean> OPTIONAL_ADAPTER = buildOptionalAdapter(); - - private static final DeclarationAnnotationElementAdapter<String> FETCH_ADAPTER = buildFetchAdapter(); - - private Boolean optional; - - private FetchType fetch; - - protected TransformationImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.optionalAdapter = new ShortCircuitAnnotationElementAdapter<Boolean>(attribute, OPTIONAL_ADAPTER); - this.fetchAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, FETCH_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.optional = this.optional(astRoot); - this.fetch = this.fetch(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** Transformation implementation **************** - public Boolean getOptional() { - return this.optional; - } - - public void setOptional(Boolean newOptional) { - if (attributeValueHasNotChanged(this.optional, newOptional)) { - return; - } - Boolean oldOptional = this.optional; - this.optional = newOptional; - this.optionalAdapter.setValue(newOptional); - firePropertyChanged(OPTIONAL_PROPERTY, oldOptional, newOptional); - } - - public FetchType getFetch() { - return this.fetch; - } - - public void setFetch(FetchType newFetch) { - if (attributeValueHasNotChanged(this.fetch, newFetch)) { - return; - } - FetchType oldFetch = this.fetch; - this.fetch = newFetch; - this.fetchAdapter.setValue(FetchType.toJavaAnnotationValue(newFetch)); - firePropertyChanged(FETCH_PROPERTY, oldFetch, newFetch); - } - - public TextRange getFetchTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(FETCH_ADAPTER, astRoot); - } - - public TextRange getOptionalTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(OPTIONAL_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setOptional(this.optional(astRoot)); - this.setFetch(this.fetch(astRoot)); - } - - protected FetchType fetch(CompilationUnit astRoot) { - return FetchType.fromJavaAnnotationValue(this.fetchAdapter.getValue(astRoot)); - } - - protected Boolean optional(CompilationUnit astRoot) { - return this.optionalAdapter.getValue(astRoot); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<Boolean> buildOptionalAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<Boolean>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.TRANSFORMATION__OPTIONAL, false, BooleanExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildFetchAdapter() { - return new EnumDeclarationAnnotationElementAdapter(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.TRANSFORMATION__FETCH, false); - } - - public static class TransformationAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final TransformationAnnotationDefinition INSTANCE = new TransformationAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static TransformationAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private TransformationAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new TransformationImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return new NullTransformation(parent); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TypeConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TypeConverterImpl.java deleted file mode 100644 index 5431b88800..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/TypeConverterImpl.java +++ /dev/null @@ -1,188 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.StringExpressionConverter; -import org.eclipse.jpt.core.internal.utility.jdt.TypeStringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.TypeConverterAnnotation; - - -public class TypeConverterImpl extends AbstractResourceAnnotation<Member> implements TypeConverterAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> nameAdapter; - private final AnnotationElementAdapter<String> dataTypeAdapter; - private final AnnotationElementAdapter<String> objectTypeAdapter; - - private static final DeclarationAnnotationElementAdapter<String> NAME_ADAPTER = buildNameAdapter(); - private static final DeclarationAnnotationElementAdapter<String> DATA_TYPE_ADAPTER = buildDataTypeAdapter(); - private static final DeclarationAnnotationElementAdapter<String> OBJECT_TYPE_ADAPTER = buildObjectTypeAdapter(); - - - private String name; - private String dataType; - private String objectType; - - protected TypeConverterImpl(JavaResourcePersistentMember parent, Member member) { - super(parent, member, DECLARATION_ANNOTATION_ADAPTER); - this.nameAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, NAME_ADAPTER); - this.dataTypeAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, DATA_TYPE_ADAPTER); - this.objectTypeAdapter = new ShortCircuitAnnotationElementAdapter<String>(member, OBJECT_TYPE_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - this.name = this.name(astRoot); - this.dataType = this.dataType(astRoot); - this.objectType = this.objectType(astRoot); - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** TypeConverter implementation **************** - public String getName() { - return this.name; - } - - public void setName(String newName) { - if (attributeValueHasNotChanged(this.name, newName)) { - return; - } - String oldName = this.name; - this.name = newName; - this.nameAdapter.setValue(newName); - firePropertyChanged(NAME_PROPERTY, oldName, newName); - } - - public String getDataType() { - return this.dataType; - } - - public void setDataType(String newDataType) { - if (attributeValueHasNotChanged(this.dataType, newDataType)) { - return; - } - String oldDataType = this.dataType; - this.dataType = newDataType; - this.dataTypeAdapter.setValue(newDataType); - firePropertyChanged(DATA_TYPE_PROPERTY, oldDataType, newDataType); - } - - public String getObjectType() { - return this.objectType; - } - - public void setObjectType(String newObjectType) { - if (attributeValueHasNotChanged(this.objectType, newObjectType)) { - return; - } - String oldObjectType = this.objectType; - this.objectType = newObjectType; - this.objectTypeAdapter.setValue(newObjectType); - firePropertyChanged(OBJECT_TYPE_PROPERTY, oldObjectType, newObjectType); - } - - public TextRange getNameTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(NAME_ADAPTER, astRoot); - } - - public TextRange getDataTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(DATA_TYPE_ADAPTER, astRoot); - } - - public TextRange getObjectTypeTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(OBJECT_TYPE_ADAPTER, astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setName(this.name(astRoot)); - this.setDataType(this.dataType(astRoot)); - this.setObjectType(this.objectType(astRoot)); - } - - protected String name(CompilationUnit astRoot) { - return this.nameAdapter.getValue(astRoot); - } - - protected String dataType(CompilationUnit astRoot) { - return this.dataTypeAdapter.getValue(astRoot); - } - - protected String objectType(CompilationUnit astRoot) { - return this.objectTypeAdapter.getValue(astRoot); - } - - @Override - public void toString(StringBuilder sb) { - sb.append(this.name); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildNameAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.TYPE_CONVERTER__NAME, false, StringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildDataTypeAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.TYPE_CONVERTER__DATE_TYPE, false, TypeStringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildObjectTypeAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.TYPE_CONVERTER__OBJECT_TYPE, false, TypeStringExpressionConverter.instance()); - } - - public static class TypeConverterAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final TypeConverterAnnotationDefinition INSTANCE = new TypeConverterAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static TypeConverterAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private TypeConverterAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new TypeConverterImpl(parent, member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/VariableOneToOneImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/VariableOneToOneImpl.java deleted file mode 100644 index 8583bdca38..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/VariableOneToOneImpl.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.VariableOneToOneAnnotation; - - -public class VariableOneToOneImpl extends AbstractResourceAnnotation<Attribute> implements VariableOneToOneAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - - protected VariableOneToOneImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - } - - public void initialize(CompilationUnit astRoot) { - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - public void update(CompilationUnit astRoot) { - } - - public static class VariableOneToOneAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final VariableOneToOneAnnotationDefinition INSTANCE = new VariableOneToOneAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static VariableOneToOneAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private VariableOneToOneAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new VariableOneToOneImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/WriteTransformerImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/WriteTransformerImpl.java deleted file mode 100644 index d841323cf8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/java/WriteTransformerImpl.java +++ /dev/null @@ -1,220 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.internal.resource.java.AbstractResourceAnnotation; -import org.eclipse.jpt.core.internal.resource.java.ColumnImpl; -import org.eclipse.jpt.core.internal.utility.jdt.ConversionDeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.MemberAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.NestedDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.ShortCircuitAnnotationElementAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleDeclarationAnnotationAdapter; -import org.eclipse.jpt.core.internal.utility.jdt.SimpleTypeStringExpressionConverter; -import org.eclipse.jpt.core.resource.java.Annotation; -import org.eclipse.jpt.core.resource.java.AnnotationDefinition; -import org.eclipse.jpt.core.resource.java.ColumnAnnotation; -import org.eclipse.jpt.core.resource.java.JPA; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentAttribute; -import org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.core.utility.jdt.AnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Attribute; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationAdapter; -import org.eclipse.jpt.core.utility.jdt.DeclarationAnnotationElementAdapter; -import org.eclipse.jpt.core.utility.jdt.Member; -import org.eclipse.jpt.eclipselink.core.resource.java.EclipseLinkJPA; -import org.eclipse.jpt.eclipselink.core.resource.java.WriteTransformerAnnotation; - - -public class WriteTransformerImpl extends AbstractResourceAnnotation<Attribute> implements WriteTransformerAnnotation -{ - private static final DeclarationAnnotationAdapter DECLARATION_ANNOTATION_ADAPTER = new SimpleDeclarationAnnotationAdapter(ANNOTATION_NAME); - - private final AnnotationElementAdapter<String> transformerClassAdapter; - private final AnnotationElementAdapter<String> methodAdapter; - private final MemberAnnotationAdapter columnAdapter; - - private static final DeclarationAnnotationElementAdapter<String> TRANSFORMER_CLASS_ADAPTER = buildTransformerClassAdapter(); - private static final DeclarationAnnotationElementAdapter<String> METHOD_ADAPTER = buildMethodAdapter(); - - private String transformerClass; - private String method; - private ColumnImpl column; - - - protected WriteTransformerImpl(JavaResourcePersistentAttribute parent, Attribute attribute) { - super(parent, attribute, DECLARATION_ANNOTATION_ADAPTER); - this.transformerClassAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, TRANSFORMER_CLASS_ADAPTER); - this.methodAdapter = new ShortCircuitAnnotationElementAdapter<String>(attribute, METHOD_ADAPTER); - this.columnAdapter = new MemberAnnotationAdapter(getMember(), buildColumnAnnotationAdapter(getDeclarationAnnotationAdapter())); - } - - public void initialize(CompilationUnit astRoot) { - this.transformerClass = this.transformerClass(astRoot); - this.method = this.method(astRoot); - if (this.columnAdapter.getAnnotation(astRoot) != null) { - this.column = createColumn(this, getMember(), getDeclarationAnnotationAdapter()); - this.column.initialize(astRoot); - } - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - - //*************** WriteTransformer implementation **************** - public String getTransformerClass() { - return this.transformerClass; - } - - public void setTransformerClass(String newTransformerClass) { - if (attributeValueHasNotChanged(this.transformerClass, newTransformerClass)) { - return; - } - String oldTransformerClass = this.transformerClass; - this.transformerClass = newTransformerClass; - this.transformerClassAdapter.setValue(newTransformerClass); - firePropertyChanged(TRANSFORMER_CLASS_PROPERTY, oldTransformerClass, newTransformerClass); - } - - public String getMethod() { - return this.method; - } - - public void setMethod(String newMethod) { - if (attributeValueHasNotChanged(this.method, newMethod)) { - return; - } - String oldMethod = this.method; - this.method = newMethod; - this.methodAdapter.setValue(newMethod); - firePropertyChanged(METHOD_PROPERTY, oldMethod, newMethod); - } - - public ColumnAnnotation getNonNullColumn() { - return (getColumn() != null) ? getColumn() : new NullWriteTransformerColumn(this); - } - - public ColumnAnnotation getColumn() { - return this.column; - } - - public ColumnAnnotation addColumn() { - ColumnImpl column = createColumn(this, getMember(), getDeclarationAnnotationAdapter()); - column.newAnnotation(); - setColumn(column); - return column; - } - - public void removeColumn() { - this.column.removeAnnotation(); - setColumn(null); - } - - protected void setColumn(ColumnImpl newColumn) { - ColumnImpl oldColumn = this.column; - this.column = newColumn; - firePropertyChanged(WriteTransformerAnnotation.COLUMN_PROPERTY, oldColumn, newColumn); - } - - - public TextRange getTransformerClassTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(TRANSFORMER_CLASS_ADAPTER, astRoot); - } - - public TextRange getMethodTextRange(CompilationUnit astRoot) { - return this.getElementTextRange(METHOD_ADAPTER, astRoot); - } - - public TextRange getColumnTextRange(CompilationUnit astRoot) { - if (this.column != null) { - return this.column.getTextRange(astRoot); - } - return getTextRange(astRoot); - } - - public void update(CompilationUnit astRoot) { - this.setTransformerClass(this.transformerClass(astRoot)); - this.setMethod(this.method(astRoot)); - if (this.columnAdapter.getAnnotation(astRoot) == null) { - this.setColumn(null); - } - else { - if (getColumn() != null) { - getColumn().update(astRoot); - } - else { - ColumnImpl column = createColumn(this, getMember(), getDeclarationAnnotationAdapter()); - column.initialize(astRoot); - this.setColumn(column); - } - } - } - - protected String transformerClass(CompilationUnit astRoot) { - return this.transformerClassAdapter.getValue(astRoot); - } - - protected String method(CompilationUnit astRoot) { - return this.methodAdapter.getValue(astRoot); - } - - // ********** static methods ********** - private static DeclarationAnnotationElementAdapter<String> buildTransformerClassAdapter() { - return new ConversionDeclarationAnnotationElementAdapter<String>(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.WRITE_TRANSFORMER__TRANSFORMER_CLASS, false, SimpleTypeStringExpressionConverter.instance()); - } - - private static DeclarationAnnotationElementAdapter<String> buildMethodAdapter() { - return ConversionDeclarationAnnotationElementAdapter.forStrings(DECLARATION_ANNOTATION_ADAPTER, EclipseLinkJPA.WRITE_TRANSFORMER__METHOD, false); - } - - private static DeclarationAnnotationAdapter buildColumnAnnotationAdapter(DeclarationAnnotationAdapter writeTransformerAnnotationAdapter) { - return new NestedDeclarationAnnotationAdapter(writeTransformerAnnotationAdapter, EclipseLinkJPA.WRITE_TRANSFORMER__COLUMN, JPA.COLUMN, false); - } - - private static ColumnImpl createColumn(JavaResourceNode parent, Member member, DeclarationAnnotationAdapter writeTransformerAnnotationAdapter) { - return new ColumnImpl(parent, member, buildColumnAnnotationAdapter(writeTransformerAnnotationAdapter)); - } - - public static class WriteTransformerAnnotationDefinition implements AnnotationDefinition - { - // singleton - private static final WriteTransformerAnnotationDefinition INSTANCE = new WriteTransformerAnnotationDefinition(); - - /** - * Return the singleton. - */ - public static WriteTransformerAnnotationDefinition instance() { - return INSTANCE; - } - - /** - * Ensure single instance. - */ - private WriteTransformerAnnotationDefinition() { - super(); - } - - public Annotation buildAnnotation(JavaResourcePersistentMember parent, Member member) { - return new WriteTransformerImpl((JavaResourcePersistentAttribute) parent, (Attribute) member); - } - - public Annotation buildNullAnnotation(JavaResourcePersistentMember parent, Member member) { - return null; - } - - public String getAnnotationName() { - return ANNOTATION_NAME; - } - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/EclipseLinkOrmXmlResourceProvider.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/EclipseLinkOrmXmlResourceProvider.java deleted file mode 100644 index 00874a8484..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/EclipseLinkOrmXmlResourceProvider.java +++ /dev/null @@ -1,84 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm; - -import org.eclipse.core.resources.IFile; -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.IPath; -import org.eclipse.core.runtime.Path; -import org.eclipse.core.runtime.content.IContentType; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.jpt.core.JptCorePlugin; -import org.eclipse.jpt.core.resource.AbstractXmlResourceProvider; -import org.eclipse.jpt.core.resource.common.JpaXmlResource; -import org.eclipse.jpt.core.resource.orm.XmlEntityMappings; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkConstants; -import org.eclipse.jpt.eclipselink.core.internal.JptEclipseLinkCorePlugin; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmXmlResource; - -public class EclipseLinkOrmXmlResourceProvider - extends AbstractXmlResourceProvider<EclipseLinkOrmXmlResource> -{ - /** - * (Convenience method) Returns an EclipseLink ORM resource model provider for - * the given file. - */ - public static EclipseLinkOrmXmlResourceProvider getXmlResourceProvider(IFile file) { - return getXmlResourceProvider_(file.getProject(), file.getFullPath().toString()); - } - - /** - * (Convenience method) Returns an EclipseLink ORM resource model provider for - * the given project in the specified deploy location - */ - public static EclipseLinkOrmXmlResourceProvider getXmlResourceProvider(IProject project, String deployLocation) { - return getXmlResourceProvider_(project, JptCorePlugin.getDeploymentURI(project, deployLocation)); - - } - - /** - * (Convenience method) Returns an EclipseLink ORM resource model provider for - * the given project in the default deploy location - */ - public static EclipseLinkOrmXmlResourceProvider getDefaultXmlResourceProvider(IProject project) { - return getXmlResourceProvider(project, JptEclipseLinkCorePlugin.DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH); - } - - private static EclipseLinkOrmXmlResourceProvider getXmlResourceProvider_(IProject project, String location) { - return new EclipseLinkOrmXmlResourceProvider(project, new Path(location)); - } - - - public EclipseLinkOrmXmlResourceProvider(IProject project) { - this(project, new Path(JptEclipseLinkCorePlugin.DEFAULT_ECLIPSELINK_ORM_XML_FILE_PATH)); - } - - public EclipseLinkOrmXmlResourceProvider(IProject project, IPath filePath) { - super(project, filePath); - } - - @Override - protected IContentType getContentType() { - return JptEclipseLinkCorePlugin.ECLIPSELINK_ORM_XML_CONTENT_TYPE; - } - - @Override - protected void populateRoot(JpaXmlResource xmlResource) { - XmlEntityMappings entityMappings = EclipseLinkOrmFactory.eINSTANCE.createXmlEntityMappings(); - entityMappings.setVersion(EclipseLinkConstants.VERSION_1_0_TEXT); - getResourceContents(xmlResource).add(entityMappings); - } - - @Override - protected EclipseLinkOrmXmlResource ensureCorrectType(Resource r) throws ClassCastException { - return (EclipseLinkOrmXmlResource) r; - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/AccessMethodsTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/AccessMethodsTranslator.java deleted file mode 100644 index d48c4f3e60..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/AccessMethodsTranslator.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class AccessMethodsTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public AccessMethodsTranslator() { - super(ACCESS_METHODS, ECLIPSELINK_ORM_PKG.getXmlAccessMethodsHolder_AccessMethods()); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlAccessMethods(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createGetMethodTranslator(), - createSetMethodTranslator(), - }; - } - - protected Translator createGetMethodTranslator() { - return new Translator(ACCESS_METHODS__GET_METHOD, ECLIPSELINK_ORM_PKG.getXmlAccessMethods_GetMethod(), DOM_ATTRIBUTE); - } - - protected Translator createSetMethodTranslator() { - return new Translator(ACCESS_METHODS__SET_METHOD, ECLIPSELINK_ORM_PKG.getXmlAccessMethods_SetMethod(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicCollectionTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicCollectionTranslator.java deleted file mode 100644 index b18deca31a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicCollectionTranslator.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class BasicCollectionTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - public BasicCollectionTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlBasicCollectionImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator() - }; - } - - protected Translator createNameTranslator() { - return new Translator(NAME, ORM_PKG.getXmlAttributeMapping_Name(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicMapTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicMapTranslator.java deleted file mode 100644 index 3c244c1c84..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/BasicMapTranslator.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.BasicTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class BasicMapTranslator extends BasicTranslator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - public BasicMapTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlBasicMapImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator() - }; - } - - @Override - protected Translator createNameTranslator() { - return new Translator(NAME, ORM_PKG.getXmlAttributeMapping_Name(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CacheTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CacheTranslator.java deleted file mode 100644 index 5e058f1962..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CacheTranslator.java +++ /dev/null @@ -1,81 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class CacheTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public CacheTranslator() { - super(CACHE, ECLIPSELINK_ORM_PKG.getXmlCacheHolder_Cache()); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createExpiryTranslator(), - createExpiryTimeOfDayTranslator(), - createSizeTranslator(), - createSharedTranslator(), - createTypeTranslator(), - createAlwaysRefreshTranslator(), - createRefreshOnlyIfNewerTranslator(), - createDisableHitsTranslator(), - createCoordinationTypeTranslator(), - }; - } - - protected Translator createExpiryTranslator() { - return new Translator(CACHE__EXPIRY, ECLIPSELINK_ORM_PKG.getXmlCache_Expiry()); - } - - protected Translator createExpiryTimeOfDayTranslator() { - return new ExpiryTimeOfDayTranslator(); - } - - protected Translator createSizeTranslator() { - return new Translator(CACHE__SIZE, ECLIPSELINK_ORM_PKG.getXmlCache_Size(), DOM_ATTRIBUTE); - } - - protected Translator createSharedTranslator() { - return new Translator(CACHE__SHARED, ECLIPSELINK_ORM_PKG.getXmlCache_Shared(), DOM_ATTRIBUTE); - } - - protected Translator createTypeTranslator() { - return new Translator(CACHE__TYPE, ECLIPSELINK_ORM_PKG.getXmlCache_Type(), DOM_ATTRIBUTE); - } - - protected Translator createAlwaysRefreshTranslator() { - return new Translator(CACHE__ALWAYS_REFRESH, ECLIPSELINK_ORM_PKG.getXmlCache_AlwaysRefresh(), DOM_ATTRIBUTE); - } - - protected Translator createRefreshOnlyIfNewerTranslator() { - return new Translator(CACHE__REFRESH_ONLY_IF_NEWER, ECLIPSELINK_ORM_PKG.getXmlCache_RefreshOnlyIfNewer(), DOM_ATTRIBUTE); - } - - protected Translator createDisableHitsTranslator() { - return new Translator(CACHE__DISABLE_HITS, ECLIPSELINK_ORM_PKG.getXmlCache_DisableHits(), DOM_ATTRIBUTE); - } - - protected Translator createCoordinationTypeTranslator() { - return new Translator(CACHE__COORDINATION_TYPE, ECLIPSELINK_ORM_PKG.getXmlCache_CoordinationType(), DOM_ATTRIBUTE); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CloneCopyPolicyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CloneCopyPolicyTranslator.java deleted file mode 100644 index 35bf0fc8ba..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CloneCopyPolicyTranslator.java +++ /dev/null @@ -1,53 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class CloneCopyPolicyTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public CloneCopyPolicyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlCloneCopyPolicy(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createMethodTranslator(), - createWorkingCopyMethodTranslator(), - }; - } - - protected Translator createMethodTranslator() { - return new Translator(CLONE_COPY_POLICY__METHOD, ECLIPSELINK_ORM_PKG.getXmlCloneCopyPolicy_Method(), DOM_ATTRIBUTE); - } - - protected Translator createWorkingCopyMethodTranslator() { - return new Translator(CLONE_COPY_POLICY__WORKING_COPY_METHOD, ECLIPSELINK_ORM_PKG.getXmlCloneCopyPolicy_WorkingCopyMethod(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConversionValueTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConversionValueTranslator.java deleted file mode 100644 index 45f04b91ce..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConversionValueTranslator.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class ConversionValueTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public ConversionValueTranslator() { - super(CONVERSION_VALUE, ECLIPSELINK_ORM_PKG.getXmlObjectTypeConverter_ConversionValues(), END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlConversionValueImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createDataValueTranslator(), - createObjectValueTranslator(), - }; - } - - protected Translator createDataValueTranslator() { - return new Translator(CONVERSION_VALUE__DATA_VALUE, ECLIPSELINK_ORM_PKG.getXmlConversionValue_DataValue(), DOM_ATTRIBUTE); - } - - protected Translator createObjectValueTranslator() { - return new Translator(CONVERSION_VALUE__OBJECT_VALUE, ECLIPSELINK_ORM_PKG.getXmlConversionValue_ObjectValue(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConverterTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConverterTranslator.java deleted file mode 100644 index 024478cb13..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ConverterTranslator.java +++ /dev/null @@ -1,53 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class ConverterTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public ConverterTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlConverterImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createClassTranslator(), - }; - } - - protected Translator createNameTranslator() { - return new Translator(CONVERTER__NAME, ECLIPSELINK_ORM_PKG.getXmlNamedConverter_Name(), DOM_ATTRIBUTE); - } - - protected Translator createClassTranslator() { - return new Translator(CONVERTER__CLASS, ECLIPSELINK_ORM_PKG.getXmlConverter_ClassName(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CopyPolicyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CopyPolicyTranslator.java deleted file mode 100644 index 012e354804..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CopyPolicyTranslator.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class CopyPolicyTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public CopyPolicyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlCopyPolicy(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createClassTranslator(), - }; - } - - protected Translator createClassTranslator() { - return new Translator(COPY_POLICY__CLASS, ECLIPSELINK_ORM_PKG.getXmlCopyPolicy_Class(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CustomizerTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CustomizerTranslator.java deleted file mode 100644 index e3eca6372f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/CustomizerTranslator.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class CustomizerTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public CustomizerTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createClassTranslator() - }; - } - - protected Translator createClassTranslator() { - return new Translator(CLASS, ECLIPSELINK_ORM_PKG.getXmlCustomizer_CustomizerClassName(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkAttributesTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkAttributesTranslator.java deleted file mode 100644 index 435d947f9d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkAttributesTranslator.java +++ /dev/null @@ -1,111 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.AttributesTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkAttributesTranslator extends AttributesTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkAttributesTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createAttributes(); - - } - @Override - protected Translator[] createChildren() { - return new Translator[] { - createIdTranslator(), - createEmbeddedIdTranslator(), - createBasicTranslator(), - createBasicCollectionTranslator(), - createBasicMapTranslator(), - createVersionTranslator(), - createManyToOneTranslator(), - createOneToManyTranslator(), - createOneToOneTranslator(), - createVariableOneToOneTranslator(), - createManyToManyTranslator(), - createEmbeddedTranslator(), - createTransformationTranslator(), - createTransientTranslator() - }; - } - - @Override - protected Translator createIdTranslator() { - return new EclipseLinkIdTranslator(ID, ORM_PKG.getAttributes_Ids()); - } - - @Override - protected Translator createEmbeddedIdTranslator() { - return new EclipseLinkEmbeddedIdTranslator(EMBEDDED_ID, ORM_PKG.getAttributes_EmbeddedIds()); - } - - @Override - protected Translator createBasicTranslator() { - return new EclipseLinkBasicTranslator(BASIC, ORM_PKG.getAttributes_Basics()); - } - - @Override - protected Translator createVersionTranslator() { - return new EclipseLinkVersionTranslator(VERSION, ORM_PKG.getAttributes_Versions()); - } - - @Override - protected Translator createManyToOneTranslator() { - return new EclipseLinkManyToOneTranslator(MANY_TO_ONE, ORM_PKG.getAttributes_ManyToOnes()); - } - - @Override - protected Translator createOneToOneTranslator() { - return new EclipseLinkOneToOneTranslator(ONE_TO_ONE, ORM_PKG.getAttributes_OneToOnes()); - } - - @Override - protected Translator createOneToManyTranslator() { - return new EclipseLinkOneToManyTranslator(ONE_TO_MANY, ORM_PKG.getAttributes_OneToManys()); - } - - @Override - protected Translator createManyToManyTranslator() { - return new EclipseLinkManyToManyTranslator(MANY_TO_MANY, ORM_PKG.getAttributes_ManyToManys()); - } - - @Override - protected Translator createEmbeddedTranslator() { - return new EclipseLinkEmbeddedTranslator(EMBEDDED, ORM_PKG.getAttributes_Embeddeds()); - } - - protected Translator createVariableOneToOneTranslator() { - return new VariableOneToOneTranslator(VARIABLE_ONE_TO_ONE, ECLIPSELINK_ORM_PKG.getAttributes_VariableOneToOnes()); - } - - protected Translator createBasicCollectionTranslator() { - return new BasicCollectionTranslator(BASIC_COLLECTION, ECLIPSELINK_ORM_PKG.getAttributes_BasicCollections()); - } - - protected Translator createBasicMapTranslator() { - return new BasicMapTranslator(BASIC_MAP, ECLIPSELINK_ORM_PKG.getAttributes_BasicMaps()); - } - - protected Translator createTransformationTranslator() { - return new TransformationTranslator(TRANSFORMATION, ECLIPSELINK_ORM_PKG.getAttributes_Transformations()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkBasicTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkBasicTranslator.java deleted file mode 100644 index 8909a2dea7..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkBasicTranslator.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.BasicTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkBasicTranslator extends BasicTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkBasicTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlBasicImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createFetchTranslator(), - createOptionalTranslator(), - createMutableTranslator(), - createColumnTranslator(), - createLobTranslator(), - createTemporalTranslator(), - createEnumeratedTranslator(), - createConvertTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createMutableTranslator() { - return new Translator(MUTABLE, ECLIPSELINK_ORM_PKG.getXmlMutable_Mutable(), DOM_ATTRIBUTE); - } - - protected Translator createConvertTranslator() { - return new Translator(CONVERT, ECLIPSELINK_ORM_PKG.getXmlConvertibleMapping_Convert()); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_Converter()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_TypeConverter()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_ObjectTypeConverter()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_StructConverter()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlBasic_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkChangeTrackingTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkChangeTrackingTranslator.java deleted file mode 100644 index 12a70b1060..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkChangeTrackingTranslator.java +++ /dev/null @@ -1,44 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkChangeTrackingTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public EclipseLinkChangeTrackingTranslator(String domNameAndPath, EStructuralFeature aFeature, int style) { - super(domNameAndPath, aFeature, style); - } - - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createTypeTranslator() - }; - } - - protected Translator createTypeTranslator() { - return new Translator(TYPE, ECLIPSELINK_ORM_PKG.getXmlChangeTracking_Type(), Translator.DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddableTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddableTranslator.java deleted file mode 100644 index 2227392528..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddableTranslator.java +++ /dev/null @@ -1,102 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.EmbeddableTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkEmbeddableTranslator extends EmbeddableTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkEmbeddableTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddable(); - } - - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createClassTranslator(), - createAccessTranslator(), - createMetadataCompleteTranslator(), - createExcludeDefaultMappingsTranslator(), - createDescriptionTranslator(), - createCustomizerTranslator(), - createChangeTrackingTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createPropertyTranslator(), - createAttributesTranslator(), - createCopyPolicyTranslator(), - createInstantiationCopyPolicyTranslator(), - createCloneCopyPolicyTranslator(), - }; - } - - protected Translator createCustomizerTranslator() { - return new CustomizerTranslator(CUSTOMIZER, ECLIPSELINK_ORM_PKG.getXmlCustomizerHolder_Customizer()); - } - - protected Translator createChangeTrackingTranslator() { - return new EclipseLinkChangeTrackingTranslator(CHANGE_TRACKING, ECLIPSELINK_ORM_PKG.getXmlChangeTrackingHolder_ChangeTracking(), END_TAG_NO_INDENT); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_Converters()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_TypeConverters()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_ObjectTypeConverters()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_StructConverters()); - } - - @Override - protected Translator createAttributesTranslator() { - return new EclipseLinkAttributesTranslator(ATTRIBUTES, ORM_PKG.getXmlTypeMapping_Attributes()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlEmbeddable_Properties()); - } - - protected Translator createCopyPolicyTranslator() { - return new CopyPolicyTranslator(COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEmbeddable_CopyPolicy()); - } - - protected Translator createInstantiationCopyPolicyTranslator() { - return new InstantiationCopyPolicyTranslator(INSTANTIATION_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEmbeddable_InstantiationCopyPolicy()); - } - - protected Translator createCloneCopyPolicyTranslator() { - return new CloneCopyPolicyTranslator(CLONE_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEmbeddable_CloneCopyPolicy()); - } - - - protected Translator createExcludeDefaultMappingsTranslator() { - return new Translator(EXCLUDE_DEFAULT_MAPPINGS, ECLIPSELINK_ORM_PKG.getXmlEmbeddable_ExcludeDefaultMappings(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedIdTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedIdTranslator.java deleted file mode 100644 index ffb43e9ed8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedIdTranslator.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. - * All rights reserve9. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.EmbeddedIdTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkEmbeddedIdTranslator extends EmbeddedIdTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkEmbeddedIdTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddedIdImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createAttributeOverrideTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlEmbeddedId_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedTranslator.java deleted file mode 100644 index 1f00a36033..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEmbeddedTranslator.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.EmbeddedTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkEmbeddedTranslator extends EmbeddedTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkEmbeddedTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlEmbeddedImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createAttributeOverrideTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlEmbedded_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityMappingsTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityMappingsTranslator.java deleted file mode 100644 index 81703a1dfa..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityMappingsTranslator.java +++ /dev/null @@ -1,104 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.jpt.core.internal.resource.orm.translators.EntityMappingsTranslator; -import org.eclipse.wst.common.internal.emf.resource.ConstantAttributeTranslator; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkEntityMappingsTranslator extends EntityMappingsTranslator - implements EclipseLinkOrmXmlMapper -{ - public static EclipseLinkEntityMappingsTranslator INSTANCE = new EclipseLinkEntityMappingsTranslator(); - - - public EclipseLinkEntityMappingsTranslator() { - super(ENTITY_MAPPINGS, ECLIPSELINK_ORM_PKG.getXmlEntityMappings()); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createVersionTranslator(), - createNamespaceTranslator(), - createSchemaNamespaceTranslator(), - createSchemaLocationTranslator(), - createDescriptionTranslator(), - createPersistenceUnitMetadataTranslator(), - createPackageTranslator(), - createSchemaTranslator(), - createCatalogTranslator(), - createAccessTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createSequenceGeneratorTranslator(), - createTableGeneratorTranslator(), - createNamedQueryTranslator(), - createNamedNativeQueryTranslator(), - createNamedStoredProcedureQueryTranslator(), - createSqlResultSetMappingTranslator(), - createMappedSuperclassTranslator(), - createEntityTranslator(), - createEmbeddableTranslator() - }; - } - - @Override - protected Translator createNamespaceTranslator() { - return new ConstantAttributeTranslator(XML_NS, ECLIPSELINK_ORM_NS_URL); - } - - @Override - protected Translator createSchemaLocationTranslator() { - return new ConstantAttributeTranslator(XSI_SCHEMA_LOCATION, ECLIPSELINK_ORM_NS_URL + ' ' + ECLIPSELINK_ORM_SCHEMA_LOC_1_0); - } - - @Override - protected Translator createPersistenceUnitMetadataTranslator() { - return new EclipseLinkPersistenceUnitMetadataTranslator(PERSISTENCE_UNIT_METADATA, ORM_PKG.getXmlEntityMappings_PersistenceUnitMetadata()); - } - - @Override - protected Translator createEmbeddableTranslator() { - return new EclipseLinkEmbeddableTranslator(EMBEDDABLE, ORM_PKG.getXmlEntityMappings_Embeddables()); - } - - @Override - protected Translator createEntityTranslator() { - return new EclipseLinkEntityTranslator(ENTITY, ORM_PKG.getXmlEntityMappings_Entities()); - } - - @Override - protected Translator createMappedSuperclassTranslator() { - return new EclipseLinkMappedSuperclassTranslator(MAPPED_SUPERCLASS, ORM_PKG.getXmlEntityMappings_MappedSuperclasses()); - } - - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_Converters()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_TypeConverters()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_ObjectTypeConverters()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_StructConverters()); - } - - protected Translator createNamedStoredProcedureQueryTranslator() { - return new NamedStoredProcedureQueryTranslator(NAMED_STORED_PROCEDURE_QUERY, ECLIPSELINK_ORM_PKG.getXmlEntityMappings_NamedStoredProcedureQueries()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityTranslator.java deleted file mode 100644 index bac233e127..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkEntityTranslator.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.EntityTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkEntityTranslator extends EntityTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkEntityTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlEntity(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createClassTranslator(), - createAccessTranslator(), - createMetadataCompleteTranslator(), - createReadOnlyTranslator(), - createExistenceCheckingTranslator(), - createExcludeDefaultMappingsTranslator(), - createDescriptionTranslator(), - createCustomizerTranslator(), - createChangeTrackingTranslator(), - createTableTranslator(), - createSecondaryTableTranslator(), - createPrimaryKeyJoinColumnTranslator(), - createIdClassTranslator(), - createInheritanceTranslator(), - createDiscriminatorValueTranslator(), - createDiscriminatorColumnTranslator(), - createOptimisticLockingTranslator(), - createCacheTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createCopyPolicyTranslator(), - createInstantiationCopyPolicyTranslator(), - createCloneCopyPolicyTranslator(), - createSequenceGeneratorTranslator(), - createTableGeneratorTranslator(), - createNamedQueryTranslator(), - createNamedNativeQueryTranslator(), - createNamedStoredProcedureQueryTranslator(), - createSqlResultSetMappingTranslator(), - createExcludeDefaultListenersTranslator(), - createExcludeSuperclassListenersTranslator(), - createEntityListenersTranslator(), - createPrePersistTranslator(), - createPostPersistTranslator(), - createPreRemoveTranslator(), - createPostRemoveTranslator(), - createPreUpdateTranslator(), - createPostUpdateTranslator(), - createPostLoadTranslator(), - createPropertyTranslator(), - createAttributeOverrideTranslator(), - createAssociationOverrideTranslator(), - createAttributesTranslator(), - }; - } - - protected Translator createReadOnlyTranslator() { - return new Translator(READ_ONLY, ECLIPSELINK_ORM_PKG.getXmlReadOnly_ReadOnly(), DOM_ATTRIBUTE); - } - - protected Translator createExistenceCheckingTranslator() { - return new Translator(EXISTENCE_CHECKING, ECLIPSELINK_ORM_PKG.getXmlCacheHolder_ExistenceChecking(), DOM_ATTRIBUTE); - } - - protected Translator createCustomizerTranslator() { - return new CustomizerTranslator(CUSTOMIZER, ECLIPSELINK_ORM_PKG.getXmlCustomizerHolder_Customizer()); - } - - protected Translator createChangeTrackingTranslator() { - return new EclipseLinkChangeTrackingTranslator(CHANGE_TRACKING, ECLIPSELINK_ORM_PKG.getXmlChangeTrackingHolder_ChangeTracking(), END_TAG_NO_INDENT); - } - - protected Translator createCacheTranslator() { - return new CacheTranslator(); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_Converters()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_TypeConverters()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_ObjectTypeConverters()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_StructConverters()); - } - - @Override - protected Translator createAttributesTranslator() { - return new EclipseLinkAttributesTranslator(ATTRIBUTES, ORM_PKG.getXmlTypeMapping_Attributes()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlEntity_Properties()); - } - - protected Translator createNamedStoredProcedureQueryTranslator() { - return new NamedStoredProcedureQueryTranslator(NAMED_STORED_PROCEDURE_QUERY, ECLIPSELINK_ORM_PKG.getXmlEntity_NamedStoredProcedureQueries()); - } - - protected Translator createCopyPolicyTranslator() { - return new CopyPolicyTranslator(COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEntity_CopyPolicy()); - } - - protected Translator createInstantiationCopyPolicyTranslator() { - return new InstantiationCopyPolicyTranslator(INSTANTIATION_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEntity_InstantiationCopyPolicy()); - } - - protected Translator createCloneCopyPolicyTranslator() { - return new CloneCopyPolicyTranslator(CLONE_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlEntity_CloneCopyPolicy()); - } - - protected Translator createOptimisticLockingTranslator() { - return new OptimisticLockingTranslator(OPTIMISTIC_LOCKING, ECLIPSELINK_ORM_PKG.getXmlEntity_OptimisticLocking()); - } - - protected Translator createExcludeDefaultMappingsTranslator() { - return new Translator(EXCLUDE_DEFAULT_MAPPINGS, ECLIPSELINK_ORM_PKG.getXmlEntity_ExcludeDefaultMappings(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkIdTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkIdTranslator.java deleted file mode 100644 index cf6dda1e4b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkIdTranslator.java +++ /dev/null @@ -1,83 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.IdTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkIdTranslator extends IdTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkIdTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlIdImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createMutableTranslator(), - createColumnTranslator(), - createGeneratedValueTranslator(), - createTemporalTranslator(), - createConvertTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createTableGeneratorTranslator(), - createSequenceGeneratorTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createMutableTranslator() { - return new Translator(MUTABLE, ECLIPSELINK_ORM_PKG.getXmlMutable_Mutable(), DOM_ATTRIBUTE); - } - - protected Translator createConvertTranslator() { - return new Translator(CONVERT, ECLIPSELINK_ORM_PKG.getXmlConvertibleMapping_Convert()); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_Converter()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_TypeConverter()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_ObjectTypeConverter()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_StructConverter()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlId_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToManyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToManyTranslator.java deleted file mode 100644 index 78e396d5a0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToManyTranslator.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.ManyToManyTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkManyToManyTranslator extends ManyToManyTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkManyToManyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlManyToManyImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createTargetEntityTranslator(), - createFetchTranslator(), - createMappedByTranslator(), - createOrderByTranslator(), - createMapKeyTranslator(), - createJoinTableTranslator(), - createCascadeTranslator(), - createJoinFetchTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createJoinFetchTranslator() { - return new Translator(JOIN_FETCH, ECLIPSELINK_ORM_PKG.getXmlJoinFetch_JoinFetch()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlManyToMany_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToOneTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToOneTranslator.java deleted file mode 100644 index 9f62f253ad..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkManyToOneTranslator.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.ManyToOneTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkManyToOneTranslator extends ManyToOneTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkManyToOneTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlManyToOneImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createTargetEntityTranslator(), - createFetchTranslator(), - createOptionalTranslator(), - createJoinColumnTranslator(), - createJoinTableTranslator(), - createCascadeTranslator(), - createJoinFetchTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createJoinFetchTranslator() { - return new Translator(JOIN_FETCH, ECLIPSELINK_ORM_PKG.getXmlJoinFetch_JoinFetch()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlManyToOne_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkMappedSuperclassTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkMappedSuperclassTranslator.java deleted file mode 100644 index 4692ace6bc..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkMappedSuperclassTranslator.java +++ /dev/null @@ -1,134 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.MappedSuperclassTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkMappedSuperclassTranslator extends MappedSuperclassTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkMappedSuperclassTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlMappedSuperclass(); - } - - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createClassTranslator(), - createAccessTranslator(), - createMetadataCompleteTranslator(), - createReadOnlyTranslator(), - createExistenceCheckingTranslator(), - createExcludeDefaultMappingsTranslator(), - createDescriptionTranslator(), - createCustomizerTranslator(), - createChangeTrackingTranslator(), - createIdClassTranslator(), - createOptimisticLockingTranslator(), - createCacheTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createCopyPolicyTranslator(), - createInstantiationCopyPolicyTranslator(), - createCloneCopyPolicyTranslator(), - createExcludeDefaultListenersTranslator(), - createExcludeSuperclassListenersTranslator(), - createEntityListenersTranslator(), - createPrePersistTranslator(), - createPostPersistTranslator(), - createPreRemoveTranslator(), - createPostRemoveTranslator(), - createPreUpdateTranslator(), - createPostUpdateTranslator(), - createPostLoadTranslator(), - createPropertyTranslator(), - createAttributesTranslator() - }; - } - - protected Translator createReadOnlyTranslator() { - return new Translator(READ_ONLY, ECLIPSELINK_ORM_PKG.getXmlReadOnly_ReadOnly(), DOM_ATTRIBUTE); - } - - protected Translator createExistenceCheckingTranslator() { - return new Translator(EXISTENCE_CHECKING, ECLIPSELINK_ORM_PKG.getXmlCacheHolder_ExistenceChecking(), DOM_ATTRIBUTE); - } - - protected Translator createCustomizerTranslator() { - return new CustomizerTranslator(CUSTOMIZER, ECLIPSELINK_ORM_PKG.getXmlCustomizerHolder_Customizer()); - } - - protected Translator createChangeTrackingTranslator() { - return new EclipseLinkChangeTrackingTranslator(CHANGE_TRACKING, ECLIPSELINK_ORM_PKG.getXmlChangeTrackingHolder_ChangeTracking(), END_TAG_NO_INDENT); - } - - protected Translator createCacheTranslator() { - return new CacheTranslator(); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_Converters()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_TypeConverters()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_ObjectTypeConverters()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConvertersHolder_StructConverters()); - } - - @Override - protected Translator createAttributesTranslator() { - return new EclipseLinkAttributesTranslator(ATTRIBUTES, ORM_PKG.getXmlTypeMapping_Attributes()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_Properties()); - } - - protected Translator createCopyPolicyTranslator() { - return new CopyPolicyTranslator(COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_CopyPolicy()); - } - - protected Translator createInstantiationCopyPolicyTranslator() { - return new InstantiationCopyPolicyTranslator(INSTANTIATION_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_InstantiationCopyPolicy()); - } - - protected Translator createCloneCopyPolicyTranslator() { - return new CloneCopyPolicyTranslator(CLONE_COPY_POLICY, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_CloneCopyPolicy()); - } - - protected Translator createOptimisticLockingTranslator() { - return new OptimisticLockingTranslator(OPTIMISTIC_LOCKING, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_OptimisticLocking()); - } - - protected Translator createExcludeDefaultMappingsTranslator() { - return new Translator(EXCLUDE_DEFAULT_MAPPINGS, ECLIPSELINK_ORM_PKG.getXmlMappedSuperclass_ExcludeDefaultMappings(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToManyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToManyTranslator.java deleted file mode 100644 index be45bc6280..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToManyTranslator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.common.translators.EmptyTagBooleanTranslator; -import org.eclipse.jpt.core.internal.resource.orm.translators.OneToManyTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkOneToManyTranslator extends OneToManyTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkOneToManyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlOneToManyImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createTargetEntityTranslator(), - createFetchTranslator(), - createMappedByTranslator(), - createOrderByTranslator(), - createMapKeyTranslator(), - createJoinTableTranslator(), - createJoinColumnTranslator(), - createCascadeTranslator(), - createPrivateOwnedTranslator(), - createJoinFetchTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createPrivateOwnedTranslator() { - return new EmptyTagBooleanTranslator(PRIVATE_OWNED, ECLIPSELINK_ORM_PKG.getXmlPrivateOwned_PrivateOwned()); - } - - protected Translator createJoinFetchTranslator() { - return new Translator(JOIN_FETCH, ECLIPSELINK_ORM_PKG.getXmlJoinFetch_JoinFetch()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlOneToMany_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToOneTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToOneTranslator.java deleted file mode 100644 index 9435dda1e1..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOneToOneTranslator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.common.translators.EmptyTagBooleanTranslator; -import org.eclipse.jpt.core.internal.resource.orm.translators.OneToOneTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkOneToOneTranslator extends OneToOneTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkOneToOneTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlOneToOneImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createTargetEntityTranslator(), - createFetchTranslator(), - createOptionalTranslator(), - createMappedByTranslator(), - createPrimaryKeyJoinColumnTranslator(), - createJoinColumnTranslator(), - createJoinTableTranslator(), - createCascadeTranslator(), - createPrivateOwnedTranslator(), - createJoinFetchTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createPrivateOwnedTranslator() { - return new EmptyTagBooleanTranslator(PRIVATE_OWNED, ECLIPSELINK_ORM_PKG.getXmlPrivateOwned_PrivateOwned()); - } - - protected Translator createJoinFetchTranslator() { - return new Translator(JOIN_FETCH, ECLIPSELINK_ORM_PKG.getXmlJoinFetch_JoinFetch()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlOneToOne_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOrmXmlMapper.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOrmXmlMapper.java deleted file mode 100644 index 69425764c2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkOrmXmlMapper.java +++ /dev/null @@ -1,127 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.jpt.core.internal.resource.orm.translators.OrmXmlMapper; -import org.eclipse.jpt.eclipselink.core.internal.EclipseLinkConstants; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage; - -public interface EclipseLinkOrmXmlMapper - extends OrmXmlMapper, EclipseLinkConstants -{ - EclipseLinkOrmPackage ECLIPSELINK_ORM_PKG = EclipseLinkOrmPackage.eINSTANCE; - - String ACCESS_METHODS = "access-methods"; //$NON-NLS-1$ - String ACCESS_METHODS__GET_METHOD = "get-method"; //$NON-NLS-1$ - String ACCESS_METHODS__SET_METHOD = "set-method"; //$NON-NLS-1$ - - String BASIC_COLLECTION = "basic-collection"; //$NON-NLS-1$ - - String BASIC_MAP = "basic-map"; //$NON-NLS-1$ - - String CACHE = "cache"; //$NON-NLS-1$ - String CACHE__EXPIRY = "expiry"; //$NON-NLS-1$ - String CACHE__SIZE = "size"; //$NON-NLS-1$ - String CACHE__SHARED = "shared"; //$NON-NLS-1$ - String CACHE__TYPE = "type"; //$NON-NLS-1$ - String CACHE__ALWAYS_REFRESH = "always-refresh"; //$NON-NLS-1$ - String CACHE__REFRESH_ONLY_IF_NEWER = "refresh-only-if-newer"; //$NON-NLS-1$ - String CACHE__DISABLE_HITS = "disable-hits"; //$NON-NLS-1$ - String CACHE__COORDINATION_TYPE = "coordination-type"; //$NON-NLS-1$ - - String CHANGE_TRACKING = "change-tracking"; //$NON-NLS-1$ - - String CONVERSION_VALUE = "conversion-value"; //$NON-NLS-1$ - String CONVERSION_VALUE__DATA_VALUE = "data-value"; //$NON-NLS-1$ - String CONVERSION_VALUE__OBJECT_VALUE = "object-value"; //$NON-NLS-1$ - - String CONVERT = "convert"; //$NON-NLS-1$ - - String CONVERTER = "converter"; //$NON-NLS-1$ - String CONVERTER__CLASS = "class"; //$NON-NLS-1$ - String CONVERTER__NAME = "name"; //$NON-NLS-1$ - - String COPY_POLICY = "copy-policy"; //$NON-NLS-1$ - String COPY_POLICY__CLASS = "class"; //$NON-NLS-1$ - - String CLONE_COPY_POLICY = "clone-copy-policy"; //$NON-NLS-1$ - String CLONE_COPY_POLICY__METHOD = "method"; //$NON-NLS-1$ - String CLONE_COPY_POLICY__WORKING_COPY_METHOD = "working-copy-method"; //$NON-NLS-1$ - - String CUSTOMIZER = "customizer"; //$NON-NLS-1$ - - String EXCLUDE_DEFAULT_MAPPINGS = "exclude-default-mappings"; //$NON-NLS-1$ - - String EXISTENCE_CHECKING = "existence-checking"; //$NON-NLS-1$ - - String EXPIRY_TIME_OF_DAY = "expiry-time-of-day"; //$NON-NLS-1$ - String EXPIRY_TIME_OF_DAY__HOUR = "hour"; //$NON-NLS-1$ - String EXPIRY_TIME_OF_DAY__MINUTE = "minute"; //$NON-NLS-1$ - String EXPIRY_TIME_OF_DAY__SECOND = "second"; //$NON-NLS-1$ - String EXPIRY_TIME_OF_DAY__MILLISECOND = "millisecond"; //$NON-NLS-1$ - - String INSTANTIATION_COPY_POLICY = "instantiation-copy-policy"; //$NON-NLS-1$ - - String JOIN_FETCH = "join-fetch"; //$NON-NLS-1$ - - String MUTABLE = "mutable"; //$NON-NLS-1$ - - String NAMED_STORED_PROCEDURE_QUERY = "named-stored-procedure-query"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__NAME = "name"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__HINT = "hint"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS = "result-class"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING = "result-set-mapping"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME = "procedure-name"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET = "returns-result-set"; //$NON-NLS-1$ - String NAMED_STORED_PROCEDURE_QUERY__PARAMETER = "parameter"; //$NON-NLS-1$ - String PARAMETER__DIRECTION = "direction"; //$NON-NLS-1$ - String PARAMETER__NAME = "name"; //$NON-NLS-1$ - String PARAMETER__QUERY_PARAMETER = "query-parameter"; //$NON-NLS-1$ - String PARAMETER__TYPE = "type"; //$NON-NLS-1$ - String PARAMETER__JDBC_TYPE = "jdbc-type"; //$NON-NLS-1$ - String PARAMETER__JDBC_TYPE_NAME = "jdbc-type-name"; //$NON-NLS-1$ - - - String OBJECT_TYPE_CONVERTER = "object-type-converter"; //$NON-NLS-1$ - String OBJECT_TYPE_CONVERTER__NAME = "name"; //$NON-NLS-1$ - String OBJECT_TYPE_CONVERTER__DATA_TYPE = "data-type"; //$NON-NLS-1$ - String OBJECT_TYPE_CONVERTER__OBJECT_TYPE = "object-type"; //$NON-NLS-1$ - String OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE = "default-object-value"; //$NON-NLS-1$ - - String OPTIMISTIC_LOCKING = "optimistic-locking"; //$NON-NLS-1$ - String OPTIMISTIC_LOCKING__SELECTED_COLUMN = "selected-column"; //$NON-NLS-1$ - String OPTIMISTIC_LOCKING__TYPE = "type"; //$NON-NLS-1$ - String OPTIMISTIC_LOCKING__CASCADE = "cascade"; //$NON-NLS-1$ - - String PRIVATE_OWNED = "private-owned"; //$NON-NLS-1$ - - String PROPERTY = "property"; //$NON-NLS-1$ - String PROPERTY__NAME = "name"; //$NON-NLS-1$ - String PROPERTY__VALUE = "value"; //$NON-NLS-1$ - String PROPERTY__VALUE_TYPE = "value-type"; //$NON-NLS-1$ - - String READ_ONLY = "read-only"; //$NON-NLS-1$ - - - String STRUCT_CONVERTER = "struct-converter"; //$NON-NLS-1$ - String STRUCT_CONVERTER__NAME = "name"; //$NON-NLS-1$ - String STRUCT_CONVERTER__CONVERTER = "converter"; //$NON-NLS-1$ - - String TRANSFORMATION = "transformation"; //$NON-NLS-1$ - - String TYPE = "type"; //$NON-NLS-1$ - - String TYPE_CONVERTER = "type-converter"; //$NON-NLS-1$ - String TYPE_CONVERTER__NAME = "name"; //$NON-NLS-1$ - String TYPE_CONVERTER__DATA_TYPE = "data-type"; //$NON-NLS-1$ - String TYPE_CONVERTER__OBJECT_TYPE = "object-type"; //$NON-NLS-1$ - - String VARIABLE_ONE_TO_ONE = "variable-one-to-one"; //$NON-NLS-1$ - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkPersistenceUnitMetadataTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkPersistenceUnitMetadataTranslator.java deleted file mode 100644 index 8a37b2cd37..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkPersistenceUnitMetadataTranslator.java +++ /dev/null @@ -1,41 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.common.translators.EmptyTagBooleanTranslator; -import org.eclipse.jpt.core.internal.resource.orm.translators.PersistenceUnitMetadataTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkPersistenceUnitMetadataTranslator extends PersistenceUnitMetadataTranslator implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkPersistenceUnitMetadataTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlPersistenceUnitMetadata(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createXmlMappingMetadataCompleteTranslator(), - createExcludeDefaultMappingsTranslator(), - createPersistenceUnitDefaultsTranslator(), - }; - } - - protected Translator createExcludeDefaultMappingsTranslator() { - return new EmptyTagBooleanTranslator(EXCLUDE_DEFAULT_MAPPINGS, ECLIPSELINK_ORM_PKG.getXmlPersistenceUnitMetadata_ExcludeDefaultMappings()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkVersionTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkVersionTranslator.java deleted file mode 100644 index 55db7542d4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/EclipseLinkVersionTranslator.java +++ /dev/null @@ -1,80 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.VersionTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class EclipseLinkVersionTranslator extends VersionTranslator - implements EclipseLinkOrmXmlMapper -{ - public EclipseLinkVersionTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlVersionImpl(); - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createMutableTranslator(), - createColumnTranslator(), - createTemporalTranslator(), - createConvertTranslator(), - createConverterTranslator(), - createTypeConverterTranslator(), - createObjectTypeConverterTranslator(), - createStructConverterTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createMutableTranslator() { - return new Translator(MUTABLE, ECLIPSELINK_ORM_PKG.getXmlMutable_Mutable(), DOM_ATTRIBUTE); - } - - protected Translator createConvertTranslator() { - return new Translator(CONVERT, ECLIPSELINK_ORM_PKG.getXmlConvertibleMapping_Convert()); - } - - protected Translator createConverterTranslator() { - return new ConverterTranslator(CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_Converter()); - } - - protected Translator createTypeConverterTranslator() { - return new TypeConverterTranslator(TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_TypeConverter()); - } - - protected Translator createObjectTypeConverterTranslator() { - return new ObjectTypeConverterTranslator(OBJECT_TYPE_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_ObjectTypeConverter()); - } - - protected Translator createStructConverterTranslator() { - return new StructConverterTranslator(STRUCT_CONVERTER, ECLIPSELINK_ORM_PKG.getXmlConverterHolder_StructConverter()); - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlVersion_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ExpiryTimeOfDayTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ExpiryTimeOfDayTranslator.java deleted file mode 100644 index 7fb7c683db..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ExpiryTimeOfDayTranslator.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class ExpiryTimeOfDayTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public ExpiryTimeOfDayTranslator() { - super(EXPIRY_TIME_OF_DAY, ECLIPSELINK_ORM_PKG.getXmlCache_ExpiryTimeOfDay(), END_TAG_NO_INDENT); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createHourTranslator(), - createMinuteTranslator(), - createSecondTranslator(), - createMillisecondTranslator(), - }; - } - protected Translator createHourTranslator() { - return new Translator(EXPIRY_TIME_OF_DAY__HOUR, ECLIPSELINK_ORM_PKG.getXmlTimeOfDay_Hour(), DOM_ATTRIBUTE); - } - - protected Translator createMinuteTranslator() { - return new Translator(EXPIRY_TIME_OF_DAY__MINUTE, ECLIPSELINK_ORM_PKG.getXmlTimeOfDay_Minute(), DOM_ATTRIBUTE); - } - - protected Translator createSecondTranslator() { - return new Translator(EXPIRY_TIME_OF_DAY__SECOND, ECLIPSELINK_ORM_PKG.getXmlTimeOfDay_Second(), DOM_ATTRIBUTE); - } - - protected Translator createMillisecondTranslator() { - return new Translator(EXPIRY_TIME_OF_DAY__MILLISECOND, ECLIPSELINK_ORM_PKG.getXmlTimeOfDay_Millisecond(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/InstantiationCopyPolicyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/InstantiationCopyPolicyTranslator.java deleted file mode 100644 index ca8f9b5c45..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/InstantiationCopyPolicyTranslator.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class InstantiationCopyPolicyTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - - public InstantiationCopyPolicyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlInstantiationPolicy(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/NamedStoredProcedureQueryTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/NamedStoredProcedureQueryTranslator.java deleted file mode 100644 index 003cc83aae..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/NamedStoredProcedureQueryTranslator.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.common.translators.BooleanTranslator; -import org.eclipse.jpt.core.internal.resource.orm.translators.QueryHintTranslator; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class NamedStoredProcedureQueryTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public NamedStoredProcedureQueryTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createResultClassTranslator(), - createResultSetMappingTranslator(), - createProcedureNameTranslator(), - createReturnResultSetTranslator(), - createHintTranslator(), - createParameterTranslator(), - }; - } - - private Translator createNameTranslator() { - return new Translator(NAMED_STORED_PROCEDURE_QUERY__NAME, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_Name(), DOM_ATTRIBUTE); - } - - private Translator createResultClassTranslator() { - return new Translator(NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_ResultClass(), DOM_ATTRIBUTE); - } - - private Translator createResultSetMappingTranslator() { - return new Translator(NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_ResultSetMapping(), DOM_ATTRIBUTE); - } - - private Translator createProcedureNameTranslator() { - return new Translator(NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_ProcedureName(), DOM_ATTRIBUTE); - } - - private Translator createReturnResultSetTranslator() { - return new BooleanTranslator(NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_ReturnsResultSet(), DOM_ATTRIBUTE); - } - - private Translator createHintTranslator() { - return new QueryHintTranslator(NAMED_STORED_PROCEDURE_QUERY__HINT, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_Hints()); - } - - private Translator createParameterTranslator() { - return new StoredProcedureParameterTranslator(NAMED_STORED_PROCEDURE_QUERY__PARAMETER, ECLIPSELINK_ORM_PKG.getXmlNamedStoredProcedureQuery_Parameters()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ObjectTypeConverterTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ObjectTypeConverterTranslator.java deleted file mode 100644 index f85f67809a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/ObjectTypeConverterTranslator.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class ObjectTypeConverterTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public ObjectTypeConverterTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlObjectTypeConverterImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createConversionValueTranslator(), - createDefaultObjectValueTranslator(), - createNameTranslator(), - createDataTypeTranslator(), - createObjectTypeTranslator(), - }; - } - - protected Translator createConversionValueTranslator() { - return new ConversionValueTranslator(); - } - - protected Translator createDefaultObjectValueTranslator() { - return new Translator(OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE, ECLIPSELINK_ORM_PKG.getXmlObjectTypeConverter_DefaultObjectValue()); - } - - protected Translator createNameTranslator() { - return new Translator(OBJECT_TYPE_CONVERTER__NAME, ECLIPSELINK_ORM_PKG.getXmlNamedConverter_Name(), DOM_ATTRIBUTE); - } - - protected Translator createDataTypeTranslator() { - return new Translator(OBJECT_TYPE_CONVERTER__DATA_TYPE, ECLIPSELINK_ORM_PKG.getXmlObjectTypeConverter_DataType(), DOM_ATTRIBUTE); - } - - protected Translator createObjectTypeTranslator() { - return new Translator(OBJECT_TYPE_CONVERTER__OBJECT_TYPE, ECLIPSELINK_ORM_PKG.getXmlObjectTypeConverter_ObjectType(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/OptimisticLockingTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/OptimisticLockingTranslator.java deleted file mode 100644 index 4421e98830..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/OptimisticLockingTranslator.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.common.translators.BooleanTranslator; -import org.eclipse.jpt.core.internal.resource.orm.translators.ColumnTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class OptimisticLockingTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public OptimisticLockingTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlOptimisticLocking(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createTypeTranslator(), - createCascadeTranslator(), - createSelectedColumnTranslator(), - }; - } - - protected Translator createTypeTranslator() { - return new Translator(OPTIMISTIC_LOCKING__TYPE, ECLIPSELINK_ORM_PKG.getXmlOptimisticLocking_Type(), DOM_ATTRIBUTE); - } - - protected Translator createCascadeTranslator() { - return new BooleanTranslator(OPTIMISTIC_LOCKING__CASCADE, ECLIPSELINK_ORM_PKG.getXmlOptimisticLocking_Cascade(), DOM_ATTRIBUTE); - } - - protected Translator createSelectedColumnTranslator() { - return new ColumnTranslator(OPTIMISTIC_LOCKING__SELECTED_COLUMN, ECLIPSELINK_ORM_PKG.getXmlOptimisticLocking_SelectedColumns()); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/PropertyTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/PropertyTranslator.java deleted file mode 100644 index 407228ab25..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/PropertyTranslator.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class PropertyTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public PropertyTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlProperty(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createValueTranslator(), - createValueTypeTranslator(), - }; - } - - protected Translator createNameTranslator() { - return new Translator(PROPERTY__NAME, ECLIPSELINK_ORM_PKG.getXmlProperty_Name(), DOM_ATTRIBUTE); - } - - protected Translator createValueTranslator() { - return new Translator(PROPERTY__VALUE, ECLIPSELINK_ORM_PKG.getXmlProperty_Value(), DOM_ATTRIBUTE); - } - - protected Translator createValueTypeTranslator() { - return new Translator(PROPERTY__VALUE_TYPE, ECLIPSELINK_ORM_PKG.getXmlProperty_ValueType(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StoredProcedureParameterTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StoredProcedureParameterTranslator.java deleted file mode 100644 index 9ffe5118b5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StoredProcedureParameterTranslator.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class StoredProcedureParameterTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public StoredProcedureParameterTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createDirectionTranslator(), - createNameTranslator(), - createQueryParameterTranslator(), - createTypeTranslator(), - createJdbcTypeTranslator(), - createJdbcTypeNameTranslator(), - }; - } - - private Translator createDirectionTranslator() { - return new Translator(PARAMETER__DIRECTION, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_Direction(), DOM_ATTRIBUTE); - } - - private Translator createNameTranslator() { - return new Translator(PARAMETER__NAME, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_Name(), DOM_ATTRIBUTE); - } - - private Translator createQueryParameterTranslator() { - return new Translator(PARAMETER__QUERY_PARAMETER, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_QueryParameter(), DOM_ATTRIBUTE); - } - - private Translator createTypeTranslator() { - return new Translator(PARAMETER__TYPE, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_Type(), DOM_ATTRIBUTE); - } - - private Translator createJdbcTypeTranslator() { - return new Translator(PARAMETER__JDBC_TYPE, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_JdbcType(), DOM_ATTRIBUTE); - } - - private Translator createJdbcTypeNameTranslator() { - return new Translator(PARAMETER__JDBC_TYPE_NAME, ECLIPSELINK_ORM_PKG.getXmlStoredProcedureParameter_JdbcTypeName(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StructConverterTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StructConverterTranslator.java deleted file mode 100644 index 50eba69001..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/StructConverterTranslator.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class StructConverterTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public StructConverterTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlStructConverterImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createConverterTranslator(), - }; - } - - protected Translator createNameTranslator() { - return new Translator(STRUCT_CONVERTER__NAME, ECLIPSELINK_ORM_PKG.getXmlNamedConverter_Name(), DOM_ATTRIBUTE); - } - - protected Translator createConverterTranslator() { - return new Translator(STRUCT_CONVERTER__CONVERTER, ECLIPSELINK_ORM_PKG.getXmlStructConverter_Converter(), DOM_ATTRIBUTE); - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TransformationTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TransformationTranslator.java deleted file mode 100644 index 4c9eddc3c9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TransformationTranslator.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.core.internal.resource.orm.translators.BasicTranslator; -import org.eclipse.jpt.core.internal.resource.persistence.translators.PropertyTranslator; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class TransformationTranslator extends BasicTranslator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - public TransformationTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlTransformationImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - @Override - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createPropertyTranslator(), - createAccessMethodsTranslator() - }; - } - - protected Translator createPropertyTranslator() { - return new PropertyTranslator(PROPERTY, ECLIPSELINK_ORM_PKG.getXmlTransformation_Properties()); - } - - protected Translator createAccessMethodsTranslator() { - return new AccessMethodsTranslator(); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TypeConverterTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TypeConverterTranslator.java deleted file mode 100644 index 2601c2aa5a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/TypeConverterTranslator.java +++ /dev/null @@ -1,58 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. This - * program and the accompanying materials are made available under the terms of - * the Eclipse Public License v1.0 which accompanies this distribution, and is - * available at http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: Oracle. - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class TypeConverterTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - - public TypeConverterTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature, END_TAG_NO_INDENT); - } - - @Override - public EObject createEMFObject(@SuppressWarnings("unused") String nodeName, @SuppressWarnings("unused") String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlTypeConverterImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator(), - createDataTypeTranslator(), - createObjectTypeTranslator(), - }; - } - - protected Translator createNameTranslator() { - return new Translator(TYPE_CONVERTER__NAME, ECLIPSELINK_ORM_PKG.getXmlNamedConverter_Name(), DOM_ATTRIBUTE); - } - - protected Translator createDataTypeTranslator() { - return new Translator(TYPE_CONVERTER__DATA_TYPE, ECLIPSELINK_ORM_PKG.getXmlTypeConverter_DataType(), DOM_ATTRIBUTE); - } - - protected Translator createObjectTypeTranslator() { - return new Translator(TYPE_CONVERTER__OBJECT_TYPE, ECLIPSELINK_ORM_PKG.getXmlTypeConverter_ObjectType(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/VariableOneToOneTranslator.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/VariableOneToOneTranslator.java deleted file mode 100644 index 93fb11ec9d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/internal/resource/orm/translators/VariableOneToOneTranslator.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -public class VariableOneToOneTranslator extends Translator - implements EclipseLinkOrmXmlMapper -{ - private Translator[] children; - - public VariableOneToOneTranslator(String domNameAndPath, EStructuralFeature aFeature) { - super(domNameAndPath, aFeature); - } - - @Override - public EObject createEMFObject(String nodeName, String readAheadName) { - return EclipseLinkOrmFactory.eINSTANCE.createXmlVariableOneToOneImpl(); - } - - @Override - protected Translator[] getChildren() { - if (this.children == null) { - this.children = createChildren(); - } - return this.children; - } - - protected Translator[] createChildren() { - return new Translator[] { - createNameTranslator() - }; - } - - protected Translator createNameTranslator() { - return new Translator(NAME, ORM_PKG.getXmlAttributeMapping_Name(), DOM_ATTRIBUTE); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicCollectionAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicCollectionAnnotation.java deleted file mode 100644 index 5fa7bc7e0d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicCollectionAnnotation.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.JavaResourceNode; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Transformation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface BasicCollectionAnnotation extends JavaResourceNode -{ - String ANNOTATION_NAME = EclipseLinkJPA.BASIC_COLLECTION; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicMapAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicMapAnnotation.java deleted file mode 100644 index 795c7c19ba..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/BasicMapAnnotation.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.JavaResourceNode; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.BasicMap - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface BasicMapAnnotation extends JavaResourceNode -{ - String ANNOTATION_NAME = EclipseLinkJPA.BASIC_MAP; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheAnnotation.java deleted file mode 100644 index febd15af1a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheAnnotation.java +++ /dev/null @@ -1,199 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.Cache annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface CacheAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.CACHE; - - /** - * Corresponds to the type element of the Cache annotation. - * Returns null if the type element does not exist in java. - */ - CacheType getType(); - - /** - * Corresponds to the type element of the Cache annotation. - * Set to null to remove the type element. - */ - void setType(CacheType type); - String TYPE_PROPERTY = "typeProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the size element of the Cache annotation. - * Returns null if the size valuePair does not exist in the annotation - */ - Integer getSize(); - - /** - * Corresponds to the size element of the Cache annotation. - * Set to null to remove the size valuePair from the annotation - */ - void setSize(Integer size); - String SIZE_PROPERTY = "sizeProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the shared element of the Cache annotation. - * Returns null if the shared element does not exist in java. - */ - Boolean getShared(); - - /** - * Corresponds to the shared element of the Cache annotation. - * Set to null to remove the shared element. - */ - void setShared(Boolean shared); - String SHARED_PROPERTY = "sharedProperty"; //$NON-NLS-1$ - - - /** - * Corresponds to the expiry element of the Cache annotation. - * Returns null if the expiry valuePair does not exist in the annotation - */ - Integer getExpiry(); - - /** - * Corresponds to the expiry element of the Cache annotation. - * Set to null to remove the expiry valuePair from the annotation - */ - void setExpiry(Integer expiry); - String EXPIRY_PROPERTY = "expiryProperty"; //$NON-NLS-1$ - - TimeOfDayAnnotation addExpiryTimeOfDay(); - void removeExpiryTimeOfDay(); - TimeOfDayAnnotation getExpiryTimeOfDay(); - String EXPIRY_TIME_OF_DAY_PROPERTY = "expiryTimeOfDayProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the alwaysRefresh element of the Cache annotation. - * Returns null if the alwaysRefresh element does not exist in java. - */ - Boolean getAlwaysRefresh(); - - /** - * Corresponds to the alwaysRefresh element of the Cache annotation. - * Set to null to remove the alwaysRefresh element. - */ - void setAlwaysRefresh(Boolean alwaysRefresh); - String ALWAYS_REFRESH_PROPERTY = "alwaysRefreshProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the refreshOnlyIfNewer element of the Cache annotation. - * Returns null if the refreshOnlyIfNewer element does not exist in java. - */ - Boolean getRefreshOnlyIfNewer(); - - /** - * Corresponds to the refreshOnlyIfNewer element of the Cache annotation. - * Set to null to remove the refreshOnlyIfNewer element. - */ - void setRefreshOnlyIfNewer(Boolean refreshOnlyIfNewer); - String REFRESH_ONLY_IF_NEWER_PROPERTY = "refreshOnlyIfNewerProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the disableHits element of the Cache annotation. - * Returns null if the disableHits element does not exist in java. - */ - Boolean getDisableHits(); - - /** - * Corresponds to the disableHits element of the Cache annotation. - * Set to null to remove the disableHits element. - */ - void setDisableHits(Boolean disableHits); - String DISABLE_HITS_PROPERTY = "disableHitsProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the type element of the Cache annotation. - * Returns null if the type element does not exist in java. - */ - CacheCoordinationType getCoordinationType(); - - /** - * Corresponds to the type element of the Cache annotation. - * Set to null to remove the type element. - */ - void setCoordinationType(CacheCoordinationType coordinationType); - String COORDINATION_TYPE_PROPERTY = "coordinationTypeProperty"; //$NON-NLS-1$ - - - /** - * Return the {@link TextRange} for the type element. If the type element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getTypeTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the shared element. If the shared element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getSizeTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the shared element. If the shared element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getSharedTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the expiry element. If the expiry element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getExpiryTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the expiryTimeOfDay element. If the expiryTimeOfDay element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getExpiryTimeOfDayTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the alwaysRefresh element. If the alwaysRefresh element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getAlwaysRefreshTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the refreshOnlyIfNewer element. If the refreshOnlyIfNewer element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getRefreshOnlyIfNewerTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the disableHits element. If the disableHits element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getDisablesHitsTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the coordinationType element. If the coordinationType element - * does not exist return the {@link TextRange} for the Cache annotation. - */ - TextRange getCoordinationTypeTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheCoordinationType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheCoordinationType.java deleted file mode 100644 index 6a3ed5204c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheCoordinationType.java +++ /dev/null @@ -1,66 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum CacheCoordinationType { - - SEND_OBJECT_CHANGES, - INVALIDATE_CHANGED_OBJECTS, - SEND_NEW_OBJECTS_WITH_CHANGES, - NONE; - - public static CacheCoordinationType fromJavaAnnotationValue(Object javaAnnotationValue) { - if (javaAnnotationValue == null) { - return null; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_COORDINATION_TYPE__SEND_OBJECT_CHANGES)) { - return SEND_OBJECT_CHANGES; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_COORDINATION_TYPE__INVALIDATE_CHANGED_OBJECTS)) { - return INVALIDATE_CHANGED_OBJECTS; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_COORDINATION_TYPE__SEND_NEW_OBJECTS_WITH_CHANGES)) { - return SEND_NEW_OBJECTS_WITH_CHANGES; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_COORDINATION_TYPE__NONE)) { - return NONE; - } - return null; - } - - public static String toJavaAnnotationValue(CacheCoordinationType cacheCoordinationType) { - if (cacheCoordinationType == null) { - return null; - } - switch (cacheCoordinationType) { - case SEND_OBJECT_CHANGES : - return EclipseLinkJPA.CACHE_COORDINATION_TYPE__SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS : - return EclipseLinkJPA.CACHE_COORDINATION_TYPE__INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES : - return EclipseLinkJPA.CACHE_COORDINATION_TYPE__SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE : - return EclipseLinkJPA.CACHE_COORDINATION_TYPE__NONE; - default : - throw new IllegalArgumentException("unknown cache coordination type: " + cacheCoordinationType); //$NON-NLS-1$ - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheType.java deleted file mode 100644 index bf0e43708d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CacheType.java +++ /dev/null @@ -1,85 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum CacheType { - - FULL, - WEAK, - SOFT, - SOFT_WEAK, - HARD_WEAK, - CACHE, - NONE; - - - public static CacheType fromJavaAnnotationValue(Object javaAnnotationValue) { - if (javaAnnotationValue == null) { - return null; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__FULL)) { - return FULL; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__WEAK)) { - return WEAK; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__SOFT)) { - return SOFT; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__SOFT_WEAK)) { - return SOFT_WEAK; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__HARD_WEAK)) { - return HARD_WEAK; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__CACHE)) { - return CACHE; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CACHE_TYPE__NONE)) { - return NONE; - } - return null; - } - - public static String toJavaAnnotationValue(CacheType cacheType) { - if (cacheType == null) { - return null; - } - switch (cacheType) { - case FULL : - return EclipseLinkJPA.CACHE_TYPE__FULL; - case WEAK : - return EclipseLinkJPA.CACHE_TYPE__WEAK; - case SOFT : - return EclipseLinkJPA.CACHE_TYPE__SOFT; - case SOFT_WEAK : - return EclipseLinkJPA.CACHE_TYPE__SOFT_WEAK; - case HARD_WEAK : - return EclipseLinkJPA.CACHE_TYPE__HARD_WEAK; - case CACHE : - return EclipseLinkJPA.CACHE_TYPE__CACHE; - case NONE : - return EclipseLinkJPA.CACHE_TYPE__NONE; - default : - throw new IllegalArgumentException("unknown cache type: " + cacheType); //$NON-NLS-1$ - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingAnnotation.java deleted file mode 100644 index e1ad12d788..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingAnnotation.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.ChangeTracking annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ChangeTrackingAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.CHANGE_TRACKING; - - /** - * Corresponds to the value element of the ChangeTracking annotation. - * Returns null if the value element does not exist in java. - */ - ChangeTrackingType getValue(); - - /** - * Corresponds to the value element of the ChangeTracking annotation. - * Set to null to remove the value element. - */ - void setValue(ChangeTrackingType value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the ChangeTracking annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingType.java deleted file mode 100644 index 749f7c2499..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ChangeTrackingType.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum ChangeTrackingType { - - - ATTRIBUTE, - OBJECT, - DEFERRED, - AUTO; - - public static ChangeTrackingType fromJavaAnnotationValue(Object javaAnnotationValue) { - if (javaAnnotationValue == null) { - return null; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CHANGE_TRACKING_TYPE__ATTRIBUTE)) { - return ATTRIBUTE; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CHANGE_TRACKING_TYPE__OBJECT)) { - return OBJECT; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CHANGE_TRACKING_TYPE__DEFERRED)) { - return DEFERRED; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.CHANGE_TRACKING_TYPE__AUTO)) { - return AUTO; - } - return null; - } - - public static String toJavaAnnotationValue(ChangeTrackingType changeTrackingType) { - if (changeTrackingType == null) { - return null; - } - switch (changeTrackingType) { - case ATTRIBUTE : - return EclipseLinkJPA.CHANGE_TRACKING_TYPE__ATTRIBUTE; - case OBJECT : - return EclipseLinkJPA.CHANGE_TRACKING_TYPE__OBJECT; - case DEFERRED : - return EclipseLinkJPA.CHANGE_TRACKING_TYPE__DEFERRED; - case AUTO : - return EclipseLinkJPA.CHANGE_TRACKING_TYPE__AUTO; - default : - throw new IllegalArgumentException("unknown change tracking type: " + changeTrackingType); //$NON-NLS-1$ - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConversionValueAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConversionValueAnnotation.java deleted file mode 100644 index 5aa1075219..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConversionValueAnnotation.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.ConversionValue - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ConversionValueAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.CONVERSION_VALUE; - - - /** - * Corresponds to the dataValue element of the ConversionValue annotation. - * Returns null if the dataValue element does not exist in java. - */ - String getDataValue(); - - /** - * Corresponds to the dataValue element of the ConversionValue annotation. - * Set to null to remove the dataValue element. - */ - void setDataValue(String dataValue); - String DATA_VALUE_PROPERTY = "dataValueProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the objectValue element of the ConversionValue annotation. - * Returns null if the objectValue element does not exist in java. - */ - String getObjectValue(); - - /** - * Corresponds to the objectValue element of the ConversionValue annotation. - * Set to null to remove the objectValue element. - */ - void setObjectValue(String objectValue); - String OBJECT_VALUE_PROPERTY = "objectValueProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the dataValue element. If the dataValue element - * does not exist return the {@link TextRange} for the ConversionValue annotation. - */ - TextRange getDataValueTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the objectValue element. If the objectValue element - * does not exist return the {@link TextRange} for the ConversionValue annotation. - */ - TextRange getObjectValueTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConvertAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConvertAnnotation.java deleted file mode 100644 index f6ff736b25..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConvertAnnotation.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Convert - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ConvertAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.CONVERT; - - - /** - * Corresponds to the value element of the Convert annotation. - * Returns null if the value element does not exist in java. - */ - String getValue(); - - /** - * Corresponds to the value element of the Convert annotation. - * Set to null to remove the value element. - */ - void setValue(String value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the Convert annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConverterAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConverterAnnotation.java deleted file mode 100644 index d81130b5a2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ConverterAnnotation.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Converter - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ConverterAnnotation extends NamedConverterAnnotation -{ - String ANNOTATION_NAME = EclipseLinkJPA.CONVERTER; - - /** - * Corresponds to the converterClass element of the CustomConverter annotation. - * Returns null if the converterClass element does not exist in java. - */ - String getConverterClass(); - - /** - * Corresponds to the converterClass element of the CustomConverter annotation. - * Set to null to remove the converterClass element. - */ - void setConverterClass(String value); - String CONVERTER_CLASS_PROPERTY = "converterClass"; //$NON-NLS-1$ - - /** - * Return whether the converterClass implements the eclipselink Converter interface - * @see org.eclipse.jpt.eclipselink.core.context.CustomConverter#ECLIPSELINK_CONVERTER_CLASS_NAME - */ - boolean converterClassImplementsInterface(String interfaceName, CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the converterClass element. If the converterClass element - * does not exist return the {@link TextRange} for the CustomConverter annotation. - */ - TextRange getConverterClassTextRange(CompilationUnit astRoot); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CustomizerAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CustomizerAnnotation.java deleted file mode 100644 index 6739a445ec..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/CustomizerAnnotation.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Converter - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface CustomizerAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.CUSTOMIZER; - - /** - * Corresponds to the value element of the Customizer annotation. - * Returns null if the value element does not exist in java. - */ - String getValue(); - - /** - * Corresponds to the value element of the Customizer annotation. - * Set to null to remove the value element. - */ - void setValue(String value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - /** - * Return whether the converterClass implements the eclipselink Customizer interface - * @see org.eclipse.jpt.eclipselink.core.context.Customizer#ECLIPSELINK_DESCRIPTOR_CUSTOMIZER_CLASS_NAME - */ - boolean customizerClassImplementsInterface(String interfaceName, CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the Customizer annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/EclipseLinkJPA.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/EclipseLinkJPA.java deleted file mode 100644 index bfc9de9d23..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/EclipseLinkJPA.java +++ /dev/null @@ -1,157 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - - -/** - * EclipseLink JPA Java-related stuff (annotations etc.) - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -@SuppressWarnings("nls") -public interface EclipseLinkJPA { - - // EclipseLink JPA package - String PACKAGE = "org.eclipse.persistence.annotations"; //$NON-NLS-1$ - String PACKAGE_ = PACKAGE + "."; - - - // ********** API ********** - - // JPA annotations - String BASIC_COLLECTION = PACKAGE_ + "BasicCollection"; - - String BASIC_MAP = PACKAGE_ + "BasicMap"; - - String CACHE = PACKAGE_ + "Cache"; - String CACHE__SHARED = "shared"; - String CACHE__EXPIRY = "expiry"; - String CACHE__EXPIRY_TIME_OF_DAY = "expiryTimeOfDay"; - String CACHE__TYPE = "type"; - String CACHE__SIZE = "size"; - String CACHE__ALWAYS_REFRESH = "alwaysRefresh"; - String CACHE__REFRESH_ONLY_IF_NEWER = "refreshOnlyIfNewer"; - String CACHE__DISABLE_HITS = "disableHits"; - String CACHE__COORDINATION_TYPE = "coordinationType"; - String CACHE_TYPE = PACKAGE_ + "CacheType"; - String CACHE_TYPE_ = CACHE_TYPE + "."; - String CACHE_TYPE__FULL = CACHE_TYPE_ + "FULL"; - String CACHE_TYPE__WEAK = CACHE_TYPE_ + "WEAK"; - String CACHE_TYPE__SOFT = CACHE_TYPE_ + "SOFT"; - String CACHE_TYPE__SOFT_WEAK = CACHE_TYPE_ + "SOFT_WEAK"; - String CACHE_TYPE__HARD_WEAK = CACHE_TYPE_ + "HARD_WEAK"; - String CACHE_TYPE__CACHE = CACHE_TYPE_ + "CACHE"; - String CACHE_TYPE__NONE = CACHE_TYPE_ + "NONE"; - - String CACHE_COORDINATION_TYPE = PACKAGE_ + "CacheCoordinationType"; - String CACHE_COORDINATION_TYPE_ = CACHE_COORDINATION_TYPE + "."; - String CACHE_COORDINATION_TYPE__SEND_OBJECT_CHANGES = CACHE_COORDINATION_TYPE_ + "SEND_OBJECT_CHANGES"; - String CACHE_COORDINATION_TYPE__INVALIDATE_CHANGED_OBJECTS = CACHE_COORDINATION_TYPE_ + "INVALIDATE_CHANGED_OBJECTS"; - String CACHE_COORDINATION_TYPE__SEND_NEW_OBJECTS_WITH_CHANGES = CACHE_COORDINATION_TYPE_ + "SEND_NEW_OBJECTS_WITH_CHANGES"; - String CACHE_COORDINATION_TYPE__NONE = CACHE_COORDINATION_TYPE_ + "NONE"; - - String CHANGE_TRACKING = PACKAGE_ + "ChangeTracking"; - String CHANGE_TRACKING__VALUE = "value"; - - String CHANGE_TRACKING_TYPE = PACKAGE_ + "ChangeTrackingType"; - String CHANGE_TRACKING_TYPE_ = CHANGE_TRACKING_TYPE + "."; - String CHANGE_TRACKING_TYPE__ATTRIBUTE = CHANGE_TRACKING_TYPE_ + "ATTRIBUTE"; - String CHANGE_TRACKING_TYPE__OBJECT = CHANGE_TRACKING_TYPE_ + "OBJECT"; - String CHANGE_TRACKING_TYPE__DEFERRED = CHANGE_TRACKING_TYPE_ + "DEFERRED"; - String CHANGE_TRACKING_TYPE__AUTO = CHANGE_TRACKING_TYPE_ + "AUTO"; - - - String CONVERSION_VALUE = PACKAGE_ + "ConversionValue"; - String CONVERSION_VALUE__DATA_VALUE = "dataValue"; - String CONVERSION_VALUE__OBJECT_VALUE = "objectValue"; - - String CONVERT = PACKAGE_ + "Convert"; - String CONVERT__VALUE = "value"; - - String CONVERTER = PACKAGE_ + "Converter"; - String CONVERTER__NAME = "name"; - String CONVERTER__CONVERTER_CLASS = "converterClass"; - - String CUSTOMIZER = PACKAGE_ + "Customizer"; - String CUSTOMIZER__VALUE = "value"; - - String EXISTENCE_CHECKING = PACKAGE_ + "ExistenceChecking"; - String EXISTENCE_CHECKING__VALUE = "value"; - - String EXISTENCE_TYPE = PACKAGE_ + "ExistenceType"; - String EXISTENCE_TYPE_ = EXISTENCE_TYPE + "."; - String EXISTENCE_TYPE__CHECK_CACHE = EXISTENCE_TYPE_ + "CHECK_CACHE"; - String EXISTENCE_TYPE__CHECK_DATABASE = EXISTENCE_TYPE_ + "CHECK_DATABASE"; - String EXISTENCE_TYPE__ASSUME_EXISTENCE = EXISTENCE_TYPE_ + "ASSUME_EXISTENCE"; - String EXISTENCE_TYPE__ASSUME_NON_EXISTENCE = EXISTENCE_TYPE_ + "ASSUME_NON_EXISTENCE"; - - String JOIN_FETCH = PACKAGE_ + "JoinFetch"; - String JOIN_FETCH_VALUE = "value"; - - String JOIN_FETCH_TYPE = PACKAGE_ + "JoinFetchType"; - String JOIN_FETCH_TYPE_ = JOIN_FETCH_TYPE + "."; - String JOIN_FETCH_TYPE__INNER = JOIN_FETCH_TYPE_ + "INNER"; - String JOIN_FETCH_TYPE__OUTER = JOIN_FETCH_TYPE_ + "OUTER"; - - String MUTABLE = PACKAGE_ + "Mutable"; - String MUTABLE__VALUE = "value"; - - String OBJECT_TYPE_CONVERTER = PACKAGE_ + "ObjectTypeConverter"; - String OBJECT_TYPE_CONVERTER__NAME = "name"; - String OBJECT_TYPE_CONVERTER__DATE_TYPE = "dataType"; - String OBJECT_TYPE_CONVERTER__OBJECT_TYPE = "objectType"; - String OBJECT_TYPE_CONVERTER__CONVERSION_VALUES = "conversionValues"; - String OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE = "defaultObjectValue"; - - String PRIVATE_OWNED = PACKAGE_ + "PrivateOwned"; - - String READ_ONLY = PACKAGE_ + "ReadOnly"; - - String READ_TRANSFORMER = PACKAGE_ + "ReadTransformer"; - String READ_TRANSFORMER__TRANSFORMER_CLASS = "transformerClass"; - String READ_TRANSFORMER__METHOD = "method"; - - String STRUCT_CONVERTER = PACKAGE_ + "StructConverter"; - String STRUCT_CONVERTER__NAME = "name"; - String STRUCT_CONVERTER__CONVERTER = "converter"; - - String TIME_OF_DAY = PACKAGE_ + "TimeOfDay"; - String TIME_OF_DAY__HOUR = "hour"; - String TIME_OF_DAY__MINUTE = "minute"; - String TIME_OF_DAY__SECOND = "second"; - String TIME_OF_DAY__MILLISECOND = "millisecond"; - - String TRANSFORMATION = PACKAGE_ + "Transformation"; - String TRANSFORMATION__FETCH = "fetch"; - String TRANSFORMATION__OPTIONAL = "optional"; - - String TYPE_CONVERTER = PACKAGE_ + "TypeConverter"; - String TYPE_CONVERTER__NAME = "name"; - String TYPE_CONVERTER__DATE_TYPE = "dataType"; - String TYPE_CONVERTER__OBJECT_TYPE = "objectType"; - - String VARIABLE_ONE_TO_ONE = PACKAGE_ + "VariableOneToOne"; - - String WRITE_TRANSFORMER = PACKAGE_ + "WriteTransformer"; - String WRITE_TRANSFORMER__TRANSFORMER_CLASS = "transformerClass"; - String WRITE_TRANSFORMER__METHOD = "method"; - String WRITE_TRANSFORMER__COLUMN = "column"; - - String WRITE_TRANSFORMERS = PACKAGE_ + "WriteTransformers"; - String WRITE_TRANSFORMERS__VALUE = "value"; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceCheckingAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceCheckingAnnotation.java deleted file mode 100644 index e57b17f093..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceCheckingAnnotation.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.ExistenceChecking annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ExistenceCheckingAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.EXISTENCE_CHECKING; - - /** - * Corresponds to the value element of the ExistenceChecking annotation. - * Returns null if the value element does not exist in java. - */ - ExistenceType getValue(); - - /** - * Corresponds to the value element of the ExistenceChecking annotation. - * Set to null to remove the value element. - */ - void setValue(ExistenceType value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the ExistenceChecking annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceType.java deleted file mode 100644 index b466c2bf2d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ExistenceType.java +++ /dev/null @@ -1,67 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum ExistenceType { - - - CHECK_CACHE, - CHECK_DATABASE, - ASSUME_EXISTENCE, - ASSUME_NON_EXISTENCE; - - public static ExistenceType fromJavaAnnotationValue(Object javaAnnotationValue) { - if (javaAnnotationValue == null) { - return null; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.EXISTENCE_TYPE__CHECK_CACHE)) { - return CHECK_CACHE; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.EXISTENCE_TYPE__CHECK_DATABASE)) { - return CHECK_DATABASE; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.EXISTENCE_TYPE__ASSUME_EXISTENCE)) { - return ASSUME_EXISTENCE; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.EXISTENCE_TYPE__ASSUME_NON_EXISTENCE)) { - return ASSUME_NON_EXISTENCE; - } - return null; - } - - public static String toJavaAnnotationValue(ExistenceType existenceType) { - if (existenceType == null) { - return null; - } - switch (existenceType) { - case CHECK_CACHE : - return EclipseLinkJPA.EXISTENCE_TYPE__CHECK_CACHE; - case CHECK_DATABASE : - return EclipseLinkJPA.EXISTENCE_TYPE__CHECK_DATABASE; - case ASSUME_EXISTENCE : - return EclipseLinkJPA.EXISTENCE_TYPE__ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE : - return EclipseLinkJPA.EXISTENCE_TYPE__ASSUME_NON_EXISTENCE; - default : - throw new IllegalArgumentException("unknown existence type: " + existenceType); //$NON-NLS-1$ - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchAnnotation.java deleted file mode 100644 index ffbb00211a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchAnnotation.java +++ /dev/null @@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.JoinFetch annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface JoinFetchAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.JOIN_FETCH; - - /** - * Corresponds to the value element of the JoinFetch annotation. - * Returns null if the value element does not exist in java. - */ - JoinFetchType getValue(); - - /** - * Corresponds to the value element of the JoinFetch annotation. - * Set to null to remove the value element. - */ - void setValue(JoinFetchType value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the JoinFetch annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchType.java deleted file mode 100644 index c6d183ab28..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/JoinFetchType.java +++ /dev/null @@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.JoinFetchType enum - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public enum JoinFetchType { - - - INNER, - OUTER; - - public static JoinFetchType fromJavaAnnotationValue(Object javaAnnotationValue) { - if (javaAnnotationValue == null) { - return null; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.JOIN_FETCH_TYPE__INNER)) { - return INNER; - } - if (javaAnnotationValue.equals(EclipseLinkJPA.JOIN_FETCH_TYPE__OUTER)) { - return OUTER; - } - return null; - } - - public static String toJavaAnnotationValue(JoinFetchType joinFetchType) { - if (joinFetchType == null) { - return null; - } - switch (joinFetchType) { - case INNER : - return EclipseLinkJPA.JOIN_FETCH_TYPE__INNER; - case OUTER : - return EclipseLinkJPA.JOIN_FETCH_TYPE__OUTER; - default : - throw new IllegalArgumentException("unknown join fetch type: " + joinFetchType); //$NON-NLS-1$ - } - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/MutableAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/MutableAnnotation.java deleted file mode 100644 index f88be1ecf3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/MutableAnnotation.java +++ /dev/null @@ -1,54 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Mutable - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface MutableAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.MUTABLE; - - - /** - * Corresponds to the value element of the Mutable annotation. - * Returns null if the value element does not exist in java. - */ - Boolean getValue(); - - /** - * Corresponds to the value element of the Mutable annotation. - * Set to null to remove the value element. - */ - void setValue(Boolean value); - String VALUE_PROPERTY = "valueProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the value element. If the value element - * does not exist return the {@link TextRange} for the Mutable annotation. - */ - TextRange getValueTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NamedConverterAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NamedConverterAnnotation.java deleted file mode 100644 index f4d0487147..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NamedConverterAnnotation.java +++ /dev/null @@ -1,47 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface NamedConverterAnnotation extends JavaResourceNode -{ - /** - * Corresponds to the name element of the CustomConverter annotation. - * Returns null if the name element does not exist in java. - */ - String getName(); - - /** - * Corresponds to the name element of the CustomConverter annotation. - * Set to null to remove the name element. - */ - void setName(String value); - String NAME_PROPERTY = "nameProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the name element. If the name element - * does not exist return the {@link TextRange} for the CustomConverter annotation. - */ - TextRange getNameTextRange(CompilationUnit astRoot); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NestableConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NestableConversionValue.java deleted file mode 100644 index 464a8e8b91..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/NestableConversionValue.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2007, 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.NestableAnnotation; - -/** - * - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - */ -public interface NestableConversionValue extends ConversionValueAnnotation, NestableAnnotation -{ - // nothing yet -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ObjectTypeConverterAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ObjectTypeConverterAnnotation.java deleted file mode 100644 index 7d8a279f55..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ObjectTypeConverterAnnotation.java +++ /dev/null @@ -1,71 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import java.util.ListIterator; -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.ObjectTypeConverter - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ObjectTypeConverterAnnotation extends TypeConverterAnnotation -{ - String ANNOTATION_NAME = EclipseLinkJPA.OBJECT_TYPE_CONVERTER; - - /** - * Corresponds to the conversionValues element of the ObjectTypeConverter annotation. - * Returns an empty iterator if the conversionValues element does not exist in java. - */ - ListIterator<ConversionValueAnnotation> conversionValues(); - - ConversionValueAnnotation conversionValueAt(int index); - - int indexOfConversionValue(ConversionValueAnnotation conversionValue); - - int conversionValuesSize(); - - ConversionValueAnnotation addConversionValue(int index); - - void removeConversionValue(int index); - - void moveConversionValue(int targetIndex, int sourceIndex); - - String CONVERSION_VALUES_LIST = "conversionValuesList"; //$NON-NLS-1$ - - /** - * Corresponds to the defaultObjectValue element of the ObjectTypeConverter annotation. - * Returns null if the defaultObjectValue element does not exist in java. - */ - String getDefaultObjectValue(); - - /** - * Corresponds to the defaultObjectValue element of the ObjectTypeConverter annotation. - * Set to null to remove the defaultObjectValue element. - */ - void setDefaultObjectValue(String value); - String DEFAULT_OBJECT_VALUE_PROPERTY = "defaultObjectValueProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the defaultObjectValue element. If the defaultObjectValue element - * does not exist return the {@link TextRange} for the ObjectTypeConverter annotation. - */ - TextRange getDefaultObjectValueTextRange(CompilationUnit astRoot); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/PrivateOwnedAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/PrivateOwnedAnnotation.java deleted file mode 100644 index a330c9dae1..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/PrivateOwnedAnnotation.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.JavaResourceNode; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.PrivateOwned annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface PrivateOwnedAnnotation extends JavaResourceNode -{ - String ANNOTATION_NAME = EclipseLinkJPA.PRIVATE_OWNED; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadOnlyAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadOnlyAnnotation.java deleted file mode 100644 index 80e8a5f822..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadOnlyAnnotation.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.JavaResourceNode; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.PrivateOwned annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ReadOnlyAnnotation extends JavaResourceNode -{ - String ANNOTATION_NAME = EclipseLinkJPA.READ_ONLY; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadTransformerAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadTransformerAnnotation.java deleted file mode 100644 index 900198ef6b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/ReadTransformerAnnotation.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.ReadTransformer - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface ReadTransformerAnnotation extends TransformerAnnotation -{ - - String ANNOTATION_NAME = EclipseLinkJPA.READ_TRANSFORMER; - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/StructConverterAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/StructConverterAnnotation.java deleted file mode 100644 index ff01803fee..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/StructConverterAnnotation.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.StructConverter - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface StructConverterAnnotation extends NamedConverterAnnotation -{ - String ANNOTATION_NAME = EclipseLinkJPA.STRUCT_CONVERTER; - - /** - * Corresponds to the converter element of the StructConverter annotation. - * Returns null if the converter element does not exist in java. - */ - String getConverter(); - - /** - * Corresponds to the converter element of the StructConverter annotation. - * Set to null to remove the converter element. - */ - void setConverter(String value); - String CONVERTER_PROPERTY = "converterProperty"; //$NON-NLS-1$ - /** - * Return the {@link TextRange} for the converter element. If the converter element - * does not exist return the {@link TextRange} for the StructConverter annotation. - */ - TextRange getConverterTextRange(CompilationUnit astRoot); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TimeOfDayAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TimeOfDayAnnotation.java deleted file mode 100644 index aa3e008fc3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TimeOfDayAnnotation.java +++ /dev/null @@ -1,113 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Resource model interface that represents the - * org.eclipse.persistence.annotations.TimeOfDay annotation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TimeOfDayAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.TIME_OF_DAY; - - /** - * Corresponds to the hour element of the TimeOfDay annotation. - * Returns null if the hour valuePair does not exist in the annotation - */ - Integer getHour(); - - /** - * Corresponds to the hour element of the TimeOfDay annotation. - * Set to null to remove the hour valuePair from the annotation - */ - void setHour(Integer hour); - String HOUR_PROPERTY = "hourProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the minute element of the TimeOfDay annotation. - * Returns null if the minute valuePair does not exist in the annotation - */ - Integer getMinute(); - - /** - * Corresponds to the minute element of the TimeOfDay annotation. - * Set to null to remove the minute valuePair from the annotation - */ - void setMinute(Integer minute); - String MINUTE_PROPERTY = "minuteProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the second element of the TimeOfDay annotation. - * Returns null if the second valuePair does not exist in the annotation - */ - Integer getSecond(); - - /** - * Corresponds to the second element of the TimeOfDay annotation. - * Set to null to remove the second valuePair from the annotation - */ - void setSecond(Integer second); - String SECOND_PROPERTY = "secondProperty"; //$NON-NLS-1$ - - - /** - * Corresponds to the millisecond element of the TimeOfDay annotation. - * Returns null if the millisecond valuePair does not exist in the annotation - */ - Integer getMillisecond(); - - /** - * Corresponds to the millisecond element of the TimeOfDay annotation. - * Set to null to remove the millisecond valuePair from the annotation - */ - void setMillisecond(Integer millisecond); - String MILLISECOND_PROPERTY = "millisecondProperty"; //$NON-NLS-1$ - - - /** - * Return the {@link TextRange} for the hour element. If the hour element - * does not exist return the {@link TextRange} for the TimeOfDay annotation. - */ - TextRange getHourTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the minute element. If the minute element - * does not exist return the {@link TextRange} for the TimeOfDay annotation. - */ - TextRange getMinuteTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the second element. If the second element - * does not exist return the {@link TextRange} for the TimeOfDay annotation. - */ - TextRange getSecondTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the millisecond element. If the millisecond element - * does not exist return the {@link TextRange} for the TimeOfDay annotation. - */ - TextRange getMillisecondTextRange(CompilationUnit astRoot); - - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformationAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformationAnnotation.java deleted file mode 100644 index 767b30bc6b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformationAnnotation.java +++ /dev/null @@ -1,73 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.FetchType; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.Transformation - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TransformationAnnotation extends JavaResourceNode -{ - - String ANNOTATION_NAME = EclipseLinkJPA.TRANSFORMATION; - - /** - * Corresponds to the fetch element of the Transformation annotation. - * Returns null if the fetch element does not exist in java. - */ - FetchType getFetch(); - - /** - * Corresponds to the fetch element of the Transformation annotation. - * Set to null to remove the fetch element. - */ - void setFetch(FetchType fetch); - String FETCH_PROPERTY = "fetchProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the optional element of the Transformation annotation. - * Returns null if the optional element does not exist in java. - */ - Boolean getOptional(); - - /** - * Corresponds to the optional element of the Transformation annotation. - * Set to null to remove the optional element. - */ - void setOptional(Boolean optional); - String OPTIONAL_PROPERTY = "optionalProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the fetch element. If the fetch element - * does not exist return the {@link TextRange} for the Transformation annotation. - */ - TextRange getFetchTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the optional element. If the optional element - * does not exist return the {@link TextRange} for the Transformation annotation. - */ - TextRange getOptionalTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformerAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformerAnnotation.java deleted file mode 100644 index 0e9952f891..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TransformerAnnotation.java +++ /dev/null @@ -1,72 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.JavaResourceNode; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TransformerAnnotation extends JavaResourceNode -{ - - /** - * Corresponds to the transformerClass element of the *Transformer annotation. - * Returns null if the transformerClass element does not exist in java. - * Returns the portion of the transformerClass preceding the .class. - * <p> - * @ReadTransformer(transformerClass=Employee.class) - * </p> - * will return "Employee" - **/ - String getTransformerClass(); - - /** - * Corresponds to the transformerClass element of the *Transformer annotation. - * Set to null to remove the transformerClass element. - */ - void setTransformerClass(String transformerClass); - String TRANSFORMER_CLASS_PROPERTY = "transformerClassProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the method element of the *Transformer annotation. - * Returns null if the method element does not exist in java. - **/ - String getMethod(); - - /** - * Corresponds to the method element of the *Transformer annotation. - * Set to null to remove the method element. - */ - void setMethod(String method); - String METHOD_PROPERTY = "methodProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the transformerClass element. If the transformerClass element - * does not exist return the {@link TextRange} for the *Transformer annotation. - */ - TextRange getTransformerClassTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the method element. If the method element - * does not exist return the {@link TextRange} for the *Transformer annotation. - */ - TextRange getMethodTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TypeConverterAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TypeConverterAnnotation.java deleted file mode 100644 index 60aa8a78df..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/TypeConverterAnnotation.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.TypeConverter - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface TypeConverterAnnotation extends NamedConverterAnnotation -{ - String ANNOTATION_NAME = EclipseLinkJPA.TYPE_CONVERTER; - - /** - * Corresponds to the dataType element of the TypeConverter annotation. - * Returns null if the dataType element does not exist in java. - */ - String getDataType(); - - /** - * Corresponds to the dataType element of the TypeConverter annotation. - * Set to null to remove the dataType element. - */ - void setDataType(String value); - String DATA_TYPE_PROPERTY = "dataTypeProperty"; //$NON-NLS-1$ - - /** - * Corresponds to the objectType element of the TypeConverter annotation. - * Returns null if the objectType element does not exist in java. - */ - String getObjectType(); - - /** - * Corresponds to the objectType element of the TypeConverter annotation. - * Set to null to remove the objectType element. - */ - void setObjectType(String value); - String OBJECT_TYPE_PROPERTY = "objectTypeProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the dataType element. If the dataType element - * does not exist return the {@link TextRange} for the TypeConverter annotation. - */ - TextRange getDataTypeTextRange(CompilationUnit astRoot); - - /** - * Return the {@link TextRange} for the objectType element. If the objectType element - * does not exist return the {@link TextRange} for the TypeConverter annotation. - */ - TextRange getObjectTypeTextRange(CompilationUnit astRoot); -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/VariableOneToOneAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/VariableOneToOneAnnotation.java deleted file mode 100644 index 21358f6113..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/VariableOneToOneAnnotation.java +++ /dev/null @@ -1,30 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jpt.core.resource.java.JavaResourceNode; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.VariableOneToOne - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - */ -public interface VariableOneToOneAnnotation extends JavaResourceNode -{ - String ANNOTATION_NAME = EclipseLinkJPA.VARIABLE_ONE_TO_ONE; -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/WriteTransformerAnnotation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/WriteTransformerAnnotation.java deleted file mode 100644 index 09f2dd96b6..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/java/WriteTransformerAnnotation.java +++ /dev/null @@ -1,65 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.java; - -import org.eclipse.jdt.core.dom.CompilationUnit; -import org.eclipse.jpt.core.resource.java.ColumnAnnotation; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * Java resource model interface that corresponds to the Eclipselink - * annotation org.eclipse.persistence.annotations.WriteTransformer - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public interface WriteTransformerAnnotation extends TransformerAnnotation -{ - - String ANNOTATION_NAME = EclipseLinkJPA.WRITE_TRANSFORMER; - - /** - * Corresponds to the column element of the WriteTransformer annotation. - * Returns null if the column element does not exist in java. - */ - ColumnAnnotation getColumn(); - - /** - * Add the column element to the WriteTransformer annotation. - */ - ColumnAnnotation addColumn(); - - /** - * Remove the column element from the WriteTransformer annotation. - */ - void removeColumn(); - - /** - * Return a ColumnAnnotation, but do not return null if the column - * element does not exist on the WriteTransformer annotation. Instead - * return a null object. - */ - ColumnAnnotation getNonNullColumn(); - - String COLUMN_PROPERTY = "columnProperty"; //$NON-NLS-1$ - - /** - * Return the {@link TextRange} for the column element. If the column element - * does not exist return the {@link TextRange} for the WriteTransformer annotation. - */ - TextRange getColumnTextRange(CompilationUnit astRoot); - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/Attributes.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/Attributes.java deleted file mode 100644 index 435091012f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/Attributes.java +++ /dev/null @@ -1,352 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; - -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.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; -import org.eclipse.jpt.utility.internal.CollectionTools; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Attributes</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicCollections <em>Basic Collections</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicMaps <em>Basic Maps</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getTransformations <em>Transformations</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getVariableOneToOnes <em>Variable One To Ones</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes() - * @model kind="class" - * @generated - */ -public class Attributes extends org.eclipse.jpt.core.resource.orm.Attributes -{ - /** - * The cached value of the '{@link #getBasicCollections() <em>Basic Collections</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getBasicCollections() - * @generated - * @ordered - */ - protected EList<XmlBasicCollection> basicCollections; - - /** - * The cached value of the '{@link #getBasicMaps() <em>Basic Maps</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getBasicMaps() - * @generated - * @ordered - */ - protected EList<XmlBasicMap> basicMaps; - - /** - * The cached value of the '{@link #getTransformations() <em>Transformations</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTransformations() - * @generated - * @ordered - */ - protected EList<XmlTransformation> transformations; - - /** - * The cached value of the '{@link #getVariableOneToOnes() <em>Variable One To Ones</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getVariableOneToOnes() - * @generated - * @ordered - */ - protected EList<XmlVariableOneToOne> variableOneToOnes; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected Attributes() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.ATTRIBUTES; - } - - /** - * Returns the value of the '<em><b>Basic Collections</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Basic Collections</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>Basic Collections</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes_BasicCollections() - * @model containment="true" - * @generated - */ - public EList<XmlBasicCollection> getBasicCollections() - { - if (basicCollections == null) - { - basicCollections = new EObjectContainmentEList<XmlBasicCollection>(XmlBasicCollection.class, this, EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS); - } - return basicCollections; - } - - /** - * Returns the value of the '<em><b>Basic Maps</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Basic Maps</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>Basic Maps</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes_BasicMaps() - * @model containment="true" - * @generated - */ - public EList<XmlBasicMap> getBasicMaps() - { - if (basicMaps == null) - { - basicMaps = new EObjectContainmentEList<XmlBasicMap>(XmlBasicMap.class, this, EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS); - } - return basicMaps; - } - - /** - * Returns the value of the '<em><b>Transformations</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Transformations</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>Transformations</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes_Transformations() - * @model containment="true" - * @generated - */ - public EList<XmlTransformation> getTransformations() - { - if (transformations == null) - { - transformations = new EObjectContainmentEList<XmlTransformation>(XmlTransformation.class, this, EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS); - } - return transformations; - } - - /** - * Returns the value of the '<em><b>Variable One To Ones</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Variable One To Ones</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>Variable One To Ones</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes_VariableOneToOnes() - * @model containment="true" - * @generated - */ - public EList<XmlVariableOneToOne> getVariableOneToOnes() - { - if (variableOneToOnes == null) - { - variableOneToOnes = new EObjectContainmentEList<XmlVariableOneToOne>(XmlVariableOneToOne.class, this, EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES); - } - return variableOneToOnes; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS: - return ((InternalEList<?>)getBasicCollections()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS: - return ((InternalEList<?>)getBasicMaps()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS: - return ((InternalEList<?>)getTransformations()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES: - return ((InternalEList<?>)getVariableOneToOnes()).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 EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS: - return getBasicCollections(); - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS: - return getBasicMaps(); - case EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS: - return getTransformations(); - case EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES: - return getVariableOneToOnes(); - } - 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 EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS: - getBasicCollections().clear(); - getBasicCollections().addAll((Collection<? extends XmlBasicCollection>)newValue); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS: - getBasicMaps().clear(); - getBasicMaps().addAll((Collection<? extends XmlBasicMap>)newValue); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS: - getTransformations().clear(); - getTransformations().addAll((Collection<? extends XmlTransformation>)newValue); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES: - getVariableOneToOnes().clear(); - getVariableOneToOnes().addAll((Collection<? extends XmlVariableOneToOne>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS: - getBasicCollections().clear(); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS: - getBasicMaps().clear(); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS: - getTransformations().clear(); - return; - case EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES: - getVariableOneToOnes().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_COLLECTIONS: - return basicCollections != null && !basicCollections.isEmpty(); - case EclipseLinkOrmPackage.ATTRIBUTES__BASIC_MAPS: - return basicMaps != null && !basicMaps.isEmpty(); - case EclipseLinkOrmPackage.ATTRIBUTES__TRANSFORMATIONS: - return transformations != null && !transformations.isEmpty(); - case EclipseLinkOrmPackage.ATTRIBUTES__VARIABLE_ONE_TO_ONES: - return variableOneToOnes != null && !variableOneToOnes.isEmpty(); - } - return super.eIsSet(featureID); - } - - @Override - public List<XmlAttributeMapping> getAttributeMappings() { - // convert lists to arrays to avoid ConcurrentModificationException while adding to result list - ArrayList<XmlAttributeMapping> attributeMappings = new ArrayList<XmlAttributeMapping>(); - CollectionTools.addAll(attributeMappings, this.getIds().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getEmbeddedIds().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getBasics().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getBasicCollections().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getBasicMaps().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getVersions().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getManyToOnes().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getOneToManys().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getOneToOnes().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getVariableOneToOnes().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getManyToManys().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getEmbeddeds().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getTransformations().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - CollectionTools.addAll(attributeMappings, this.getTransients().toArray(EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY)); - return attributeMappings; - } - - protected static final XmlAttributeMapping[] EMPTY_XML_ATTRIBUTE_MAPPING_ARRAY = new XmlAttributeMapping[0]; - -} // Attributes diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheCoordinationType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheCoordinationType.java deleted file mode 100644 index c050c8178d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheCoordinationType.java +++ /dev/null @@ -1,294 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * - * A representation of the literals of the enumeration '<em><b>Cache Coordination Type</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheCoordinationType() - * @model - * @generated - */ -public enum CacheCoordinationType implements Enumerator -{ - /** - * The '<em><b>SEND OBJECT CHANGES</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #SEND_OBJECT_CHANGES_VALUE - * @generated - * @ordered - */ - SEND_OBJECT_CHANGES(0, "SEND_OBJECT_CHANGES", "SEND_OBJECT_CHANGES"), - - /** - * The '<em><b>INVALIDATE CHANGED OBJECTS</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #INVALIDATE_CHANGED_OBJECTS_VALUE - * @generated - * @ordered - */ - INVALIDATE_CHANGED_OBJECTS(1, "INVALIDATE_CHANGED_OBJECTS", "INVALIDATE_CHANGED_OBJECTS"), - - /** - * The '<em><b>SEND NEW OBJECTS WITH CHANGES</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #SEND_NEW_OBJECTS_WITH_CHANGES_VALUE - * @generated - * @ordered - */ - SEND_NEW_OBJECTS_WITH_CHANGES(2, "SEND_NEW_OBJECTS_WITH_CHANGES", "SEND_NEW_OBJECTS_WITH_CHANGES"), - - /** - * The '<em><b>NONE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #NONE_VALUE - * @generated - * @ordered - */ - NONE(3, "NONE", "NONE"); - - /** - * The '<em><b>SEND OBJECT CHANGES</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>SEND OBJECT CHANGES</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #SEND_OBJECT_CHANGES - * @model - * @generated - * @ordered - */ - public static final int SEND_OBJECT_CHANGES_VALUE = 0; - - /** - * The '<em><b>INVALIDATE CHANGED OBJECTS</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>INVALIDATE CHANGED OBJECTS</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #INVALIDATE_CHANGED_OBJECTS - * @model - * @generated - * @ordered - */ - public static final int INVALIDATE_CHANGED_OBJECTS_VALUE = 1; - - /** - * The '<em><b>SEND NEW OBJECTS WITH CHANGES</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>SEND NEW OBJECTS WITH CHANGES</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #SEND_NEW_OBJECTS_WITH_CHANGES - * @model - * @generated - * @ordered - */ - public static final int SEND_NEW_OBJECTS_WITH_CHANGES_VALUE = 2; - - /** - * The '<em><b>NONE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>NONE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #NONE - * @model - * @generated - * @ordered - */ - public static final int NONE_VALUE = 3; - - /** - * An array of all the '<em><b>Cache Coordination Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final CacheCoordinationType[] VALUES_ARRAY = - new CacheCoordinationType[] - { - SEND_OBJECT_CHANGES, - INVALIDATE_CHANGED_OBJECTS, - SEND_NEW_OBJECTS_WITH_CHANGES, - NONE, - }; - - /** - * A public read-only list of all the '<em><b>Cache Coordination Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<CacheCoordinationType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Cache Coordination Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheCoordinationType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - CacheCoordinationType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Cache Coordination Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheCoordinationType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - CacheCoordinationType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Cache Coordination Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheCoordinationType get(int value) - { - switch (value) - { - case SEND_OBJECT_CHANGES_VALUE: return SEND_OBJECT_CHANGES; - case INVALIDATE_CHANGED_OBJECTS_VALUE: return INVALIDATE_CHANGED_OBJECTS; - case SEND_NEW_OBJECTS_WITH_CHANGES_VALUE: return SEND_NEW_OBJECTS_WITH_CHANGES; - case NONE_VALUE: return NONE; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private CacheCoordinationType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //CacheCoordinationType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheType.java deleted file mode 100644 index 8515373d69..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/CacheType.java +++ /dev/null @@ -1,372 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheType() - * @model - * @generated - */ -public enum CacheType implements Enumerator -{ - /** - * The '<em><b>FULL</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #FULL_VALUE - * @generated - * @ordered - */ - FULL(0, "FULL", "FULL"), - - /** - * The '<em><b>WEAK</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #WEAK_VALUE - * @generated - * @ordered - */ - WEAK(1, "WEAK", "WEAK"), - - /** - * The '<em><b>SOFT</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #SOFT_VALUE - * @generated - * @ordered - */ - SOFT(2, "SOFT", "SOFT"), - - /** - * The '<em><b>SOFT WEAK</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #SOFT_WEAK_VALUE - * @generated - * @ordered - */ - SOFT_WEAK(3, "SOFT_WEAK", "SOFT_WEAK"), - - /** - * The '<em><b>HARD WEAK</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #HARD_WEAK_VALUE - * @generated - * @ordered - */ - HARD_WEAK(4, "HARD_WEAK", "HARD_WEAK"), - - /** - * The '<em><b>CACHE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #CACHE_VALUE - * @generated - * @ordered - */ - CACHE(5, "CACHE", "CACHE"), - - /** - * The '<em><b>NONE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #NONE_VALUE - * @generated - * @ordered - */ - NONE(6, "NONE", "NONE"); - - /** - * The '<em><b>FULL</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>FULL</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #FULL - * @model - * @generated - * @ordered - */ - public static final int FULL_VALUE = 0; - - /** - * The '<em><b>WEAK</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>WEAK</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #WEAK - * @model - * @generated - * @ordered - */ - public static final int WEAK_VALUE = 1; - - /** - * The '<em><b>SOFT</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>SOFT</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #SOFT - * @model - * @generated - * @ordered - */ - public static final int SOFT_VALUE = 2; - - /** - * The '<em><b>SOFT WEAK</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>SOFT WEAK</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #SOFT_WEAK - * @model - * @generated - * @ordered - */ - public static final int SOFT_WEAK_VALUE = 3; - - /** - * The '<em><b>HARD WEAK</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>HARD WEAK</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #HARD_WEAK - * @model - * @generated - * @ordered - */ - public static final int HARD_WEAK_VALUE = 4; - - /** - * The '<em><b>CACHE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>CACHE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #CACHE - * @model - * @generated - * @ordered - */ - public static final int CACHE_VALUE = 5; - - /** - * The '<em><b>NONE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>NONE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #NONE - * @model - * @generated - * @ordered - */ - public static final int NONE_VALUE = 6; - - /** - * An array of all the '<em><b>Cache Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final CacheType[] VALUES_ARRAY = - new CacheType[] - { - FULL, - WEAK, - SOFT, - SOFT_WEAK, - HARD_WEAK, - CACHE, - NONE, - }; - - /** - * A public read-only list of all the '<em><b>Cache Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<CacheType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Cache Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - CacheType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Cache Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - CacheType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Cache Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static CacheType get(int value) - { - switch (value) - { - case FULL_VALUE: return FULL; - case WEAK_VALUE: return WEAK; - case SOFT_VALUE: return SOFT; - case SOFT_WEAK_VALUE: return SOFT_WEAK; - case HARD_WEAK_VALUE: return HARD_WEAK; - case CACHE_VALUE: return CACHE; - case NONE_VALUE: return NONE; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private CacheType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //CacheType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmFactory.java deleted file mode 100644 index a8b5be6480..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmFactory.java +++ /dev/null @@ -1,761 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.impl.EFactoryImpl; -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -/** - * <!-- begin-user-doc --> - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage - * @generated - */ -public class EclipseLinkOrmFactory extends EFactoryImpl -{ - /** - * The singleton instance of the factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EclipseLinkOrmFactory eINSTANCE = init(); - - /** - * Creates the default factory implementation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static EclipseLinkOrmFactory init() - { - try - { - EclipseLinkOrmFactory theEclipseLinkOrmFactory = (EclipseLinkOrmFactory)EPackage.Registry.INSTANCE.getEFactory("jpt.eclipselink.orm.xmi"); - if (theEclipseLinkOrmFactory != null) - { - return theEclipseLinkOrmFactory; - } - } - catch (Exception exception) - { - EcorePlugin.INSTANCE.log(exception); - } - return new EclipseLinkOrmFactory(); - } - - /** - * Creates an instance of the factory. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public EclipseLinkOrmFactory() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public EObject create(EClass eClass) - { - switch (eClass.getClassifierID()) - { - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL: return (EObject)createXmlConverterImpl(); - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL: return (EObject)createXmlTypeConverterImpl(); - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL: return (EObject)createXmlConversionValueImpl(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL: return (EObject)createXmlObjectTypeConverterImpl(); - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL: return (EObject)createXmlStructConverterImpl(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER: return (EObject)createXmlStoredProcedureParameter(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY: return (EObject)createXmlNamedStoredProcedureQuery(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS: return (EObject)createXmlEntityMappings(); - case EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA: return (EObject)createXmlPersistenceUnitMetadata(); - case EclipseLinkOrmPackage.XML_CUSTOMIZER: return (EObject)createXmlCustomizer(); - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING: return (EObject)createXmlChangeTracking(); - case EclipseLinkOrmPackage.XML_COPY_POLICY: return (EObject)createXmlCopyPolicy(); - case EclipseLinkOrmPackage.XML_INSTANTIATION_POLICY: return (EObject)createXmlInstantiationPolicy(); - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY: return (EObject)createXmlCloneCopyPolicy(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE: return (EObject)createXmlEmbeddable(); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY: return (EObject)createXmlTimeOfDay(); - case EclipseLinkOrmPackage.XML_CACHE: return (EObject)createXmlCache(); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING: return (EObject)createXmlOptimisticLocking(); - case EclipseLinkOrmPackage.XML_ENTITY: return (EObject)createXmlEntity(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS: return (EObject)createXmlMappedSuperclass(); - case EclipseLinkOrmPackage.XML_ACCESS_METHODS: return (EObject)createXmlAccessMethods(); - case EclipseLinkOrmPackage.XML_PROPERTY: return (EObject)createXmlProperty(); - case EclipseLinkOrmPackage.XML_ID_IMPL: return (EObject)createXmlIdImpl(); - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL: return (EObject)createXmlEmbeddedIdImpl(); - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL: return (EObject)createXmlEmbeddedImpl(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL: return (EObject)createXmlBasicImpl(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL: return (EObject)createXmlVersionImpl(); - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL: return (EObject)createXmlOneToOneImpl(); - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL: return (EObject)createXmlOneToManyImpl(); - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL: return (EObject)createXmlManyToOneImpl(); - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL: return (EObject)createXmlManyToManyImpl(); - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL: return (EObject)createXmlBasicCollectionImpl(); - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL: return (EObject)createXmlBasicMapImpl(); - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL: return (EObject)createXmlTransformationImpl(); - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL: return (EObject)createXmlVariableOneToOneImpl(); - case EclipseLinkOrmPackage.ATTRIBUTES: return (EObject)createAttributes(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object createFromString(EDataType eDataType, String initialValue) - { - switch (eDataType.getClassifierID()) - { - case EclipseLinkOrmPackage.XML_DIRECTION: - return createXmlDirectionFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING_TYPE: - return createXmlChangeTrackingTypeFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.CACHE_TYPE: - return createCacheTypeFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.CACHE_COORDINATION_TYPE: - return createCacheCoordinationTypeFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.EXISTENCE_TYPE: - return createExistenceTypeFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING_TYPE: - return createXmlOptimisticLockingTypeFromString(eDataType, initialValue); - case EclipseLinkOrmPackage.XML_JOIN_FETCH_TYPE: - return createXmlJoinFetchTypeFromString(eDataType, initialValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String convertToString(EDataType eDataType, Object instanceValue) - { - switch (eDataType.getClassifierID()) - { - case EclipseLinkOrmPackage.XML_DIRECTION: - return convertXmlDirectionToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING_TYPE: - return convertXmlChangeTrackingTypeToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.CACHE_TYPE: - return convertCacheTypeToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.CACHE_COORDINATION_TYPE: - return convertCacheCoordinationTypeToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.EXISTENCE_TYPE: - return convertExistenceTypeToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING_TYPE: - return convertXmlOptimisticLockingTypeToString(eDataType, instanceValue); - case EclipseLinkOrmPackage.XML_JOIN_FETCH_TYPE: - return convertXmlJoinFetchTypeToString(eDataType, instanceValue); - default: - throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); - } - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlEntityMappings createXmlEntityMappings() - { - XmlEntityMappings xmlEntityMappings = new XmlEntityMappings(); - return xmlEntityMappings; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlPersistenceUnitMetadata createXmlPersistenceUnitMetadata() - { - XmlPersistenceUnitMetadata xmlPersistenceUnitMetadata = new XmlPersistenceUnitMetadata(); - return xmlPersistenceUnitMetadata; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlCustomizer createXmlCustomizer() - { - XmlCustomizer xmlCustomizer = new XmlCustomizer(); - return xmlCustomizer; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlChangeTracking createXmlChangeTracking() - { - XmlChangeTracking xmlChangeTracking = new XmlChangeTracking(); - return xmlChangeTracking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlCopyPolicy createXmlCopyPolicy() - { - XmlCopyPolicy xmlCopyPolicy = new XmlCopyPolicy(); - return xmlCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlInstantiationPolicy createXmlInstantiationPolicy() - { - XmlInstantiationPolicy xmlInstantiationPolicy = new XmlInstantiationPolicy(); - return xmlInstantiationPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlCloneCopyPolicy createXmlCloneCopyPolicy() - { - XmlCloneCopyPolicy xmlCloneCopyPolicy = new XmlCloneCopyPolicy(); - return xmlCloneCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlEmbeddable createXmlEmbeddable() - { - XmlEmbeddable xmlEmbeddable = new XmlEmbeddable(); - return xmlEmbeddable; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlEntity createXmlEntity() - { - XmlEntity xmlEntity = new XmlEntity(); - return xmlEntity; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlMappedSuperclass createXmlMappedSuperclass() - { - XmlMappedSuperclass xmlMappedSuperclass = new XmlMappedSuperclass(); - return xmlMappedSuperclass; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlAccessMethods createXmlAccessMethods() - { - XmlAccessMethods xmlAccessMethods = new XmlAccessMethods(); - return xmlAccessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlConverterImpl createXmlConverterImpl() - { - XmlConverterImpl xmlConverterImpl = new XmlConverterImpl(); - return xmlConverterImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlTypeConverterImpl createXmlTypeConverterImpl() - { - XmlTypeConverterImpl xmlTypeConverterImpl = new XmlTypeConverterImpl(); - return xmlTypeConverterImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlConversionValueImpl createXmlConversionValueImpl() - { - XmlConversionValueImpl xmlConversionValueImpl = new XmlConversionValueImpl(); - return xmlConversionValueImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlObjectTypeConverterImpl createXmlObjectTypeConverterImpl() - { - XmlObjectTypeConverterImpl xmlObjectTypeConverterImpl = new XmlObjectTypeConverterImpl(); - return xmlObjectTypeConverterImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlStructConverterImpl createXmlStructConverterImpl() - { - XmlStructConverterImpl xmlStructConverterImpl = new XmlStructConverterImpl(); - return xmlStructConverterImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlStoredProcedureParameter createXmlStoredProcedureParameter() - { - XmlStoredProcedureParameter xmlStoredProcedureParameter = new XmlStoredProcedureParameter(); - return xmlStoredProcedureParameter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlNamedStoredProcedureQuery createXmlNamedStoredProcedureQuery() - { - XmlNamedStoredProcedureQuery xmlNamedStoredProcedureQuery = new XmlNamedStoredProcedureQuery(); - return xmlNamedStoredProcedureQuery; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlIdImpl createXmlIdImpl() - { - XmlIdImpl xmlIdImpl = new XmlIdImpl(); - return xmlIdImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlEmbeddedIdImpl createXmlEmbeddedIdImpl() - { - XmlEmbeddedIdImpl xmlEmbeddedIdImpl = new XmlEmbeddedIdImpl(); - return xmlEmbeddedIdImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlEmbeddedImpl createXmlEmbeddedImpl() - { - XmlEmbeddedImpl xmlEmbeddedImpl = new XmlEmbeddedImpl(); - return xmlEmbeddedImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlBasicImpl createXmlBasicImpl() - { - XmlBasicImpl xmlBasicImpl = new XmlBasicImpl(); - return xmlBasicImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlVersionImpl createXmlVersionImpl() - { - XmlVersionImpl xmlVersionImpl = new XmlVersionImpl(); - return xmlVersionImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlOneToOneImpl createXmlOneToOneImpl() - { - XmlOneToOneImpl xmlOneToOneImpl = new XmlOneToOneImpl(); - return xmlOneToOneImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlOneToManyImpl createXmlOneToManyImpl() - { - XmlOneToManyImpl xmlOneToManyImpl = new XmlOneToManyImpl(); - return xmlOneToManyImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlManyToOneImpl createXmlManyToOneImpl() - { - XmlManyToOneImpl xmlManyToOneImpl = new XmlManyToOneImpl(); - return xmlManyToOneImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlManyToManyImpl createXmlManyToManyImpl() - { - XmlManyToManyImpl xmlManyToManyImpl = new XmlManyToManyImpl(); - return xmlManyToManyImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public Attributes createAttributes() - { - Attributes attributes = new Attributes(); - return attributes; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlBasicCollectionImpl createXmlBasicCollectionImpl() - { - XmlBasicCollectionImpl xmlBasicCollectionImpl = new XmlBasicCollectionImpl(); - return xmlBasicCollectionImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlBasicMapImpl createXmlBasicMapImpl() - { - XmlBasicMapImpl xmlBasicMapImpl = new XmlBasicMapImpl(); - return xmlBasicMapImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlTransformationImpl createXmlTransformationImpl() - { - XmlTransformationImpl xmlTransformationImpl = new XmlTransformationImpl(); - return xmlTransformationImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlProperty createXmlProperty() - { - XmlProperty xmlProperty = new XmlProperty(); - return xmlProperty; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlVariableOneToOneImpl createXmlVariableOneToOneImpl() - { - XmlVariableOneToOneImpl xmlVariableOneToOneImpl = new XmlVariableOneToOneImpl(); - return xmlVariableOneToOneImpl; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlDirection createXmlDirectionFromString(EDataType eDataType, String initialValue) - { - XmlDirection result = XmlDirection.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertXmlDirectionToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlChangeTrackingType createXmlChangeTrackingTypeFromString(EDataType eDataType, String initialValue) - { - XmlChangeTrackingType result = XmlChangeTrackingType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertXmlChangeTrackingTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlTimeOfDay createXmlTimeOfDay() - { - XmlTimeOfDay xmlTimeOfDay = new XmlTimeOfDay(); - return xmlTimeOfDay; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlCache createXmlCache() - { - XmlCache xmlCache = new XmlCache(); - return xmlCache; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlOptimisticLocking createXmlOptimisticLocking() - { - XmlOptimisticLocking xmlOptimisticLocking = new XmlOptimisticLocking(); - return xmlOptimisticLocking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlJoinFetchType createXmlJoinFetchTypeFromString(EDataType eDataType, String initialValue) - { - XmlJoinFetchType result = XmlJoinFetchType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertXmlJoinFetchTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public CacheType createCacheTypeFromString(EDataType eDataType, String initialValue) - { - CacheType result = CacheType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertCacheTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public CacheCoordinationType createCacheCoordinationTypeFromString(EDataType eDataType, String initialValue) - { - CacheCoordinationType result = CacheCoordinationType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertCacheCoordinationTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public ExistenceType createExistenceTypeFromString(EDataType eDataType, String initialValue) - { - ExistenceType result = ExistenceType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertExistenceTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public XmlOptimisticLockingType createXmlOptimisticLockingTypeFromString(EDataType eDataType, String initialValue) - { - XmlOptimisticLockingType result = XmlOptimisticLockingType.get(initialValue); - if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); - return result; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String convertXmlOptimisticLockingTypeToString(EDataType eDataType, Object instanceValue) - { - return instanceValue == null ? null : instanceValue.toString(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public EclipseLinkOrmPackage getEclipseLinkOrmPackage() - { - return (EclipseLinkOrmPackage)getEPackage(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @deprecated - * @generated - */ - @Deprecated - public static EclipseLinkOrmPackage getPackage() - { - return EclipseLinkOrmPackage.eINSTANCE; - } - -} //EclipseLinkOrmFactory diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmPackage.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmPackage.java deleted file mode 100644 index 3a1bb870cb..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmPackage.java +++ /dev/null @@ -1,10830 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.ecore.xml.type.XMLTypePackage; -import org.eclipse.jpt.core.resource.orm.OrmPackage; - -/** - * <!-- begin-user-doc --> - * - * The <b>Package</b> for the model. - * It contains accessors for the meta objects to represent - * <ul> - * <li>each class,</li> - * <li>each feature of each class,</li> - * <li>each enum,</li> - * <li>and each data type</li> - * </ul> - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmFactory - * @model kind="package" - * @generated - */ -public class EclipseLinkOrmPackage extends EPackageImpl -{ - /** - * The package name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final String eNAME = "orm"; - - /** - * The package namespace URI. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final String eNS_URI = "jpt.eclipselink.orm.xmi"; - - /** - * The package namespace name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final String eNS_PREFIX = "org.eclipse.jpt.eclipselink.core.resource.orm"; - - /** - * The singleton instance of the package. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EclipseLinkOrmPackage eINSTANCE = org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage.init(); - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter <em>Xml Named Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter() - * @generated - */ - public static final int XML_NAMED_CONVERTER = 0; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_CONVERTER__NAME = 0; - - /** - * The number of structural features of the '<em>Xml Named Converter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_CONVERTER_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer <em>Xml Customizer</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizer() - * @generated - */ - public static final int XML_CUSTOMIZER = 16; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder <em>Xml Customizer Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder() - * @generated - */ - public static final int XML_CUSTOMIZER_HOLDER = 17; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder <em>Xml Converters Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder() - * @generated - */ - public static final int XML_CONVERTERS_HOLDER = 11; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings <em>Xml Entity Mappings</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntityMappings() - * @generated - */ - public static final int XML_ENTITY_MAPPINGS = 14; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking <em>Xml Change Tracking</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTracking() - * @generated - */ - public static final int XML_CHANGE_TRACKING = 18; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder <em>Xml Change Tracking Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder() - * @generated - */ - public static final int XML_CHANGE_TRACKING_HOLDER = 19; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable <em>Xml Embeddable</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable() - * @generated - */ - public static final int XML_EMBEDDABLE = 23; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly <em>Xml Read Only</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly() - * @generated - */ - public static final int XML_READ_ONLY = 24; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay <em>Xml Time Of Day</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay() - * @generated - */ - public static final int XML_TIME_OF_DAY = 25; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache <em>Xml Cache</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache() - * @generated - */ - public static final int XML_CACHE = 26; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder <em>Xml Cache Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder() - * @generated - */ - public static final int XML_CACHE_HOLDER = 27; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity <em>Xml Entity</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity() - * @generated - */ - public static final int XML_ENTITY = 29; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass <em>Xml Mapped Superclass</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass() - * @generated - */ - public static final int XML_MAPPED_SUPERCLASS = 30; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable <em>Xml Mutable</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable() - * @generated - */ - public static final int XML_MUTABLE = 31; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping <em>Xml Convertible Mapping</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping() - * @generated - */ - public static final int XML_CONVERTIBLE_MAPPING = 33; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlId <em>Xml Id</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlId - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlId() - * @generated - */ - public static final int XML_ID = 37; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl <em>Xml Id Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlIdImpl() - * @generated - */ - public static final int XML_ID_IMPL = 38; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic <em>Xml Basic</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasic() - * @generated - */ - public static final int XML_BASIC = 43; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl <em>Xml Basic Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicImpl() - * @generated - */ - public static final int XML_BASIC_IMPL = 44; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion <em>Xml Version</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersion() - * @generated - */ - public static final int XML_VERSION = 45; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl <em>Xml Version Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersionImpl() - * @generated - */ - public static final int XML_VERSION_IMPL = 46; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned <em>Xml Private Owned</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned() - * @generated - */ - public static final int XML_PRIVATE_OWNED = 47; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch <em>Xml Join Fetch</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch() - * @generated - */ - public static final int XML_JOIN_FETCH = 48; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne <em>Xml One To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOne() - * @generated - */ - public static final int XML_ONE_TO_ONE = 49; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl <em>Xml One To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOneImpl() - * @generated - */ - public static final int XML_ONE_TO_ONE_IMPL = 50; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany <em>Xml One To Many</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToMany() - * @generated - */ - public static final int XML_ONE_TO_MANY = 51; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl <em>Xml One To Many Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToManyImpl() - * @generated - */ - public static final int XML_ONE_TO_MANY_IMPL = 52; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne <em>Xml Many To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOne() - * @generated - */ - public static final int XML_MANY_TO_ONE = 53; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl <em>Xml Many To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOneImpl() - * @generated - */ - public static final int XML_MANY_TO_ONE_IMPL = 54; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany <em>Xml Many To Many</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToMany() - * @generated - */ - public static final int XML_MANY_TO_MANY = 55; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl <em>Xml Many To Many Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToManyImpl() - * @generated - */ - public static final int XML_MANY_TO_MANY_IMPL = 56; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter <em>Xml Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverter() - * @generated - */ - public static final int XML_CONVERTER = 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter <em>Xml Type Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter() - * @generated - */ - public static final int XML_TYPE_CONVERTER = 3; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue <em>Xml Conversion Value</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue() - * @generated - */ - public static final int XML_CONVERSION_VALUE = 5; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter <em>Xml Object Type Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter() - * @generated - */ - public static final int XML_OBJECT_TYPE_CONVERTER = 7; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter <em>Xml Struct Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverter() - * @generated - */ - public static final int XML_STRUCT_CONVERTER = 9; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder <em>Xml Converter Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder() - * @generated - */ - public static final int XML_CONVERTER_HOLDER = 32; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER__NAME = XML_NAMED_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER__CLASS_NAME = XML_NAMED_CONVERTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the '<em>Xml Converter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_FEATURE_COUNT = XML_NAMED_CONVERTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl <em>Xml Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterImpl() - * @generated - */ - public static final int XML_CONVERTER_IMPL = 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_IMPL__NAME = XML_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_IMPL__CLASS_NAME = XML_CONVERTER__CLASS_NAME; - - /** - * The number of structural features of the '<em>Xml Converter Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_IMPL_FEATURE_COUNT = XML_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER__NAME = XML_NAMED_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER__DATA_TYPE = XML_NAMED_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER__OBJECT_TYPE = XML_NAMED_CONVERTER_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Type Converter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER_FEATURE_COUNT = XML_NAMED_CONVERTER_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl <em>Xml Type Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverterImpl() - * @generated - */ - public static final int XML_TYPE_CONVERTER_IMPL = 4; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER_IMPL__NAME = XML_TYPE_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER_IMPL__DATA_TYPE = XML_TYPE_CONVERTER__DATA_TYPE; - - /** - * The feature id for the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE = XML_TYPE_CONVERTER__OBJECT_TYPE; - - /** - * The number of structural features of the '<em>Xml Type Converter Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TYPE_CONVERTER_IMPL_FEATURE_COUNT = XML_TYPE_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Data Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE__DATA_VALUE = 0; - - /** - * The feature id for the '<em><b>Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE__OBJECT_VALUE = 1; - - /** - * The number of structural features of the '<em>Xml Conversion Value</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE_FEATURE_COUNT = 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl <em>Xml Conversion Value Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValueImpl() - * @generated - */ - public static final int XML_CONVERSION_VALUE_IMPL = 6; - - /** - * The feature id for the '<em><b>Data Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE_IMPL__DATA_VALUE = XML_CONVERSION_VALUE__DATA_VALUE; - - /** - * The feature id for the '<em><b>Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE = XML_CONVERSION_VALUE__OBJECT_VALUE; - - /** - * The number of structural features of the '<em>Xml Conversion Value Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERSION_VALUE_IMPL_FEATURE_COUNT = XML_CONVERSION_VALUE_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER__NAME = XML_NAMED_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER__DATA_TYPE = XML_NAMED_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER__OBJECT_TYPE = XML_NAMED_CONVERTER_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Conversion Values</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER__CONVERSION_VALUES = XML_NAMED_CONVERTER_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Default Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE = XML_NAMED_CONVERTER_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Xml Object Type Converter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_FEATURE_COUNT = XML_NAMED_CONVERTER_FEATURE_COUNT + 4; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl <em>Xml Object Type Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverterImpl() - * @generated - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL = 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL__NAME = XML_OBJECT_TYPE_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE = XML_OBJECT_TYPE_CONVERTER__DATA_TYPE; - - /** - * The feature id for the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE = XML_OBJECT_TYPE_CONVERTER__OBJECT_TYPE; - - /** - * The feature id for the '<em><b>Conversion Values</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES = XML_OBJECT_TYPE_CONVERTER__CONVERSION_VALUES; - - /** - * The feature id for the '<em><b>Default Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE = XML_OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE; - - /** - * The number of structural features of the '<em>Xml Object Type Converter Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OBJECT_TYPE_CONVERTER_IMPL_FEATURE_COUNT = XML_OBJECT_TYPE_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER__NAME = XML_NAMED_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Converter</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER__CONVERTER = XML_NAMED_CONVERTER_FEATURE_COUNT + 0; - - /** - * The number of structural features of the '<em>Xml Struct Converter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER_FEATURE_COUNT = XML_NAMED_CONVERTER_FEATURE_COUNT + 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl <em>Xml Struct Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverterImpl() - * @generated - */ - public static final int XML_STRUCT_CONVERTER_IMPL = 10; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER_IMPL__NAME = XML_STRUCT_CONVERTER__NAME; - - /** - * The feature id for the '<em><b>Converter</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER_IMPL__CONVERTER = XML_STRUCT_CONVERTER__CONVERTER; - - /** - * The number of structural features of the '<em>Xml Struct Converter Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STRUCT_CONVERTER_IMPL_FEATURE_COUNT = XML_STRUCT_CONVERTER_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTERS_HOLDER__CONVERTERS = 0; - - /** - * The feature id for the '<em><b>Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTERS_HOLDER__TYPE_CONVERTERS = 1; - - /** - * The feature id for the '<em><b>Object Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS = 2; - - /** - * The feature id for the '<em><b>Struct Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS = 3; - - /** - * The number of structural features of the '<em>Xml Converters Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTERS_HOLDER_FEATURE_COUNT = 4; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter <em>Xml Stored Procedure Parameter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter() - * @generated - */ - public static final int XML_STORED_PROCEDURE_PARAMETER = 12; - - /** - * The feature id for the '<em><b>Direction</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__DIRECTION = 0; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__NAME = 1; - - /** - * The feature id for the '<em><b>Query Parameter</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER = 2; - - /** - * The feature id for the '<em><b>Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__TYPE = 3; - - /** - * The feature id for the '<em><b>Jdbc Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE = 4; - - /** - * The feature id for the '<em><b>Jdbc Type Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME = 5; - - /** - * The number of structural features of the '<em>Xml Stored Procedure Parameter</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_STORED_PROCEDURE_PARAMETER_FEATURE_COUNT = 6; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery <em>Xml Named Stored Procedure Query</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery() - * @generated - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY = 13; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__NAME = 0; - - /** - * The feature id for the '<em><b>Result Class</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS = 1; - - /** - * The feature id for the '<em><b>Result Set Mapping</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING = 2; - - /** - * The feature id for the '<em><b>Procedure Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME = 3; - - /** - * The feature id for the '<em><b>Returns Result Set</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET = 4; - - /** - * The feature id for the '<em><b>Hints</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__HINTS = 5; - - /** - * The feature id for the '<em><b>Parameters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS = 6; - - /** - * The number of structural features of the '<em>Xml Named Stored Procedure Query</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_NAMED_STORED_PROCEDURE_QUERY_FEATURE_COUNT = 7; - - /** - * The feature id for the '<em><b>Version</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__VERSION = OrmPackage.XML_ENTITY_MAPPINGS__VERSION; - - /** - * The feature id for the '<em><b>Description</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__DESCRIPTION = OrmPackage.XML_ENTITY_MAPPINGS__DESCRIPTION; - - /** - * The feature id for the '<em><b>Persistence Unit Metadata</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__PERSISTENCE_UNIT_METADATA = OrmPackage.XML_ENTITY_MAPPINGS__PERSISTENCE_UNIT_METADATA; - - /** - * The feature id for the '<em><b>Package</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__PACKAGE = OrmPackage.XML_ENTITY_MAPPINGS__PACKAGE; - - /** - * The feature id for the '<em><b>Schema</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__SCHEMA = OrmPackage.XML_ENTITY_MAPPINGS__SCHEMA; - - /** - * The feature id for the '<em><b>Catalog</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__CATALOG = OrmPackage.XML_ENTITY_MAPPINGS__CATALOG; - - /** - * The feature id for the '<em><b>Access</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__ACCESS = OrmPackage.XML_ENTITY_MAPPINGS__ACCESS; - - /** - * The feature id for the '<em><b>Sequence Generators</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__SEQUENCE_GENERATORS = OrmPackage.XML_ENTITY_MAPPINGS__SEQUENCE_GENERATORS; - - /** - * The feature id for the '<em><b>Table Generators</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__TABLE_GENERATORS = OrmPackage.XML_ENTITY_MAPPINGS__TABLE_GENERATORS; - - /** - * The feature id for the '<em><b>Named Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__NAMED_QUERIES = OrmPackage.XML_ENTITY_MAPPINGS__NAMED_QUERIES; - - /** - * The feature id for the '<em><b>Named Native Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__NAMED_NATIVE_QUERIES = OrmPackage.XML_ENTITY_MAPPINGS__NAMED_NATIVE_QUERIES; - - /** - * The feature id for the '<em><b>Sql Result Set Mappings</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__SQL_RESULT_SET_MAPPINGS = OrmPackage.XML_ENTITY_MAPPINGS__SQL_RESULT_SET_MAPPINGS; - - /** - * The feature id for the '<em><b>Mapped Superclasses</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__MAPPED_SUPERCLASSES = OrmPackage.XML_ENTITY_MAPPINGS__MAPPED_SUPERCLASSES; - - /** - * The feature id for the '<em><b>Entities</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__ENTITIES = OrmPackage.XML_ENTITY_MAPPINGS__ENTITIES; - - /** - * The feature id for the '<em><b>Embeddables</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__EMBEDDABLES = OrmPackage.XML_ENTITY_MAPPINGS__EMBEDDABLES; - - /** - * The feature id for the '<em><b>Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__CONVERTERS = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__TYPE_CONVERTERS = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Object Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Struct Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 4; - - /** - * The number of structural features of the '<em>Xml Entity Mappings</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_MAPPINGS_FEATURE_COUNT = OrmPackage.XML_ENTITY_MAPPINGS_FEATURE_COUNT + 5; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata <em>Xml Persistence Unit Metadata</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPersistenceUnitMetadata() - * @generated - */ - public static final int XML_PERSISTENCE_UNIT_METADATA = 15; - - /** - * The feature id for the '<em><b>Xml Mapping Metadata Complete</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PERSISTENCE_UNIT_METADATA__XML_MAPPING_METADATA_COMPLETE = OrmPackage.XML_PERSISTENCE_UNIT_METADATA__XML_MAPPING_METADATA_COMPLETE; - - /** - * The feature id for the '<em><b>Persistence Unit Defaults</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PERSISTENCE_UNIT_METADATA__PERSISTENCE_UNIT_DEFAULTS = OrmPackage.XML_PERSISTENCE_UNIT_METADATA__PERSISTENCE_UNIT_DEFAULTS; - - /** - * The feature id for the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS = OrmPackage.XML_PERSISTENCE_UNIT_METADATA_FEATURE_COUNT + 0; - - /** - * The number of structural features of the '<em>Xml Persistence Unit Metadata</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PERSISTENCE_UNIT_METADATA_FEATURE_COUNT = OrmPackage.XML_PERSISTENCE_UNIT_METADATA_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Customizer Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME = 0; - - /** - * The number of structural features of the '<em>Xml Customizer</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CUSTOMIZER_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CUSTOMIZER_HOLDER__CUSTOMIZER = 0; - - /** - * The number of structural features of the '<em>Xml Customizer Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CUSTOMIZER_HOLDER_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CHANGE_TRACKING__TYPE = 0; - - /** - * The number of structural features of the '<em>Xml Change Tracking</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CHANGE_TRACKING_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING = 0; - - /** - * The number of structural features of the '<em>Xml Change Tracking Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CHANGE_TRACKING_HOLDER_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy <em>Xml Copy Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCopyPolicy() - * @generated - */ - public static final int XML_COPY_POLICY = 20; - - /** - * The feature id for the '<em><b>Class</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_COPY_POLICY__CLASS = 0; - - /** - * The number of structural features of the '<em>Xml Copy Policy</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_COPY_POLICY_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy <em>Xml Instantiation Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlInstantiationPolicy() - * @generated - */ - public static final int XML_INSTANTIATION_POLICY = 21; - - /** - * The number of structural features of the '<em>Xml Instantiation Policy</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_INSTANTIATION_POLICY_FEATURE_COUNT = 0; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy <em>Xml Clone Copy Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCloneCopyPolicy() - * @generated - */ - public static final int XML_CLONE_COPY_POLICY = 22; - - /** - * The feature id for the '<em><b>Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CLONE_COPY_POLICY__METHOD = 0; - - /** - * The feature id for the '<em><b>Working Copy Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD = 1; - - /** - * The number of structural features of the '<em>Xml Clone Copy Policy</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CLONE_COPY_POLICY_FEATURE_COUNT = 2; - - /** - * The feature id for the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__CLASS_NAME = OrmPackage.XML_EMBEDDABLE__CLASS_NAME; - - /** - * The feature id for the '<em><b>Access</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__ACCESS = OrmPackage.XML_EMBEDDABLE__ACCESS; - - /** - * The feature id for the '<em><b>Metadata Complete</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__METADATA_COMPLETE = OrmPackage.XML_EMBEDDABLE__METADATA_COMPLETE; - - /** - * The feature id for the '<em><b>Description</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__DESCRIPTION = OrmPackage.XML_EMBEDDABLE__DESCRIPTION; - - /** - * The feature id for the '<em><b>Attributes</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__ATTRIBUTES = OrmPackage.XML_EMBEDDABLE__ATTRIBUTES; - - /** - * The feature id for the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__CUSTOMIZER = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__CHANGE_TRACKING = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__CONVERTERS = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__TYPE_CONVERTERS = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Object Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Struct Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__STRUCT_CONVERTERS = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__COPY_POLICY = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 7; - - /** - * The feature id for the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__CLONE_COPY_POLICY = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__PROPERTIES = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 9; - - /** - * The feature id for the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 10; - - /** - * The number of structural features of the '<em>Xml Embeddable</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDABLE_FEATURE_COUNT = OrmPackage.XML_EMBEDDABLE_FEATURE_COUNT + 11; - - /** - * The feature id for the '<em><b>Read Only</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_READ_ONLY__READ_ONLY = 0; - - /** - * The number of structural features of the '<em>Xml Read Only</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_READ_ONLY_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Hour</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TIME_OF_DAY__HOUR = 0; - - /** - * The feature id for the '<em><b>Minute</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TIME_OF_DAY__MINUTE = 1; - - /** - * The feature id for the '<em><b>Second</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TIME_OF_DAY__SECOND = 2; - - /** - * The feature id for the '<em><b>Millisecond</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TIME_OF_DAY__MILLISECOND = 3; - - /** - * The number of structural features of the '<em>Xml Time Of Day</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TIME_OF_DAY_FEATURE_COUNT = 4; - - /** - * The feature id for the '<em><b>Expiry</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__EXPIRY = 0; - - /** - * The feature id for the '<em><b>Size</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__SIZE = 1; - - /** - * The feature id for the '<em><b>Shared</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__SHARED = 2; - - /** - * The feature id for the '<em><b>Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__TYPE = 3; - - /** - * The feature id for the '<em><b>Always Refresh</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__ALWAYS_REFRESH = 4; - - /** - * The feature id for the '<em><b>Refresh Only If Newer</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__REFRESH_ONLY_IF_NEWER = 5; - - /** - * The feature id for the '<em><b>Disable Hits</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__DISABLE_HITS = 6; - - /** - * The feature id for the '<em><b>Coordination Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__COORDINATION_TYPE = 7; - - /** - * The feature id for the '<em><b>Expiry Time Of Day</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE__EXPIRY_TIME_OF_DAY = 8; - - /** - * The number of structural features of the '<em>Xml Cache</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE_FEATURE_COUNT = 9; - - /** - * The feature id for the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE_HOLDER__CACHE = 0; - - /** - * The feature id for the '<em><b>Existence Checking</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE_HOLDER__EXISTENCE_CHECKING = 1; - - /** - * The number of structural features of the '<em>Xml Cache Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CACHE_HOLDER_FEATURE_COUNT = 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking <em>Xml Optimistic Locking</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking() - * @generated - */ - public static final int XML_OPTIMISTIC_LOCKING = 28; - - /** - * The feature id for the '<em><b>Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OPTIMISTIC_LOCKING__TYPE = 0; - - /** - * The feature id for the '<em><b>Cascade</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OPTIMISTIC_LOCKING__CASCADE = 1; - - /** - * The feature id for the '<em><b>Selected Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS = 2; - - /** - * The number of structural features of the '<em>Xml Optimistic Locking</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_OPTIMISTIC_LOCKING_FEATURE_COUNT = 3; - - /** - * The feature id for the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CLASS_NAME = OrmPackage.XML_ENTITY__CLASS_NAME; - - /** - * The feature id for the '<em><b>Access</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ACCESS = OrmPackage.XML_ENTITY__ACCESS; - - /** - * The feature id for the '<em><b>Metadata Complete</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__METADATA_COMPLETE = OrmPackage.XML_ENTITY__METADATA_COMPLETE; - - /** - * The feature id for the '<em><b>Description</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__DESCRIPTION = OrmPackage.XML_ENTITY__DESCRIPTION; - - /** - * The feature id for the '<em><b>Attributes</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ATTRIBUTES = OrmPackage.XML_ENTITY__ATTRIBUTES; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__NAME = OrmPackage.XML_ENTITY__NAME; - - /** - * The feature id for the '<em><b>Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__TABLE = OrmPackage.XML_ENTITY__TABLE; - - /** - * The feature id for the '<em><b>Secondary Tables</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__SECONDARY_TABLES = OrmPackage.XML_ENTITY__SECONDARY_TABLES; - - /** - * The feature id for the '<em><b>Primary Key Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__PRIMARY_KEY_JOIN_COLUMNS = OrmPackage.XML_ENTITY__PRIMARY_KEY_JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Id Class</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ID_CLASS = OrmPackage.XML_ENTITY__ID_CLASS; - - /** - * The feature id for the '<em><b>Inheritance</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__INHERITANCE = OrmPackage.XML_ENTITY__INHERITANCE; - - /** - * The feature id for the '<em><b>Discriminator Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__DISCRIMINATOR_VALUE = OrmPackage.XML_ENTITY__DISCRIMINATOR_VALUE; - - /** - * The feature id for the '<em><b>Discriminator Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__DISCRIMINATOR_COLUMN = OrmPackage.XML_ENTITY__DISCRIMINATOR_COLUMN; - - /** - * The feature id for the '<em><b>Sequence Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__SEQUENCE_GENERATOR = OrmPackage.XML_ENTITY__SEQUENCE_GENERATOR; - - /** - * The feature id for the '<em><b>Table Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__TABLE_GENERATOR = OrmPackage.XML_ENTITY__TABLE_GENERATOR; - - /** - * The feature id for the '<em><b>Named Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__NAMED_QUERIES = OrmPackage.XML_ENTITY__NAMED_QUERIES; - - /** - * The feature id for the '<em><b>Named Native Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__NAMED_NATIVE_QUERIES = OrmPackage.XML_ENTITY__NAMED_NATIVE_QUERIES; - - /** - * The feature id for the '<em><b>Sql Result Set Mappings</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__SQL_RESULT_SET_MAPPINGS = OrmPackage.XML_ENTITY__SQL_RESULT_SET_MAPPINGS; - - /** - * The feature id for the '<em><b>Exclude Default Listeners</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__EXCLUDE_DEFAULT_LISTENERS = OrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_LISTENERS; - - /** - * The feature id for the '<em><b>Exclude Superclass Listeners</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__EXCLUDE_SUPERCLASS_LISTENERS = OrmPackage.XML_ENTITY__EXCLUDE_SUPERCLASS_LISTENERS; - - /** - * The feature id for the '<em><b>Entity Listeners</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ENTITY_LISTENERS = OrmPackage.XML_ENTITY__ENTITY_LISTENERS; - - /** - * The feature id for the '<em><b>Pre Persist</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__PRE_PERSIST = OrmPackage.XML_ENTITY__PRE_PERSIST; - - /** - * The feature id for the '<em><b>Post Persist</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__POST_PERSIST = OrmPackage.XML_ENTITY__POST_PERSIST; - - /** - * The feature id for the '<em><b>Pre Remove</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__PRE_REMOVE = OrmPackage.XML_ENTITY__PRE_REMOVE; - - /** - * The feature id for the '<em><b>Post Remove</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__POST_REMOVE = OrmPackage.XML_ENTITY__POST_REMOVE; - - /** - * The feature id for the '<em><b>Pre Update</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__PRE_UPDATE = OrmPackage.XML_ENTITY__PRE_UPDATE; - - /** - * The feature id for the '<em><b>Post Update</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__POST_UPDATE = OrmPackage.XML_ENTITY__POST_UPDATE; - - /** - * The feature id for the '<em><b>Post Load</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__POST_LOAD = OrmPackage.XML_ENTITY__POST_LOAD; - - /** - * The feature id for the '<em><b>Attribute Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ATTRIBUTE_OVERRIDES = OrmPackage.XML_ENTITY__ATTRIBUTE_OVERRIDES; - - /** - * The feature id for the '<em><b>Association Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__ASSOCIATION_OVERRIDES = OrmPackage.XML_ENTITY__ASSOCIATION_OVERRIDES; - - /** - * The feature id for the '<em><b>Read Only</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__READ_ONLY = OrmPackage.XML_ENTITY_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CUSTOMIZER = OrmPackage.XML_ENTITY_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CHANGE_TRACKING = OrmPackage.XML_ENTITY_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CACHE = OrmPackage.XML_ENTITY_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Existence Checking</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__EXISTENCE_CHECKING = OrmPackage.XML_ENTITY_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CONVERTERS = OrmPackage.XML_ENTITY_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__TYPE_CONVERTERS = OrmPackage.XML_ENTITY_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Object Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__OBJECT_TYPE_CONVERTERS = OrmPackage.XML_ENTITY_FEATURE_COUNT + 7; - - /** - * The feature id for the '<em><b>Struct Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__STRUCT_CONVERTERS = OrmPackage.XML_ENTITY_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Optimistic Locking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__OPTIMISTIC_LOCKING = OrmPackage.XML_ENTITY_FEATURE_COUNT + 9; - - /** - * The feature id for the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__COPY_POLICY = OrmPackage.XML_ENTITY_FEATURE_COUNT + 10; - - /** - * The feature id for the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__INSTANTIATION_COPY_POLICY = OrmPackage.XML_ENTITY_FEATURE_COUNT + 11; - - /** - * The feature id for the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__CLONE_COPY_POLICY = OrmPackage.XML_ENTITY_FEATURE_COUNT + 12; - - /** - * The feature id for the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES = OrmPackage.XML_ENTITY_FEATURE_COUNT + 13; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__PROPERTIES = OrmPackage.XML_ENTITY_FEATURE_COUNT + 14; - - /** - * The feature id for the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS = OrmPackage.XML_ENTITY_FEATURE_COUNT + 15; - - /** - * The number of structural features of the '<em>Xml Entity</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ENTITY_FEATURE_COUNT = OrmPackage.XML_ENTITY_FEATURE_COUNT + 16; - - /** - * The feature id for the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CLASS_NAME = OrmPackage.XML_MAPPED_SUPERCLASS__CLASS_NAME; - - /** - * The feature id for the '<em><b>Access</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__ACCESS = OrmPackage.XML_MAPPED_SUPERCLASS__ACCESS; - - /** - * The feature id for the '<em><b>Metadata Complete</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__METADATA_COMPLETE = OrmPackage.XML_MAPPED_SUPERCLASS__METADATA_COMPLETE; - - /** - * The feature id for the '<em><b>Description</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__DESCRIPTION = OrmPackage.XML_MAPPED_SUPERCLASS__DESCRIPTION; - - /** - * The feature id for the '<em><b>Attributes</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__ATTRIBUTES = OrmPackage.XML_MAPPED_SUPERCLASS__ATTRIBUTES; - - /** - * The feature id for the '<em><b>Id Class</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__ID_CLASS = OrmPackage.XML_MAPPED_SUPERCLASS__ID_CLASS; - - /** - * The feature id for the '<em><b>Exclude Default Listeners</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_LISTENERS = OrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_LISTENERS; - - /** - * The feature id for the '<em><b>Exclude Superclass Listeners</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__EXCLUDE_SUPERCLASS_LISTENERS = OrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_SUPERCLASS_LISTENERS; - - /** - * The feature id for the '<em><b>Entity Listeners</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__ENTITY_LISTENERS = OrmPackage.XML_MAPPED_SUPERCLASS__ENTITY_LISTENERS; - - /** - * The feature id for the '<em><b>Pre Persist</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__PRE_PERSIST = OrmPackage.XML_MAPPED_SUPERCLASS__PRE_PERSIST; - - /** - * The feature id for the '<em><b>Post Persist</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__POST_PERSIST = OrmPackage.XML_MAPPED_SUPERCLASS__POST_PERSIST; - - /** - * The feature id for the '<em><b>Pre Remove</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__PRE_REMOVE = OrmPackage.XML_MAPPED_SUPERCLASS__PRE_REMOVE; - - /** - * The feature id for the '<em><b>Post Remove</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__POST_REMOVE = OrmPackage.XML_MAPPED_SUPERCLASS__POST_REMOVE; - - /** - * The feature id for the '<em><b>Pre Update</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__PRE_UPDATE = OrmPackage.XML_MAPPED_SUPERCLASS__PRE_UPDATE; - - /** - * The feature id for the '<em><b>Post Update</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__POST_UPDATE = OrmPackage.XML_MAPPED_SUPERCLASS__POST_UPDATE; - - /** - * The feature id for the '<em><b>Post Load</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__POST_LOAD = OrmPackage.XML_MAPPED_SUPERCLASS__POST_LOAD; - - /** - * The feature id for the '<em><b>Read Only</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__READ_ONLY = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CUSTOMIZER = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CHANGE_TRACKING = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CACHE = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Existence Checking</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CONVERTERS = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Object Type Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 7; - - /** - * The feature id for the '<em><b>Struct Converters</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Optimistic Locking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 9; - - /** - * The feature id for the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__COPY_POLICY = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 10; - - /** - * The feature id for the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 11; - - /** - * The feature id for the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 12; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__PROPERTIES = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 13; - - /** - * The feature id for the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 14; - - /** - * The number of structural features of the '<em>Xml Mapped Superclass</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MAPPED_SUPERCLASS_FEATURE_COUNT = OrmPackage.XML_MAPPED_SUPERCLASS_FEATURE_COUNT + 15; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MUTABLE__MUTABLE = 0; - - /** - * The number of structural features of the '<em>Xml Mutable</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MUTABLE_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_HOLDER__CONVERTER = 0; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_HOLDER__TYPE_CONVERTER = 1; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER = 2; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_HOLDER__STRUCT_CONVERTER = 3; - - /** - * The number of structural features of the '<em>Xml Converter Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTER_HOLDER_FEATURE_COUNT = 4; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__LOB = OrmPackage.XML_CONVERTIBLE_MAPPING__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__TEMPORAL = OrmPackage.XML_CONVERTIBLE_MAPPING__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__ENUMERATED = OrmPackage.XML_CONVERTIBLE_MAPPING__ENUMERATED; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__CONVERTER = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__TYPE_CONVERTER = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__OBJECT_TYPE_CONVERTER = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__STRUCT_CONVERTER = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING__CONVERT = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 4; - - /** - * The number of structural features of the '<em>Xml Convertible Mapping</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_CONVERTIBLE_MAPPING_FEATURE_COUNT = OrmPackage.XML_CONVERTIBLE_MAPPING_FEATURE_COUNT + 5; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods <em>Xml Access Methods</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethods() - * @generated - */ - public static final int XML_ACCESS_METHODS = 34; - - /** - * The feature id for the '<em><b>Get Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ACCESS_METHODS__GET_METHOD = 0; - - /** - * The feature id for the '<em><b>Set Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ACCESS_METHODS__SET_METHOD = 1; - - /** - * The number of structural features of the '<em>Xml Access Methods</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ACCESS_METHODS_FEATURE_COUNT = 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder <em>Xml Access Methods Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder() - * @generated - */ - public static final int XML_ACCESS_METHODS_HOLDER = 35; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS = 0; - - /** - * The number of structural features of the '<em>Xml Access Methods Holder</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ACCESS_METHODS_HOLDER_FEATURE_COUNT = 1; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId <em>Xml Embedded Id</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedId() - * @generated - */ - public static final int XML_EMBEDDED_ID = 39; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl <em>Xml Embedded Id Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedIdImpl() - * @generated - */ - public static final int XML_EMBEDDED_ID_IMPL = 40; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded <em>Xml Embedded</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbedded() - * @generated - */ - public static final int XML_EMBEDDED = 41; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl <em>Xml Embedded Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedImpl() - * @generated - */ - public static final int XML_EMBEDDED_IMPL = 42; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes <em>Attributes</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes() - * @generated - */ - public static final int ATTRIBUTES = 65; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection <em>Xml Basic Collection</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollection() - * @generated - */ - public static final int XML_BASIC_COLLECTION = 57; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl <em>Xml Basic Collection Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollectionImpl() - * @generated - */ - public static final int XML_BASIC_COLLECTION_IMPL = 58; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap <em>Xml Basic Map</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMap() - * @generated - */ - public static final int XML_BASIC_MAP = 59; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl <em>Xml Basic Map Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMapImpl() - * @generated - */ - public static final int XML_BASIC_MAP_IMPL = 60; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation <em>Xml Transformation</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformation() - * @generated - */ - public static final int XML_TRANSFORMATION = 61; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl <em>Xml Transformation Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformationImpl() - * @generated - */ - public static final int XML_TRANSFORMATION_IMPL = 62; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty <em>Xml Property</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty() - * @generated - */ - public static final int XML_PROPERTY = 36; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PROPERTY__NAME = 0; - - /** - * The feature id for the '<em><b>Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PROPERTY__VALUE = 1; - - /** - * The feature id for the '<em><b>Value Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PROPERTY__VALUE_TYPE = 2; - - /** - * The number of structural features of the '<em>Xml Property</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PROPERTY_FEATURE_COUNT = 3; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__NAME = OrmPackage.XML_ID__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__COLUMN = OrmPackage.XML_ID__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__LOB = OrmPackage.XML_ID__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__TEMPORAL = OrmPackage.XML_ID__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__ENUMERATED = OrmPackage.XML_ID__ENUMERATED; - - /** - * The feature id for the '<em><b>Generated Value</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__GENERATED_VALUE = OrmPackage.XML_ID__GENERATED_VALUE; - - /** - * The feature id for the '<em><b>Table Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__TABLE_GENERATOR = OrmPackage.XML_ID__TABLE_GENERATOR; - - /** - * The feature id for the '<em><b>Sequence Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__SEQUENCE_GENERATOR = OrmPackage.XML_ID__SEQUENCE_GENERATOR; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__MUTABLE = OrmPackage.XML_ID_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__CONVERTER = OrmPackage.XML_ID_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__TYPE_CONVERTER = OrmPackage.XML_ID_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__OBJECT_TYPE_CONVERTER = OrmPackage.XML_ID_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__STRUCT_CONVERTER = OrmPackage.XML_ID_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__CONVERT = OrmPackage.XML_ID_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__ACCESS_METHODS = OrmPackage.XML_ID_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID__PROPERTIES = OrmPackage.XML_ID_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Id</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_FEATURE_COUNT = OrmPackage.XML_ID_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__NAME = OrmPackage.XML_ID_IMPL__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__COLUMN = OrmPackage.XML_ID_IMPL__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__LOB = OrmPackage.XML_ID_IMPL__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__TEMPORAL = OrmPackage.XML_ID_IMPL__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__ENUMERATED = OrmPackage.XML_ID_IMPL__ENUMERATED; - - /** - * The feature id for the '<em><b>Generated Value</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__GENERATED_VALUE = OrmPackage.XML_ID_IMPL__GENERATED_VALUE; - - /** - * The feature id for the '<em><b>Table Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__TABLE_GENERATOR = OrmPackage.XML_ID_IMPL__TABLE_GENERATOR; - - /** - * The feature id for the '<em><b>Sequence Generator</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__SEQUENCE_GENERATOR = OrmPackage.XML_ID_IMPL__SEQUENCE_GENERATOR; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__MUTABLE = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__CONVERTER = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__TYPE_CONVERTER = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__OBJECT_TYPE_CONVERTER = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__STRUCT_CONVERTER = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__CONVERT = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__ACCESS_METHODS = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL__PROPERTIES = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Id Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ID_IMPL_FEATURE_COUNT = OrmPackage.XML_ID_IMPL_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID__NAME = OrmPackage.XML_EMBEDDED_ID__NAME; - - /** - * The feature id for the '<em><b>Attribute Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID__ATTRIBUTE_OVERRIDES = OrmPackage.XML_EMBEDDED_ID__ATTRIBUTE_OVERRIDES; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID__ACCESS_METHODS = OrmPackage.XML_EMBEDDED_ID_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID__PROPERTIES = OrmPackage.XML_EMBEDDED_ID_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Embedded Id</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_FEATURE_COUNT = OrmPackage.XML_EMBEDDED_ID_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_IMPL__NAME = OrmPackage.XML_EMBEDDED_ID_IMPL__NAME; - - /** - * The feature id for the '<em><b>Attribute Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_IMPL__ATTRIBUTE_OVERRIDES = OrmPackage.XML_EMBEDDED_ID_IMPL__ATTRIBUTE_OVERRIDES; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_IMPL__ACCESS_METHODS = OrmPackage.XML_EMBEDDED_ID_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_IMPL__PROPERTIES = OrmPackage.XML_EMBEDDED_ID_IMPL_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Embedded Id Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_ID_IMPL_FEATURE_COUNT = OrmPackage.XML_EMBEDDED_ID_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED__NAME = OrmPackage.XML_EMBEDDED__NAME; - - /** - * The feature id for the '<em><b>Attribute Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED__ATTRIBUTE_OVERRIDES = OrmPackage.XML_EMBEDDED__ATTRIBUTE_OVERRIDES; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED__ACCESS_METHODS = OrmPackage.XML_EMBEDDED_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED__PROPERTIES = OrmPackage.XML_EMBEDDED_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Embedded</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_FEATURE_COUNT = OrmPackage.XML_EMBEDDED_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_IMPL__NAME = OrmPackage.XML_EMBEDDED_IMPL__NAME; - - /** - * The feature id for the '<em><b>Attribute Overrides</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_IMPL__ATTRIBUTE_OVERRIDES = OrmPackage.XML_EMBEDDED_IMPL__ATTRIBUTE_OVERRIDES; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_IMPL__ACCESS_METHODS = OrmPackage.XML_EMBEDDED_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_IMPL__PROPERTIES = OrmPackage.XML_EMBEDDED_IMPL_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Embedded Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_EMBEDDED_IMPL_FEATURE_COUNT = OrmPackage.XML_EMBEDDED_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__NAME = OrmPackage.XML_BASIC__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__COLUMN = OrmPackage.XML_BASIC__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__LOB = OrmPackage.XML_BASIC__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__TEMPORAL = OrmPackage.XML_BASIC__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__ENUMERATED = OrmPackage.XML_BASIC__ENUMERATED; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__FETCH = OrmPackage.XML_BASIC__FETCH; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__OPTIONAL = OrmPackage.XML_BASIC__OPTIONAL; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__MUTABLE = OrmPackage.XML_BASIC_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__CONVERTER = OrmPackage.XML_BASIC_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__TYPE_CONVERTER = OrmPackage.XML_BASIC_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__OBJECT_TYPE_CONVERTER = OrmPackage.XML_BASIC_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__STRUCT_CONVERTER = OrmPackage.XML_BASIC_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__CONVERT = OrmPackage.XML_BASIC_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__ACCESS_METHODS = OrmPackage.XML_BASIC_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC__PROPERTIES = OrmPackage.XML_BASIC_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Basic</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_FEATURE_COUNT = OrmPackage.XML_BASIC_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__NAME = OrmPackage.XML_BASIC_IMPL__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__COLUMN = OrmPackage.XML_BASIC_IMPL__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__LOB = OrmPackage.XML_BASIC_IMPL__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__TEMPORAL = OrmPackage.XML_BASIC_IMPL__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__ENUMERATED = OrmPackage.XML_BASIC_IMPL__ENUMERATED; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__FETCH = OrmPackage.XML_BASIC_IMPL__FETCH; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__OPTIONAL = OrmPackage.XML_BASIC_IMPL__OPTIONAL; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__MUTABLE = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__CONVERTER = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__TYPE_CONVERTER = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__STRUCT_CONVERTER = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__CONVERT = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__ACCESS_METHODS = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL__PROPERTIES = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Basic Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_IMPL_FEATURE_COUNT = OrmPackage.XML_BASIC_IMPL_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__NAME = OrmPackage.XML_VERSION__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__COLUMN = OrmPackage.XML_VERSION__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__LOB = OrmPackage.XML_VERSION__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__TEMPORAL = OrmPackage.XML_VERSION__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__ENUMERATED = OrmPackage.XML_VERSION__ENUMERATED; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__MUTABLE = OrmPackage.XML_VERSION_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__CONVERTER = OrmPackage.XML_VERSION_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__TYPE_CONVERTER = OrmPackage.XML_VERSION_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__OBJECT_TYPE_CONVERTER = OrmPackage.XML_VERSION_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__STRUCT_CONVERTER = OrmPackage.XML_VERSION_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__CONVERT = OrmPackage.XML_VERSION_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__ACCESS_METHODS = OrmPackage.XML_VERSION_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION__PROPERTIES = OrmPackage.XML_VERSION_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Version</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_FEATURE_COUNT = OrmPackage.XML_VERSION_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__NAME = OrmPackage.XML_VERSION_IMPL__NAME; - - /** - * The feature id for the '<em><b>Column</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__COLUMN = OrmPackage.XML_VERSION_IMPL__COLUMN; - - /** - * The feature id for the '<em><b>Lob</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__LOB = OrmPackage.XML_VERSION_IMPL__LOB; - - /** - * The feature id for the '<em><b>Temporal</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__TEMPORAL = OrmPackage.XML_VERSION_IMPL__TEMPORAL; - - /** - * The feature id for the '<em><b>Enumerated</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__ENUMERATED = OrmPackage.XML_VERSION_IMPL__ENUMERATED; - - /** - * The feature id for the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__MUTABLE = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__CONVERTER = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__TYPE_CONVERTER = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__STRUCT_CONVERTER = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__CONVERT = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 5; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__ACCESS_METHODS = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 6; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL__PROPERTIES = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 7; - - /** - * The number of structural features of the '<em>Xml Version Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VERSION_IMPL_FEATURE_COUNT = OrmPackage.XML_VERSION_IMPL_FEATURE_COUNT + 8; - - /** - * The feature id for the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PRIVATE_OWNED__PRIVATE_OWNED = 0; - - /** - * The number of structural features of the '<em>Xml Private Owned</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_PRIVATE_OWNED_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_JOIN_FETCH__JOIN_FETCH = 0; - - /** - * The number of structural features of the '<em>Xml Join Fetch</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_JOIN_FETCH_FEATURE_COUNT = 1; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__NAME = OrmPackage.XML_ONE_TO_ONE__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__TARGET_ENTITY = OrmPackage.XML_ONE_TO_ONE__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__FETCH = OrmPackage.XML_ONE_TO_ONE__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__JOIN_TABLE = OrmPackage.XML_ONE_TO_ONE__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__CASCADE = OrmPackage.XML_ONE_TO_ONE__CASCADE; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__OPTIONAL = OrmPackage.XML_ONE_TO_ONE__OPTIONAL; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__JOIN_COLUMNS = OrmPackage.XML_ONE_TO_ONE__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__MAPPED_BY = OrmPackage.XML_ONE_TO_ONE__MAPPED_BY; - - /** - * The feature id for the '<em><b>Primary Key Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__PRIMARY_KEY_JOIN_COLUMNS = OrmPackage.XML_ONE_TO_ONE__PRIMARY_KEY_JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__PRIVATE_OWNED = OrmPackage.XML_ONE_TO_ONE_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__JOIN_FETCH = OrmPackage.XML_ONE_TO_ONE_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__ACCESS_METHODS = OrmPackage.XML_ONE_TO_ONE_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE__PROPERTIES = OrmPackage.XML_ONE_TO_ONE_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Xml One To One</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_FEATURE_COUNT = OrmPackage.XML_ONE_TO_ONE_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__NAME = OrmPackage.XML_ONE_TO_ONE_IMPL__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__TARGET_ENTITY = OrmPackage.XML_ONE_TO_ONE_IMPL__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__FETCH = OrmPackage.XML_ONE_TO_ONE_IMPL__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__JOIN_TABLE = OrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__CASCADE = OrmPackage.XML_ONE_TO_ONE_IMPL__CASCADE; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__OPTIONAL = OrmPackage.XML_ONE_TO_ONE_IMPL__OPTIONAL; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__JOIN_COLUMNS = OrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__MAPPED_BY = OrmPackage.XML_ONE_TO_ONE_IMPL__MAPPED_BY; - - /** - * The feature id for the '<em><b>Primary Key Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__PRIMARY_KEY_JOIN_COLUMNS = OrmPackage.XML_ONE_TO_ONE_IMPL__PRIMARY_KEY_JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED = OrmPackage.XML_ONE_TO_ONE_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__JOIN_FETCH = OrmPackage.XML_ONE_TO_ONE_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__ACCESS_METHODS = OrmPackage.XML_ONE_TO_ONE_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL__PROPERTIES = OrmPackage.XML_ONE_TO_ONE_IMPL_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Xml One To One Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_ONE_IMPL_FEATURE_COUNT = OrmPackage.XML_ONE_TO_ONE_IMPL_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__NAME = OrmPackage.XML_ONE_TO_MANY__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__TARGET_ENTITY = OrmPackage.XML_ONE_TO_MANY__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__FETCH = OrmPackage.XML_ONE_TO_MANY__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__JOIN_TABLE = OrmPackage.XML_ONE_TO_MANY__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__CASCADE = OrmPackage.XML_ONE_TO_MANY__CASCADE; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__MAPPED_BY = OrmPackage.XML_ONE_TO_MANY__MAPPED_BY; - - /** - * The feature id for the '<em><b>Order By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__ORDER_BY = OrmPackage.XML_ONE_TO_MANY__ORDER_BY; - - /** - * The feature id for the '<em><b>Map Key</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__MAP_KEY = OrmPackage.XML_ONE_TO_MANY__MAP_KEY; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__JOIN_COLUMNS = OrmPackage.XML_ONE_TO_MANY__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__PRIVATE_OWNED = OrmPackage.XML_ONE_TO_MANY_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__JOIN_FETCH = OrmPackage.XML_ONE_TO_MANY_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__ACCESS_METHODS = OrmPackage.XML_ONE_TO_MANY_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY__PROPERTIES = OrmPackage.XML_ONE_TO_MANY_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Xml One To Many</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_FEATURE_COUNT = OrmPackage.XML_ONE_TO_MANY_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__NAME = OrmPackage.XML_ONE_TO_MANY_IMPL__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__TARGET_ENTITY = OrmPackage.XML_ONE_TO_MANY_IMPL__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__FETCH = OrmPackage.XML_ONE_TO_MANY_IMPL__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__JOIN_TABLE = OrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__CASCADE = OrmPackage.XML_ONE_TO_MANY_IMPL__CASCADE; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__MAPPED_BY = OrmPackage.XML_ONE_TO_MANY_IMPL__MAPPED_BY; - - /** - * The feature id for the '<em><b>Order By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__ORDER_BY = OrmPackage.XML_ONE_TO_MANY_IMPL__ORDER_BY; - - /** - * The feature id for the '<em><b>Map Key</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__MAP_KEY = OrmPackage.XML_ONE_TO_MANY_IMPL__MAP_KEY; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__JOIN_COLUMNS = OrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED = OrmPackage.XML_ONE_TO_MANY_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__JOIN_FETCH = OrmPackage.XML_ONE_TO_MANY_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__ACCESS_METHODS = OrmPackage.XML_ONE_TO_MANY_IMPL_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL__PROPERTIES = OrmPackage.XML_ONE_TO_MANY_IMPL_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Xml One To Many Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_ONE_TO_MANY_IMPL_FEATURE_COUNT = OrmPackage.XML_ONE_TO_MANY_IMPL_FEATURE_COUNT + 4; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__NAME = OrmPackage.XML_MANY_TO_ONE__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__TARGET_ENTITY = OrmPackage.XML_MANY_TO_ONE__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__FETCH = OrmPackage.XML_MANY_TO_ONE__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__JOIN_TABLE = OrmPackage.XML_MANY_TO_ONE__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__CASCADE = OrmPackage.XML_MANY_TO_ONE__CASCADE; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__OPTIONAL = OrmPackage.XML_MANY_TO_ONE__OPTIONAL; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__JOIN_COLUMNS = OrmPackage.XML_MANY_TO_ONE__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__JOIN_FETCH = OrmPackage.XML_MANY_TO_ONE_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__ACCESS_METHODS = OrmPackage.XML_MANY_TO_ONE_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE__PROPERTIES = OrmPackage.XML_MANY_TO_ONE_FEATURE_COUNT + 2; - - /** - * The number of structural features of the '<em>Xml Many To One</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_FEATURE_COUNT = OrmPackage.XML_MANY_TO_ONE_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__NAME = OrmPackage.XML_MANY_TO_ONE_IMPL__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__TARGET_ENTITY = OrmPackage.XML_MANY_TO_ONE_IMPL__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__FETCH = OrmPackage.XML_MANY_TO_ONE_IMPL__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__JOIN_TABLE = OrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__CASCADE = OrmPackage.XML_MANY_TO_ONE_IMPL__CASCADE; - - /** - * The feature id for the '<em><b>Optional</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__OPTIONAL = OrmPackage.XML_MANY_TO_ONE_IMPL__OPTIONAL; - - /** - * The feature id for the '<em><b>Join Columns</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__JOIN_COLUMNS = OrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_COLUMNS; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__JOIN_FETCH = OrmPackage.XML_MANY_TO_ONE_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__ACCESS_METHODS = OrmPackage.XML_MANY_TO_ONE_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL__PROPERTIES = OrmPackage.XML_MANY_TO_ONE_IMPL_FEATURE_COUNT + 2; - - /** - * The number of structural features of the '<em>Xml Many To One Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_ONE_IMPL_FEATURE_COUNT = OrmPackage.XML_MANY_TO_ONE_IMPL_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__NAME = OrmPackage.XML_MANY_TO_MANY__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__TARGET_ENTITY = OrmPackage.XML_MANY_TO_MANY__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__FETCH = OrmPackage.XML_MANY_TO_MANY__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__JOIN_TABLE = OrmPackage.XML_MANY_TO_MANY__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__CASCADE = OrmPackage.XML_MANY_TO_MANY__CASCADE; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__MAPPED_BY = OrmPackage.XML_MANY_TO_MANY__MAPPED_BY; - - /** - * The feature id for the '<em><b>Order By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__ORDER_BY = OrmPackage.XML_MANY_TO_MANY__ORDER_BY; - - /** - * The feature id for the '<em><b>Map Key</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__MAP_KEY = OrmPackage.XML_MANY_TO_MANY__MAP_KEY; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__JOIN_FETCH = OrmPackage.XML_MANY_TO_MANY_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__ACCESS_METHODS = OrmPackage.XML_MANY_TO_MANY_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY__PROPERTIES = OrmPackage.XML_MANY_TO_MANY_FEATURE_COUNT + 2; - - /** - * The number of structural features of the '<em>Xml Many To Many</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_FEATURE_COUNT = OrmPackage.XML_MANY_TO_MANY_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__NAME = OrmPackage.XML_MANY_TO_MANY_IMPL__NAME; - - /** - * The feature id for the '<em><b>Target Entity</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__TARGET_ENTITY = OrmPackage.XML_MANY_TO_MANY_IMPL__TARGET_ENTITY; - - /** - * The feature id for the '<em><b>Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__FETCH = OrmPackage.XML_MANY_TO_MANY_IMPL__FETCH; - - /** - * The feature id for the '<em><b>Join Table</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__JOIN_TABLE = OrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_TABLE; - - /** - * The feature id for the '<em><b>Cascade</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__CASCADE = OrmPackage.XML_MANY_TO_MANY_IMPL__CASCADE; - - /** - * The feature id for the '<em><b>Mapped By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__MAPPED_BY = OrmPackage.XML_MANY_TO_MANY_IMPL__MAPPED_BY; - - /** - * The feature id for the '<em><b>Order By</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__ORDER_BY = OrmPackage.XML_MANY_TO_MANY_IMPL__ORDER_BY; - - /** - * The feature id for the '<em><b>Map Key</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__MAP_KEY = OrmPackage.XML_MANY_TO_MANY_IMPL__MAP_KEY; - - /** - * The feature id for the '<em><b>Join Fetch</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__JOIN_FETCH = OrmPackage.XML_MANY_TO_MANY_IMPL_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__ACCESS_METHODS = OrmPackage.XML_MANY_TO_MANY_IMPL_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL__PROPERTIES = OrmPackage.XML_MANY_TO_MANY_IMPL_FEATURE_COUNT + 2; - - /** - * The number of structural features of the '<em>Xml Many To Many Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_MANY_TO_MANY_IMPL_FEATURE_COUNT = OrmPackage.XML_MANY_TO_MANY_IMPL_FEATURE_COUNT + 3; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION__NAME = OrmPackage.XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION__ACCESS_METHODS = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION__PROPERTIES = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Basic Collection</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION_FEATURE_COUNT = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION_IMPL__NAME = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION_IMPL__PROPERTIES = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Basic Collection Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_COLLECTION_IMPL_FEATURE_COUNT = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP__NAME = OrmPackage.XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP__ACCESS_METHODS = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP__PROPERTIES = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Basic Map</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP_FEATURE_COUNT = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP_IMPL__NAME = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP_IMPL__ACCESS_METHODS = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP_IMPL__PROPERTIES = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Basic Map Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_BASIC_MAP_IMPL_FEATURE_COUNT = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION__NAME = OrmPackage.XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION__ACCESS_METHODS = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION__PROPERTIES = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Transformation</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION_FEATURE_COUNT = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION_IMPL__NAME = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION_IMPL__ACCESS_METHODS = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION_IMPL__PROPERTIES = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Transformation Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_TRANSFORMATION_IMPL_FEATURE_COUNT = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne <em>Xml Variable One To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOne() - * @generated - */ - public static final int XML_VARIABLE_ONE_TO_ONE = 63; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE__NAME = OrmPackage.XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE__ACCESS_METHODS = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE__PROPERTIES = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Variable One To One</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE_FEATURE_COUNT = OrmPackage.XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl <em>Xml Variable One To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOneImpl() - * @generated - */ - public static final int XML_VARIABLE_ONE_TO_ONE_IMPL = 64; - - /** - * The feature id for the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE_IMPL__NAME = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING__NAME; - - /** - * The feature id for the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Properties</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 1; - - /** - * The number of structural features of the '<em>Xml Variable One To One Impl</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int XML_VARIABLE_ONE_TO_ONE_IMPL_FEATURE_COUNT = OrmPackage.ABSTRACT_XML_ATTRIBUTE_MAPPING_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Ids</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__IDS = OrmPackage.ATTRIBUTES__IDS; - - /** - * The feature id for the '<em><b>Embedded Ids</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__EMBEDDED_IDS = OrmPackage.ATTRIBUTES__EMBEDDED_IDS; - - /** - * The feature id for the '<em><b>Basics</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__BASICS = OrmPackage.ATTRIBUTES__BASICS; - - /** - * The feature id for the '<em><b>Versions</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__VERSIONS = OrmPackage.ATTRIBUTES__VERSIONS; - - /** - * The feature id for the '<em><b>Many To Ones</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__MANY_TO_ONES = OrmPackage.ATTRIBUTES__MANY_TO_ONES; - - /** - * The feature id for the '<em><b>One To Manys</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__ONE_TO_MANYS = OrmPackage.ATTRIBUTES__ONE_TO_MANYS; - - /** - * The feature id for the '<em><b>One To Ones</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__ONE_TO_ONES = OrmPackage.ATTRIBUTES__ONE_TO_ONES; - - /** - * The feature id for the '<em><b>Many To Manys</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__MANY_TO_MANYS = OrmPackage.ATTRIBUTES__MANY_TO_MANYS; - - /** - * The feature id for the '<em><b>Embeddeds</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__EMBEDDEDS = OrmPackage.ATTRIBUTES__EMBEDDEDS; - - /** - * The feature id for the '<em><b>Transients</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__TRANSIENTS = OrmPackage.ATTRIBUTES__TRANSIENTS; - - /** - * The feature id for the '<em><b>Basic Collections</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__BASIC_COLLECTIONS = OrmPackage.ATTRIBUTES_FEATURE_COUNT + 0; - - /** - * The feature id for the '<em><b>Basic Maps</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__BASIC_MAPS = OrmPackage.ATTRIBUTES_FEATURE_COUNT + 1; - - /** - * The feature id for the '<em><b>Transformations</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__TRANSFORMATIONS = OrmPackage.ATTRIBUTES_FEATURE_COUNT + 2; - - /** - * The feature id for the '<em><b>Variable One To Ones</b></em>' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES__VARIABLE_ONE_TO_ONES = OrmPackage.ATTRIBUTES_FEATURE_COUNT + 3; - - /** - * The number of structural features of the '<em>Attributes</em>' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - * @ordered - */ - public static final int ATTRIBUTES_FEATURE_COUNT = OrmPackage.ATTRIBUTES_FEATURE_COUNT + 4; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection <em>Xml Direction</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlDirection() - * @generated - */ - public static final int XML_DIRECTION = 66; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType <em>Xml Change Tracking Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingType() - * @generated - */ - public static final int XML_CHANGE_TRACKING_TYPE = 67; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheType <em>Cache Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheType() - * @generated - */ - public static final int CACHE_TYPE = 68; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType <em>Cache Coordination Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheCoordinationType() - * @generated - */ - public static final int CACHE_COORDINATION_TYPE = 69; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType <em>Xml Join Fetch Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetchType() - * @generated - */ - public static final int XML_JOIN_FETCH_TYPE = 72; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlNamedConverterEClass = null; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType <em>Existence Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getExistenceType() - * @generated - */ - public static final int EXISTENCE_TYPE = 70; - - /** - * The meta object id for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType <em>Xml Optimistic Locking Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLockingType() - * @generated - */ - public static final int XML_OPTIMISTIC_LOCKING_TYPE = 71; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCustomizerEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCustomizerHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlChangeTrackingEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlChangeTrackingHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCopyPolicyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlInstantiationPolicyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCloneCopyPolicyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConvertersHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlStoredProcedureParameterEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlNamedStoredProcedureQueryEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEntityMappingsEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlPersistenceUnitMetadataEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEmbeddableEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlReadOnlyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlTimeOfDayEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCacheEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlCacheHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlOptimisticLockingEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEntityEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlMappedSuperclassEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlMutableEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConvertibleMappingEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlAccessMethodsEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlAccessMethodsHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlIdEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlIdImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEmbeddedIdEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEmbeddedIdImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEmbeddedEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlEmbeddedImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlVersionEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlVersionImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlPrivateOwnedEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlJoinFetchEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlOneToOneEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlOneToOneImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlOneToManyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlOneToManyImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlManyToOneEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlManyToOneImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlManyToManyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlManyToManyImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass attributesEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicCollectionEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicCollectionImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicMapEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlBasicMapImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlTransformationEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlTransformationImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlPropertyEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlVariableOneToOneEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlVariableOneToOneImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum xmlDirectionEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum xmlChangeTrackingTypeEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConverterEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConverterImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlTypeConverterEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlTypeConverterImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConversionValueEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConversionValueImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlObjectTypeConverterEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlObjectTypeConverterImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlStructConverterEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlStructConverterImplEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EClass xmlConverterHolderEClass = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum cacheTypeEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum cacheCoordinationTypeEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum xmlJoinFetchTypeEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum existenceTypeEEnum = null; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private EEnum xmlOptimisticLockingTypeEEnum = null; - - /** - * Creates an instance of the model <b>Package</b>, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - * <p>Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#eNS_URI - * @see #init() - * @generated - */ - private EclipseLinkOrmPackage() - { - super(eNS_URI, EclipseLinkOrmFactory.eINSTANCE); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the <b>Package</b> for this - * model, and for any others upon which it depends. Simple - * dependencies are satisfied by calling this method on all - * dependent packages before doing anything else. This method drives - * initialization for interdependent packages directly, in parallel - * with this package, itself. - * <p>Of this package and its interdependencies, all packages which - * have not yet been registered by their URI values are first created - * and registered. The packages are then initialized in two steps: - * meta-model objects for all of the packages are created before any - * are initialized, since one package's meta-model objects may refer to - * those of another. - * <p>Invocation of this method will not affect any packages that have - * already been initialized. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static EclipseLinkOrmPackage init() - { - if (isInited) return (EclipseLinkOrmPackage)EPackage.Registry.INSTANCE.getEPackage(EclipseLinkOrmPackage.eNS_URI); - - // Obtain or create and register package - EclipseLinkOrmPackage theEclipseLinkOrmPackage = (EclipseLinkOrmPackage)(EPackage.Registry.INSTANCE.getEPackage(eNS_URI) instanceof EclipseLinkOrmPackage ? EPackage.Registry.INSTANCE.getEPackage(eNS_URI) : new EclipseLinkOrmPackage()); - - isInited = true; - - // Initialize simple dependencies - OrmPackage.eINSTANCE.eClass(); - XMLTypePackage.eINSTANCE.eClass(); - - // Create package meta-data objects - theEclipseLinkOrmPackage.createPackageContents(); - - // Initialize created meta-data - theEclipseLinkOrmPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theEclipseLinkOrmPackage.freeze(); - - return theEclipseLinkOrmPackage; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter <em>Xml Named Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Named Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter - * @generated - */ - public EClass getXmlNamedConverter() - { - return xmlNamedConverterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter#getName <em>Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter#getName() - * @see #getXmlNamedConverter() - * @generated - */ - public EAttribute getXmlNamedConverter_Name() - { - return (EAttribute)xmlNamedConverterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer <em>Xml Customizer</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Customizer</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer - * @generated - */ - public EClass getXmlCustomizer() - { - return xmlCustomizerEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer#getCustomizerClassName <em>Customizer Class Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Customizer Class Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer#getCustomizerClassName() - * @see #getXmlCustomizer() - * @generated - */ - public EAttribute getXmlCustomizer_CustomizerClassName() - { - return (EAttribute)xmlCustomizerEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder <em>Xml Customizer Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Customizer Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder - * @generated - */ - public EClass getXmlCustomizerHolder() - { - return xmlCustomizerHolderEClass; - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder#getCustomizer <em>Customizer</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Customizer</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder#getCustomizer() - * @see #getXmlCustomizerHolder() - * @generated - */ - public EReference getXmlCustomizerHolder_Customizer() - { - return (EReference)xmlCustomizerHolderEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking <em>Xml Change Tracking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Change Tracking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking - * @generated - */ - public EClass getXmlChangeTracking() - { - return xmlChangeTrackingEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking#getType <em>Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking#getType() - * @see #getXmlChangeTracking() - * @generated - */ - public EAttribute getXmlChangeTracking_Type() - { - return (EAttribute)xmlChangeTrackingEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder <em>Xml Change Tracking Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Change Tracking Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder - * @generated - */ - public EClass getXmlChangeTrackingHolder() - { - return xmlChangeTrackingHolderEClass; - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder#getChangeTracking <em>Change Tracking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Change Tracking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder#getChangeTracking() - * @see #getXmlChangeTrackingHolder() - * @generated - */ - public EReference getXmlChangeTrackingHolder_ChangeTracking() - { - return (EReference)xmlChangeTrackingHolderEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy <em>Xml Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy - * @generated - */ - public EClass getXmlCopyPolicy() - { - return xmlCopyPolicyEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy#getClass_ <em>Class</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Class</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy#getClass_() - * @see #getXmlCopyPolicy() - * @generated - */ - public EAttribute getXmlCopyPolicy_Class() - { - return (EAttribute)xmlCopyPolicyEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy <em>Xml Instantiation Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Instantiation Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy - * @generated - */ - public EClass getXmlInstantiationPolicy() - { - return xmlInstantiationPolicyEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy <em>Xml Clone Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Clone Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy - * @generated - */ - public EClass getXmlCloneCopyPolicy() - { - return xmlCloneCopyPolicyEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getMethod <em>Method</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Method</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getMethod() - * @see #getXmlCloneCopyPolicy() - * @generated - */ - public EAttribute getXmlCloneCopyPolicy_Method() - { - return (EAttribute)xmlCloneCopyPolicyEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getWorkingCopyMethod <em>Working Copy Method</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Working Copy Method</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getWorkingCopyMethod() - * @see #getXmlCloneCopyPolicy() - * @generated - */ - public EAttribute getXmlCloneCopyPolicy_WorkingCopyMethod() - { - return (EAttribute)xmlCloneCopyPolicyEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder <em>Xml Converters Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Converters Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder - * @generated - */ - public EClass getXmlConvertersHolder() - { - return xmlConvertersHolderEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getConverters <em>Converters</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Converters</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getConverters() - * @see #getXmlConvertersHolder() - * @generated - */ - public EReference getXmlConvertersHolder_Converters() - { - return (EReference)xmlConvertersHolderEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getTypeConverters <em>Type Converters</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Type Converters</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getTypeConverters() - * @see #getXmlConvertersHolder() - * @generated - */ - public EReference getXmlConvertersHolder_TypeConverters() - { - return (EReference)xmlConvertersHolderEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getObjectTypeConverters <em>Object Type Converters</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Object Type Converters</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getObjectTypeConverters() - * @see #getXmlConvertersHolder() - * @generated - */ - public EReference getXmlConvertersHolder_ObjectTypeConverters() - { - return (EReference)xmlConvertersHolderEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getStructConverters <em>Struct Converters</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Struct Converters</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getStructConverters() - * @see #getXmlConvertersHolder() - * @generated - */ - public EReference getXmlConvertersHolder_StructConverters() - { - return (EReference)xmlConvertersHolderEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter <em>Xml Stored Procedure Parameter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Stored Procedure Parameter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter - * @generated - */ - public EClass getXmlStoredProcedureParameter() - { - return xmlStoredProcedureParameterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getDirection <em>Direction</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Direction</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getDirection() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_Direction() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getName <em>Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getName() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_Name() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getQueryParameter <em>Query Parameter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Query Parameter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getQueryParameter() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_QueryParameter() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getType <em>Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getType() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_Type() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcType <em>Jdbc Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Jdbc Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcType() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_JdbcType() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(4); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcTypeName <em>Jdbc Type Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Jdbc Type Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcTypeName() - * @see #getXmlStoredProcedureParameter() - * @generated - */ - public EAttribute getXmlStoredProcedureParameter_JdbcTypeName() - { - return (EAttribute)xmlStoredProcedureParameterEClass.getEStructuralFeatures().get(5); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery <em>Xml Named Stored Procedure Query</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Named Stored Procedure Query</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery - * @generated - */ - public EClass getXmlNamedStoredProcedureQuery() - { - return xmlNamedStoredProcedureQueryEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getName <em>Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getName() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EAttribute getXmlNamedStoredProcedureQuery_Name() - { - return (EAttribute)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultClass <em>Result Class</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Result Class</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultClass() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EAttribute getXmlNamedStoredProcedureQuery_ResultClass() - { - return (EAttribute)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultSetMapping <em>Result Set Mapping</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Result Set Mapping</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultSetMapping() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EAttribute getXmlNamedStoredProcedureQuery_ResultSetMapping() - { - return (EAttribute)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getProcedureName <em>Procedure Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Procedure Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getProcedureName() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EAttribute getXmlNamedStoredProcedureQuery_ProcedureName() - { - return (EAttribute)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getReturnsResultSet <em>Returns Result Set</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Returns Result Set</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getReturnsResultSet() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EAttribute getXmlNamedStoredProcedureQuery_ReturnsResultSet() - { - return (EAttribute)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(4); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getHints <em>Hints</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Hints</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getHints() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EReference getXmlNamedStoredProcedureQuery_Hints() - { - return (EReference)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(5); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getParameters <em>Parameters</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Parameters</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getParameters() - * @see #getXmlNamedStoredProcedureQuery() - * @generated - */ - public EReference getXmlNamedStoredProcedureQuery_Parameters() - { - return (EReference)xmlNamedStoredProcedureQueryEClass.getEStructuralFeatures().get(6); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings <em>Xml Entity Mappings</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Entity Mappings</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings - * @generated - */ - public EClass getXmlEntityMappings() - { - return xmlEntityMappingsEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings#getNamedStoredProcedureQueries <em>Named Stored Procedure Queries</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Named Stored Procedure Queries</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings#getNamedStoredProcedureQueries() - * @see #getXmlEntityMappings() - * @generated - */ - public EReference getXmlEntityMappings_NamedStoredProcedureQueries() - { - return (EReference)xmlEntityMappingsEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata <em>Xml Persistence Unit Metadata</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Persistence Unit Metadata</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata - * @generated - */ - public EClass getXmlPersistenceUnitMetadata() - { - return xmlPersistenceUnitMetadataEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata#isExcludeDefaultMappings <em>Exclude Default Mappings</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Exclude Default Mappings</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata#isExcludeDefaultMappings() - * @see #getXmlPersistenceUnitMetadata() - * @generated - */ - public EAttribute getXmlPersistenceUnitMetadata_ExcludeDefaultMappings() - { - return (EAttribute)xmlPersistenceUnitMetadataEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable <em>Xml Embeddable</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Embeddable</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable - * @generated - */ - public EClass getXmlEmbeddable() - { - return xmlEmbeddableEClass; - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCopyPolicy <em>Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCopyPolicy() - * @see #getXmlEmbeddable() - * @generated - */ - public EReference getXmlEmbeddable_CopyPolicy() - { - return (EReference)xmlEmbeddableEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Instantiation Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getInstantiationCopyPolicy() - * @see #getXmlEmbeddable() - * @generated - */ - public EReference getXmlEmbeddable_InstantiationCopyPolicy() - { - return (EReference)xmlEmbeddableEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCloneCopyPolicy <em>Clone Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Clone Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCloneCopyPolicy() - * @see #getXmlEmbeddable() - * @generated - */ - public EReference getXmlEmbeddable_CloneCopyPolicy() - { - return (EReference)xmlEmbeddableEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getProperties() - * @see #getXmlEmbeddable() - * @generated - */ - public EReference getXmlEmbeddable_Properties() - { - return (EReference)xmlEmbeddableEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Exclude Default Mappings</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getExcludeDefaultMappings() - * @see #getXmlEmbeddable() - * @generated - */ - public EAttribute getXmlEmbeddable_ExcludeDefaultMappings() - { - return (EAttribute)xmlEmbeddableEClass.getEStructuralFeatures().get(4); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly <em>Xml Read Only</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Read Only</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly - * @generated - */ - public EClass getXmlReadOnly() - { - return xmlReadOnlyEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly#getReadOnly <em>Read Only</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Read Only</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly#getReadOnly() - * @see #getXmlReadOnly() - * @generated - */ - public EAttribute getXmlReadOnly_ReadOnly() - { - return (EAttribute)xmlReadOnlyEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay <em>Xml Time Of Day</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Time Of Day</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay - * @generated - */ - public EClass getXmlTimeOfDay() - { - return xmlTimeOfDayEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getHour <em>Hour</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Hour</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getHour() - * @see #getXmlTimeOfDay() - * @generated - */ - public EAttribute getXmlTimeOfDay_Hour() - { - return (EAttribute)xmlTimeOfDayEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMinute <em>Minute</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Minute</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMinute() - * @see #getXmlTimeOfDay() - * @generated - */ - public EAttribute getXmlTimeOfDay_Minute() - { - return (EAttribute)xmlTimeOfDayEClass.getEStructuralFeatures().get(1); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getSecond <em>Second</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Second</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getSecond() - * @see #getXmlTimeOfDay() - * @generated - */ - public EAttribute getXmlTimeOfDay_Second() - { - return (EAttribute)xmlTimeOfDayEClass.getEStructuralFeatures().get(2); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMillisecond <em>Millisecond</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Millisecond</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMillisecond() - * @see #getXmlTimeOfDay() - * @generated - */ - public EAttribute getXmlTimeOfDay_Millisecond() - { - return (EAttribute)xmlTimeOfDayEClass.getEStructuralFeatures().get(3); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache <em>Xml Cache</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Cache</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache - * @generated - */ - public EClass getXmlCache() - { - return xmlCacheEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiry <em>Expiry</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Expiry</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiry() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_Expiry() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getSize <em>Size</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Size</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getSize() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_Size() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(1); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getShared <em>Shared</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Shared</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getShared() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_Shared() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(2); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getType <em>Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getType() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_Type() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(3); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getAlwaysRefresh <em>Always Refresh</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Always Refresh</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getAlwaysRefresh() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_AlwaysRefresh() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(4); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getRefreshOnlyIfNewer <em>Refresh Only If Newer</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Refresh Only If Newer</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getRefreshOnlyIfNewer() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_RefreshOnlyIfNewer() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(5); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getDisableHits <em>Disable Hits</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Disable Hits</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getDisableHits() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_DisableHits() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(6); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getCoordinationType <em>Coordination Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Coordination Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getCoordinationType() - * @see #getXmlCache() - * @generated - */ - public EAttribute getXmlCache_CoordinationType() - { - return (EAttribute)xmlCacheEClass.getEStructuralFeatures().get(7); - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiryTimeOfDay <em>Expiry Time Of Day</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Expiry Time Of Day</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiryTimeOfDay() - * @see #getXmlCache() - * @generated - */ - public EReference getXmlCache_ExpiryTimeOfDay() - { - return (EReference)xmlCacheEClass.getEStructuralFeatures().get(8); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder <em>Xml Cache Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Cache Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder - * @generated - */ - public EClass getXmlCacheHolder() - { - return xmlCacheHolderEClass; - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getCache <em>Cache</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Cache</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getCache() - * @see #getXmlCacheHolder() - * @generated - */ - public EReference getXmlCacheHolder_Cache() - { - return (EReference)xmlCacheHolderEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getExistenceChecking <em>Existence Checking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Existence Checking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getExistenceChecking() - * @see #getXmlCacheHolder() - * @generated - */ - public EAttribute getXmlCacheHolder_ExistenceChecking() - { - return (EAttribute)xmlCacheHolderEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking <em>Xml Optimistic Locking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Optimistic Locking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking - * @generated - */ - public EClass getXmlOptimisticLocking() - { - return xmlOptimisticLockingEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getType <em>Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getType() - * @see #getXmlOptimisticLocking() - * @generated - */ - public EAttribute getXmlOptimisticLocking_Type() - { - return (EAttribute)xmlOptimisticLockingEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getCascade <em>Cascade</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Cascade</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getCascade() - * @see #getXmlOptimisticLocking() - * @generated - */ - public EAttribute getXmlOptimisticLocking_Cascade() - { - return (EAttribute)xmlOptimisticLockingEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getSelectedColumns <em>Selected Columns</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Selected Columns</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getSelectedColumns() - * @see #getXmlOptimisticLocking() - * @generated - */ - public EReference getXmlOptimisticLocking_SelectedColumns() - { - return (EReference)xmlOptimisticLockingEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity <em>Xml Entity</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Entity</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity - * @generated - */ - public EClass getXmlEntity() - { - return xmlEntityEClass; - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getOptimisticLocking <em>Optimistic Locking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Optimistic Locking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getOptimisticLocking() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_OptimisticLocking() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCopyPolicy <em>Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCopyPolicy() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_CopyPolicy() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Instantiation Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getInstantiationCopyPolicy() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_InstantiationCopyPolicy() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCloneCopyPolicy <em>Clone Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Clone Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCloneCopyPolicy() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_CloneCopyPolicy() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getNamedStoredProcedureQueries <em>Named Stored Procedure Queries</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Named Stored Procedure Queries</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getNamedStoredProcedureQueries() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_NamedStoredProcedureQueries() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(4); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getProperties() - * @see #getXmlEntity() - * @generated - */ - public EReference getXmlEntity_Properties() - { - return (EReference)xmlEntityEClass.getEStructuralFeatures().get(5); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Exclude Default Mappings</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getExcludeDefaultMappings() - * @see #getXmlEntity() - * @generated - */ - public EAttribute getXmlEntity_ExcludeDefaultMappings() - { - return (EAttribute)xmlEntityEClass.getEStructuralFeatures().get(6); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass <em>Xml Mapped Superclass</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Mapped Superclass</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass - * @generated - */ - public EClass getXmlMappedSuperclass() - { - return xmlMappedSuperclassEClass; - } - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getOptimisticLocking <em>Optimistic Locking</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Optimistic Locking</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getOptimisticLocking() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EReference getXmlMappedSuperclass_OptimisticLocking() - { - return (EReference)xmlMappedSuperclassEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCopyPolicy <em>Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCopyPolicy() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EReference getXmlMappedSuperclass_CopyPolicy() - { - return (EReference)xmlMappedSuperclassEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Instantiation Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getInstantiationCopyPolicy() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EReference getXmlMappedSuperclass_InstantiationCopyPolicy() - { - return (EReference)xmlMappedSuperclassEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCloneCopyPolicy <em>Clone Copy Policy</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Clone Copy Policy</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCloneCopyPolicy() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EReference getXmlMappedSuperclass_CloneCopyPolicy() - { - return (EReference)xmlMappedSuperclassEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getProperties() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EReference getXmlMappedSuperclass_Properties() - { - return (EReference)xmlMappedSuperclassEClass.getEStructuralFeatures().get(4); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Exclude Default Mappings</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getExcludeDefaultMappings() - * @see #getXmlMappedSuperclass() - * @generated - */ - public EAttribute getXmlMappedSuperclass_ExcludeDefaultMappings() - { - return (EAttribute)xmlMappedSuperclassEClass.getEStructuralFeatures().get(5); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable <em>Xml Mutable</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Mutable</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable - * @generated - */ - public EClass getXmlMutable() - { - return xmlMutableEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable#getMutable <em>Mutable</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Mutable</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable#getMutable() - * @see #getXmlMutable() - * @generated - */ - public EAttribute getXmlMutable_Mutable() - { - return (EAttribute)xmlMutableEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping <em>Xml Convertible Mapping</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Convertible Mapping</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping - * @generated - */ - public EClass getXmlConvertibleMapping() - { - return xmlConvertibleMappingEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping#getConvert <em>Convert</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Convert</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping#getConvert() - * @see #getXmlConvertibleMapping() - * @generated - */ - public EAttribute getXmlConvertibleMapping_Convert() - { - return (EAttribute)xmlConvertibleMappingEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods <em>Xml Access Methods</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Access Methods</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods - * @generated - */ - public EClass getXmlAccessMethods() - { - return xmlAccessMethodsEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getGetMethod <em>Get Method</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Get Method</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getGetMethod() - * @see #getXmlAccessMethods() - * @generated - */ - public EAttribute getXmlAccessMethods_GetMethod() - { - return (EAttribute)xmlAccessMethodsEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getSetMethod <em>Set Method</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Set Method</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getSetMethod() - * @see #getXmlAccessMethods() - * @generated - */ - public EAttribute getXmlAccessMethods_SetMethod() - { - return (EAttribute)xmlAccessMethodsEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder <em>Xml Access Methods Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Access Methods Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder - * @generated - */ - public EClass getXmlAccessMethodsHolder() - { - return xmlAccessMethodsHolderEClass; - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder#getAccessMethods <em>Access Methods</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Access Methods</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder#getAccessMethods() - * @see #getXmlAccessMethodsHolder() - * @generated - */ - public EReference getXmlAccessMethodsHolder_AccessMethods() - { - return (EReference)xmlAccessMethodsHolderEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlId <em>Xml Id</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Id</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlId - * @generated - */ - public EClass getXmlId() - { - return xmlIdEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlId#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlId#getProperties() - * @see #getXmlId() - * @generated - */ - public EReference getXmlId_Properties() - { - return (EReference)xmlIdEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl <em>Xml Id Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Id Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl - * @generated - */ - public EClass getXmlIdImpl() - { - return xmlIdImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId <em>Xml Embedded Id</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Embedded Id</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId - * @generated - */ - public EClass getXmlEmbeddedId() - { - return xmlEmbeddedIdEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId#getProperties() - * @see #getXmlEmbeddedId() - * @generated - */ - public EReference getXmlEmbeddedId_Properties() - { - return (EReference)xmlEmbeddedIdEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl <em>Xml Embedded Id Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Embedded Id Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl - * @generated - */ - public EClass getXmlEmbeddedIdImpl() - { - return xmlEmbeddedIdImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded <em>Xml Embedded</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Embedded</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded - * @generated - */ - public EClass getXmlEmbedded() - { - return xmlEmbeddedEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded#getProperties() - * @see #getXmlEmbedded() - * @generated - */ - public EReference getXmlEmbedded_Properties() - { - return (EReference)xmlEmbeddedEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl <em>Xml Embedded Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Embedded Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl - * @generated - */ - public EClass getXmlEmbeddedImpl() - { - return xmlEmbeddedImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic <em>Xml Basic</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic - * @generated - */ - public EClass getXmlBasic() - { - return xmlBasicEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic#getProperties() - * @see #getXmlBasic() - * @generated - */ - public EReference getXmlBasic_Properties() - { - return (EReference)xmlBasicEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl <em>Xml Basic Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl - * @generated - */ - public EClass getXmlBasicImpl() - { - return xmlBasicImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion <em>Xml Version</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Version</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion - * @generated - */ - public EClass getXmlVersion() - { - return xmlVersionEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion#getProperties() - * @see #getXmlVersion() - * @generated - */ - public EReference getXmlVersion_Properties() - { - return (EReference)xmlVersionEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl <em>Xml Version Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Version Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl - * @generated - */ - public EClass getXmlVersionImpl() - { - return xmlVersionImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned <em>Xml Private Owned</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Private Owned</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned - * @generated - */ - public EClass getXmlPrivateOwned() - { - return xmlPrivateOwnedEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned#isPrivateOwned <em>Private Owned</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Private Owned</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned#isPrivateOwned() - * @see #getXmlPrivateOwned() - * @generated - */ - public EAttribute getXmlPrivateOwned_PrivateOwned() - { - return (EAttribute)xmlPrivateOwnedEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch <em>Xml Join Fetch</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Join Fetch</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch - * @generated - */ - public EClass getXmlJoinFetch() - { - return xmlJoinFetchEClass; - } - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch#getJoinFetch <em>Join Fetch</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Join Fetch</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch#getJoinFetch() - * @see #getXmlJoinFetch() - * @generated - */ - public EAttribute getXmlJoinFetch_JoinFetch() - { - return (EAttribute)xmlJoinFetchEClass.getEStructuralFeatures().get(0); - } - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne <em>Xml One To One</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml One To One</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne - * @generated - */ - public EClass getXmlOneToOne() - { - return xmlOneToOneEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne#getProperties() - * @see #getXmlOneToOne() - * @generated - */ - public EReference getXmlOneToOne_Properties() - { - return (EReference)xmlOneToOneEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl <em>Xml One To One Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml One To One Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl - * @generated - */ - public EClass getXmlOneToOneImpl() - { - return xmlOneToOneImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany <em>Xml One To Many</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml One To Many</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany - * @generated - */ - public EClass getXmlOneToMany() - { - return xmlOneToManyEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany#getProperties() - * @see #getXmlOneToMany() - * @generated - */ - public EReference getXmlOneToMany_Properties() - { - return (EReference)xmlOneToManyEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl <em>Xml One To Many Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml One To Many Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl - * @generated - */ - public EClass getXmlOneToManyImpl() - { - return xmlOneToManyImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne <em>Xml Many To One</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Many To One</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne - * @generated - */ - public EClass getXmlManyToOne() - { - return xmlManyToOneEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne#getProperties() - * @see #getXmlManyToOne() - * @generated - */ - public EReference getXmlManyToOne_Properties() - { - return (EReference)xmlManyToOneEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl <em>Xml Many To One Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Many To One Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl - * @generated - */ - public EClass getXmlManyToOneImpl() - { - return xmlManyToOneImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany <em>Xml Many To Many</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Many To Many</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany - * @generated - */ - public EClass getXmlManyToMany() - { - return xmlManyToManyEClass; - } - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany#getProperties() - * @see #getXmlManyToMany() - * @generated - */ - public EReference getXmlManyToMany_Properties() - { - return (EReference)xmlManyToManyEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl <em>Xml Many To Many Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Many To Many Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl - * @generated - */ - public EClass getXmlManyToManyImpl() - { - return xmlManyToManyImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes <em>Attributes</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Attributes</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes - * @generated - */ - public EClass getAttributes() - { - return attributesEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicCollections <em>Basic Collections</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Basic Collections</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicCollections() - * @see #getAttributes() - * @generated - */ - public EReference getAttributes_BasicCollections() - { - return (EReference)attributesEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicMaps <em>Basic Maps</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Basic Maps</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getBasicMaps() - * @see #getAttributes() - * @generated - */ - public EReference getAttributes_BasicMaps() - { - return (EReference)attributesEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getTransformations <em>Transformations</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Transformations</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getTransformations() - * @see #getAttributes() - * @generated - */ - public EReference getAttributes_Transformations() - { - return (EReference)attributesEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getVariableOneToOnes <em>Variable One To Ones</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Variable One To Ones</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes#getVariableOneToOnes() - * @see #getAttributes() - * @generated - */ - public EReference getAttributes_VariableOneToOnes() - { - return (EReference)attributesEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection <em>Xml Basic Collection</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic Collection</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection - * @generated - */ - public EClass getXmlBasicCollection() - { - return xmlBasicCollectionEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection#getProperties() - * @see #getXmlBasicCollection() - * @generated - */ - public EReference getXmlBasicCollection_Properties() - { - return (EReference)xmlBasicCollectionEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl <em>Xml Basic Collection Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic Collection Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl - * @generated - */ - public EClass getXmlBasicCollectionImpl() - { - return xmlBasicCollectionImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap <em>Xml Basic Map</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic Map</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap - * @generated - */ - public EClass getXmlBasicMap() - { - return xmlBasicMapEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap#getProperties() - * @see #getXmlBasicMap() - * @generated - */ - public EReference getXmlBasicMap_Properties() - { - return (EReference)xmlBasicMapEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl <em>Xml Basic Map Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Basic Map Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl - * @generated - */ - public EClass getXmlBasicMapImpl() - { - return xmlBasicMapImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation <em>Xml Transformation</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Transformation</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation - * @generated - */ - public EClass getXmlTransformation() - { - return xmlTransformationEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation#getProperties() - * @see #getXmlTransformation() - * @generated - */ - public EReference getXmlTransformation_Properties() - { - return (EReference)xmlTransformationEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl <em>Xml Transformation Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Transformation Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl - * @generated - */ - public EClass getXmlTransformationImpl() - { - return xmlTransformationImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty <em>Xml Property</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Property</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty - * @generated - */ - public EClass getXmlProperty() - { - return xmlPropertyEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getName <em>Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getName() - * @see #getXmlProperty() - * @generated - */ - public EAttribute getXmlProperty_Name() - { - return (EAttribute)xmlPropertyEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValue <em>Value</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Value</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValue() - * @see #getXmlProperty() - * @generated - */ - public EAttribute getXmlProperty_Value() - { - return (EAttribute)xmlPropertyEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValueType <em>Value Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Value Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValueType() - * @see #getXmlProperty() - * @generated - */ - public EAttribute getXmlProperty_ValueType() - { - return (EAttribute)xmlPropertyEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne <em>Xml Variable One To One</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Variable One To One</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne - * @generated - */ - public EClass getXmlVariableOneToOne() - { - return xmlVariableOneToOneEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne#getProperties <em>Properties</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Properties</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne#getProperties() - * @see #getXmlVariableOneToOne() - * @generated - */ - public EReference getXmlVariableOneToOne_Properties() - { - return (EReference)xmlVariableOneToOneEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl <em>Xml Variable One To One Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Variable One To One Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl - * @generated - */ - public EClass getXmlVariableOneToOneImpl() - { - return xmlVariableOneToOneImplEClass; - } - - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection <em>Xml Direction</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Xml Direction</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection - * @generated - */ - public EEnum getXmlDirection() - { - return xmlDirectionEEnum; - } - - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType <em>Xml Change Tracking Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Xml Change Tracking Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType - * @generated - */ - public EEnum getXmlChangeTrackingType() - { - return xmlChangeTrackingTypeEEnum; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter <em>Xml Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter - * @generated - */ - public EClass getXmlConverter() - { - return xmlConverterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter#getClassName <em>Class Name</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Class Name</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter#getClassName() - * @see #getXmlConverter() - * @generated - */ - public EAttribute getXmlConverter_ClassName() - { - return (EAttribute)xmlConverterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl <em>Xml Converter Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Converter Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl - * @generated - */ - public EClass getXmlConverterImpl() - { - return xmlConverterImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter <em>Xml Type Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Type Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter - * @generated - */ - public EClass getXmlTypeConverter() - { - return xmlTypeConverterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getDataType <em>Data Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Data Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getDataType() - * @see #getXmlTypeConverter() - * @generated - */ - public EAttribute getXmlTypeConverter_DataType() - { - return (EAttribute)xmlTypeConverterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getObjectType <em>Object Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Object Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getObjectType() - * @see #getXmlTypeConverter() - * @generated - */ - public EAttribute getXmlTypeConverter_ObjectType() - { - return (EAttribute)xmlTypeConverterEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl <em>Xml Type Converter Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Type Converter Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl - * @generated - */ - public EClass getXmlTypeConverterImpl() - { - return xmlTypeConverterImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue <em>Xml Conversion Value</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Conversion Value</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue - * @generated - */ - public EClass getXmlConversionValue() - { - return xmlConversionValueEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getDataValue <em>Data Value</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Data Value</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getDataValue() - * @see #getXmlConversionValue() - * @generated - */ - public EAttribute getXmlConversionValue_DataValue() - { - return (EAttribute)xmlConversionValueEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getObjectValue <em>Object Value</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Object Value</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getObjectValue() - * @see #getXmlConversionValue() - * @generated - */ - public EAttribute getXmlConversionValue_ObjectValue() - { - return (EAttribute)xmlConversionValueEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl <em>Xml Conversion Value Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Conversion Value Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl - * @generated - */ - public EClass getXmlConversionValueImpl() - { - return xmlConversionValueImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter <em>Xml Object Type Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Object Type Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter - * @generated - */ - public EClass getXmlObjectTypeConverter() - { - return xmlObjectTypeConverterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDataType <em>Data Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Data Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDataType() - * @see #getXmlObjectTypeConverter() - * @generated - */ - public EAttribute getXmlObjectTypeConverter_DataType() - { - return (EAttribute)xmlObjectTypeConverterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getObjectType <em>Object Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Object Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getObjectType() - * @see #getXmlObjectTypeConverter() - * @generated - */ - public EAttribute getXmlObjectTypeConverter_ObjectType() - { - return (EAttribute)xmlObjectTypeConverterEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl <em>Xml Object Type Converter Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Object Type Converter Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl - * @generated - */ - public EClass getXmlObjectTypeConverterImpl() - { - return xmlObjectTypeConverterImplEClass; - } - - - /** - * Returns the meta object for the containment reference list '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getConversionValues <em>Conversion Values</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference list '<em>Conversion Values</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getConversionValues() - * @see #getXmlObjectTypeConverter() - * @generated - */ - public EReference getXmlObjectTypeConverter_ConversionValues() - { - return (EReference)xmlObjectTypeConverterEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDefaultObjectValue <em>Default Object Value</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Default Object Value</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDefaultObjectValue() - * @see #getXmlObjectTypeConverter() - * @generated - */ - public EAttribute getXmlObjectTypeConverter_DefaultObjectValue() - { - return (EAttribute)xmlObjectTypeConverterEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter <em>Xml Struct Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Struct Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter - * @generated - */ - public EClass getXmlStructConverter() - { - return xmlStructConverterEClass; - } - - - /** - * Returns the meta object for the attribute '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter#getConverter <em>Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the attribute '<em>Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter#getConverter() - * @see #getXmlStructConverter() - * @generated - */ - public EAttribute getXmlStructConverter_Converter() - { - return (EAttribute)xmlStructConverterEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl <em>Xml Struct Converter Impl</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Struct Converter Impl</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl - * @generated - */ - public EClass getXmlStructConverterImpl() - { - return xmlStructConverterImplEClass; - } - - - /** - * Returns the meta object for class '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder <em>Xml Converter Holder</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Xml Converter Holder</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder - * @generated - */ - public EClass getXmlConverterHolder() - { - return xmlConverterHolderEClass; - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getConverter <em>Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getConverter() - * @see #getXmlConverterHolder() - * @generated - */ - public EReference getXmlConverterHolder_Converter() - { - return (EReference)xmlConverterHolderEClass.getEStructuralFeatures().get(0); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getTypeConverter <em>Type Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Type Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getTypeConverter() - * @see #getXmlConverterHolder() - * @generated - */ - public EReference getXmlConverterHolder_TypeConverter() - { - return (EReference)xmlConverterHolderEClass.getEStructuralFeatures().get(1); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getObjectTypeConverter <em>Object Type Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Object Type Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getObjectTypeConverter() - * @see #getXmlConverterHolder() - * @generated - */ - public EReference getXmlConverterHolder_ObjectTypeConverter() - { - return (EReference)xmlConverterHolderEClass.getEStructuralFeatures().get(2); - } - - - /** - * Returns the meta object for the containment reference '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getStructConverter <em>Struct Converter</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for the containment reference '<em>Struct Converter</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getStructConverter() - * @see #getXmlConverterHolder() - * @generated - */ - public EReference getXmlConverterHolder_StructConverter() - { - return (EReference)xmlConverterHolderEClass.getEStructuralFeatures().get(3); - } - - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheType <em>Cache Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Cache Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheType - * @generated - */ - public EEnum getCacheType() - { - return cacheTypeEEnum; - } - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType <em>Cache Coordination Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Cache Coordination Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType - * @generated - */ - public EEnum getCacheCoordinationType() - { - return cacheCoordinationTypeEEnum; - } - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType <em>Xml Join Fetch Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Xml Join Fetch Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @generated - */ - public EEnum getXmlJoinFetchType() - { - return xmlJoinFetchTypeEEnum; - } - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType <em>Existence Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Existence Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @generated - */ - public EEnum getExistenceType() - { - return existenceTypeEEnum; - } - - /** - * Returns the meta object for enum '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType <em>Xml Optimistic Locking Type</em>}'. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for enum '<em>Xml Optimistic Locking Type</em>'. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType - * @generated - */ - public EEnum getXmlOptimisticLockingType() - { - return xmlOptimisticLockingTypeEEnum; - } - - - /** - * Returns the factory that creates the instances of the model. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the factory that creates the instances of the model. - * @generated - */ - public EclipseLinkOrmFactory getEclipseLinkOrmFactory() - { - return (EclipseLinkOrmFactory)getEFactoryInstance(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public void createPackageContents() - { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - xmlNamedConverterEClass = createEClass(XML_NAMED_CONVERTER); - createEAttribute(xmlNamedConverterEClass, XML_NAMED_CONVERTER__NAME); - - xmlConverterEClass = createEClass(XML_CONVERTER); - createEAttribute(xmlConverterEClass, XML_CONVERTER__CLASS_NAME); - - xmlConverterImplEClass = createEClass(XML_CONVERTER_IMPL); - - xmlTypeConverterEClass = createEClass(XML_TYPE_CONVERTER); - createEAttribute(xmlTypeConverterEClass, XML_TYPE_CONVERTER__DATA_TYPE); - createEAttribute(xmlTypeConverterEClass, XML_TYPE_CONVERTER__OBJECT_TYPE); - - xmlTypeConverterImplEClass = createEClass(XML_TYPE_CONVERTER_IMPL); - - xmlConversionValueEClass = createEClass(XML_CONVERSION_VALUE); - createEAttribute(xmlConversionValueEClass, XML_CONVERSION_VALUE__DATA_VALUE); - createEAttribute(xmlConversionValueEClass, XML_CONVERSION_VALUE__OBJECT_VALUE); - - xmlConversionValueImplEClass = createEClass(XML_CONVERSION_VALUE_IMPL); - - xmlObjectTypeConverterEClass = createEClass(XML_OBJECT_TYPE_CONVERTER); - createEAttribute(xmlObjectTypeConverterEClass, XML_OBJECT_TYPE_CONVERTER__DATA_TYPE); - createEAttribute(xmlObjectTypeConverterEClass, XML_OBJECT_TYPE_CONVERTER__OBJECT_TYPE); - createEReference(xmlObjectTypeConverterEClass, XML_OBJECT_TYPE_CONVERTER__CONVERSION_VALUES); - createEAttribute(xmlObjectTypeConverterEClass, XML_OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE); - - xmlObjectTypeConverterImplEClass = createEClass(XML_OBJECT_TYPE_CONVERTER_IMPL); - - xmlStructConverterEClass = createEClass(XML_STRUCT_CONVERTER); - createEAttribute(xmlStructConverterEClass, XML_STRUCT_CONVERTER__CONVERTER); - - xmlStructConverterImplEClass = createEClass(XML_STRUCT_CONVERTER_IMPL); - - xmlConvertersHolderEClass = createEClass(XML_CONVERTERS_HOLDER); - createEReference(xmlConvertersHolderEClass, XML_CONVERTERS_HOLDER__CONVERTERS); - createEReference(xmlConvertersHolderEClass, XML_CONVERTERS_HOLDER__TYPE_CONVERTERS); - createEReference(xmlConvertersHolderEClass, XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS); - createEReference(xmlConvertersHolderEClass, XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS); - - xmlStoredProcedureParameterEClass = createEClass(XML_STORED_PROCEDURE_PARAMETER); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__DIRECTION); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__NAME); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__TYPE); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE); - createEAttribute(xmlStoredProcedureParameterEClass, XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME); - - xmlNamedStoredProcedureQueryEClass = createEClass(XML_NAMED_STORED_PROCEDURE_QUERY); - createEAttribute(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__NAME); - createEAttribute(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS); - createEAttribute(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING); - createEAttribute(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME); - createEAttribute(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET); - createEReference(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__HINTS); - createEReference(xmlNamedStoredProcedureQueryEClass, XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS); - - xmlEntityMappingsEClass = createEClass(XML_ENTITY_MAPPINGS); - createEReference(xmlEntityMappingsEClass, XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES); - - xmlPersistenceUnitMetadataEClass = createEClass(XML_PERSISTENCE_UNIT_METADATA); - createEAttribute(xmlPersistenceUnitMetadataEClass, XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS); - - xmlCustomizerEClass = createEClass(XML_CUSTOMIZER); - createEAttribute(xmlCustomizerEClass, XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME); - - xmlCustomizerHolderEClass = createEClass(XML_CUSTOMIZER_HOLDER); - createEReference(xmlCustomizerHolderEClass, XML_CUSTOMIZER_HOLDER__CUSTOMIZER); - - xmlChangeTrackingEClass = createEClass(XML_CHANGE_TRACKING); - createEAttribute(xmlChangeTrackingEClass, XML_CHANGE_TRACKING__TYPE); - - xmlChangeTrackingHolderEClass = createEClass(XML_CHANGE_TRACKING_HOLDER); - createEReference(xmlChangeTrackingHolderEClass, XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING); - - xmlCopyPolicyEClass = createEClass(XML_COPY_POLICY); - createEAttribute(xmlCopyPolicyEClass, XML_COPY_POLICY__CLASS); - - xmlInstantiationPolicyEClass = createEClass(XML_INSTANTIATION_POLICY); - - xmlCloneCopyPolicyEClass = createEClass(XML_CLONE_COPY_POLICY); - createEAttribute(xmlCloneCopyPolicyEClass, XML_CLONE_COPY_POLICY__METHOD); - createEAttribute(xmlCloneCopyPolicyEClass, XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD); - - xmlEmbeddableEClass = createEClass(XML_EMBEDDABLE); - createEReference(xmlEmbeddableEClass, XML_EMBEDDABLE__COPY_POLICY); - createEReference(xmlEmbeddableEClass, XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY); - createEReference(xmlEmbeddableEClass, XML_EMBEDDABLE__CLONE_COPY_POLICY); - createEReference(xmlEmbeddableEClass, XML_EMBEDDABLE__PROPERTIES); - createEAttribute(xmlEmbeddableEClass, XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS); - - xmlReadOnlyEClass = createEClass(XML_READ_ONLY); - createEAttribute(xmlReadOnlyEClass, XML_READ_ONLY__READ_ONLY); - - xmlTimeOfDayEClass = createEClass(XML_TIME_OF_DAY); - createEAttribute(xmlTimeOfDayEClass, XML_TIME_OF_DAY__HOUR); - createEAttribute(xmlTimeOfDayEClass, XML_TIME_OF_DAY__MINUTE); - createEAttribute(xmlTimeOfDayEClass, XML_TIME_OF_DAY__SECOND); - createEAttribute(xmlTimeOfDayEClass, XML_TIME_OF_DAY__MILLISECOND); - - xmlCacheEClass = createEClass(XML_CACHE); - createEAttribute(xmlCacheEClass, XML_CACHE__EXPIRY); - createEAttribute(xmlCacheEClass, XML_CACHE__SIZE); - createEAttribute(xmlCacheEClass, XML_CACHE__SHARED); - createEAttribute(xmlCacheEClass, XML_CACHE__TYPE); - createEAttribute(xmlCacheEClass, XML_CACHE__ALWAYS_REFRESH); - createEAttribute(xmlCacheEClass, XML_CACHE__REFRESH_ONLY_IF_NEWER); - createEAttribute(xmlCacheEClass, XML_CACHE__DISABLE_HITS); - createEAttribute(xmlCacheEClass, XML_CACHE__COORDINATION_TYPE); - createEReference(xmlCacheEClass, XML_CACHE__EXPIRY_TIME_OF_DAY); - - xmlCacheHolderEClass = createEClass(XML_CACHE_HOLDER); - createEReference(xmlCacheHolderEClass, XML_CACHE_HOLDER__CACHE); - createEAttribute(xmlCacheHolderEClass, XML_CACHE_HOLDER__EXISTENCE_CHECKING); - - xmlOptimisticLockingEClass = createEClass(XML_OPTIMISTIC_LOCKING); - createEAttribute(xmlOptimisticLockingEClass, XML_OPTIMISTIC_LOCKING__TYPE); - createEAttribute(xmlOptimisticLockingEClass, XML_OPTIMISTIC_LOCKING__CASCADE); - createEReference(xmlOptimisticLockingEClass, XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS); - - xmlEntityEClass = createEClass(XML_ENTITY); - createEReference(xmlEntityEClass, XML_ENTITY__OPTIMISTIC_LOCKING); - createEReference(xmlEntityEClass, XML_ENTITY__COPY_POLICY); - createEReference(xmlEntityEClass, XML_ENTITY__INSTANTIATION_COPY_POLICY); - createEReference(xmlEntityEClass, XML_ENTITY__CLONE_COPY_POLICY); - createEReference(xmlEntityEClass, XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES); - createEReference(xmlEntityEClass, XML_ENTITY__PROPERTIES); - createEAttribute(xmlEntityEClass, XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS); - - xmlMappedSuperclassEClass = createEClass(XML_MAPPED_SUPERCLASS); - createEReference(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING); - createEReference(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__COPY_POLICY); - createEReference(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY); - createEReference(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY); - createEReference(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__PROPERTIES); - createEAttribute(xmlMappedSuperclassEClass, XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS); - - xmlMutableEClass = createEClass(XML_MUTABLE); - createEAttribute(xmlMutableEClass, XML_MUTABLE__MUTABLE); - - xmlConverterHolderEClass = createEClass(XML_CONVERTER_HOLDER); - createEReference(xmlConverterHolderEClass, XML_CONVERTER_HOLDER__CONVERTER); - createEReference(xmlConverterHolderEClass, XML_CONVERTER_HOLDER__TYPE_CONVERTER); - createEReference(xmlConverterHolderEClass, XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER); - createEReference(xmlConverterHolderEClass, XML_CONVERTER_HOLDER__STRUCT_CONVERTER); - - xmlConvertibleMappingEClass = createEClass(XML_CONVERTIBLE_MAPPING); - createEAttribute(xmlConvertibleMappingEClass, XML_CONVERTIBLE_MAPPING__CONVERT); - - xmlAccessMethodsEClass = createEClass(XML_ACCESS_METHODS); - createEAttribute(xmlAccessMethodsEClass, XML_ACCESS_METHODS__GET_METHOD); - createEAttribute(xmlAccessMethodsEClass, XML_ACCESS_METHODS__SET_METHOD); - - xmlAccessMethodsHolderEClass = createEClass(XML_ACCESS_METHODS_HOLDER); - createEReference(xmlAccessMethodsHolderEClass, XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS); - - xmlPropertyEClass = createEClass(XML_PROPERTY); - createEAttribute(xmlPropertyEClass, XML_PROPERTY__NAME); - createEAttribute(xmlPropertyEClass, XML_PROPERTY__VALUE); - createEAttribute(xmlPropertyEClass, XML_PROPERTY__VALUE_TYPE); - - xmlIdEClass = createEClass(XML_ID); - createEReference(xmlIdEClass, XML_ID__PROPERTIES); - - xmlIdImplEClass = createEClass(XML_ID_IMPL); - - xmlEmbeddedIdEClass = createEClass(XML_EMBEDDED_ID); - createEReference(xmlEmbeddedIdEClass, XML_EMBEDDED_ID__PROPERTIES); - - xmlEmbeddedIdImplEClass = createEClass(XML_EMBEDDED_ID_IMPL); - - xmlEmbeddedEClass = createEClass(XML_EMBEDDED); - createEReference(xmlEmbeddedEClass, XML_EMBEDDED__PROPERTIES); - - xmlEmbeddedImplEClass = createEClass(XML_EMBEDDED_IMPL); - - xmlBasicEClass = createEClass(XML_BASIC); - createEReference(xmlBasicEClass, XML_BASIC__PROPERTIES); - - xmlBasicImplEClass = createEClass(XML_BASIC_IMPL); - - xmlVersionEClass = createEClass(XML_VERSION); - createEReference(xmlVersionEClass, XML_VERSION__PROPERTIES); - - xmlVersionImplEClass = createEClass(XML_VERSION_IMPL); - - xmlPrivateOwnedEClass = createEClass(XML_PRIVATE_OWNED); - createEAttribute(xmlPrivateOwnedEClass, XML_PRIVATE_OWNED__PRIVATE_OWNED); - - xmlJoinFetchEClass = createEClass(XML_JOIN_FETCH); - createEAttribute(xmlJoinFetchEClass, XML_JOIN_FETCH__JOIN_FETCH); - - xmlOneToOneEClass = createEClass(XML_ONE_TO_ONE); - createEReference(xmlOneToOneEClass, XML_ONE_TO_ONE__PROPERTIES); - - xmlOneToOneImplEClass = createEClass(XML_ONE_TO_ONE_IMPL); - - xmlOneToManyEClass = createEClass(XML_ONE_TO_MANY); - createEReference(xmlOneToManyEClass, XML_ONE_TO_MANY__PROPERTIES); - - xmlOneToManyImplEClass = createEClass(XML_ONE_TO_MANY_IMPL); - - xmlManyToOneEClass = createEClass(XML_MANY_TO_ONE); - createEReference(xmlManyToOneEClass, XML_MANY_TO_ONE__PROPERTIES); - - xmlManyToOneImplEClass = createEClass(XML_MANY_TO_ONE_IMPL); - - xmlManyToManyEClass = createEClass(XML_MANY_TO_MANY); - createEReference(xmlManyToManyEClass, XML_MANY_TO_MANY__PROPERTIES); - - xmlManyToManyImplEClass = createEClass(XML_MANY_TO_MANY_IMPL); - - xmlBasicCollectionEClass = createEClass(XML_BASIC_COLLECTION); - createEReference(xmlBasicCollectionEClass, XML_BASIC_COLLECTION__PROPERTIES); - - xmlBasicCollectionImplEClass = createEClass(XML_BASIC_COLLECTION_IMPL); - - xmlBasicMapEClass = createEClass(XML_BASIC_MAP); - createEReference(xmlBasicMapEClass, XML_BASIC_MAP__PROPERTIES); - - xmlBasicMapImplEClass = createEClass(XML_BASIC_MAP_IMPL); - - xmlTransformationEClass = createEClass(XML_TRANSFORMATION); - createEReference(xmlTransformationEClass, XML_TRANSFORMATION__PROPERTIES); - - xmlTransformationImplEClass = createEClass(XML_TRANSFORMATION_IMPL); - - xmlVariableOneToOneEClass = createEClass(XML_VARIABLE_ONE_TO_ONE); - createEReference(xmlVariableOneToOneEClass, XML_VARIABLE_ONE_TO_ONE__PROPERTIES); - - xmlVariableOneToOneImplEClass = createEClass(XML_VARIABLE_ONE_TO_ONE_IMPL); - - attributesEClass = createEClass(ATTRIBUTES); - createEReference(attributesEClass, ATTRIBUTES__BASIC_COLLECTIONS); - createEReference(attributesEClass, ATTRIBUTES__BASIC_MAPS); - createEReference(attributesEClass, ATTRIBUTES__TRANSFORMATIONS); - createEReference(attributesEClass, ATTRIBUTES__VARIABLE_ONE_TO_ONES); - - // Create enums - xmlDirectionEEnum = createEEnum(XML_DIRECTION); - xmlChangeTrackingTypeEEnum = createEEnum(XML_CHANGE_TRACKING_TYPE); - cacheTypeEEnum = createEEnum(CACHE_TYPE); - cacheCoordinationTypeEEnum = createEEnum(CACHE_COORDINATION_TYPE); - existenceTypeEEnum = createEEnum(EXISTENCE_TYPE); - xmlOptimisticLockingTypeEEnum = createEEnum(XML_OPTIMISTIC_LOCKING_TYPE); - xmlJoinFetchTypeEEnum = createEEnum(XML_JOIN_FETCH_TYPE); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public void initializePackageContents() - { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - XMLTypePackage theXMLTypePackage = (XMLTypePackage)EPackage.Registry.INSTANCE.getEPackage(XMLTypePackage.eNS_URI); - OrmPackage theOrmPackage = (OrmPackage)EPackage.Registry.INSTANCE.getEPackage(OrmPackage.eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - xmlConverterEClass.getESuperTypes().add(this.getXmlNamedConverter()); - xmlConverterImplEClass.getESuperTypes().add(this.getXmlConverter()); - xmlTypeConverterEClass.getESuperTypes().add(this.getXmlNamedConverter()); - xmlTypeConverterImplEClass.getESuperTypes().add(this.getXmlTypeConverter()); - xmlConversionValueImplEClass.getESuperTypes().add(this.getXmlConversionValue()); - xmlObjectTypeConverterEClass.getESuperTypes().add(this.getXmlNamedConverter()); - xmlObjectTypeConverterImplEClass.getESuperTypes().add(this.getXmlObjectTypeConverter()); - xmlStructConverterEClass.getESuperTypes().add(this.getXmlNamedConverter()); - xmlStructConverterImplEClass.getESuperTypes().add(this.getXmlStructConverter()); - xmlEntityMappingsEClass.getESuperTypes().add(theOrmPackage.getXmlEntityMappings()); - xmlEntityMappingsEClass.getESuperTypes().add(this.getXmlConvertersHolder()); - xmlPersistenceUnitMetadataEClass.getESuperTypes().add(theOrmPackage.getXmlPersistenceUnitMetadata()); - xmlEmbeddableEClass.getESuperTypes().add(theOrmPackage.getXmlEmbeddable()); - xmlEmbeddableEClass.getESuperTypes().add(this.getXmlCustomizerHolder()); - xmlEmbeddableEClass.getESuperTypes().add(this.getXmlChangeTrackingHolder()); - xmlEmbeddableEClass.getESuperTypes().add(this.getXmlConvertersHolder()); - xmlEntityEClass.getESuperTypes().add(theOrmPackage.getXmlEntity()); - xmlEntityEClass.getESuperTypes().add(this.getXmlReadOnly()); - xmlEntityEClass.getESuperTypes().add(this.getXmlCustomizerHolder()); - xmlEntityEClass.getESuperTypes().add(this.getXmlChangeTrackingHolder()); - xmlEntityEClass.getESuperTypes().add(this.getXmlCacheHolder()); - xmlEntityEClass.getESuperTypes().add(this.getXmlConvertersHolder()); - xmlMappedSuperclassEClass.getESuperTypes().add(theOrmPackage.getXmlMappedSuperclass()); - xmlMappedSuperclassEClass.getESuperTypes().add(this.getXmlReadOnly()); - xmlMappedSuperclassEClass.getESuperTypes().add(this.getXmlCustomizerHolder()); - xmlMappedSuperclassEClass.getESuperTypes().add(this.getXmlChangeTrackingHolder()); - xmlMappedSuperclassEClass.getESuperTypes().add(this.getXmlCacheHolder()); - xmlMappedSuperclassEClass.getESuperTypes().add(this.getXmlConvertersHolder()); - xmlConvertibleMappingEClass.getESuperTypes().add(theOrmPackage.getXmlConvertibleMapping()); - xmlConvertibleMappingEClass.getESuperTypes().add(this.getXmlConverterHolder()); - xmlIdEClass.getESuperTypes().add(theOrmPackage.getXmlId()); - xmlIdEClass.getESuperTypes().add(this.getXmlMutable()); - xmlIdEClass.getESuperTypes().add(this.getXmlConvertibleMapping()); - xmlIdEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlIdImplEClass.getESuperTypes().add(theOrmPackage.getXmlIdImpl()); - xmlIdImplEClass.getESuperTypes().add(this.getXmlId()); - xmlEmbeddedIdEClass.getESuperTypes().add(theOrmPackage.getXmlEmbeddedId()); - xmlEmbeddedIdEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlEmbeddedIdImplEClass.getESuperTypes().add(theOrmPackage.getXmlEmbeddedIdImpl()); - xmlEmbeddedIdImplEClass.getESuperTypes().add(this.getXmlEmbeddedId()); - xmlEmbeddedEClass.getESuperTypes().add(theOrmPackage.getXmlEmbedded()); - xmlEmbeddedEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlEmbeddedImplEClass.getESuperTypes().add(theOrmPackage.getXmlEmbeddedImpl()); - xmlEmbeddedImplEClass.getESuperTypes().add(this.getXmlEmbedded()); - xmlBasicEClass.getESuperTypes().add(theOrmPackage.getXmlBasic()); - xmlBasicEClass.getESuperTypes().add(this.getXmlMutable()); - xmlBasicEClass.getESuperTypes().add(this.getXmlConvertibleMapping()); - xmlBasicEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlBasicImplEClass.getESuperTypes().add(theOrmPackage.getXmlBasicImpl()); - xmlBasicImplEClass.getESuperTypes().add(this.getXmlBasic()); - xmlVersionEClass.getESuperTypes().add(theOrmPackage.getXmlVersion()); - xmlVersionEClass.getESuperTypes().add(this.getXmlMutable()); - xmlVersionEClass.getESuperTypes().add(this.getXmlConvertibleMapping()); - xmlVersionEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlVersionImplEClass.getESuperTypes().add(theOrmPackage.getXmlVersionImpl()); - xmlVersionImplEClass.getESuperTypes().add(this.getXmlVersion()); - xmlOneToOneEClass.getESuperTypes().add(theOrmPackage.getXmlOneToOne()); - xmlOneToOneEClass.getESuperTypes().add(this.getXmlPrivateOwned()); - xmlOneToOneEClass.getESuperTypes().add(this.getXmlJoinFetch()); - xmlOneToOneEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlOneToOneImplEClass.getESuperTypes().add(theOrmPackage.getXmlOneToOneImpl()); - xmlOneToOneImplEClass.getESuperTypes().add(this.getXmlOneToOne()); - xmlOneToManyEClass.getESuperTypes().add(theOrmPackage.getXmlOneToMany()); - xmlOneToManyEClass.getESuperTypes().add(this.getXmlPrivateOwned()); - xmlOneToManyEClass.getESuperTypes().add(this.getXmlJoinFetch()); - xmlOneToManyEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlOneToManyImplEClass.getESuperTypes().add(theOrmPackage.getXmlOneToManyImpl()); - xmlOneToManyImplEClass.getESuperTypes().add(this.getXmlOneToMany()); - xmlManyToOneEClass.getESuperTypes().add(theOrmPackage.getXmlManyToOne()); - xmlManyToOneEClass.getESuperTypes().add(this.getXmlJoinFetch()); - xmlManyToOneEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlManyToOneImplEClass.getESuperTypes().add(theOrmPackage.getXmlManyToOneImpl()); - xmlManyToOneImplEClass.getESuperTypes().add(this.getXmlManyToOne()); - xmlManyToManyEClass.getESuperTypes().add(theOrmPackage.getXmlManyToMany()); - xmlManyToManyEClass.getESuperTypes().add(this.getXmlJoinFetch()); - xmlManyToManyEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlManyToManyImplEClass.getESuperTypes().add(theOrmPackage.getXmlManyToManyImpl()); - xmlManyToManyImplEClass.getESuperTypes().add(this.getXmlManyToMany()); - xmlBasicCollectionEClass.getESuperTypes().add(theOrmPackage.getXmlAttributeMapping()); - xmlBasicCollectionEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlBasicCollectionImplEClass.getESuperTypes().add(theOrmPackage.getAbstractXmlAttributeMapping()); - xmlBasicCollectionImplEClass.getESuperTypes().add(this.getXmlBasicCollection()); - xmlBasicMapEClass.getESuperTypes().add(theOrmPackage.getXmlAttributeMapping()); - xmlBasicMapEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlBasicMapImplEClass.getESuperTypes().add(theOrmPackage.getAbstractXmlAttributeMapping()); - xmlBasicMapImplEClass.getESuperTypes().add(this.getXmlBasicMap()); - xmlTransformationEClass.getESuperTypes().add(theOrmPackage.getXmlAttributeMapping()); - xmlTransformationEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlTransformationImplEClass.getESuperTypes().add(theOrmPackage.getAbstractXmlAttributeMapping()); - xmlTransformationImplEClass.getESuperTypes().add(this.getXmlTransformation()); - xmlVariableOneToOneEClass.getESuperTypes().add(theOrmPackage.getXmlAttributeMapping()); - xmlVariableOneToOneEClass.getESuperTypes().add(this.getXmlAccessMethodsHolder()); - xmlVariableOneToOneImplEClass.getESuperTypes().add(theOrmPackage.getAbstractXmlAttributeMapping()); - xmlVariableOneToOneImplEClass.getESuperTypes().add(this.getXmlVariableOneToOne()); - attributesEClass.getESuperTypes().add(theOrmPackage.getAttributes()); - - // Initialize classes and features; add operations and parameters - initEClass(xmlNamedConverterEClass, XmlNamedConverter.class, "XmlNamedConverter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlNamedConverter_Name(), ecorePackage.getEString(), "name", null, 0, 1, XmlNamedConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlConverterEClass, XmlConverter.class, "XmlConverter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlConverter_ClassName(), ecorePackage.getEString(), "className", null, 0, 1, XmlConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlConverterImplEClass, XmlConverterImpl.class, "XmlConverterImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlTypeConverterEClass, XmlTypeConverter.class, "XmlTypeConverter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlTypeConverter_DataType(), ecorePackage.getEString(), "dataType", null, 0, 1, XmlTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlTypeConverter_ObjectType(), ecorePackage.getEString(), "objectType", null, 0, 1, XmlTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlTypeConverterImplEClass, XmlTypeConverterImpl.class, "XmlTypeConverterImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlConversionValueEClass, XmlConversionValue.class, "XmlConversionValue", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlConversionValue_DataValue(), ecorePackage.getEString(), "dataValue", null, 0, 1, XmlConversionValue.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlConversionValue_ObjectValue(), ecorePackage.getEString(), "objectValue", null, 0, 1, XmlConversionValue.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlConversionValueImplEClass, XmlConversionValueImpl.class, "XmlConversionValueImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlObjectTypeConverterEClass, XmlObjectTypeConverter.class, "XmlObjectTypeConverter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlObjectTypeConverter_DataType(), ecorePackage.getEString(), "dataType", null, 0, 1, XmlObjectTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlObjectTypeConverter_ObjectType(), ecorePackage.getEString(), "objectType", null, 0, 1, XmlObjectTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlObjectTypeConverter_ConversionValues(), this.getXmlConversionValue(), null, "conversionValues", null, 0, -1, XmlObjectTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlObjectTypeConverter_DefaultObjectValue(), ecorePackage.getEString(), "defaultObjectValue", null, 0, 1, XmlObjectTypeConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlObjectTypeConverterImplEClass, XmlObjectTypeConverterImpl.class, "XmlObjectTypeConverterImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlStructConverterEClass, XmlStructConverter.class, "XmlStructConverter", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlStructConverter_Converter(), ecorePackage.getEString(), "converter", null, 0, 1, XmlStructConverter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlStructConverterImplEClass, XmlStructConverterImpl.class, "XmlStructConverterImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlConvertersHolderEClass, XmlConvertersHolder.class, "XmlConvertersHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlConvertersHolder_Converters(), this.getXmlConverter(), null, "converters", null, 0, -1, XmlConvertersHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConvertersHolder_TypeConverters(), this.getXmlTypeConverter(), null, "typeConverters", null, 0, -1, XmlConvertersHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConvertersHolder_ObjectTypeConverters(), this.getXmlObjectTypeConverter(), null, "objectTypeConverters", null, 0, -1, XmlConvertersHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConvertersHolder_StructConverters(), this.getXmlStructConverter(), null, "structConverters", null, 0, -1, XmlConvertersHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlStoredProcedureParameterEClass, XmlStoredProcedureParameter.class, "XmlStoredProcedureParameter", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlStoredProcedureParameter_Direction(), this.getXmlDirection(), "direction", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlStoredProcedureParameter_Name(), theXMLTypePackage.getString(), "name", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlStoredProcedureParameter_QueryParameter(), theXMLTypePackage.getString(), "queryParameter", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlStoredProcedureParameter_Type(), theXMLTypePackage.getString(), "type", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlStoredProcedureParameter_JdbcType(), theXMLTypePackage.getIntObject(), "jdbcType", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlStoredProcedureParameter_JdbcTypeName(), theXMLTypePackage.getString(), "jdbcTypeName", null, 0, 1, XmlStoredProcedureParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlNamedStoredProcedureQueryEClass, XmlNamedStoredProcedureQuery.class, "XmlNamedStoredProcedureQuery", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlNamedStoredProcedureQuery_Name(), theXMLTypePackage.getString(), "name", null, 0, 1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlNamedStoredProcedureQuery_ResultClass(), theXMLTypePackage.getString(), "resultClass", null, 0, 1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlNamedStoredProcedureQuery_ResultSetMapping(), theXMLTypePackage.getString(), "resultSetMapping", null, 0, 1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlNamedStoredProcedureQuery_ProcedureName(), theXMLTypePackage.getString(), "procedureName", null, 0, 1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlNamedStoredProcedureQuery_ReturnsResultSet(), theXMLTypePackage.getBooleanObject(), "returnsResultSet", null, 0, 1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlNamedStoredProcedureQuery_Hints(), theOrmPackage.getXmlQueryHint(), null, "hints", null, 0, -1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlNamedStoredProcedureQuery_Parameters(), this.getXmlStoredProcedureParameter(), null, "parameters", null, 0, -1, XmlNamedStoredProcedureQuery.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlEntityMappingsEClass, XmlEntityMappings.class, "XmlEntityMappings", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlEntityMappings_NamedStoredProcedureQueries(), this.getXmlNamedStoredProcedureQuery(), null, "namedStoredProcedureQueries", null, 0, -1, XmlEntityMappings.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlPersistenceUnitMetadataEClass, XmlPersistenceUnitMetadata.class, "XmlPersistenceUnitMetadata", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlPersistenceUnitMetadata_ExcludeDefaultMappings(), theXMLTypePackage.getBoolean(), "excludeDefaultMappings", null, 0, 1, XmlPersistenceUnitMetadata.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlCustomizerEClass, XmlCustomizer.class, "XmlCustomizer", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlCustomizer_CustomizerClassName(), ecorePackage.getEString(), "customizerClassName", null, 0, 1, XmlCustomizer.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlCustomizerHolderEClass, XmlCustomizerHolder.class, "XmlCustomizerHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlCustomizerHolder_Customizer(), this.getXmlCustomizer(), null, "customizer", null, 0, 1, XmlCustomizerHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlChangeTrackingEClass, XmlChangeTracking.class, "XmlChangeTracking", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlChangeTracking_Type(), this.getXmlChangeTrackingType(), "type", null, 0, 1, XmlChangeTracking.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlChangeTrackingHolderEClass, XmlChangeTrackingHolder.class, "XmlChangeTrackingHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlChangeTrackingHolder_ChangeTracking(), this.getXmlChangeTracking(), null, "changeTracking", null, 0, 1, XmlChangeTrackingHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlCopyPolicyEClass, XmlCopyPolicy.class, "XmlCopyPolicy", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlCopyPolicy_Class(), theXMLTypePackage.getString(), "class", null, 0, 1, XmlCopyPolicy.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlInstantiationPolicyEClass, XmlInstantiationPolicy.class, "XmlInstantiationPolicy", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlCloneCopyPolicyEClass, XmlCloneCopyPolicy.class, "XmlCloneCopyPolicy", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlCloneCopyPolicy_Method(), theXMLTypePackage.getString(), "method", null, 0, 1, XmlCloneCopyPolicy.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCloneCopyPolicy_WorkingCopyMethod(), theXMLTypePackage.getString(), "workingCopyMethod", null, 0, 1, XmlCloneCopyPolicy.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlEmbeddableEClass, XmlEmbeddable.class, "XmlEmbeddable", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlEmbeddable_CopyPolicy(), this.getXmlCopyPolicy(), null, "copyPolicy", null, 0, 1, XmlEmbeddable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEmbeddable_InstantiationCopyPolicy(), this.getXmlCopyPolicy(), null, "instantiationCopyPolicy", null, 0, 1, XmlEmbeddable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEmbeddable_CloneCopyPolicy(), this.getXmlCopyPolicy(), null, "cloneCopyPolicy", null, 0, 1, XmlEmbeddable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEmbeddable_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlEmbeddable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlEmbeddable_ExcludeDefaultMappings(), theXMLTypePackage.getBooleanObject(), "excludeDefaultMappings", null, 0, 1, XmlEmbeddable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlReadOnlyEClass, XmlReadOnly.class, "XmlReadOnly", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlReadOnly_ReadOnly(), theXMLTypePackage.getBooleanObject(), "readOnly", null, 0, 1, XmlReadOnly.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlTimeOfDayEClass, XmlTimeOfDay.class, "XmlTimeOfDay", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlTimeOfDay_Hour(), theXMLTypePackage.getIntObject(), "hour", null, 0, 1, XmlTimeOfDay.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlTimeOfDay_Minute(), theXMLTypePackage.getIntObject(), "minute", null, 0, 1, XmlTimeOfDay.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlTimeOfDay_Second(), theXMLTypePackage.getIntObject(), "second", null, 0, 1, XmlTimeOfDay.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlTimeOfDay_Millisecond(), theXMLTypePackage.getIntObject(), "millisecond", null, 0, 1, XmlTimeOfDay.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlCacheEClass, XmlCache.class, "XmlCache", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlCache_Expiry(), theXMLTypePackage.getIntObject(), "expiry", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_Size(), theXMLTypePackage.getIntObject(), "size", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_Shared(), theXMLTypePackage.getBooleanObject(), "shared", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_Type(), this.getCacheType(), "type", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_AlwaysRefresh(), theXMLTypePackage.getBooleanObject(), "alwaysRefresh", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_RefreshOnlyIfNewer(), theXMLTypePackage.getBooleanObject(), "refreshOnlyIfNewer", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_DisableHits(), theXMLTypePackage.getBooleanObject(), "disableHits", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCache_CoordinationType(), this.getCacheCoordinationType(), "coordinationType", "", 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlCache_ExpiryTimeOfDay(), this.getXmlTimeOfDay(), null, "expiryTimeOfDay", null, 0, 1, XmlCache.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlCacheHolderEClass, XmlCacheHolder.class, "XmlCacheHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlCacheHolder_Cache(), this.getXmlCache(), null, "cache", null, 0, 1, XmlCacheHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlCacheHolder_ExistenceChecking(), this.getExistenceType(), "existenceChecking", "", 0, 1, XmlCacheHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlOptimisticLockingEClass, XmlOptimisticLocking.class, "XmlOptimisticLocking", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlOptimisticLocking_Type(), this.getXmlOptimisticLockingType(), "type", null, 0, 1, XmlOptimisticLocking.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlOptimisticLocking_Cascade(), theXMLTypePackage.getBooleanObject(), "cascade", null, 0, 1, XmlOptimisticLocking.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlOptimisticLocking_SelectedColumns(), theOrmPackage.getXmlColumn(), null, "selectedColumns", null, 0, -1, XmlOptimisticLocking.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlEntityEClass, XmlEntity.class, "XmlEntity", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlEntity_OptimisticLocking(), this.getXmlOptimisticLocking(), null, "optimisticLocking", null, 0, 1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEntity_CopyPolicy(), this.getXmlCopyPolicy(), null, "copyPolicy", null, 0, 1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEntity_InstantiationCopyPolicy(), this.getXmlCopyPolicy(), null, "instantiationCopyPolicy", null, 0, 1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEntity_CloneCopyPolicy(), this.getXmlCopyPolicy(), null, "cloneCopyPolicy", null, 0, 1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEntity_NamedStoredProcedureQueries(), this.getXmlNamedStoredProcedureQuery(), null, "namedStoredProcedureQueries", null, 0, -1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlEntity_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlEntity_ExcludeDefaultMappings(), theXMLTypePackage.getBooleanObject(), "excludeDefaultMappings", null, 0, 1, XmlEntity.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlMappedSuperclassEClass, XmlMappedSuperclass.class, "XmlMappedSuperclass", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlMappedSuperclass_OptimisticLocking(), this.getXmlOptimisticLocking(), null, "optimisticLocking", null, 0, 1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlMappedSuperclass_CopyPolicy(), this.getXmlCopyPolicy(), null, "copyPolicy", null, 0, 1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlMappedSuperclass_InstantiationCopyPolicy(), this.getXmlCopyPolicy(), null, "instantiationCopyPolicy", null, 0, 1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlMappedSuperclass_CloneCopyPolicy(), this.getXmlCopyPolicy(), null, "cloneCopyPolicy", null, 0, 1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlMappedSuperclass_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlMappedSuperclass_ExcludeDefaultMappings(), theXMLTypePackage.getBooleanObject(), "excludeDefaultMappings", null, 0, 1, XmlMappedSuperclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlMutableEClass, XmlMutable.class, "XmlMutable", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlMutable_Mutable(), theXMLTypePackage.getBooleanObject(), "mutable", null, 0, 1, XmlMutable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlConverterHolderEClass, XmlConverterHolder.class, "XmlConverterHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlConverterHolder_Converter(), this.getXmlConverter(), null, "converter", null, 0, 1, XmlConverterHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConverterHolder_TypeConverter(), this.getXmlTypeConverter(), null, "typeConverter", null, 0, 1, XmlConverterHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConverterHolder_ObjectTypeConverter(), this.getXmlObjectTypeConverter(), null, "objectTypeConverter", null, 0, 1, XmlConverterHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getXmlConverterHolder_StructConverter(), this.getXmlStructConverter(), null, "structConverter", null, 0, 1, XmlConverterHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlConvertibleMappingEClass, XmlConvertibleMapping.class, "XmlConvertibleMapping", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlConvertibleMapping_Convert(), ecorePackage.getEString(), "convert", null, 0, 1, XmlConvertibleMapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlAccessMethodsEClass, XmlAccessMethods.class, "XmlAccessMethods", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlAccessMethods_GetMethod(), theXMLTypePackage.getString(), "getMethod", null, 0, 1, XmlAccessMethods.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlAccessMethods_SetMethod(), theXMLTypePackage.getString(), "setMethod", null, 0, 1, XmlAccessMethods.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlAccessMethodsHolderEClass, XmlAccessMethodsHolder.class, "XmlAccessMethodsHolder", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlAccessMethodsHolder_AccessMethods(), this.getXmlAccessMethods(), null, "accessMethods", null, 0, 1, XmlAccessMethodsHolder.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlPropertyEClass, XmlProperty.class, "XmlProperty", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlProperty_Name(), theXMLTypePackage.getString(), "name", null, 0, 1, XmlProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlProperty_Value(), theXMLTypePackage.getString(), "value", null, 0, 1, XmlProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getXmlProperty_ValueType(), theXMLTypePackage.getString(), "valueType", null, 0, 1, XmlProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlIdEClass, XmlId.class, "XmlId", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlId_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlId.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlIdImplEClass, XmlIdImpl.class, "XmlIdImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlEmbeddedIdEClass, XmlEmbeddedId.class, "XmlEmbeddedId", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlEmbeddedId_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlEmbeddedId.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlEmbeddedIdImplEClass, XmlEmbeddedIdImpl.class, "XmlEmbeddedIdImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlEmbeddedEClass, XmlEmbedded.class, "XmlEmbedded", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlEmbedded_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlEmbedded.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlEmbeddedImplEClass, XmlEmbeddedImpl.class, "XmlEmbeddedImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlBasicEClass, XmlBasic.class, "XmlBasic", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlBasic_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlBasic.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlBasicImplEClass, XmlBasicImpl.class, "XmlBasicImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlVersionEClass, XmlVersion.class, "XmlVersion", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlVersion_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlVersion.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlVersionImplEClass, XmlVersionImpl.class, "XmlVersionImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlPrivateOwnedEClass, XmlPrivateOwned.class, "XmlPrivateOwned", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlPrivateOwned_PrivateOwned(), theXMLTypePackage.getBoolean(), "privateOwned", null, 0, 1, XmlPrivateOwned.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlJoinFetchEClass, XmlJoinFetch.class, "XmlJoinFetch", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEAttribute(getXmlJoinFetch_JoinFetch(), this.getXmlJoinFetchType(), "joinFetch", null, 0, 1, XmlJoinFetch.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlOneToOneEClass, XmlOneToOne.class, "XmlOneToOne", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlOneToOne_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlOneToOne.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlOneToOneImplEClass, XmlOneToOneImpl.class, "XmlOneToOneImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlOneToManyEClass, XmlOneToMany.class, "XmlOneToMany", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlOneToMany_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlOneToMany.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlOneToManyImplEClass, XmlOneToManyImpl.class, "XmlOneToManyImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlManyToOneEClass, XmlManyToOne.class, "XmlManyToOne", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlManyToOne_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlManyToOne.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlManyToOneImplEClass, XmlManyToOneImpl.class, "XmlManyToOneImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlManyToManyEClass, XmlManyToMany.class, "XmlManyToMany", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlManyToMany_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlManyToMany.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlManyToManyImplEClass, XmlManyToManyImpl.class, "XmlManyToManyImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlBasicCollectionEClass, XmlBasicCollection.class, "XmlBasicCollection", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlBasicCollection_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlBasicCollection.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlBasicCollectionImplEClass, XmlBasicCollectionImpl.class, "XmlBasicCollectionImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlBasicMapEClass, XmlBasicMap.class, "XmlBasicMap", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlBasicMap_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlBasicMap.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlBasicMapImplEClass, XmlBasicMapImpl.class, "XmlBasicMapImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlTransformationEClass, XmlTransformation.class, "XmlTransformation", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlTransformation_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlTransformation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlTransformationImplEClass, XmlTransformationImpl.class, "XmlTransformationImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(xmlVariableOneToOneEClass, XmlVariableOneToOne.class, "XmlVariableOneToOne", IS_ABSTRACT, IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getXmlVariableOneToOne_Properties(), this.getXmlProperty(), null, "properties", null, 0, -1, XmlVariableOneToOne.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(xmlVariableOneToOneImplEClass, XmlVariableOneToOneImpl.class, "XmlVariableOneToOneImpl", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(attributesEClass, Attributes.class, "Attributes", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getAttributes_BasicCollections(), this.getXmlBasicCollection(), null, "basicCollections", null, 0, -1, Attributes.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAttributes_BasicMaps(), this.getXmlBasicMap(), null, "basicMaps", null, 0, -1, Attributes.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAttributes_Transformations(), this.getXmlTransformation(), null, "transformations", null, 0, -1, Attributes.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getAttributes_VariableOneToOnes(), this.getXmlVariableOneToOne(), null, "variableOneToOnes", null, 0, -1, Attributes.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - // Initialize enums and add enum literals - initEEnum(xmlDirectionEEnum, XmlDirection.class, "XmlDirection"); - addEEnumLiteral(xmlDirectionEEnum, XmlDirection.IN); - addEEnumLiteral(xmlDirectionEEnum, XmlDirection.OUT); - addEEnumLiteral(xmlDirectionEEnum, XmlDirection.IN_OUT); - addEEnumLiteral(xmlDirectionEEnum, XmlDirection.OUT_CURSOR); - - initEEnum(xmlChangeTrackingTypeEEnum, XmlChangeTrackingType.class, "XmlChangeTrackingType"); - addEEnumLiteral(xmlChangeTrackingTypeEEnum, XmlChangeTrackingType.ATTRIBUTE); - addEEnumLiteral(xmlChangeTrackingTypeEEnum, XmlChangeTrackingType.OBJECT); - addEEnumLiteral(xmlChangeTrackingTypeEEnum, XmlChangeTrackingType.DEFERRED); - addEEnumLiteral(xmlChangeTrackingTypeEEnum, XmlChangeTrackingType.AUTO); - - initEEnum(cacheTypeEEnum, CacheType.class, "CacheType"); - addEEnumLiteral(cacheTypeEEnum, CacheType.FULL); - addEEnumLiteral(cacheTypeEEnum, CacheType.WEAK); - addEEnumLiteral(cacheTypeEEnum, CacheType.SOFT); - addEEnumLiteral(cacheTypeEEnum, CacheType.SOFT_WEAK); - addEEnumLiteral(cacheTypeEEnum, CacheType.HARD_WEAK); - addEEnumLiteral(cacheTypeEEnum, CacheType.CACHE); - addEEnumLiteral(cacheTypeEEnum, CacheType.NONE); - - initEEnum(cacheCoordinationTypeEEnum, CacheCoordinationType.class, "CacheCoordinationType"); - addEEnumLiteral(cacheCoordinationTypeEEnum, CacheCoordinationType.SEND_OBJECT_CHANGES); - addEEnumLiteral(cacheCoordinationTypeEEnum, CacheCoordinationType.INVALIDATE_CHANGED_OBJECTS); - addEEnumLiteral(cacheCoordinationTypeEEnum, CacheCoordinationType.SEND_NEW_OBJECTS_WITH_CHANGES); - addEEnumLiteral(cacheCoordinationTypeEEnum, CacheCoordinationType.NONE); - - initEEnum(existenceTypeEEnum, ExistenceType.class, "ExistenceType"); - addEEnumLiteral(existenceTypeEEnum, ExistenceType.CHECK_CACHE); - addEEnumLiteral(existenceTypeEEnum, ExistenceType.CHECK_DATABASE); - addEEnumLiteral(existenceTypeEEnum, ExistenceType.ASSUME_EXISTENCE); - addEEnumLiteral(existenceTypeEEnum, ExistenceType.ASSUME_NON_EXISTENCE); - - initEEnum(xmlOptimisticLockingTypeEEnum, XmlOptimisticLockingType.class, "XmlOptimisticLockingType"); - addEEnumLiteral(xmlOptimisticLockingTypeEEnum, XmlOptimisticLockingType.ALL_COLUMNS); - addEEnumLiteral(xmlOptimisticLockingTypeEEnum, XmlOptimisticLockingType.CHANGED_COLUMNS); - addEEnumLiteral(xmlOptimisticLockingTypeEEnum, XmlOptimisticLockingType.SELECTED_COLUMNS); - addEEnumLiteral(xmlOptimisticLockingTypeEEnum, XmlOptimisticLockingType.VERSION_COLUMN); - - initEEnum(xmlJoinFetchTypeEEnum, XmlJoinFetchType.class, "XmlJoinFetchType"); - addEEnumLiteral(xmlJoinFetchTypeEEnum, XmlJoinFetchType.INNER); - addEEnumLiteral(xmlJoinFetchTypeEEnum, XmlJoinFetchType.OUTER); - - // Create resource - createResource(eNS_URI); - } - - /** - * <!-- begin-user-doc --> - * Defines literals for the meta objects that represent - * <ul> - * <li>each class,</li> - * <li>each feature of each class,</li> - * <li>each enum,</li> - * <li>and each data type</li> - * </ul> - * <!-- end-user-doc --> - * @generated - */ - public interface Literals - { - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter <em>Xml Named Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter() - * @generated - */ - public static final EClass XML_NAMED_CONVERTER = eINSTANCE.getXmlNamedConverter(); - - /** - * The meta object literal for the '<em><b>Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_CONVERTER__NAME = eINSTANCE.getXmlNamedConverter_Name(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer <em>Xml Customizer</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizer() - * @generated - */ - public static final EClass XML_CUSTOMIZER = eINSTANCE.getXmlCustomizer(); - - /** - * The meta object literal for the '<em><b>Customizer Class Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME = eINSTANCE.getXmlCustomizer_CustomizerClassName(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder <em>Xml Customizer Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder() - * @generated - */ - public static final EClass XML_CUSTOMIZER_HOLDER = eINSTANCE.getXmlCustomizerHolder(); - - /** - * The meta object literal for the '<em><b>Customizer</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CUSTOMIZER_HOLDER__CUSTOMIZER = eINSTANCE.getXmlCustomizerHolder_Customizer(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking <em>Xml Change Tracking</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTracking() - * @generated - */ - public static final EClass XML_CHANGE_TRACKING = eINSTANCE.getXmlChangeTracking(); - - /** - * The meta object literal for the '<em><b>Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CHANGE_TRACKING__TYPE = eINSTANCE.getXmlChangeTracking_Type(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder <em>Xml Change Tracking Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder() - * @generated - */ - public static final EClass XML_CHANGE_TRACKING_HOLDER = eINSTANCE.getXmlChangeTrackingHolder(); - - /** - * The meta object literal for the '<em><b>Change Tracking</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING = eINSTANCE.getXmlChangeTrackingHolder_ChangeTracking(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy <em>Xml Copy Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCopyPolicy() - * @generated - */ - public static final EClass XML_COPY_POLICY = eINSTANCE.getXmlCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Class</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_COPY_POLICY__CLASS = eINSTANCE.getXmlCopyPolicy_Class(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy <em>Xml Instantiation Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlInstantiationPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlInstantiationPolicy() - * @generated - */ - public static final EClass XML_INSTANTIATION_POLICY = eINSTANCE.getXmlInstantiationPolicy(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy <em>Xml Clone Copy Policy</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCloneCopyPolicy() - * @generated - */ - public static final EClass XML_CLONE_COPY_POLICY = eINSTANCE.getXmlCloneCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Method</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CLONE_COPY_POLICY__METHOD = eINSTANCE.getXmlCloneCopyPolicy_Method(); - - /** - * The meta object literal for the '<em><b>Working Copy Method</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD = eINSTANCE.getXmlCloneCopyPolicy_WorkingCopyMethod(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder <em>Xml Converters Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder() - * @generated - */ - public static final EClass XML_CONVERTERS_HOLDER = eINSTANCE.getXmlConvertersHolder(); - - /** - * The meta object literal for the '<em><b>Converters</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTERS_HOLDER__CONVERTERS = eINSTANCE.getXmlConvertersHolder_Converters(); - - /** - * The meta object literal for the '<em><b>Type Converters</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTERS_HOLDER__TYPE_CONVERTERS = eINSTANCE.getXmlConvertersHolder_TypeConverters(); - - /** - * The meta object literal for the '<em><b>Object Type Converters</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS = eINSTANCE.getXmlConvertersHolder_ObjectTypeConverters(); - - /** - * The meta object literal for the '<em><b>Struct Converters</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS = eINSTANCE.getXmlConvertersHolder_StructConverters(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter <em>Xml Stored Procedure Parameter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter() - * @generated - */ - public static final EClass XML_STORED_PROCEDURE_PARAMETER = eINSTANCE.getXmlStoredProcedureParameter(); - - /** - * The meta object literal for the '<em><b>Direction</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__DIRECTION = eINSTANCE.getXmlStoredProcedureParameter_Direction(); - - /** - * The meta object literal for the '<em><b>Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__NAME = eINSTANCE.getXmlStoredProcedureParameter_Name(); - - /** - * The meta object literal for the '<em><b>Query Parameter</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER = eINSTANCE.getXmlStoredProcedureParameter_QueryParameter(); - - /** - * The meta object literal for the '<em><b>Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__TYPE = eINSTANCE.getXmlStoredProcedureParameter_Type(); - - /** - * The meta object literal for the '<em><b>Jdbc Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE = eINSTANCE.getXmlStoredProcedureParameter_JdbcType(); - - /** - * The meta object literal for the '<em><b>Jdbc Type Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME = eINSTANCE.getXmlStoredProcedureParameter_JdbcTypeName(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery <em>Xml Named Stored Procedure Query</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery() - * @generated - */ - public static final EClass XML_NAMED_STORED_PROCEDURE_QUERY = eINSTANCE.getXmlNamedStoredProcedureQuery(); - - /** - * The meta object literal for the '<em><b>Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_STORED_PROCEDURE_QUERY__NAME = eINSTANCE.getXmlNamedStoredProcedureQuery_Name(); - - /** - * The meta object literal for the '<em><b>Result Class</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS = eINSTANCE.getXmlNamedStoredProcedureQuery_ResultClass(); - - /** - * The meta object literal for the '<em><b>Result Set Mapping</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING = eINSTANCE.getXmlNamedStoredProcedureQuery_ResultSetMapping(); - - /** - * The meta object literal for the '<em><b>Procedure Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME = eINSTANCE.getXmlNamedStoredProcedureQuery_ProcedureName(); - - /** - * The meta object literal for the '<em><b>Returns Result Set</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET = eINSTANCE.getXmlNamedStoredProcedureQuery_ReturnsResultSet(); - - /** - * The meta object literal for the '<em><b>Hints</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_NAMED_STORED_PROCEDURE_QUERY__HINTS = eINSTANCE.getXmlNamedStoredProcedureQuery_Hints(); - - /** - * The meta object literal for the '<em><b>Parameters</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS = eINSTANCE.getXmlNamedStoredProcedureQuery_Parameters(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings <em>Xml Entity Mappings</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntityMappings() - * @generated - */ - public static final EClass XML_ENTITY_MAPPINGS = eINSTANCE.getXmlEntityMappings(); - - /** - * The meta object literal for the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES = eINSTANCE.getXmlEntityMappings_NamedStoredProcedureQueries(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata <em>Xml Persistence Unit Metadata</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPersistenceUnitMetadata() - * @generated - */ - public static final EClass XML_PERSISTENCE_UNIT_METADATA = eINSTANCE.getXmlPersistenceUnitMetadata(); - - /** - * The meta object literal for the '<em><b>Exclude Default Mappings</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS = eINSTANCE.getXmlPersistenceUnitMetadata_ExcludeDefaultMappings(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable <em>Xml Embeddable</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable() - * @generated - */ - public static final EClass XML_EMBEDDABLE = eINSTANCE.getXmlEmbeddable(); - - /** - * The meta object literal for the '<em><b>Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDABLE__COPY_POLICY = eINSTANCE.getXmlEmbeddable_CopyPolicy(); - - /** - * The meta object literal for the '<em><b>Instantiation Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY = eINSTANCE.getXmlEmbeddable_InstantiationCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Clone Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDABLE__CLONE_COPY_POLICY = eINSTANCE.getXmlEmbeddable_CloneCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDABLE__PROPERTIES = eINSTANCE.getXmlEmbeddable_Properties(); - - /** - * The meta object literal for the '<em><b>Exclude Default Mappings</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS = eINSTANCE.getXmlEmbeddable_ExcludeDefaultMappings(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly <em>Xml Read Only</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly() - * @generated - */ - public static final EClass XML_READ_ONLY = eINSTANCE.getXmlReadOnly(); - - /** - * The meta object literal for the '<em><b>Read Only</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_READ_ONLY__READ_ONLY = eINSTANCE.getXmlReadOnly_ReadOnly(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay <em>Xml Time Of Day</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay() - * @generated - */ - public static final EClass XML_TIME_OF_DAY = eINSTANCE.getXmlTimeOfDay(); - - /** - * The meta object literal for the '<em><b>Hour</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TIME_OF_DAY__HOUR = eINSTANCE.getXmlTimeOfDay_Hour(); - - /** - * The meta object literal for the '<em><b>Minute</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TIME_OF_DAY__MINUTE = eINSTANCE.getXmlTimeOfDay_Minute(); - - /** - * The meta object literal for the '<em><b>Second</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TIME_OF_DAY__SECOND = eINSTANCE.getXmlTimeOfDay_Second(); - - /** - * The meta object literal for the '<em><b>Millisecond</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TIME_OF_DAY__MILLISECOND = eINSTANCE.getXmlTimeOfDay_Millisecond(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache <em>Xml Cache</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache() - * @generated - */ - public static final EClass XML_CACHE = eINSTANCE.getXmlCache(); - - /** - * The meta object literal for the '<em><b>Expiry</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__EXPIRY = eINSTANCE.getXmlCache_Expiry(); - - /** - * The meta object literal for the '<em><b>Size</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__SIZE = eINSTANCE.getXmlCache_Size(); - - /** - * The meta object literal for the '<em><b>Shared</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__SHARED = eINSTANCE.getXmlCache_Shared(); - - /** - * The meta object literal for the '<em><b>Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__TYPE = eINSTANCE.getXmlCache_Type(); - - /** - * The meta object literal for the '<em><b>Always Refresh</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__ALWAYS_REFRESH = eINSTANCE.getXmlCache_AlwaysRefresh(); - - /** - * The meta object literal for the '<em><b>Refresh Only If Newer</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__REFRESH_ONLY_IF_NEWER = eINSTANCE.getXmlCache_RefreshOnlyIfNewer(); - - /** - * The meta object literal for the '<em><b>Disable Hits</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__DISABLE_HITS = eINSTANCE.getXmlCache_DisableHits(); - - /** - * The meta object literal for the '<em><b>Coordination Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE__COORDINATION_TYPE = eINSTANCE.getXmlCache_CoordinationType(); - - /** - * The meta object literal for the '<em><b>Expiry Time Of Day</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CACHE__EXPIRY_TIME_OF_DAY = eINSTANCE.getXmlCache_ExpiryTimeOfDay(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder <em>Xml Cache Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder() - * @generated - */ - public static final EClass XML_CACHE_HOLDER = eINSTANCE.getXmlCacheHolder(); - - /** - * The meta object literal for the '<em><b>Cache</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CACHE_HOLDER__CACHE = eINSTANCE.getXmlCacheHolder_Cache(); - - /** - * The meta object literal for the '<em><b>Existence Checking</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CACHE_HOLDER__EXISTENCE_CHECKING = eINSTANCE.getXmlCacheHolder_ExistenceChecking(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking <em>Xml Optimistic Locking</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking() - * @generated - */ - public static final EClass XML_OPTIMISTIC_LOCKING = eINSTANCE.getXmlOptimisticLocking(); - - /** - * The meta object literal for the '<em><b>Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_OPTIMISTIC_LOCKING__TYPE = eINSTANCE.getXmlOptimisticLocking_Type(); - - /** - * The meta object literal for the '<em><b>Cascade</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_OPTIMISTIC_LOCKING__CASCADE = eINSTANCE.getXmlOptimisticLocking_Cascade(); - - /** - * The meta object literal for the '<em><b>Selected Columns</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS = eINSTANCE.getXmlOptimisticLocking_SelectedColumns(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity <em>Xml Entity</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity() - * @generated - */ - public static final EClass XML_ENTITY = eINSTANCE.getXmlEntity(); - - /** - * The meta object literal for the '<em><b>Optimistic Locking</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__OPTIMISTIC_LOCKING = eINSTANCE.getXmlEntity_OptimisticLocking(); - - /** - * The meta object literal for the '<em><b>Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__COPY_POLICY = eINSTANCE.getXmlEntity_CopyPolicy(); - - /** - * The meta object literal for the '<em><b>Instantiation Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__INSTANTIATION_COPY_POLICY = eINSTANCE.getXmlEntity_InstantiationCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Clone Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__CLONE_COPY_POLICY = eINSTANCE.getXmlEntity_CloneCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES = eINSTANCE.getXmlEntity_NamedStoredProcedureQueries(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ENTITY__PROPERTIES = eINSTANCE.getXmlEntity_Properties(); - - /** - * The meta object literal for the '<em><b>Exclude Default Mappings</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS = eINSTANCE.getXmlEntity_ExcludeDefaultMappings(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass <em>Xml Mapped Superclass</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass() - * @generated - */ - public static final EClass XML_MAPPED_SUPERCLASS = eINSTANCE.getXmlMappedSuperclass(); - - /** - * The meta object literal for the '<em><b>Optimistic Locking</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING = eINSTANCE.getXmlMappedSuperclass_OptimisticLocking(); - - /** - * The meta object literal for the '<em><b>Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MAPPED_SUPERCLASS__COPY_POLICY = eINSTANCE.getXmlMappedSuperclass_CopyPolicy(); - - /** - * The meta object literal for the '<em><b>Instantiation Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY = eINSTANCE.getXmlMappedSuperclass_InstantiationCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Clone Copy Policy</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY = eINSTANCE.getXmlMappedSuperclass_CloneCopyPolicy(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MAPPED_SUPERCLASS__PROPERTIES = eINSTANCE.getXmlMappedSuperclass_Properties(); - - /** - * The meta object literal for the '<em><b>Exclude Default Mappings</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS = eINSTANCE.getXmlMappedSuperclass_ExcludeDefaultMappings(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable <em>Xml Mutable</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable() - * @generated - */ - public static final EClass XML_MUTABLE = eINSTANCE.getXmlMutable(); - - /** - * The meta object literal for the '<em><b>Mutable</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_MUTABLE__MUTABLE = eINSTANCE.getXmlMutable_Mutable(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping <em>Xml Convertible Mapping</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping() - * @generated - */ - public static final EClass XML_CONVERTIBLE_MAPPING = eINSTANCE.getXmlConvertibleMapping(); - - /** - * The meta object literal for the '<em><b>Convert</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CONVERTIBLE_MAPPING__CONVERT = eINSTANCE.getXmlConvertibleMapping_Convert(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods <em>Xml Access Methods</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethods() - * @generated - */ - public static final EClass XML_ACCESS_METHODS = eINSTANCE.getXmlAccessMethods(); - - /** - * The meta object literal for the '<em><b>Get Method</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_ACCESS_METHODS__GET_METHOD = eINSTANCE.getXmlAccessMethods_GetMethod(); - - /** - * The meta object literal for the '<em><b>Set Method</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_ACCESS_METHODS__SET_METHOD = eINSTANCE.getXmlAccessMethods_SetMethod(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder <em>Xml Access Methods Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder() - * @generated - */ - public static final EClass XML_ACCESS_METHODS_HOLDER = eINSTANCE.getXmlAccessMethodsHolder(); - - /** - * The meta object literal for the '<em><b>Access Methods</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS = eINSTANCE.getXmlAccessMethodsHolder_AccessMethods(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlId <em>Xml Id</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlId - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlId() - * @generated - */ - public static final EClass XML_ID = eINSTANCE.getXmlId(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ID__PROPERTIES = eINSTANCE.getXmlId_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl <em>Xml Id Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlIdImpl() - * @generated - */ - public static final EClass XML_ID_IMPL = eINSTANCE.getXmlIdImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId <em>Xml Embedded Id</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedId() - * @generated - */ - public static final EClass XML_EMBEDDED_ID = eINSTANCE.getXmlEmbeddedId(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDED_ID__PROPERTIES = eINSTANCE.getXmlEmbeddedId_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl <em>Xml Embedded Id Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedIdImpl() - * @generated - */ - public static final EClass XML_EMBEDDED_ID_IMPL = eINSTANCE.getXmlEmbeddedIdImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded <em>Xml Embedded</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbedded() - * @generated - */ - public static final EClass XML_EMBEDDED = eINSTANCE.getXmlEmbedded(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_EMBEDDED__PROPERTIES = eINSTANCE.getXmlEmbedded_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl <em>Xml Embedded Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedImpl() - * @generated - */ - public static final EClass XML_EMBEDDED_IMPL = eINSTANCE.getXmlEmbeddedImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic <em>Xml Basic</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasic() - * @generated - */ - public static final EClass XML_BASIC = eINSTANCE.getXmlBasic(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_BASIC__PROPERTIES = eINSTANCE.getXmlBasic_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl <em>Xml Basic Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicImpl() - * @generated - */ - public static final EClass XML_BASIC_IMPL = eINSTANCE.getXmlBasicImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion <em>Xml Version</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersion() - * @generated - */ - public static final EClass XML_VERSION = eINSTANCE.getXmlVersion(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_VERSION__PROPERTIES = eINSTANCE.getXmlVersion_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl <em>Xml Version Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersionImpl() - * @generated - */ - public static final EClass XML_VERSION_IMPL = eINSTANCE.getXmlVersionImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned <em>Xml Private Owned</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned() - * @generated - */ - public static final EClass XML_PRIVATE_OWNED = eINSTANCE.getXmlPrivateOwned(); - - /** - * The meta object literal for the '<em><b>Private Owned</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_PRIVATE_OWNED__PRIVATE_OWNED = eINSTANCE.getXmlPrivateOwned_PrivateOwned(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch <em>Xml Join Fetch</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch() - * @generated - */ - public static final EClass XML_JOIN_FETCH = eINSTANCE.getXmlJoinFetch(); - - /** - * The meta object literal for the '<em><b>Join Fetch</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_JOIN_FETCH__JOIN_FETCH = eINSTANCE.getXmlJoinFetch_JoinFetch(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne <em>Xml One To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOne() - * @generated - */ - public static final EClass XML_ONE_TO_ONE = eINSTANCE.getXmlOneToOne(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ONE_TO_ONE__PROPERTIES = eINSTANCE.getXmlOneToOne_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl <em>Xml One To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOneImpl() - * @generated - */ - public static final EClass XML_ONE_TO_ONE_IMPL = eINSTANCE.getXmlOneToOneImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany <em>Xml One To Many</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToMany() - * @generated - */ - public static final EClass XML_ONE_TO_MANY = eINSTANCE.getXmlOneToMany(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_ONE_TO_MANY__PROPERTIES = eINSTANCE.getXmlOneToMany_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl <em>Xml One To Many Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToManyImpl() - * @generated - */ - public static final EClass XML_ONE_TO_MANY_IMPL = eINSTANCE.getXmlOneToManyImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne <em>Xml Many To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOne() - * @generated - */ - public static final EClass XML_MANY_TO_ONE = eINSTANCE.getXmlManyToOne(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MANY_TO_ONE__PROPERTIES = eINSTANCE.getXmlManyToOne_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl <em>Xml Many To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOneImpl() - * @generated - */ - public static final EClass XML_MANY_TO_ONE_IMPL = eINSTANCE.getXmlManyToOneImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany <em>Xml Many To Many</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToMany() - * @generated - */ - public static final EClass XML_MANY_TO_MANY = eINSTANCE.getXmlManyToMany(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_MANY_TO_MANY__PROPERTIES = eINSTANCE.getXmlManyToMany_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl <em>Xml Many To Many Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToManyImpl() - * @generated - */ - public static final EClass XML_MANY_TO_MANY_IMPL = eINSTANCE.getXmlManyToManyImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.Attributes <em>Attributes</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.Attributes - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getAttributes() - * @generated - */ - public static final EClass ATTRIBUTES = eINSTANCE.getAttributes(); - - /** - * The meta object literal for the '<em><b>Basic Collections</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference ATTRIBUTES__BASIC_COLLECTIONS = eINSTANCE.getAttributes_BasicCollections(); - - /** - * The meta object literal for the '<em><b>Basic Maps</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference ATTRIBUTES__BASIC_MAPS = eINSTANCE.getAttributes_BasicMaps(); - - /** - * The meta object literal for the '<em><b>Transformations</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference ATTRIBUTES__TRANSFORMATIONS = eINSTANCE.getAttributes_Transformations(); - - /** - * The meta object literal for the '<em><b>Variable One To Ones</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference ATTRIBUTES__VARIABLE_ONE_TO_ONES = eINSTANCE.getAttributes_VariableOneToOnes(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection <em>Xml Basic Collection</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollection() - * @generated - */ - public static final EClass XML_BASIC_COLLECTION = eINSTANCE.getXmlBasicCollection(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_BASIC_COLLECTION__PROPERTIES = eINSTANCE.getXmlBasicCollection_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl <em>Xml Basic Collection Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollectionImpl() - * @generated - */ - public static final EClass XML_BASIC_COLLECTION_IMPL = eINSTANCE.getXmlBasicCollectionImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap <em>Xml Basic Map</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMap() - * @generated - */ - public static final EClass XML_BASIC_MAP = eINSTANCE.getXmlBasicMap(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_BASIC_MAP__PROPERTIES = eINSTANCE.getXmlBasicMap_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl <em>Xml Basic Map Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMapImpl() - * @generated - */ - public static final EClass XML_BASIC_MAP_IMPL = eINSTANCE.getXmlBasicMapImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation <em>Xml Transformation</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformation() - * @generated - */ - public static final EClass XML_TRANSFORMATION = eINSTANCE.getXmlTransformation(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_TRANSFORMATION__PROPERTIES = eINSTANCE.getXmlTransformation_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl <em>Xml Transformation Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformationImpl() - * @generated - */ - public static final EClass XML_TRANSFORMATION_IMPL = eINSTANCE.getXmlTransformationImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty <em>Xml Property</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty() - * @generated - */ - public static final EClass XML_PROPERTY = eINSTANCE.getXmlProperty(); - - /** - * The meta object literal for the '<em><b>Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_PROPERTY__NAME = eINSTANCE.getXmlProperty_Name(); - - /** - * The meta object literal for the '<em><b>Value</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_PROPERTY__VALUE = eINSTANCE.getXmlProperty_Value(); - - /** - * The meta object literal for the '<em><b>Value Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_PROPERTY__VALUE_TYPE = eINSTANCE.getXmlProperty_ValueType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne <em>Xml Variable One To One</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOne() - * @generated - */ - public static final EClass XML_VARIABLE_ONE_TO_ONE = eINSTANCE.getXmlVariableOneToOne(); - - /** - * The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_VARIABLE_ONE_TO_ONE__PROPERTIES = eINSTANCE.getXmlVariableOneToOne_Properties(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl <em>Xml Variable One To One Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOneImpl() - * @generated - */ - public static final EClass XML_VARIABLE_ONE_TO_ONE_IMPL = eINSTANCE.getXmlVariableOneToOneImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection <em>Xml Direction</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlDirection() - * @generated - */ - public static final EEnum XML_DIRECTION = eINSTANCE.getXmlDirection(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType <em>Xml Change Tracking Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingType() - * @generated - */ - public static final EEnum XML_CHANGE_TRACKING_TYPE = eINSTANCE.getXmlChangeTrackingType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter <em>Xml Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverter() - * @generated - */ - public static final EClass XML_CONVERTER = eINSTANCE.getXmlConverter(); - - /** - * The meta object literal for the '<em><b>Class Name</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CONVERTER__CLASS_NAME = eINSTANCE.getXmlConverter_ClassName(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl <em>Xml Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterImpl() - * @generated - */ - public static final EClass XML_CONVERTER_IMPL = eINSTANCE.getXmlConverterImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter <em>Xml Type Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter() - * @generated - */ - public static final EClass XML_TYPE_CONVERTER = eINSTANCE.getXmlTypeConverter(); - - /** - * The meta object literal for the '<em><b>Data Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TYPE_CONVERTER__DATA_TYPE = eINSTANCE.getXmlTypeConverter_DataType(); - - /** - * The meta object literal for the '<em><b>Object Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_TYPE_CONVERTER__OBJECT_TYPE = eINSTANCE.getXmlTypeConverter_ObjectType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl <em>Xml Type Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverterImpl() - * @generated - */ - public static final EClass XML_TYPE_CONVERTER_IMPL = eINSTANCE.getXmlTypeConverterImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue <em>Xml Conversion Value</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue() - * @generated - */ - public static final EClass XML_CONVERSION_VALUE = eINSTANCE.getXmlConversionValue(); - - /** - * The meta object literal for the '<em><b>Data Value</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CONVERSION_VALUE__DATA_VALUE = eINSTANCE.getXmlConversionValue_DataValue(); - - /** - * The meta object literal for the '<em><b>Object Value</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_CONVERSION_VALUE__OBJECT_VALUE = eINSTANCE.getXmlConversionValue_ObjectValue(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl <em>Xml Conversion Value Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValueImpl() - * @generated - */ - public static final EClass XML_CONVERSION_VALUE_IMPL = eINSTANCE.getXmlConversionValueImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter <em>Xml Object Type Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter() - * @generated - */ - public static final EClass XML_OBJECT_TYPE_CONVERTER = eINSTANCE.getXmlObjectTypeConverter(); - - /** - * The meta object literal for the '<em><b>Data Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_OBJECT_TYPE_CONVERTER__DATA_TYPE = eINSTANCE.getXmlObjectTypeConverter_DataType(); - - /** - * The meta object literal for the '<em><b>Object Type</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_OBJECT_TYPE_CONVERTER__OBJECT_TYPE = eINSTANCE.getXmlObjectTypeConverter_ObjectType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl <em>Xml Object Type Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverterImpl() - * @generated - */ - public static final EClass XML_OBJECT_TYPE_CONVERTER_IMPL = eINSTANCE.getXmlObjectTypeConverterImpl(); - - /** - * The meta object literal for the '<em><b>Conversion Values</b></em>' containment reference list feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_OBJECT_TYPE_CONVERTER__CONVERSION_VALUES = eINSTANCE.getXmlObjectTypeConverter_ConversionValues(); - - /** - * The meta object literal for the '<em><b>Default Object Value</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_OBJECT_TYPE_CONVERTER__DEFAULT_OBJECT_VALUE = eINSTANCE.getXmlObjectTypeConverter_DefaultObjectValue(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter <em>Xml Struct Converter</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverter() - * @generated - */ - public static final EClass XML_STRUCT_CONVERTER = eINSTANCE.getXmlStructConverter(); - - /** - * The meta object literal for the '<em><b>Converter</b></em>' attribute feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EAttribute XML_STRUCT_CONVERTER__CONVERTER = eINSTANCE.getXmlStructConverter_Converter(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl <em>Xml Struct Converter Impl</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverterImpl() - * @generated - */ - public static final EClass XML_STRUCT_CONVERTER_IMPL = eINSTANCE.getXmlStructConverterImpl(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder <em>Xml Converter Holder</em>}' class. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder() - * @generated - */ - public static final EClass XML_CONVERTER_HOLDER = eINSTANCE.getXmlConverterHolder(); - - /** - * The meta object literal for the '<em><b>Converter</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTER_HOLDER__CONVERTER = eINSTANCE.getXmlConverterHolder_Converter(); - - /** - * The meta object literal for the '<em><b>Type Converter</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTER_HOLDER__TYPE_CONVERTER = eINSTANCE.getXmlConverterHolder_TypeConverter(); - - /** - * The meta object literal for the '<em><b>Object Type Converter</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER = eINSTANCE.getXmlConverterHolder_ObjectTypeConverter(); - - /** - * The meta object literal for the '<em><b>Struct Converter</b></em>' containment reference feature. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final EReference XML_CONVERTER_HOLDER__STRUCT_CONVERTER = eINSTANCE.getXmlConverterHolder_StructConverter(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheType <em>Cache Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheType() - * @generated - */ - public static final EEnum CACHE_TYPE = eINSTANCE.getCacheType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType <em>Cache Coordination Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getCacheCoordinationType() - * @generated - */ - public static final EEnum CACHE_COORDINATION_TYPE = eINSTANCE.getCacheCoordinationType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType <em>Xml Join Fetch Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetchType() - * @generated - */ - public static final EEnum XML_JOIN_FETCH_TYPE = eINSTANCE.getXmlJoinFetchType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType <em>Existence Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getExistenceType() - * @generated - */ - public static final EEnum EXISTENCE_TYPE = eINSTANCE.getExistenceType(); - - /** - * The meta object literal for the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType <em>Xml Optimistic Locking Type</em>}' enum. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLockingType() - * @generated - */ - public static final EEnum XML_OPTIMISTIC_LOCKING_TYPE = eINSTANCE.getXmlOptimisticLockingType(); - - } - -} //EclipseLinkOrmPackage diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResource.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResource.java deleted file mode 100644 index 96555b166d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResource.java +++ /dev/null @@ -1,52 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.URI; -import org.eclipse.jpt.core.resource.orm.OrmXmlResource; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkEntityMappingsTranslator; -import org.eclipse.wst.common.internal.emf.resource.Renderer; -import org.eclipse.wst.common.internal.emf.resource.Translator; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public class EclipseLinkOrmXmlResource - extends OrmXmlResource -{ - public static final String TYPE = "eclipselink"; - - public EclipseLinkOrmXmlResource(URI uri, Renderer renderer) { - super(uri, renderer); - } - - @Override - public XmlEntityMappings getEntityMappings() { - return (XmlEntityMappings) super.getEntityMappings(); - } - - @Override - public Translator getRootTranslator() { - return EclipseLinkEntityMappingsTranslator.INSTANCE; - } - - @Override - public String getType() { - return TYPE; - } - -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResourceFactory.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResourceFactory.java deleted file mode 100644 index 41542600d0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/EclipseLinkOrmXmlResourceFactory.java +++ /dev/null @@ -1,50 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.URI; -import org.eclipse.wst.common.internal.emf.resource.Renderer; -import org.eclipse.wst.common.internal.emf.resource.RendererFactory; -import org.eclipse.wst.common.internal.emf.resource.TranslatorResource; -import org.eclipse.wst.common.internal.emf.resource.TranslatorResourceFactory; - -/** - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - */ -public class EclipseLinkOrmXmlResourceFactory extends TranslatorResourceFactory -{ - public EclipseLinkOrmXmlResourceFactory() { - this(RendererFactory.getDefaultRendererFactory()); - } - - public EclipseLinkOrmXmlResourceFactory(RendererFactory aRendererFactory) { - super(aRendererFactory); - } - - public EclipseLinkOrmXmlResourceFactory(RendererFactory aRendererFactory, boolean listeningForUpdates) { - super(aRendererFactory, listeningForUpdates); - } - - - /** - * @see TranslatorResourceFactory#createResource(URI, Renderer) - */ - @Override - protected TranslatorResource createResource(URI uri, Renderer renderer) { - return new EclipseLinkOrmXmlResource(uri, renderer); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/ExistenceType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/ExistenceType.java deleted file mode 100644 index b0ebe4c603..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/ExistenceType.java +++ /dev/null @@ -1,294 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * - * A representation of the literals of the enumeration '<em><b>Existence Type</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getExistenceType() - * @model - * @generated - */ -public enum ExistenceType implements Enumerator -{ - /** - * The '<em><b>CHECK CACHE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #CHECK_CACHE_VALUE - * @generated - * @ordered - */ - CHECK_CACHE(0, "CHECK_CACHE", "CHECK_CACHE"), - - /** - * The '<em><b>CHECK DATABASE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #CHECK_DATABASE_VALUE - * @generated - * @ordered - */ - CHECK_DATABASE(1, "CHECK_DATABASE", "CHECK_DATABASE"), - - /** - * The '<em><b>ASSUME EXISTENCE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #ASSUME_EXISTENCE_VALUE - * @generated - * @ordered - */ - ASSUME_EXISTENCE(2, "ASSUME_EXISTENCE", "ASSUME_EXISTENCE"), - - /** - * The '<em><b>ASSUME NON EXISTENCE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #ASSUME_NON_EXISTENCE_VALUE - * @generated - * @ordered - */ - ASSUME_NON_EXISTENCE(3, "ASSUME_NON_EXISTENCE", "ASSUME_NON_EXISTENCE"); - - /** - * The '<em><b>CHECK CACHE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>CHECK CACHE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #CHECK_CACHE - * @model - * @generated - * @ordered - */ - public static final int CHECK_CACHE_VALUE = 0; - - /** - * The '<em><b>CHECK DATABASE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>CHECK DATABASE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #CHECK_DATABASE - * @model - * @generated - * @ordered - */ - public static final int CHECK_DATABASE_VALUE = 1; - - /** - * The '<em><b>ASSUME EXISTENCE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>ASSUME EXISTENCE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #ASSUME_EXISTENCE - * @model - * @generated - * @ordered - */ - public static final int ASSUME_EXISTENCE_VALUE = 2; - - /** - * The '<em><b>ASSUME NON EXISTENCE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>ASSUME NON EXISTENCE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #ASSUME_NON_EXISTENCE - * @model - * @generated - * @ordered - */ - public static final int ASSUME_NON_EXISTENCE_VALUE = 3; - - /** - * An array of all the '<em><b>Existence Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final ExistenceType[] VALUES_ARRAY = - new ExistenceType[] - { - CHECK_CACHE, - CHECK_DATABASE, - ASSUME_EXISTENCE, - ASSUME_NON_EXISTENCE, - }; - - /** - * A public read-only list of all the '<em><b>Existence Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<ExistenceType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Existence Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static ExistenceType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - ExistenceType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Existence Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static ExistenceType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - ExistenceType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Existence Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static ExistenceType get(int value) - { - switch (value) - { - case CHECK_CACHE_VALUE: return CHECK_CACHE; - case CHECK_DATABASE_VALUE: return CHECK_DATABASE; - case ASSUME_EXISTENCE_VALUE: return ASSUME_EXISTENCE; - case ASSUME_NON_EXISTENCE_VALUE: return ASSUME_NON_EXISTENCE; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private ExistenceType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //ExistenceType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethods.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethods.java deleted file mode 100644 index eeed0f133e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethods.java +++ /dev/null @@ -1,267 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Access Methods</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getGetMethod <em>Get Method</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getSetMethod <em>Set Method</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethods() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlAccessMethods extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getGetMethod() <em>Get Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getGetMethod() - * @generated - * @ordered - */ - protected static final String GET_METHOD_EDEFAULT = null; - - /** - * The cached value of the '{@link #getGetMethod() <em>Get Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getGetMethod() - * @generated - * @ordered - */ - protected String getMethod = GET_METHOD_EDEFAULT; - - /** - * The default value of the '{@link #getSetMethod() <em>Set Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSetMethod() - * @generated - * @ordered - */ - protected static final String SET_METHOD_EDEFAULT = null; - - /** - * The cached value of the '{@link #getSetMethod() <em>Set Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSetMethod() - * @generated - * @ordered - */ - protected String setMethod = SET_METHOD_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlAccessMethods() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ACCESS_METHODS; - } - - /** - * Returns the value of the '<em><b>Get Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Get Method</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Get Method</em>' attribute. - * @see #setGetMethod(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethods_GetMethod() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getGetMethod() - { - return getMethod; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getGetMethod <em>Get Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Get Method</em>' attribute. - * @see #getGetMethod() - * @generated - */ - public void setGetMethod(String newGetMethod) - { - String oldGetMethod = getMethod; - getMethod = newGetMethod; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ACCESS_METHODS__GET_METHOD, oldGetMethod, getMethod)); - } - - /** - * Returns the value of the '<em><b>Set Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Set Method</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Set Method</em>' attribute. - * @see #setSetMethod(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethods_SetMethod() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getSetMethod() - { - return setMethod; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethods#getSetMethod <em>Set Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Set Method</em>' attribute. - * @see #getSetMethod() - * @generated - */ - public void setSetMethod(String newSetMethod) - { - String oldSetMethod = setMethod; - setMethod = newSetMethod; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ACCESS_METHODS__SET_METHOD, oldSetMethod, setMethod)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__GET_METHOD: - return getGetMethod(); - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__SET_METHOD: - return getSetMethod(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__GET_METHOD: - setGetMethod((String)newValue); - return; - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__SET_METHOD: - setSetMethod((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__GET_METHOD: - setGetMethod(GET_METHOD_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__SET_METHOD: - setSetMethod(SET_METHOD_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__GET_METHOD: - return GET_METHOD_EDEFAULT == null ? getMethod != null : !GET_METHOD_EDEFAULT.equals(getMethod); - case EclipseLinkOrmPackage.XML_ACCESS_METHODS__SET_METHOD: - return SET_METHOD_EDEFAULT == null ? setMethod != null : !SET_METHOD_EDEFAULT.equals(setMethod); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (getMethod: "); - result.append(getMethod); - result.append(", setMethod: "); - result.append(setMethod); - result.append(')'); - return result.toString(); - } - -} // XmlAccessMethods diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethodsHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethodsHolder.java deleted file mode 100644 index 336ece9ac2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlAccessMethodsHolder.java +++ /dev/null @@ -1,59 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Access Methods Holder</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder#getAccessMethods <em>Access Methods</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlAccessMethodsHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - XmlAccessMethods getAccessMethods(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlAccessMethodsHolder#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - void setAccessMethods(XmlAccessMethods value); - -} // XmlAccessMethodsHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasic.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasic.java deleted file mode 100644 index 1e63e22682..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasic.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Basic</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasic#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasic() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlBasic extends org.eclipse.jpt.core.resource.orm.XmlBasic, XmlMutable, XmlConvertibleMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasic_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollection.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollection.java deleted file mode 100644 index 87d9736487..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollection.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Basic Collection</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollection#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollection() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlBasicCollection extends XmlAttributeMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollection_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlBasicCollection diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollectionImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollectionImpl.java deleted file mode 100644 index 18512af8ad..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicCollectionImpl.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.orm.AbstractXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Basic Collection Impl</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollectionImpl() - * @model kind="class" - * @generated - */ -public class XmlBasicCollectionImpl extends AbstractXmlAttributeMapping implements XmlBasicCollection -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlBasicCollectionImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_BASIC_COLLECTION_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicCollectionImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicCollection_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasicCollection.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC_COLLECTION__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasicCollection.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_COLLECTION__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC_COLLECTION_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - public String getMappingKey() { - return EclipseLinkMappingKeys.BASIC_COLLECTION_ATTRIBUTE_MAPPING_KEY; - } -} // XmlBasicCollectionImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicImpl.java deleted file mode 100644 index 7e521a9ed0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicImpl.java +++ /dev/null @@ -1,853 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Basic</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicImpl() - * @model kind="class" - * @generated - */ -public class XmlBasicImpl extends org.eclipse.jpt.core.resource.orm.XmlBasicImpl implements XmlBasic -{ - /** - * The default value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected static final Boolean MUTABLE_EDEFAULT = null; - /** - * The cached value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected Boolean mutable = MUTABLE_EDEFAULT; - - /** - * The cached value of the '{@link #getConverter() <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverter() - * @generated - * @ordered - */ - protected XmlConverter converter; - /** - * The cached value of the '{@link #getTypeConverter() <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverter() - * @generated - * @ordered - */ - protected XmlTypeConverter typeConverter; - /** - * The cached value of the '{@link #getObjectTypeConverter() <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverter() - * @generated - * @ordered - */ - protected XmlObjectTypeConverter objectTypeConverter; - /** - * The cached value of the '{@link #getStructConverter() <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverter() - * @generated - * @ordered - */ - protected XmlStructConverter structConverter; - /** - * The default value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected static final String CONVERT_EDEFAULT = null; - /** - * The cached value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected String convert = CONVERT_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlBasicImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_BASIC_IMPL; - } - - /** - * Returns the value of the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Mutable</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Mutable</em>' attribute. - * @see #setMutable(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable_Mutable() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getMutable() - { - return mutable; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getMutable <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Mutable</em>' attribute. - * @see #getMutable() - * @generated - */ - public void setMutable(Boolean newMutable) - { - Boolean oldMutable = mutable; - mutable = newMutable; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE, oldMutable, mutable)); - } - - /** - * Returns the value of the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Convert</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>Convert</em>' attribute. - * @see #setConvert(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping_Convert() - * @model - * @generated - */ - public String getConvert() - { - return convert; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getConvert <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Convert</em>' attribute. - * @see #getConvert() - * @generated - */ - public void setConvert(String newConvert) - { - String oldConvert = convert; - convert = newConvert; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT, oldConvert, convert)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasic_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</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>Converter</em>' containment reference. - * @see #setConverter(XmlConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_Converter() - * @model containment="true" - * @generated - */ - public XmlConverter getConverter() - { - return converter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetConverter(XmlConverter newConverter, NotificationChain msgs) - { - XmlConverter oldConverter = converter; - converter = newConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER, oldConverter, newConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getConverter <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' containment reference. - * @see #getConverter() - * @generated - */ - public void setConverter(XmlConverter newConverter) - { - if (newConverter != converter) - { - NotificationChain msgs = null; - if (converter != null) - msgs = ((InternalEObject)converter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER, null, msgs); - if (newConverter != null) - msgs = ((InternalEObject)newConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER, null, msgs); - msgs = basicSetConverter(newConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER, newConverter, newConverter)); - } - - /** - * Returns the value of the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type CustomConverter</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>Type Converter</em>' containment reference. - * @see #setTypeConverter(XmlTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_TypeConverter() - * @model containment="true" - * @generated - */ - public XmlTypeConverter getTypeConverter() - { - return typeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetTypeConverter(XmlTypeConverter newTypeConverter, NotificationChain msgs) - { - XmlTypeConverter oldTypeConverter = typeConverter; - typeConverter = newTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER, oldTypeConverter, newTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getTypeConverter <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type Converter</em>' containment reference. - * @see #getTypeConverter() - * @generated - */ - public void setTypeConverter(XmlTypeConverter newTypeConverter) - { - if (newTypeConverter != typeConverter) - { - NotificationChain msgs = null; - if (typeConverter != null) - msgs = ((InternalEObject)typeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER, null, msgs); - if (newTypeConverter != null) - msgs = ((InternalEObject)newTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER, null, msgs); - msgs = basicSetTypeConverter(newTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER, newTypeConverter, newTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type CustomConverter</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>Object Type Converter</em>' containment reference. - * @see #setObjectTypeConverter(XmlObjectTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_ObjectTypeConverter() - * @model containment="true" - * @generated - */ - public XmlObjectTypeConverter getObjectTypeConverter() - { - return objectTypeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter, NotificationChain msgs) - { - XmlObjectTypeConverter oldObjectTypeConverter = objectTypeConverter; - objectTypeConverter = newObjectTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER, oldObjectTypeConverter, newObjectTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getObjectTypeConverter <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type Converter</em>' containment reference. - * @see #getObjectTypeConverter() - * @generated - */ - public void setObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter) - { - if (newObjectTypeConverter != objectTypeConverter) - { - NotificationChain msgs = null; - if (objectTypeConverter != null) - msgs = ((InternalEObject)objectTypeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - if (newObjectTypeConverter != null) - msgs = ((InternalEObject)newObjectTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - msgs = basicSetObjectTypeConverter(newObjectTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER, newObjectTypeConverter, newObjectTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct CustomConverter</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>Struct Converter</em>' containment reference. - * @see #setStructConverter(XmlStructConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_StructConverter() - * @model containment="true" - * @generated - */ - public XmlStructConverter getStructConverter() - { - return structConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetStructConverter(XmlStructConverter newStructConverter, NotificationChain msgs) - { - XmlStructConverter oldStructConverter = structConverter; - structConverter = newStructConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER, oldStructConverter, newStructConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicImpl#getStructConverter <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Struct Converter</em>' containment reference. - * @see #getStructConverter() - * @generated - */ - public void setStructConverter(XmlStructConverter newStructConverter) - { - if (newStructConverter != structConverter) - { - NotificationChain msgs = null; - if (structConverter != null) - msgs = ((InternalEObject)structConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER, null, msgs); - if (newStructConverter != null) - msgs = ((InternalEObject)newStructConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER, null, msgs); - msgs = basicSetStructConverter(newStructConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER, newStructConverter, newStructConverter)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: - return basicSetConverter(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: - return basicSetTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: - return basicSetObjectTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: - return basicSetStructConverter(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE: - return getMutable(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: - return getConverter(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: - return getTypeConverter(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: - return getObjectTypeConverter(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: - return getStructConverter(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT: - return getConvert(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE: - setMutable((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: - setConverter((XmlConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT: - setConvert((String)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE: - setMutable(MUTABLE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: - setConverter((XmlConverter)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT: - setConvert(CONVERT_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE: - return MUTABLE_EDEFAULT == null ? mutable != null : !MUTABLE_EDEFAULT.equals(mutable); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: - return converter != null; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: - return typeConverter != null; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: - return objectTypeConverter != null; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: - return structConverter != null; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT: - return CONVERT_EDEFAULT == null ? convert != null : !CONVERT_EDEFAULT.equals(convert); - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlMutable.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE: return EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT: return EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasic.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC__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 == XmlMutable.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE: return EclipseLinkOrmPackage.XML_BASIC_IMPL__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER: return EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_BASIC_IMPL__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_BASIC_IMPL__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_BASIC_IMPL__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT: return EclipseLinkOrmPackage.XML_BASIC_IMPL__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_BASIC_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasic.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC_IMPL__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(" (mutable: "); - result.append(mutable); - result.append(", convert: "); - result.append(convert); - result.append(')'); - return result.toString(); - } - - public TextRange getMutableTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.MUTABLE); - } - - public TextRange getConvertTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.CONVERT); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMap.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMap.java deleted file mode 100644 index 002abd39ec..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMap.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Basic Map</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMap#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMap() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlBasicMap extends XmlAttributeMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMap_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlBasicMap diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMapImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMapImpl.java deleted file mode 100644 index d9ccdf633e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlBasicMapImpl.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.orm.AbstractXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Basic Map Impl</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMapImpl() - * @model kind="class" - * @generated - */ -public class XmlBasicMapImpl extends AbstractXmlAttributeMapping implements XmlBasicMap -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlBasicMapImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_BASIC_MAP_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlBasicMapImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlBasicMap_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasicMap.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC_MAP__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlBasicMap.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_BASIC_MAP__PROPERTIES: return EclipseLinkOrmPackage.XML_BASIC_MAP_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - public String getMappingKey() { - return EclipseLinkMappingKeys.BASIC_MAP_ATTRIBUTE_MAPPING_KEY; - } -} // XmlBasicMapImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCache.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCache.java deleted file mode 100644 index 5c614f5a5a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCache.java +++ /dev/null @@ -1,781 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Cache</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiry <em>Expiry</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getSize <em>Size</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getShared <em>Shared</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getType <em>Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getAlwaysRefresh <em>Always Refresh</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getRefreshOnlyIfNewer <em>Refresh Only If Newer</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getDisableHits <em>Disable Hits</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getCoordinationType <em>Coordination Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiryTimeOfDay <em>Expiry Time Of Day</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlCache extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getExpiry() <em>Expiry</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExpiry() - * @generated - * @ordered - */ - protected static final Integer EXPIRY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExpiry() <em>Expiry</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExpiry() - * @generated - * @ordered - */ - protected Integer expiry = EXPIRY_EDEFAULT; - - /** - * The default value of the '{@link #getSize() <em>Size</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSize() - * @generated - * @ordered - */ - protected static final Integer SIZE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getSize() <em>Size</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSize() - * @generated - * @ordered - */ - protected Integer size = SIZE_EDEFAULT; - - /** - * The default value of the '{@link #getShared() <em>Shared</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getShared() - * @generated - * @ordered - */ - protected static final Boolean SHARED_EDEFAULT = null; - - /** - * The cached value of the '{@link #getShared() <em>Shared</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getShared() - * @generated - * @ordered - */ - protected Boolean shared = SHARED_EDEFAULT; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final CacheType TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getType() <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getType() - * @generated - * @ordered - */ - protected CacheType type = TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getAlwaysRefresh() <em>Always Refresh</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAlwaysRefresh() - * @generated - * @ordered - */ - protected static final Boolean ALWAYS_REFRESH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getAlwaysRefresh() <em>Always Refresh</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAlwaysRefresh() - * @generated - * @ordered - */ - protected Boolean alwaysRefresh = ALWAYS_REFRESH_EDEFAULT; - - /** - * The default value of the '{@link #getRefreshOnlyIfNewer() <em>Refresh Only If Newer</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getRefreshOnlyIfNewer() - * @generated - * @ordered - */ - protected static final Boolean REFRESH_ONLY_IF_NEWER_EDEFAULT = null; - - /** - * The cached value of the '{@link #getRefreshOnlyIfNewer() <em>Refresh Only If Newer</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getRefreshOnlyIfNewer() - * @generated - * @ordered - */ - protected Boolean refreshOnlyIfNewer = REFRESH_ONLY_IF_NEWER_EDEFAULT; - - /** - * The default value of the '{@link #getDisableHits() <em>Disable Hits</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDisableHits() - * @generated - * @ordered - */ - protected static final Boolean DISABLE_HITS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDisableHits() <em>Disable Hits</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDisableHits() - * @generated - * @ordered - */ - protected Boolean disableHits = DISABLE_HITS_EDEFAULT; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final CacheCoordinationType COORDINATION_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getCoordinationType() <em>Coordination Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCoordinationType() - * @generated - * @ordered - */ - protected CacheCoordinationType coordinationType = COORDINATION_TYPE_EDEFAULT; - - /** - * The cached value of the '{@link #getExpiryTimeOfDay() <em>Expiry Time Of Day</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExpiryTimeOfDay() - * @generated - * @ordered - */ - protected XmlTimeOfDay expiryTimeOfDay; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlCache() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CACHE; - } - - /** - * Returns the value of the '<em><b>Expiry</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Expiry</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Expiry</em>' attribute. - * @see #setExpiry(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_Expiry() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getExpiry() - { - return expiry; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiry <em>Expiry</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Expiry</em>' attribute. - * @see #getExpiry() - * @generated - */ - public void setExpiry(Integer newExpiry) - { - Integer oldExpiry = expiry; - expiry = newExpiry; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__EXPIRY, oldExpiry, expiry)); - } - - /** - * Returns the value of the '<em><b>Size</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Size</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Size</em>' attribute. - * @see #setSize(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_Size() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getSize() - { - return size; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getSize <em>Size</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Size</em>' attribute. - * @see #getSize() - * @generated - */ - public void setSize(Integer newSize) - { - Integer oldSize = size; - size = newSize; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__SIZE, oldSize, size)); - } - - /** - * Returns the value of the '<em><b>Shared</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Shared</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Shared</em>' attribute. - * @see #setShared(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_Shared() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getShared() - { - return shared; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getShared <em>Shared</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Shared</em>' attribute. - * @see #getShared() - * @generated - */ - public void setShared(Boolean newShared) - { - Boolean oldShared = shared; - shared = newShared; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__SHARED, oldShared, shared)); - } - - /** - * Returns the value of the '<em><b>Type</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheType - * @see #setType(CacheType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_Type() - * @model - * @generated - */ - public CacheType getType() - { - return type; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getType <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheType - * @see #getType() - * @generated - */ - public void setType(CacheType newType) - { - CacheType oldType = type; - type = newType == null ? TYPE_EDEFAULT : newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__TYPE, oldType, type)); - } - - /** - * Returns the value of the '<em><b>Always Refresh</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Always Refresh</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Always Refresh</em>' attribute. - * @see #setAlwaysRefresh(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_AlwaysRefresh() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getAlwaysRefresh() - { - return alwaysRefresh; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getAlwaysRefresh <em>Always Refresh</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Always Refresh</em>' attribute. - * @see #getAlwaysRefresh() - * @generated - */ - public void setAlwaysRefresh(Boolean newAlwaysRefresh) - { - Boolean oldAlwaysRefresh = alwaysRefresh; - alwaysRefresh = newAlwaysRefresh; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__ALWAYS_REFRESH, oldAlwaysRefresh, alwaysRefresh)); - } - - /** - * Returns the value of the '<em><b>Refresh Only If Newer</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Refresh Only If Newer</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Refresh Only If Newer</em>' attribute. - * @see #setRefreshOnlyIfNewer(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_RefreshOnlyIfNewer() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getRefreshOnlyIfNewer() - { - return refreshOnlyIfNewer; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getRefreshOnlyIfNewer <em>Refresh Only If Newer</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Refresh Only If Newer</em>' attribute. - * @see #getRefreshOnlyIfNewer() - * @generated - */ - public void setRefreshOnlyIfNewer(Boolean newRefreshOnlyIfNewer) - { - Boolean oldRefreshOnlyIfNewer = refreshOnlyIfNewer; - refreshOnlyIfNewer = newRefreshOnlyIfNewer; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__REFRESH_ONLY_IF_NEWER, oldRefreshOnlyIfNewer, refreshOnlyIfNewer)); - } - - /** - * Returns the value of the '<em><b>Disable Hits</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Disable Hits</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Disable Hits</em>' attribute. - * @see #setDisableHits(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_DisableHits() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getDisableHits() - { - return disableHits; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getDisableHits <em>Disable Hits</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Disable Hits</em>' attribute. - * @see #getDisableHits() - * @generated - */ - public void setDisableHits(Boolean newDisableHits) - { - Boolean oldDisableHits = disableHits; - disableHits = newDisableHits; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__DISABLE_HITS, oldDisableHits, disableHits)); - } - - /** - * Returns the value of the '<em><b>Coordination Type</b></em>' attribute. - * The default value is <code>""</code>. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Coordination 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>Coordination Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType - * @see #setCoordinationType(CacheCoordinationType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_CoordinationType() - * @model default="" - * @generated - */ - public CacheCoordinationType getCoordinationType() - { - return coordinationType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getCoordinationType <em>Coordination Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Coordination Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.CacheCoordinationType - * @see #getCoordinationType() - * @generated - */ - public void setCoordinationType(CacheCoordinationType newCoordinationType) - { - CacheCoordinationType oldCoordinationType = coordinationType; - coordinationType = newCoordinationType == null ? COORDINATION_TYPE_EDEFAULT : newCoordinationType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__COORDINATION_TYPE, oldCoordinationType, coordinationType)); - } - - /** - * Returns the value of the '<em><b>Expiry Time Of Day</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Expiry Time Of Day</em>' reference isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Expiry Time Of Day</em>' containment reference. - * @see #setExpiryTimeOfDay(XmlTimeOfDay) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCache_ExpiryTimeOfDay() - * @model containment="true" - * @generated - */ - public XmlTimeOfDay getExpiryTimeOfDay() - { - return expiryTimeOfDay; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetExpiryTimeOfDay(XmlTimeOfDay newExpiryTimeOfDay, NotificationChain msgs) - { - XmlTimeOfDay oldExpiryTimeOfDay = expiryTimeOfDay; - expiryTimeOfDay = newExpiryTimeOfDay; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY, oldExpiryTimeOfDay, newExpiryTimeOfDay); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCache#getExpiryTimeOfDay <em>Expiry Time Of Day</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Expiry Time Of Day</em>' containment reference. - * @see #getExpiryTimeOfDay() - * @generated - */ - public void setExpiryTimeOfDay(XmlTimeOfDay newExpiryTimeOfDay) - { - if (newExpiryTimeOfDay != expiryTimeOfDay) - { - NotificationChain msgs = null; - if (expiryTimeOfDay != null) - msgs = ((InternalEObject)expiryTimeOfDay).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY, null, msgs); - if (newExpiryTimeOfDay != null) - msgs = ((InternalEObject)newExpiryTimeOfDay).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY, null, msgs); - msgs = basicSetExpiryTimeOfDay(newExpiryTimeOfDay, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY, newExpiryTimeOfDay, newExpiryTimeOfDay)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY: - return basicSetExpiryTimeOfDay(null, 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 EclipseLinkOrmPackage.XML_CACHE__EXPIRY: - return getExpiry(); - case EclipseLinkOrmPackage.XML_CACHE__SIZE: - return getSize(); - case EclipseLinkOrmPackage.XML_CACHE__SHARED: - return getShared(); - case EclipseLinkOrmPackage.XML_CACHE__TYPE: - return getType(); - case EclipseLinkOrmPackage.XML_CACHE__ALWAYS_REFRESH: - return getAlwaysRefresh(); - case EclipseLinkOrmPackage.XML_CACHE__REFRESH_ONLY_IF_NEWER: - return getRefreshOnlyIfNewer(); - case EclipseLinkOrmPackage.XML_CACHE__DISABLE_HITS: - return getDisableHits(); - case EclipseLinkOrmPackage.XML_CACHE__COORDINATION_TYPE: - return getCoordinationType(); - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY: - return getExpiryTimeOfDay(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY: - setExpiry((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__SIZE: - setSize((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__SHARED: - setShared((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__TYPE: - setType((CacheType)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__ALWAYS_REFRESH: - setAlwaysRefresh((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__REFRESH_ONLY_IF_NEWER: - setRefreshOnlyIfNewer((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__DISABLE_HITS: - setDisableHits((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__COORDINATION_TYPE: - setCoordinationType((CacheCoordinationType)newValue); - return; - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY: - setExpiryTimeOfDay((XmlTimeOfDay)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY: - setExpiry(EXPIRY_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__SIZE: - setSize(SIZE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__SHARED: - setShared(SHARED_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__TYPE: - setType(TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__ALWAYS_REFRESH: - setAlwaysRefresh(ALWAYS_REFRESH_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__REFRESH_ONLY_IF_NEWER: - setRefreshOnlyIfNewer(REFRESH_ONLY_IF_NEWER_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__DISABLE_HITS: - setDisableHits(DISABLE_HITS_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__COORDINATION_TYPE: - setCoordinationType(COORDINATION_TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY: - setExpiryTimeOfDay((XmlTimeOfDay)null); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY: - return EXPIRY_EDEFAULT == null ? expiry != null : !EXPIRY_EDEFAULT.equals(expiry); - case EclipseLinkOrmPackage.XML_CACHE__SIZE: - return SIZE_EDEFAULT == null ? size != null : !SIZE_EDEFAULT.equals(size); - case EclipseLinkOrmPackage.XML_CACHE__SHARED: - return SHARED_EDEFAULT == null ? shared != null : !SHARED_EDEFAULT.equals(shared); - case EclipseLinkOrmPackage.XML_CACHE__TYPE: - return type != TYPE_EDEFAULT; - case EclipseLinkOrmPackage.XML_CACHE__ALWAYS_REFRESH: - return ALWAYS_REFRESH_EDEFAULT == null ? alwaysRefresh != null : !ALWAYS_REFRESH_EDEFAULT.equals(alwaysRefresh); - case EclipseLinkOrmPackage.XML_CACHE__REFRESH_ONLY_IF_NEWER: - return REFRESH_ONLY_IF_NEWER_EDEFAULT == null ? refreshOnlyIfNewer != null : !REFRESH_ONLY_IF_NEWER_EDEFAULT.equals(refreshOnlyIfNewer); - case EclipseLinkOrmPackage.XML_CACHE__DISABLE_HITS: - return DISABLE_HITS_EDEFAULT == null ? disableHits != null : !DISABLE_HITS_EDEFAULT.equals(disableHits); - case EclipseLinkOrmPackage.XML_CACHE__COORDINATION_TYPE: - return coordinationType != COORDINATION_TYPE_EDEFAULT; - case EclipseLinkOrmPackage.XML_CACHE__EXPIRY_TIME_OF_DAY: - return expiryTimeOfDay != null; - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (expiry: "); - result.append(expiry); - result.append(", size: "); - result.append(size); - result.append(", shared: "); - result.append(shared); - result.append(", type: "); - result.append(type); - result.append(", alwaysRefresh: "); - result.append(alwaysRefresh); - result.append(", refreshOnlyIfNewer: "); - result.append(refreshOnlyIfNewer); - result.append(", disableHits: "); - result.append(disableHits); - result.append(", coordinationType: "); - result.append(coordinationType); - result.append(')'); - return result.toString(); - } - -} // XmlCache diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCacheHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCacheHolder.java deleted file mode 100644 index 35dc607a18..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCacheHolder.java +++ /dev/null @@ -1,101 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Cache Holder</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getCache <em>Cache</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getExistenceChecking <em>Existence Checking</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlCacheHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Cache</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>Cache</em>' containment reference. - * @see #setCache(XmlCache) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_Cache() - * @model containment="true" - * @generated - */ - XmlCache getCache(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getCache <em>Cache</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Cache</em>' containment reference. - * @see #getCache() - * @generated - */ - void setCache(XmlCache value); - - /** - * Returns the value of the '<em><b>Existence Checking</b></em>' attribute. - * The default value is <code>""</code>. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Existence Checking</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #setExistenceChecking(ExistenceType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_ExistenceChecking() - * @model default="" - * @generated - */ - ExistenceType getExistenceChecking(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCacheHolder#getExistenceChecking <em>Existence Checking</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #getExistenceChecking() - * @generated - */ - void setExistenceChecking(ExistenceType value); - -} // XmlCacheHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTracking.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTracking.java deleted file mode 100644 index 8f7314586a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTracking.java +++ /dev/null @@ -1,203 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlChangeTracking.java,v 1.2 2008/11/03 16:58:54 pfullbright Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - - * A representation of the model object '<em><b>Xml Change Tracking</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking#getType <em>Type</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTracking() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlChangeTracking extends AbstractJpaEObject implements JpaEObject -{ - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlChangeTrackingType TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getType() <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getType() - * @generated - * @ordered - */ - protected XmlChangeTrackingType type = TYPE_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlChangeTracking() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CHANGE_TRACKING; - } - - /** - * Returns the value of the '<em><b>Type</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType - * @see #setType(XmlChangeTrackingType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTracking_Type() - * @model - * @generated - */ - public XmlChangeTrackingType getType() - { - return type; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTracking#getType <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingType - * @see #getType() - * @generated - */ - public void setType(XmlChangeTrackingType newType) - { - XmlChangeTrackingType oldType = type; - type = newType == null ? TYPE_EDEFAULT : newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CHANGE_TRACKING__TYPE, oldType, type)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING__TYPE: - return getType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING__TYPE: - setType((XmlChangeTrackingType)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING__TYPE: - setType(TYPE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING__TYPE: - return type != TYPE_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (type: "); - result.append(type); - result.append(')'); - return result.toString(); - } - -} // XmlChangeTracking diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingHolder.java deleted file mode 100644 index 9fa686650a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingHolder.java +++ /dev/null @@ -1,67 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlChangeTrackingHolder.java,v 1.3 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Change Tracking Holder</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder#getChangeTracking <em>Change Tracking</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlChangeTrackingHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Change Tracking</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>Change Tracking</em>' containment reference. - * @see #setChangeTracking(XmlChangeTracking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder_ChangeTracking() - * @model containment="true" - * @generated - */ - XmlChangeTracking getChangeTracking(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlChangeTrackingHolder#getChangeTracking <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Change Tracking</em>' containment reference. - * @see #getChangeTracking() - * @generated - */ - void setChangeTracking(XmlChangeTracking value); - -} // XmlChangeTrackingHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingType.java deleted file mode 100644 index 98544f17bc..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlChangeTrackingType.java +++ /dev/null @@ -1,286 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlChangeTrackingType.java,v 1.3 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * - * A representation of the literals of the enumeration '<em><b>Xml Change Tracking Type</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingType() - * @model - * @generated - */ -public enum XmlChangeTrackingType implements Enumerator -{ - /** - * The '<em><b>ATTRIBUTE</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #ATTRIBUTE_VALUE - * @generated - * @ordered - */ - ATTRIBUTE(0, "ATTRIBUTE", "ATTRIBUTE"), /** - * The '<em><b>OBJECT</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #OBJECT_VALUE - * @generated - * @ordered - */ - OBJECT(1, "OBJECT", "OBJECT"), /** - * The '<em><b>DEFERRED</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #DEFERRED_VALUE - * @generated - * @ordered - */ - DEFERRED(2, "DEFERRED", "DEFERRED"), /** - * The '<em><b>AUTO</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #AUTO_VALUE - * @generated - * @ordered - */ - AUTO(3, "AUTO", "AUTO") - ; - - /** - * The '<em><b>ATTRIBUTE</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>ATTRIBUTE</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #ATTRIBUTE - * @model - * @generated - * @ordered - */ - public static final int ATTRIBUTE_VALUE = 0; - -/** - * The '<em><b>OBJECT</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>OBJECT</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #OBJECT - * @model - * @generated - * @ordered - */ - public static final int OBJECT_VALUE = 1; - -/** - * The '<em><b>DEFERRED</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>DEFERRED</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #DEFERRED - * @model - * @generated - * @ordered - */ - public static final int DEFERRED_VALUE = 2; - -/** - * The '<em><b>AUTO</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>AUTO</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #AUTO - * @model - * @generated - * @ordered - */ - public static final int AUTO_VALUE = 3; - - /** - * An array of all the '<em><b>Xml Change Tracking Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final XmlChangeTrackingType[] VALUES_ARRAY = - new XmlChangeTrackingType[] - { - ATTRIBUTE, - OBJECT, - DEFERRED, - AUTO, - }; - - /** - * A public read-only list of all the '<em><b>Xml Change Tracking Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<XmlChangeTrackingType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Xml Change Tracking Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlChangeTrackingType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlChangeTrackingType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Change Tracking Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlChangeTrackingType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlChangeTrackingType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Change Tracking Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlChangeTrackingType get(int value) - { - switch (value) - { - case ATTRIBUTE_VALUE: return ATTRIBUTE; - case OBJECT_VALUE: return OBJECT; - case DEFERRED_VALUE: return DEFERRED; - case AUTO_VALUE: return AUTO; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private XmlChangeTrackingType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //XmlChangeTrackingType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCloneCopyPolicy.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCloneCopyPolicy.java deleted file mode 100644 index 2d986e2a30..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCloneCopyPolicy.java +++ /dev/null @@ -1,277 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Clone Copy Policy</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getMethod <em>Method</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getWorkingCopyMethod <em>Working Copy Method</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCloneCopyPolicy() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlCloneCopyPolicy extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getMethod() <em>Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMethod() - * @generated - * @ordered - */ - protected static final String METHOD_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMethod() <em>Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMethod() - * @generated - * @ordered - */ - protected String method = METHOD_EDEFAULT; - - /** - * The default value of the '{@link #getWorkingCopyMethod() <em>Working Copy Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getWorkingCopyMethod() - * @generated - * @ordered - */ - protected static final String WORKING_COPY_METHOD_EDEFAULT = null; - - /** - * The cached value of the '{@link #getWorkingCopyMethod() <em>Working Copy Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getWorkingCopyMethod() - * @generated - * @ordered - */ - protected String workingCopyMethod = WORKING_COPY_METHOD_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlCloneCopyPolicy() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CLONE_COPY_POLICY; - } - - /** - * Returns the value of the '<em><b>Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Method</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Method</em>' attribute. - * @see #setMethod(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCloneCopyPolicy_Method() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getMethod() - { - return method; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getMethod <em>Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Method</em>' attribute. - * @see #getMethod() - * @generated - */ - public void setMethod(String newMethod) - { - String oldMethod = method; - method = newMethod; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__METHOD, oldMethod, method)); - } - - /** - * Returns the value of the '<em><b>Working Copy Method</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Working Copy Method</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Working Copy Method</em>' attribute. - * @see #setWorkingCopyMethod(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCloneCopyPolicy_WorkingCopyMethod() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getWorkingCopyMethod() - { - return workingCopyMethod; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCloneCopyPolicy#getWorkingCopyMethod <em>Working Copy Method</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Working Copy Method</em>' attribute. - * @see #getWorkingCopyMethod() - * @generated - */ - public void setWorkingCopyMethod(String newWorkingCopyMethod) - { - String oldWorkingCopyMethod = workingCopyMethod; - workingCopyMethod = newWorkingCopyMethod; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD, oldWorkingCopyMethod, workingCopyMethod)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__METHOD: - return getMethod(); - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD: - return getWorkingCopyMethod(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__METHOD: - setMethod((String)newValue); - return; - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD: - setWorkingCopyMethod((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__METHOD: - setMethod(METHOD_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD: - setWorkingCopyMethod(WORKING_COPY_METHOD_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__METHOD: - return METHOD_EDEFAULT == null ? method != null : !METHOD_EDEFAULT.equals(method); - case EclipseLinkOrmPackage.XML_CLONE_COPY_POLICY__WORKING_COPY_METHOD: - return WORKING_COPY_METHOD_EDEFAULT == null ? workingCopyMethod != null : !WORKING_COPY_METHOD_EDEFAULT.equals(workingCopyMethod); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (method: "); - result.append(method); - result.append(", workingCopyMethod: "); - result.append(workingCopyMethod); - result.append(')'); - return result.toString(); - } - -} // XmlCloneCopyPolicy diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValue.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValue.java deleted file mode 100644 index ca5fe35e1a..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValue.java +++ /dev/null @@ -1,108 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - - * A representation of the model object '<em><b>Xml Conversion Value</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getDataValue <em>Data Value</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getObjectValue <em>Object Value</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlConversionValue extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Data Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Data Value</em>' attribute. - * @see #setDataValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue_DataValue() - * @model - * @generated - */ - String getDataValue(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getDataValue <em>Data Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Value</em>' attribute. - * @see #getDataValue() - * @generated - */ - void setDataValue(String value); - - /** - * Returns the value of the '<em><b>Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Object Value</em>' attribute. - * @see #setObjectValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue_ObjectValue() - * @model - * @generated - */ - String getObjectValue(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue#getObjectValue <em>Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Value</em>' attribute. - * @see #getObjectValue() - * @generated - */ - void setObjectValue(String value); - - /** - * Return the {@link TextRange} for the data-value attribute. - */ - public TextRange getDataValueTextRange(); - - /** - * Return the {@link TextRange} for the object-value attribute. - */ - public TextRange getObjectValueTextRange(); - -} // XmlConversionValue diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValueImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValueImpl.java deleted file mode 100644 index 06fb4a60a9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConversionValueImpl.java +++ /dev/null @@ -1,275 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Conversion Value</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValueImpl() - * @model kind="class" - * @generated - */ -public class XmlConversionValueImpl extends AbstractJpaEObject implements XmlConversionValue -{ - /** - * The default value of the '{@link #getDataValue() <em>Data Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataValue() - * @generated - * @ordered - */ - protected static final String DATA_VALUE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDataValue() <em>Data Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataValue() - * @generated - * @ordered - */ - protected String dataValue = DATA_VALUE_EDEFAULT; - - /** - * The default value of the '{@link #getObjectValue() <em>Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectValue() - * @generated - * @ordered - */ - protected static final String OBJECT_VALUE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getObjectValue() <em>Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectValue() - * @generated - * @ordered - */ - protected String objectValue = OBJECT_VALUE_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlConversionValueImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CONVERSION_VALUE_IMPL; - } - - /** - * Returns the value of the '<em><b>Data Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Data Value</em>' attribute. - * @see #setDataValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue_DataValue() - * @model - * @generated - */ - public String getDataValue() - { - return dataValue; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl#getDataValue <em>Data Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Value</em>' attribute. - * @see #getDataValue() - * @generated - */ - public void setDataValue(String newDataValue) - { - String oldDataValue = dataValue; - dataValue = newDataValue; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__DATA_VALUE, oldDataValue, dataValue)); - } - - /** - * Returns the value of the '<em><b>Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Object Value</em>' attribute. - * @see #setObjectValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConversionValue_ObjectValue() - * @model - * @generated - */ - public String getObjectValue() - { - return objectValue; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValueImpl#getObjectValue <em>Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Value</em>' attribute. - * @see #getObjectValue() - * @generated - */ - public void setObjectValue(String newObjectValue) - { - String oldObjectValue = objectValue; - objectValue = newObjectValue; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE, oldObjectValue, objectValue)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__DATA_VALUE: - return getDataValue(); - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE: - return getObjectValue(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__DATA_VALUE: - setDataValue((String)newValue); - return; - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE: - setObjectValue((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__DATA_VALUE: - setDataValue(DATA_VALUE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE: - setObjectValue(OBJECT_VALUE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__DATA_VALUE: - return DATA_VALUE_EDEFAULT == null ? dataValue != null : !DATA_VALUE_EDEFAULT.equals(dataValue); - case EclipseLinkOrmPackage.XML_CONVERSION_VALUE_IMPL__OBJECT_VALUE: - return OBJECT_VALUE_EDEFAULT == null ? objectValue != null : !OBJECT_VALUE_EDEFAULT.equals(objectValue); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (dataValue: "); - result.append(dataValue); - result.append(", objectValue: "); - result.append(objectValue); - result.append(')'); - return result.toString(); - } - - public TextRange getDataValueTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.CONVERSION_VALUE__DATA_VALUE); - } - - public TextRange getObjectValueTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.CONVERSION_VALUE__OBJECT_VALUE); - } -} // XmlConversionValue diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverter.java deleted file mode 100644 index 35636a7a52..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverter.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter#getClassName <em>Class Name</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverter() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlConverter extends XmlNamedConverter -{ - /** - * Returns the value of the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Class Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Class Name</em>' attribute. - * @see #setClassName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverter_ClassName() - * @model - * @generated - */ - String getClassName(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter#getClassName <em>Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Class Name</em>' attribute. - * @see #getClassName() - * @generated - */ - void setClassName(String value); - -} // XmlConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterHolder.java deleted file mode 100644 index c3dd02be0f..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterHolder.java +++ /dev/null @@ -1,151 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml CustomConverter Holder</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getConverter <em>Converter</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getTypeConverter <em>Type Converter</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getObjectTypeConverter <em>Object Type Converter</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getStructConverter <em>Struct Converter</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlConverterHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</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>Converter</em>' containment reference. - * @see #setConverter(XmlConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_Converter() - * @model containment="true" - * @generated - */ - XmlConverter getConverter(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getConverter <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' containment reference. - * @see #getConverter() - * @generated - */ - void setConverter(XmlConverter value); - - /** - * Returns the value of the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type CustomConverter</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>Type Converter</em>' containment reference. - * @see #setTypeConverter(XmlTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_TypeConverter() - * @model containment="true" - * @generated - */ - XmlTypeConverter getTypeConverter(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getTypeConverter <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type Converter</em>' containment reference. - * @see #getTypeConverter() - * @generated - */ - void setTypeConverter(XmlTypeConverter value); - - /** - * Returns the value of the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type CustomConverter</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>Object Type Converter</em>' containment reference. - * @see #setObjectTypeConverter(XmlObjectTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_ObjectTypeConverter() - * @model containment="true" - * @generated - */ - XmlObjectTypeConverter getObjectTypeConverter(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getObjectTypeConverter <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type Converter</em>' containment reference. - * @see #getObjectTypeConverter() - * @generated - */ - void setObjectTypeConverter(XmlObjectTypeConverter value); - - /** - * Returns the value of the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct CustomConverter</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>Struct Converter</em>' containment reference. - * @see #setStructConverter(XmlStructConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_StructConverter() - * @model containment="true" - * @generated - */ - XmlStructConverter getStructConverter(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterHolder#getStructConverter <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Struct Converter</em>' containment reference. - * @see #getStructConverter() - * @generated - */ - void setStructConverter(XmlStructConverter value); - -} // XmlConverterHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterImpl.java deleted file mode 100644 index 1fc324bfff..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConverterImpl.java +++ /dev/null @@ -1,266 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterImpl() - * @model kind="class" - * @generated - */ -public class XmlConverterImpl extends AbstractJpaEObject implements XmlConverter -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getClassName() <em>Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getClassName() - * @generated - * @ordered - */ - protected static final String CLASS_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getClassName() <em>Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getClassName() - * @generated - * @ordered - */ - protected String className = CLASS_NAME_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlConverterImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CONVERTER_IMPL; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter_Name() - * @model - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CONVERTER_IMPL__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Class Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Class Name</em>' attribute. - * @see #setClassName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverter_ClassName() - * @model - * @generated - */ - public String getClassName() - { - return className; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverterImpl#getClassName <em>Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Class Name</em>' attribute. - * @see #getClassName() - * @generated - */ - public void setClassName(String newClassName) - { - String oldClassName = className; - className = newClassName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CONVERTER_IMPL__CLASS_NAME, oldClassName, className)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__CLASS_NAME: - return getClassName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__CLASS_NAME: - setClassName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__CLASS_NAME: - setClassName(CLASS_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_CONVERTER_IMPL__CLASS_NAME: - return CLASS_NAME_EDEFAULT == null ? className != null : !CLASS_NAME_EDEFAULT.equals(className); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", className: "); - result.append(className); - result.append(')'); - return result.toString(); - } - -} // XmlConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertersHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertersHolder.java deleted file mode 100644 index 4136425a89..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertersHolder.java +++ /dev/null @@ -1,112 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Converters Holder</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getConverters <em>Converters</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getTypeConverters <em>Type Converters</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getObjectTypeConverters <em>Object Type Converters</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertersHolder#getStructConverters <em>Struct Converters</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlConvertersHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Converters</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>Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_Converters() - * @model containment="true" - * @generated - */ - EList<XmlConverter> getConverters(); - - /** - * Returns the value of the '<em><b>Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type Converters</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>Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_TypeConverters() - * @model containment="true" - * @generated - */ - EList<XmlTypeConverter> getTypeConverters(); - - /** - * Returns the value of the '<em><b>Object Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type Converters</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>Object Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_ObjectTypeConverters() - * @model containment="true" - * @generated - */ - EList<XmlObjectTypeConverter> getObjectTypeConverters(); - - /** - * Returns the value of the '<em><b>Struct Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct Converters</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>Struct Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_StructConverters() - * @model containment="true" - * @generated - */ - EList<XmlStructConverter> getStructConverters(); - -} // XmlConvertersHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertibleMapping.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertibleMapping.java deleted file mode 100644 index 9fd20b4734..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlConvertibleMapping.java +++ /dev/null @@ -1,76 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.utility.TextRange; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Convertible Mapping</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping#getConvert <em>Convert</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlConvertibleMapping extends org.eclipse.jpt.core.resource.orm.XmlConvertibleMapping, XmlConverterHolder -{ - /** - * Returns the value of the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Convert</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>Convert</em>' attribute. - * @see #setConvert(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping_Convert() - * @model - * @generated - */ - String getConvert(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConvertibleMapping#getConvert <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Convert</em>' attribute. - * @see #getConvert() - * @generated - */ - void setConvert(String value); - - /** - * Return the {@link TextRange} for the convert element. If the convert element - * does not exist return the {@link TextRange} for the mapping element. - */ - TextRange getConvertTextRange(); - -} // XmlConvertibleMapping diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCopyPolicy.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCopyPolicy.java deleted file mode 100644 index 5552d6527c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCopyPolicy.java +++ /dev/null @@ -1,209 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Copy Policy</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy#getClass_ <em>Class</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCopyPolicy() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlCopyPolicy extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getClass_() <em>Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getClass_() - * @generated - * @ordered - */ - protected static final String CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getClass_() <em>Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getClass_() - * @generated - * @ordered - */ - protected String class_ = CLASS_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlCopyPolicy() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_COPY_POLICY; - } - - /** - * Returns the value of the '<em><b>Class</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Class</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Class</em>' attribute. - * @see #setClass(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCopyPolicy_Class() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getClass_() - { - return class_; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCopyPolicy#getClass_ <em>Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Class</em>' attribute. - * @see #getClass_() - * @generated - */ - public void setClass(String newClass) - { - String oldClass = class_; - class_ = newClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_COPY_POLICY__CLASS, oldClass, class_)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_COPY_POLICY__CLASS: - return getClass_(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_COPY_POLICY__CLASS: - setClass((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_COPY_POLICY__CLASS: - setClass(CLASS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_COPY_POLICY__CLASS: - return CLASS_EDEFAULT == null ? class_ != null : !CLASS_EDEFAULT.equals(class_); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (class: "); - result.append(class_); - result.append(')'); - return result.toString(); - } - -} // XmlCopyPolicy diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizer.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizer.java deleted file mode 100644 index 3ee1e16baf..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizer.java +++ /dev/null @@ -1,213 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.internal.resource.orm.translators.OrmXmlMapper; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Customizer</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer#getCustomizerClassName <em>Customizer Class Name</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizer() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlCustomizer extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getCustomizerClassName() <em>Customizer Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCustomizerClassName() - * @generated - * @ordered - */ - protected static final String CUSTOMIZER_CLASS_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getCustomizerClassName() <em>Customizer Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCustomizerClassName() - * @generated - * @ordered - */ - protected String customizerClassName = CUSTOMIZER_CLASS_NAME_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlCustomizer() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_CUSTOMIZER; - } - - /** - * Returns the value of the '<em><b>Customizer Class Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Customizer Class Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Customizer Class Name</em>' attribute. - * @see #setCustomizerClassName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizer_CustomizerClassName() - * @model - * @generated - */ - public String getCustomizerClassName() - { - return customizerClassName; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizer#getCustomizerClassName <em>Customizer Class Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Customizer Class Name</em>' attribute. - * @see #getCustomizerClassName() - * @generated - */ - public void setCustomizerClassName(String newCustomizerClassName) - { - String oldCustomizerClassName = customizerClassName; - customizerClassName = newCustomizerClassName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME, oldCustomizerClassName, customizerClassName)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME: - return getCustomizerClassName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME: - setCustomizerClassName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME: - setCustomizerClassName(CUSTOMIZER_CLASS_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER__CUSTOMIZER_CLASS_NAME: - return CUSTOMIZER_CLASS_NAME_EDEFAULT == null ? customizerClassName != null : !CUSTOMIZER_CLASS_NAME_EDEFAULT.equals(customizerClassName); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (customizerClassName: "); - result.append(customizerClassName); - result.append(')'); - return result.toString(); - } - - public TextRange getCustomizerClassNameTextRange() { - return getAttributeTextRange(OrmXmlMapper.CLASS); - } - -} // XmlCustomizer diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizerHolder.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizerHolder.java deleted file mode 100644 index 81b77385ef..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlCustomizerHolder.java +++ /dev/null @@ -1,70 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Customizer Holder</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder#getCustomizer <em>Customizer</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlCustomizerHolder extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Customizer</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>Customizer</em>' containment reference. - * @see #setCustomizer(XmlCustomizer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder_Customizer() - * @model containment="true" - * @generated - */ - XmlCustomizer getCustomizer(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlCustomizerHolder#getCustomizer <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Customizer</em>' containment reference. - * @see #getCustomizer() - * @generated - */ - void setCustomizer(XmlCustomizer value); - -} // XmlCustomizerHolder diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlDirection.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlDirection.java deleted file mode 100644 index 5dba109b89..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlDirection.java +++ /dev/null @@ -1,294 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * A representation of the literals of the enumeration '<em><b>Xml Direction</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlDirection() - * @model - * @generated - */ -public enum XmlDirection implements Enumerator -{ - /** - * The '<em><b>IN</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #IN_VALUE - * @generated - * @ordered - */ - IN(0, "IN", "IN"), - - /** - * The '<em><b>OUT</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #OUT_VALUE - * @generated - * @ordered - */ - OUT(1, "OUT", "OUT"), - - /** - * The '<em><b>IN OUT</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #IN_OUT_VALUE - * @generated - * @ordered - */ - IN_OUT(2, "IN_OUT", "IN_OUT"), - - /** - * The '<em><b>OUT CURSOR</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #OUT_CURSOR_VALUE - * @generated - * @ordered - */ - OUT_CURSOR(3, "OUT_CURSOR", "OUT_CURSOR"); - - /** - * The '<em><b>IN</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>IN</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #IN - * @model - * @generated - * @ordered - */ - public static final int IN_VALUE = 0; - - /** - * The '<em><b>OUT</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>OUT</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #OUT - * @model - * @generated - * @ordered - */ - public static final int OUT_VALUE = 1; - - /** - * The '<em><b>IN OUT</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>IN OUT</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #IN_OUT - * @model - * @generated - * @ordered - */ - public static final int IN_OUT_VALUE = 2; - - /** - * The '<em><b>OUT CURSOR</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>OUT CURSOR</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #OUT_CURSOR - * @model - * @generated - * @ordered - */ - public static final int OUT_CURSOR_VALUE = 3; - - /** - * An array of all the '<em><b>Xml Direction</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final XmlDirection[] VALUES_ARRAY = - new XmlDirection[] - { - IN, - OUT, - IN_OUT, - OUT_CURSOR, - }; - - /** - * A public read-only list of all the '<em><b>Xml Direction</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<XmlDirection> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Xml Direction</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlDirection get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlDirection result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Direction</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlDirection getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlDirection result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Direction</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlDirection get(int value) - { - switch (value) - { - case IN_VALUE: return IN; - case OUT_VALUE: return OUT; - case IN_OUT_VALUE: return IN_OUT; - case OUT_CURSOR_VALUE: return OUT_CURSOR; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private XmlDirection(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //XmlDirection diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddable.java deleted file mode 100644 index 9d1e62f3b6..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddable.java +++ /dev/null @@ -1,945 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Embeddable</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCopyPolicy <em>Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCloneCopyPolicy <em>Clone Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getProperties <em>Properties</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable() - * @model kind="class" - * @generated - */ -public class XmlEmbeddable extends org.eclipse.jpt.core.resource.orm.XmlEmbeddable implements XmlCustomizerHolder, XmlChangeTrackingHolder, XmlConvertersHolder -{ - /** - * The cached value of the '{@link #getCustomizer() <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCustomizer() - * @generated - * @ordered - */ - protected XmlCustomizer customizer; - - /** - * The cached value of the '{@link #getChangeTracking() <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getChangeTracking() - * @generated - * @ordered - */ - protected XmlChangeTracking changeTracking; - - /** - * The cached value of the '{@link #getConverters() <em>Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverters() - * @generated - * @ordered - */ - protected EList<XmlConverter> converters; - - /** - * The cached value of the '{@link #getTypeConverters() <em>Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlTypeConverter> typeConverters; - - /** - * The cached value of the '{@link #getObjectTypeConverters() <em>Object Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlObjectTypeConverter> objectTypeConverters; - - /** - * The cached value of the '{@link #getStructConverters() <em>Struct Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverters() - * @generated - * @ordered - */ - protected EList<XmlStructConverter> structConverters; - - /** - * The cached value of the '{@link #getCopyPolicy() <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy copyPolicy; - - /** - * The cached value of the '{@link #getInstantiationCopyPolicy() <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getInstantiationCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy instantiationCopyPolicy; - - /** - * The cached value of the '{@link #getCloneCopyPolicy() <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCloneCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy cloneCopyPolicy; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * The default value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected static final Boolean EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected Boolean excludeDefaultMappings = EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlEmbeddable() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_EMBEDDABLE; - } - - /** - * Returns the value of the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Customizer</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>Customizer</em>' containment reference. - * @see #setCustomizer(XmlCustomizer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder_Customizer() - * @model containment="true" - * @generated - */ - public XmlCustomizer getCustomizer() - { - return customizer; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCustomizer(XmlCustomizer newCustomizer, NotificationChain msgs) - { - XmlCustomizer oldCustomizer = customizer; - customizer = newCustomizer; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER, oldCustomizer, newCustomizer); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCustomizer <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Customizer</em>' containment reference. - * @see #getCustomizer() - * @generated - */ - public void setCustomizer(XmlCustomizer newCustomizer) - { - if (newCustomizer != customizer) - { - NotificationChain msgs = null; - if (customizer != null) - msgs = ((InternalEObject)customizer).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER, null, msgs); - if (newCustomizer != null) - msgs = ((InternalEObject)newCustomizer).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER, null, msgs); - msgs = basicSetCustomizer(newCustomizer, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER, newCustomizer, newCustomizer)); - } - - /** - * Returns the value of the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Change Tracking</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>Change Tracking</em>' containment reference. - * @see #setChangeTracking(XmlChangeTracking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder_ChangeTracking() - * @model containment="true" - * @generated - */ - public XmlChangeTracking getChangeTracking() - { - return changeTracking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetChangeTracking(XmlChangeTracking newChangeTracking, NotificationChain msgs) - { - XmlChangeTracking oldChangeTracking = changeTracking; - changeTracking = newChangeTracking; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING, oldChangeTracking, newChangeTracking); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getChangeTracking <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Change Tracking</em>' containment reference. - * @see #getChangeTracking() - * @generated - */ - public void setChangeTracking(XmlChangeTracking newChangeTracking) - { - if (newChangeTracking != changeTracking) - { - NotificationChain msgs = null; - if (changeTracking != null) - msgs = ((InternalEObject)changeTracking).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING, null, msgs); - if (newChangeTracking != null) - msgs = ((InternalEObject)newChangeTracking).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING, null, msgs); - msgs = basicSetChangeTracking(newChangeTracking, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING, newChangeTracking, newChangeTracking)); - } - - /** - * Returns the value of the '<em><b>Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Converters</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>Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_Converters() - * @model containment="true" - * @generated - */ - public EList<XmlConverter> getConverters() - { - if (converters == null) - { - converters = new EObjectContainmentEList<XmlConverter>(XmlConverter.class, this, EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS); - } - return converters; - } - - /** - * Returns the value of the '<em><b>Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type Converters</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>Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_TypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlTypeConverter> getTypeConverters() - { - if (typeConverters == null) - { - typeConverters = new EObjectContainmentEList<XmlTypeConverter>(XmlTypeConverter.class, this, EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS); - } - return typeConverters; - } - - /** - * Returns the value of the '<em><b>Object Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type Converters</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>Object Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_ObjectTypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlObjectTypeConverter> getObjectTypeConverters() - { - if (objectTypeConverters == null) - { - objectTypeConverters = new EObjectContainmentEList<XmlObjectTypeConverter>(XmlObjectTypeConverter.class, this, EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS); - } - return objectTypeConverters; - } - - /** - * Returns the value of the '<em><b>Struct Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct Converters</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>Struct Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_StructConverters() - * @model containment="true" - * @generated - */ - public EList<XmlStructConverter> getStructConverters() - { - if (structConverters == null) - { - structConverters = new EObjectContainmentEList<XmlStructConverter>(XmlStructConverter.class, this, EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS); - } - return structConverters; - } - - /** - * Returns the value of the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Copy Policy</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>Copy Policy</em>' containment reference. - * @see #setCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable_CopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCopyPolicy() - { - return copyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCopyPolicy(XmlCopyPolicy newCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCopyPolicy = copyPolicy; - copyPolicy = newCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY, oldCopyPolicy, newCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCopyPolicy <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Copy Policy</em>' containment reference. - * @see #getCopyPolicy() - * @generated - */ - public void setCopyPolicy(XmlCopyPolicy newCopyPolicy) - { - if (newCopyPolicy != copyPolicy) - { - NotificationChain msgs = null; - if (copyPolicy != null) - msgs = ((InternalEObject)copyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY, null, msgs); - if (newCopyPolicy != null) - msgs = ((InternalEObject)newCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY, null, msgs); - msgs = basicSetCopyPolicy(newCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY, newCopyPolicy, newCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Instantiation Copy Policy</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>Instantiation Copy Policy</em>' containment reference. - * @see #setInstantiationCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable_InstantiationCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getInstantiationCopyPolicy() - { - return instantiationCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldInstantiationCopyPolicy = instantiationCopyPolicy; - instantiationCopyPolicy = newInstantiationCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY, oldInstantiationCopyPolicy, newInstantiationCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Instantiation Copy Policy</em>' containment reference. - * @see #getInstantiationCopyPolicy() - * @generated - */ - public void setInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy) - { - if (newInstantiationCopyPolicy != instantiationCopyPolicy) - { - NotificationChain msgs = null; - if (instantiationCopyPolicy != null) - msgs = ((InternalEObject)instantiationCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY, null, msgs); - if (newInstantiationCopyPolicy != null) - msgs = ((InternalEObject)newInstantiationCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY, null, msgs); - msgs = basicSetInstantiationCopyPolicy(newInstantiationCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY, newInstantiationCopyPolicy, newInstantiationCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Clone Copy Policy</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>Clone Copy Policy</em>' containment reference. - * @see #setCloneCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable_CloneCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCloneCopyPolicy() - { - return cloneCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCloneCopyPolicy = cloneCopyPolicy; - cloneCopyPolicy = newCloneCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY, oldCloneCopyPolicy, newCloneCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getCloneCopyPolicy <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Clone Copy Policy</em>' containment reference. - * @see #getCloneCopyPolicy() - * @generated - */ - public void setCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy) - { - if (newCloneCopyPolicy != cloneCopyPolicy) - { - NotificationChain msgs = null; - if (cloneCopyPolicy != null) - msgs = ((InternalEObject)cloneCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY, null, msgs); - if (newCloneCopyPolicy != null) - msgs = ((InternalEObject)newCloneCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY, null, msgs); - msgs = basicSetCloneCopyPolicy(newCloneCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY, newCloneCopyPolicy, newCloneCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Exclude Default Mappings</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #setExcludeDefaultMappings(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddable_ExcludeDefaultMappings() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getExcludeDefaultMappings() - { - return excludeDefaultMappings; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddable#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #getExcludeDefaultMappings() - * @generated - */ - public void setExcludeDefaultMappings(Boolean newExcludeDefaultMappings) - { - Boolean oldExcludeDefaultMappings = excludeDefaultMappings; - excludeDefaultMappings = newExcludeDefaultMappings; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS, oldExcludeDefaultMappings, excludeDefaultMappings)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: - return basicSetCustomizer(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: - return basicSetChangeTracking(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: - return ((InternalEList<?>)getConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: - return ((InternalEList<?>)getTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: - return ((InternalEList<?>)getObjectTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: - return ((InternalEList<?>)getStructConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY: - return basicSetCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY: - return basicSetInstantiationCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY: - return basicSetCloneCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: - return getCustomizer(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: - return getChangeTracking(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: - return getConverters(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: - return getTypeConverters(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: - return getObjectTypeConverters(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: - return getStructConverters(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY: - return getCopyPolicy(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY: - return getInstantiationCopyPolicy(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY: - return getCloneCopyPolicy(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES: - return getProperties(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS: - return getExcludeDefaultMappings(); - } - 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 EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: - setCustomizer((XmlCustomizer)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: - getConverters().clear(); - getConverters().addAll((Collection<? extends XmlConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: - getTypeConverters().clear(); - getTypeConverters().addAll((Collection<? extends XmlTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - getObjectTypeConverters().addAll((Collection<? extends XmlObjectTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: - getStructConverters().clear(); - getStructConverters().addAll((Collection<? extends XmlStructConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: - setCustomizer((XmlCustomizer)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: - getConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: - getTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: - getStructConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES: - getProperties().clear(); - return; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings(EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: - return customizer != null; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: - return changeTracking != null; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: - return converters != null && !converters.isEmpty(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: - return typeConverters != null && !typeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: - return objectTypeConverters != null && !objectTypeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: - return structConverters != null && !structConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__COPY_POLICY: - return copyPolicy != null; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__INSTANTIATION_COPY_POLICY: - return instantiationCopyPolicy != null; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CLONE_COPY_POLICY: - return cloneCopyPolicy != null; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__PROPERTIES: - return properties != null && !properties.isEmpty(); - case EclipseLinkOrmPackage.XML_EMBEDDABLE__EXCLUDE_DEFAULT_MAPPINGS: - return EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT == null ? excludeDefaultMappings != null : !EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT.equals(excludeDefaultMappings); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlCustomizerHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER: return EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS; - 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 == XmlCustomizerHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER: return EclipseLinkOrmPackage.XML_EMBEDDABLE__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_EMBEDDABLE__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS: return EclipseLinkOrmPackage.XML_EMBEDDABLE__CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_EMBEDDABLE__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_EMBEDDABLE__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_EMBEDDABLE__STRUCT_CONVERTERS; - 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(" (excludeDefaultMappings: "); - result.append(excludeDefaultMappings); - result.append(')'); - return result.toString(); - } - -} // XmlEmbeddable diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbedded.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbedded.java deleted file mode 100644 index 9f8082833b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbedded.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Embedded</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbedded#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbedded() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlEmbedded extends org.eclipse.jpt.core.resource.orm.XmlEmbedded, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbedded_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlEmbedded diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedId.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedId.java deleted file mode 100644 index c8f8d1b893..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedId.java +++ /dev/null @@ -1,49 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Embedded Id</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedId#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedId() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlEmbeddedId extends org.eclipse.jpt.core.resource.orm.XmlEmbeddedId, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedId_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlEmbeddedId diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedIdImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedIdImpl.java deleted file mode 100644 index 271de1516e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedIdImpl.java +++ /dev/null @@ -1,310 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Embedded Id Impl</b></em>'. - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedIdImpl() - * @model kind="class" - * @generated - */ -public class XmlEmbeddedIdImpl extends org.eclipse.jpt.core.resource.orm.XmlEmbeddedIdImpl implements XmlEmbeddedId -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlEmbeddedIdImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_EMBEDDED_ID_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedIdImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedId_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlEmbeddedId.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_EMBEDDED_ID__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlEmbeddedId.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_ID__PROPERTIES: return EclipseLinkOrmPackage.XML_EMBEDDED_ID_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -} // XmlEmbeddedIdImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedImpl.java deleted file mode 100644 index b100959172..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEmbeddedImpl.java +++ /dev/null @@ -1,310 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Embedded Impl</b></em>'. - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbeddedImpl() - * @model kind="class" - * @generated - */ -public class XmlEmbeddedImpl extends org.eclipse.jpt.core.resource.orm.XmlEmbeddedImpl implements XmlEmbedded -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlEmbeddedImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_EMBEDDED_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEmbeddedImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEmbedded_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlEmbedded.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_EMBEDDED__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlEmbedded.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_EMBEDDED__PROPERTIES: return EclipseLinkOrmPackage.XML_EMBEDDED_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -} // XmlEmbeddedImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntity.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntity.java deleted file mode 100644 index a2eb438448..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntity.java +++ /dev/null @@ -1,1331 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Oracle - initial API and implementation - *******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Entity</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getOptimisticLocking <em>Optimistic Locking</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCopyPolicy <em>Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCloneCopyPolicy <em>Clone Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getNamedStoredProcedureQueries <em>Named Stored Procedure Queries</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getProperties <em>Properties</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity() - * @model kind="class" - * @generated - */ -public class XmlEntity extends org.eclipse.jpt.core.resource.orm.XmlEntity implements XmlReadOnly, XmlCustomizerHolder, XmlChangeTrackingHolder, XmlCacheHolder, XmlConvertersHolder -{ - /** - * The default value of the '{@link #getReadOnly() <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReadOnly() - * @generated - * @ordered - */ - protected static final Boolean READ_ONLY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getReadOnly() <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReadOnly() - * @generated - * @ordered - */ - protected Boolean readOnly = READ_ONLY_EDEFAULT; - - /** - * The cached value of the '{@link #getCustomizer() <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCustomizer() - * @generated - * @ordered - */ - protected XmlCustomizer customizer; - - /** - * The cached value of the '{@link #getChangeTracking() <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getChangeTracking() - * @generated - * @ordered - */ - protected XmlChangeTracking changeTracking; - - /** - * The cached value of the '{@link #getCache() <em>Cache</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCache() - * @generated - * @ordered - */ - protected XmlCache cache; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final ExistenceType EXISTENCE_CHECKING_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExistenceChecking() <em>Existence Checking</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExistenceChecking() - * @generated - * @ordered - */ - protected ExistenceType existenceChecking = EXISTENCE_CHECKING_EDEFAULT; - - /** - * The cached value of the '{@link #getConverters() <em>Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverters() - * @generated - * @ordered - */ - protected EList<XmlConverter> converters; - - /** - * The cached value of the '{@link #getTypeConverters() <em>Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlTypeConverter> typeConverters; - - /** - * The cached value of the '{@link #getObjectTypeConverters() <em>Object Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlObjectTypeConverter> objectTypeConverters; - - /** - * The cached value of the '{@link #getStructConverters() <em>Struct Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverters() - * @generated - * @ordered - */ - protected EList<XmlStructConverter> structConverters; - - /** - * The cached value of the '{@link #getOptimisticLocking() <em>Optimistic Locking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getOptimisticLocking() - * @generated - * @ordered - */ - protected XmlOptimisticLocking optimisticLocking; - - /** - * The cached value of the '{@link #getCopyPolicy() <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy copyPolicy; - - /** - * The cached value of the '{@link #getInstantiationCopyPolicy() <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getInstantiationCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy instantiationCopyPolicy; - - /** - * The cached value of the '{@link #getCloneCopyPolicy() <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCloneCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy cloneCopyPolicy; - - /** - * The cached value of the '{@link #getNamedStoredProcedureQueries() <em>Named Stored Procedure Queries</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getNamedStoredProcedureQueries() - * @generated - * @ordered - */ - protected EList<XmlNamedStoredProcedureQuery> namedStoredProcedureQueries; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * The default value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected static final Boolean EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected Boolean excludeDefaultMappings = EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlEntity() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ENTITY; - } - - /** - * 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.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly_ReadOnly() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getReadOnly() - { - return readOnly; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getReadOnly <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Read Only</em>' attribute. - * @see #getReadOnly() - * @generated - */ - public void setReadOnly(Boolean newReadOnly) - { - Boolean oldReadOnly = readOnly; - readOnly = newReadOnly; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY, oldReadOnly, readOnly)); - } - - /** - * Returns the value of the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Customizer</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>Customizer</em>' containment reference. - * @see #setCustomizer(XmlCustomizer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder_Customizer() - * @model containment="true" - * @generated - */ - public XmlCustomizer getCustomizer() - { - return customizer; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCustomizer(XmlCustomizer newCustomizer, NotificationChain msgs) - { - XmlCustomizer oldCustomizer = customizer; - customizer = newCustomizer; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER, oldCustomizer, newCustomizer); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCustomizer <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Customizer</em>' containment reference. - * @see #getCustomizer() - * @generated - */ - public void setCustomizer(XmlCustomizer newCustomizer) - { - if (newCustomizer != customizer) - { - NotificationChain msgs = null; - if (customizer != null) - msgs = ((InternalEObject)customizer).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER, null, msgs); - if (newCustomizer != null) - msgs = ((InternalEObject)newCustomizer).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER, null, msgs); - msgs = basicSetCustomizer(newCustomizer, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER, newCustomizer, newCustomizer)); - } - - /** - * Returns the value of the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Change Tracking</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>Change Tracking</em>' containment reference. - * @see #setChangeTracking(XmlChangeTracking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder_ChangeTracking() - * @model containment="true" - * @generated - */ - public XmlChangeTracking getChangeTracking() - { - return changeTracking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetChangeTracking(XmlChangeTracking newChangeTracking, NotificationChain msgs) - { - XmlChangeTracking oldChangeTracking = changeTracking; - changeTracking = newChangeTracking; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING, oldChangeTracking, newChangeTracking); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getChangeTracking <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Change Tracking</em>' containment reference. - * @see #getChangeTracking() - * @generated - */ - public void setChangeTracking(XmlChangeTracking newChangeTracking) - { - if (newChangeTracking != changeTracking) - { - NotificationChain msgs = null; - if (changeTracking != null) - msgs = ((InternalEObject)changeTracking).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING, null, msgs); - if (newChangeTracking != null) - msgs = ((InternalEObject)newChangeTracking).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING, null, msgs); - msgs = basicSetChangeTracking(newChangeTracking, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING, newChangeTracking, newChangeTracking)); - } - - /** - * Returns the value of the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Cache</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>Cache</em>' containment reference. - * @see #setCache(XmlCache) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_Cache() - * @model containment="true" - * @generated - */ - public XmlCache getCache() - { - return cache; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCache(XmlCache newCache, NotificationChain msgs) - { - XmlCache oldCache = cache; - cache = newCache; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CACHE, oldCache, newCache); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCache <em>Cache</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Cache</em>' containment reference. - * @see #getCache() - * @generated - */ - public void setCache(XmlCache newCache) - { - if (newCache != cache) - { - NotificationChain msgs = null; - if (cache != null) - msgs = ((InternalEObject)cache).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CACHE, null, msgs); - if (newCache != null) - msgs = ((InternalEObject)newCache).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CACHE, null, msgs); - msgs = basicSetCache(newCache, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CACHE, newCache, newCache)); - } - - /** - * Returns the value of the '<em><b>Existence Checking</b></em>' attribute. - * The default value is <code>""</code>. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Existence Checking</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #setExistenceChecking(ExistenceType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_ExistenceChecking() - * @model default="" - * @generated - */ - public ExistenceType getExistenceChecking() - { - return existenceChecking; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getExistenceChecking <em>Existence Checking</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #getExistenceChecking() - * @generated - */ - public void setExistenceChecking(ExistenceType newExistenceChecking) - { - ExistenceType oldExistenceChecking = existenceChecking; - existenceChecking = newExistenceChecking == null ? EXISTENCE_CHECKING_EDEFAULT : newExistenceChecking; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING, oldExistenceChecking, existenceChecking)); - } - - /** - * Returns the value of the '<em><b>Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Converters</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>Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_Converters() - * @model containment="true" - * @generated - */ - public EList<XmlConverter> getConverters() - { - if (converters == null) - { - converters = new EObjectContainmentEList<XmlConverter>(XmlConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS); - } - return converters; - } - - /** - * Returns the value of the '<em><b>Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type Converters</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>Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_TypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlTypeConverter> getTypeConverters() - { - if (typeConverters == null) - { - typeConverters = new EObjectContainmentEList<XmlTypeConverter>(XmlTypeConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS); - } - return typeConverters; - } - - /** - * Returns the value of the '<em><b>Object Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type Converters</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>Object Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_ObjectTypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlObjectTypeConverter> getObjectTypeConverters() - { - if (objectTypeConverters == null) - { - objectTypeConverters = new EObjectContainmentEList<XmlObjectTypeConverter>(XmlObjectTypeConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS); - } - return objectTypeConverters; - } - - /** - * Returns the value of the '<em><b>Struct Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct Converters</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>Struct Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_StructConverters() - * @model containment="true" - * @generated - */ - public EList<XmlStructConverter> getStructConverters() - { - if (structConverters == null) - { - structConverters = new EObjectContainmentEList<XmlStructConverter>(XmlStructConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS); - } - return structConverters; - } - - /** - * Returns the value of the '<em><b>Optimistic Locking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Optimistic Locking</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>Optimistic Locking</em>' containment reference. - * @see #setOptimisticLocking(XmlOptimisticLocking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_OptimisticLocking() - * @model containment="true" - * @generated - */ - public XmlOptimisticLocking getOptimisticLocking() - { - return optimisticLocking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetOptimisticLocking(XmlOptimisticLocking newOptimisticLocking, NotificationChain msgs) - { - XmlOptimisticLocking oldOptimisticLocking = optimisticLocking; - optimisticLocking = newOptimisticLocking; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING, oldOptimisticLocking, newOptimisticLocking); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getOptimisticLocking <em>Optimistic Locking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Optimistic Locking</em>' containment reference. - * @see #getOptimisticLocking() - * @generated - */ - public void setOptimisticLocking(XmlOptimisticLocking newOptimisticLocking) - { - if (newOptimisticLocking != optimisticLocking) - { - NotificationChain msgs = null; - if (optimisticLocking != null) - msgs = ((InternalEObject)optimisticLocking).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING, null, msgs); - if (newOptimisticLocking != null) - msgs = ((InternalEObject)newOptimisticLocking).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING, null, msgs); - msgs = basicSetOptimisticLocking(newOptimisticLocking, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING, newOptimisticLocking, newOptimisticLocking)); - } - - /** - * Returns the value of the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Copy Policy</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>Copy Policy</em>' containment reference. - * @see #setCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_CopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCopyPolicy() - { - return copyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCopyPolicy(XmlCopyPolicy newCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCopyPolicy = copyPolicy; - copyPolicy = newCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY, oldCopyPolicy, newCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCopyPolicy <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Copy Policy</em>' containment reference. - * @see #getCopyPolicy() - * @generated - */ - public void setCopyPolicy(XmlCopyPolicy newCopyPolicy) - { - if (newCopyPolicy != copyPolicy) - { - NotificationChain msgs = null; - if (copyPolicy != null) - msgs = ((InternalEObject)copyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY, null, msgs); - if (newCopyPolicy != null) - msgs = ((InternalEObject)newCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY, null, msgs); - msgs = basicSetCopyPolicy(newCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY, newCopyPolicy, newCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Instantiation Copy Policy</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>Instantiation Copy Policy</em>' containment reference. - * @see #setInstantiationCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_InstantiationCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getInstantiationCopyPolicy() - { - return instantiationCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldInstantiationCopyPolicy = instantiationCopyPolicy; - instantiationCopyPolicy = newInstantiationCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY, oldInstantiationCopyPolicy, newInstantiationCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Instantiation Copy Policy</em>' containment reference. - * @see #getInstantiationCopyPolicy() - * @generated - */ - public void setInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy) - { - if (newInstantiationCopyPolicy != instantiationCopyPolicy) - { - NotificationChain msgs = null; - if (instantiationCopyPolicy != null) - msgs = ((InternalEObject)instantiationCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY, null, msgs); - if (newInstantiationCopyPolicy != null) - msgs = ((InternalEObject)newInstantiationCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY, null, msgs); - msgs = basicSetInstantiationCopyPolicy(newInstantiationCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY, newInstantiationCopyPolicy, newInstantiationCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Clone Copy Policy</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>Clone Copy Policy</em>' containment reference. - * @see #setCloneCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_CloneCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCloneCopyPolicy() - { - return cloneCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCloneCopyPolicy = cloneCopyPolicy; - cloneCopyPolicy = newCloneCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY, oldCloneCopyPolicy, newCloneCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getCloneCopyPolicy <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Clone Copy Policy</em>' containment reference. - * @see #getCloneCopyPolicy() - * @generated - */ - public void setCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy) - { - if (newCloneCopyPolicy != cloneCopyPolicy) - { - NotificationChain msgs = null; - if (cloneCopyPolicy != null) - msgs = ((InternalEObject)cloneCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY, null, msgs); - if (newCloneCopyPolicy != null) - msgs = ((InternalEObject)newCloneCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY, null, msgs); - msgs = basicSetCloneCopyPolicy(newCloneCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY, newCloneCopyPolicy, newCloneCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Named Stored Procedure Queries</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>Named Stored Procedure Queries</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_NamedStoredProcedureQueries() - * @model containment="true" - * @generated - */ - public EList<XmlNamedStoredProcedureQuery> getNamedStoredProcedureQueries() - { - if (namedStoredProcedureQueries == null) - { - namedStoredProcedureQueries = new EObjectContainmentEList<XmlNamedStoredProcedureQuery>(XmlNamedStoredProcedureQuery.class, this, EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES); - } - return namedStoredProcedureQueries; - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Exclude Default Mappings</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #setExcludeDefaultMappings(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntity_ExcludeDefaultMappings() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getExcludeDefaultMappings() - { - return excludeDefaultMappings; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntity#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #getExcludeDefaultMappings() - * @generated - */ - public void setExcludeDefaultMappings(Boolean newExcludeDefaultMappings) - { - Boolean oldExcludeDefaultMappings = excludeDefaultMappings; - excludeDefaultMappings = newExcludeDefaultMappings; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS, oldExcludeDefaultMappings, excludeDefaultMappings)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: - return basicSetCustomizer(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: - return basicSetChangeTracking(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: - return basicSetCache(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: - return ((InternalEList<?>)getConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: - return ((InternalEList<?>)getTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: - return ((InternalEList<?>)getObjectTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: - return ((InternalEList<?>)getStructConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING: - return basicSetOptimisticLocking(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY: - return basicSetCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY: - return basicSetInstantiationCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY: - return basicSetCloneCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES: - return ((InternalEList<?>)getNamedStoredProcedureQueries()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY: - return getReadOnly(); - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: - return getCustomizer(); - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: - return getChangeTracking(); - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: - return getCache(); - case EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING: - return getExistenceChecking(); - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: - return getConverters(); - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: - return getTypeConverters(); - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: - return getObjectTypeConverters(); - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: - return getStructConverters(); - case EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING: - return getOptimisticLocking(); - case EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY: - return getCopyPolicy(); - case EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY: - return getInstantiationCopyPolicy(); - case EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY: - return getCloneCopyPolicy(); - case EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES: - return getNamedStoredProcedureQueries(); - case EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES: - return getProperties(); - case EclipseLinkOrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS: - return getExcludeDefaultMappings(); - } - 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 EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY: - setReadOnly((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: - setCustomizer((XmlCustomizer)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: - setCache((XmlCache)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING: - setExistenceChecking((ExistenceType)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: - getConverters().clear(); - getConverters().addAll((Collection<? extends XmlConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: - getTypeConverters().clear(); - getTypeConverters().addAll((Collection<? extends XmlTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - getObjectTypeConverters().addAll((Collection<? extends XmlObjectTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: - getStructConverters().clear(); - getStructConverters().addAll((Collection<? extends XmlStructConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING: - setOptimisticLocking((XmlOptimisticLocking)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES: - getNamedStoredProcedureQueries().clear(); - getNamedStoredProcedureQueries().addAll((Collection<? extends XmlNamedStoredProcedureQuery>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY: - setReadOnly(READ_ONLY_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: - setCustomizer((XmlCustomizer)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: - setCache((XmlCache)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING: - setExistenceChecking(EXISTENCE_CHECKING_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: - getConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: - getTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: - getStructConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING: - setOptimisticLocking((XmlOptimisticLocking)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES: - getNamedStoredProcedureQueries().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES: - getProperties().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings(EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY: - return READ_ONLY_EDEFAULT == null ? readOnly != null : !READ_ONLY_EDEFAULT.equals(readOnly); - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: - return customizer != null; - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: - return changeTracking != null; - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: - return cache != null; - case EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING: - return existenceChecking != EXISTENCE_CHECKING_EDEFAULT; - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: - return converters != null && !converters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: - return typeConverters != null && !typeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: - return objectTypeConverters != null && !objectTypeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: - return structConverters != null && !structConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__OPTIMISTIC_LOCKING: - return optimisticLocking != null; - case EclipseLinkOrmPackage.XML_ENTITY__COPY_POLICY: - return copyPolicy != null; - case EclipseLinkOrmPackage.XML_ENTITY__INSTANTIATION_COPY_POLICY: - return instantiationCopyPolicy != null; - case EclipseLinkOrmPackage.XML_ENTITY__CLONE_COPY_POLICY: - return cloneCopyPolicy != null; - case EclipseLinkOrmPackage.XML_ENTITY__NAMED_STORED_PROCEDURE_QUERIES: - return namedStoredProcedureQueries != null && !namedStoredProcedureQueries.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__PROPERTIES: - return properties != null && !properties.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY__EXCLUDE_DEFAULT_MAPPINGS: - return EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT == null ? excludeDefaultMappings != null : !EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT.equals(excludeDefaultMappings); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlReadOnly.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY: return EclipseLinkOrmPackage.XML_READ_ONLY__READ_ONLY; - default: return -1; - } - } - if (baseClass == XmlCustomizerHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER: return EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlCacheHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__CACHE: return EclipseLinkOrmPackage.XML_CACHE_HOLDER__CACHE; - case EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING: return EclipseLinkOrmPackage.XML_CACHE_HOLDER__EXISTENCE_CHECKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS; - 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 == XmlReadOnly.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_READ_ONLY__READ_ONLY: return EclipseLinkOrmPackage.XML_ENTITY__READ_ONLY; - default: return -1; - } - } - if (baseClass == XmlCustomizerHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER: return EclipseLinkOrmPackage.XML_ENTITY__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_ENTITY__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlCacheHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CACHE_HOLDER__CACHE: return EclipseLinkOrmPackage.XML_ENTITY__CACHE; - case EclipseLinkOrmPackage.XML_CACHE_HOLDER__EXISTENCE_CHECKING: return EclipseLinkOrmPackage.XML_ENTITY__EXISTENCE_CHECKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY__CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY__STRUCT_CONVERTERS; - 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(" (readOnly: "); - result.append(readOnly); - result.append(", existenceChecking: "); - result.append(existenceChecking); - result.append(", excludeDefaultMappings: "); - result.append(excludeDefaultMappings); - result.append(')'); - return result.toString(); - } - - public TextRange getReadOnlyTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.READ_ONLY); - } -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntityMappings.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntityMappings.java deleted file mode 100644 index 5fe9886a7e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlEntityMappings.java +++ /dev/null @@ -1,415 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Collection; -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.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Entity Mappings</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlEntityMappings#getNamedStoredProcedureQueries <em>Named Stored Procedure Queries</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntityMappings() - * @model kind="class" - * @generated - */ -public class XmlEntityMappings extends org.eclipse.jpt.core.resource.orm.XmlEntityMappings implements XmlConvertersHolder -{ - /** - * The cached value of the '{@link #getConverters() <em>Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverters() - * @generated - * @ordered - */ - protected EList<XmlConverter> converters; - - /** - * The cached value of the '{@link #getTypeConverters() <em>Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlTypeConverter> typeConverters; - - /** - * The cached value of the '{@link #getObjectTypeConverters() <em>Object Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlObjectTypeConverter> objectTypeConverters; - - /** - * The cached value of the '{@link #getStructConverters() <em>Struct Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverters() - * @generated - * @ordered - */ - protected EList<XmlStructConverter> structConverters; - - /** - * The cached value of the '{@link #getNamedStoredProcedureQueries() <em>Named Stored Procedure Queries</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getNamedStoredProcedureQueries() - * @generated - * @ordered - */ - protected EList<XmlNamedStoredProcedureQuery> namedStoredProcedureQueries; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlEntityMappings() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ENTITY_MAPPINGS; - } - - /** - * Returns the value of the '<em><b>Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Converters</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>Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_Converters() - * @model containment="true" - * @generated - */ - public EList<XmlConverter> getConverters() - { - if (converters == null) - { - converters = new EObjectContainmentEList<XmlConverter>(XmlConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS); - } - return converters; - } - - /** - * Returns the value of the '<em><b>Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type Converters</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>Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_TypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlTypeConverter> getTypeConverters() - { - if (typeConverters == null) - { - typeConverters = new EObjectContainmentEList<XmlTypeConverter>(XmlTypeConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS); - } - return typeConverters; - } - - /** - * Returns the value of the '<em><b>Object Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type Converters</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>Object Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_ObjectTypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlObjectTypeConverter> getObjectTypeConverters() - { - if (objectTypeConverters == null) - { - objectTypeConverters = new EObjectContainmentEList<XmlObjectTypeConverter>(XmlObjectTypeConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS); - } - return objectTypeConverters; - } - - /** - * Returns the value of the '<em><b>Struct Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct Converters</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>Struct Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_StructConverters() - * @model containment="true" - * @generated - */ - public EList<XmlStructConverter> getStructConverters() - { - if (structConverters == null) - { - structConverters = new EObjectContainmentEList<XmlStructConverter>(XmlStructConverter.class, this, EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS); - } - return structConverters; - } - - /** - * Returns the value of the '<em><b>Named Stored Procedure Queries</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Named Stored Procedure Queries</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>Named Stored Procedure Queries</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlEntityMappings_NamedStoredProcedureQueries() - * @model containment="true" - * @generated - */ - public EList<XmlNamedStoredProcedureQuery> getNamedStoredProcedureQueries() - { - if (namedStoredProcedureQueries == null) - { - namedStoredProcedureQueries = new EObjectContainmentEList<XmlNamedStoredProcedureQuery>(XmlNamedStoredProcedureQuery.class, this, EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES); - } - return namedStoredProcedureQueries; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: - return ((InternalEList<?>)getConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: - return ((InternalEList<?>)getTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: - return ((InternalEList<?>)getObjectTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: - return ((InternalEList<?>)getStructConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES: - return ((InternalEList<?>)getNamedStoredProcedureQueries()).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 EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: - return getConverters(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: - return getTypeConverters(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: - return getObjectTypeConverters(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: - return getStructConverters(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES: - return getNamedStoredProcedureQueries(); - } - 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 EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: - getConverters().clear(); - getConverters().addAll((Collection<? extends XmlConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: - getTypeConverters().clear(); - getTypeConverters().addAll((Collection<? extends XmlTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - getObjectTypeConverters().addAll((Collection<? extends XmlObjectTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: - getStructConverters().clear(); - getStructConverters().addAll((Collection<? extends XmlStructConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES: - getNamedStoredProcedureQueries().clear(); - getNamedStoredProcedureQueries().addAll((Collection<? extends XmlNamedStoredProcedureQuery>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: - getConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: - getTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: - getStructConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES: - getNamedStoredProcedureQueries().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: - return converters != null && !converters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: - return typeConverters != null && !typeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: - return objectTypeConverters != null && !objectTypeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: - return structConverters != null && !structConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__NAMED_STORED_PROCEDURE_QUERIES: - return namedStoredProcedureQueries != null && !namedStoredProcedureQueries.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlConvertersHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS; - 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 == XmlConvertersHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_ENTITY_MAPPINGS__STRUCT_CONVERTERS; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - -} // XmlEntityMappings diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlId.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlId.java deleted file mode 100644 index 388162705e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlId.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Id</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlId#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlId() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlId extends org.eclipse.jpt.core.resource.orm.XmlId, XmlMutable, XmlConvertibleMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlId_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlId diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlIdImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlIdImpl.java deleted file mode 100644 index 87adaa9b39..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlIdImpl.java +++ /dev/null @@ -1,859 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Id</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlIdImpl() - * @model kind="class" - * @generated - */ -public class XmlIdImpl extends org.eclipse.jpt.core.resource.orm.XmlIdImpl implements XmlId -{ - /** - * The default value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected static final Boolean MUTABLE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected Boolean mutable = MUTABLE_EDEFAULT; - - /** - * The cached value of the '{@link #getConverter() <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverter() - * @generated - * @ordered - */ - protected XmlConverter converter; - - /** - * The cached value of the '{@link #getTypeConverter() <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverter() - * @generated - * @ordered - */ - protected XmlTypeConverter typeConverter; - - /** - * The cached value of the '{@link #getObjectTypeConverter() <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverter() - * @generated - * @ordered - */ - protected XmlObjectTypeConverter objectTypeConverter; - - /** - * The cached value of the '{@link #getStructConverter() <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverter() - * @generated - * @ordered - */ - protected XmlStructConverter structConverter; - - /** - * The default value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected static final String CONVERT_EDEFAULT = null; - - /** - * The cached value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected String convert = CONVERT_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlIdImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ID_IMPL; - } - - /** - * Returns the value of the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Mutable</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Mutable</em>' attribute. - * @see #setMutable(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable_Mutable() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getMutable() - { - return mutable; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getMutable <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Mutable</em>' attribute. - * @see #getMutable() - * @generated - */ - public void setMutable(Boolean newMutable) - { - Boolean oldMutable = mutable; - mutable = newMutable; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE, oldMutable, mutable)); - } - - /** - * Returns the value of the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Convert</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Convert</em>' attribute. - * @see #setConvert(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping_Convert() - * @model - * @generated - */ - public String getConvert() - { - return convert; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getConvert <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Convert</em>' attribute. - * @see #getConvert() - * @generated - */ - public void setConvert(String newConvert) - { - String oldConvert = convert; - convert = newConvert; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT, oldConvert, convert)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlId_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</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>Converter</em>' containment reference. - * @see #setConverter(XmlConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_Converter() - * @model containment="true" - * @generated - */ - public XmlConverter getConverter() - { - return converter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetConverter(XmlConverter newConverter, NotificationChain msgs) - { - XmlConverter oldConverter = converter; - converter = newConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER, oldConverter, newConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getConverter <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' containment reference. - * @see #getConverter() - * @generated - */ - public void setConverter(XmlConverter newConverter) - { - if (newConverter != converter) - { - NotificationChain msgs = null; - if (converter != null) - msgs = ((InternalEObject)converter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER, null, msgs); - if (newConverter != null) - msgs = ((InternalEObject)newConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER, null, msgs); - msgs = basicSetConverter(newConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER, newConverter, newConverter)); - } - - /** - * Returns the value of the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type CustomConverter</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>Type Converter</em>' containment reference. - * @see #setTypeConverter(XmlTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_TypeConverter() - * @model containment="true" - * @generated - */ - public XmlTypeConverter getTypeConverter() - { - return typeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetTypeConverter(XmlTypeConverter newTypeConverter, NotificationChain msgs) - { - XmlTypeConverter oldTypeConverter = typeConverter; - typeConverter = newTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER, oldTypeConverter, newTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getTypeConverter <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type Converter</em>' containment reference. - * @see #getTypeConverter() - * @generated - */ - public void setTypeConverter(XmlTypeConverter newTypeConverter) - { - if (newTypeConverter != typeConverter) - { - NotificationChain msgs = null; - if (typeConverter != null) - msgs = ((InternalEObject)typeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER, null, msgs); - if (newTypeConverter != null) - msgs = ((InternalEObject)newTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER, null, msgs); - msgs = basicSetTypeConverter(newTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER, newTypeConverter, newTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type CustomConverter</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>Object Type Converter</em>' containment reference. - * @see #setObjectTypeConverter(XmlObjectTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_ObjectTypeConverter() - * @model containment="true" - * @generated - */ - public XmlObjectTypeConverter getObjectTypeConverter() - { - return objectTypeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter, NotificationChain msgs) - { - XmlObjectTypeConverter oldObjectTypeConverter = objectTypeConverter; - objectTypeConverter = newObjectTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER, oldObjectTypeConverter, newObjectTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getObjectTypeConverter <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type Converter</em>' containment reference. - * @see #getObjectTypeConverter() - * @generated - */ - public void setObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter) - { - if (newObjectTypeConverter != objectTypeConverter) - { - NotificationChain msgs = null; - if (objectTypeConverter != null) - msgs = ((InternalEObject)objectTypeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - if (newObjectTypeConverter != null) - msgs = ((InternalEObject)newObjectTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - msgs = basicSetObjectTypeConverter(newObjectTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER, newObjectTypeConverter, newObjectTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct CustomConverter</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>Struct Converter</em>' containment reference. - * @see #setStructConverter(XmlStructConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_StructConverter() - * @model containment="true" - * @generated - */ - public XmlStructConverter getStructConverter() - { - return structConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetStructConverter(XmlStructConverter newStructConverter, NotificationChain msgs) - { - XmlStructConverter oldStructConverter = structConverter; - structConverter = newStructConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER, oldStructConverter, newStructConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlIdImpl#getStructConverter <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Struct Converter</em>' containment reference. - * @see #getStructConverter() - * @generated - */ - public void setStructConverter(XmlStructConverter newStructConverter) - { - if (newStructConverter != structConverter) - { - NotificationChain msgs = null; - if (structConverter != null) - msgs = ((InternalEObject)structConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER, null, msgs); - if (newStructConverter != null) - msgs = ((InternalEObject)newStructConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER, null, msgs); - msgs = basicSetStructConverter(newStructConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER, newStructConverter, newStructConverter)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: - return basicSetConverter(null, msgs); - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: - return basicSetTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: - return basicSetObjectTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: - return basicSetStructConverter(null, msgs); - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE: - return getMutable(); - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: - return getConverter(); - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: - return getTypeConverter(); - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: - return getObjectTypeConverter(); - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: - return getStructConverter(); - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT: - return getConvert(); - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE: - setMutable((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: - setConverter((XmlConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT: - setConvert((String)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE: - setMutable(MUTABLE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: - setConverter((XmlConverter)null); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)null); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT: - setConvert(CONVERT_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE: - return MUTABLE_EDEFAULT == null ? mutable != null : !MUTABLE_EDEFAULT.equals(mutable); - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: - return converter != null; - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: - return typeConverter != null; - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: - return objectTypeConverter != null; - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: - return structConverter != null; - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT: - return CONVERT_EDEFAULT == null ? convert != null : !CONVERT_EDEFAULT.equals(convert); - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlMutable.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE: return EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER; - case EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT: return EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlId.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ID_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_ID__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 == XmlMutable.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE: return EclipseLinkOrmPackage.XML_ID_IMPL__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER: return EclipseLinkOrmPackage.XML_ID_IMPL__CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_ID_IMPL__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_ID_IMPL__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_ID_IMPL__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT: return EclipseLinkOrmPackage.XML_ID_IMPL__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ID_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlId.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ID__PROPERTIES: return EclipseLinkOrmPackage.XML_ID_IMPL__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(" (mutable: "); - result.append(mutable); - result.append(", convert: "); - result.append(convert); - result.append(')'); - return result.toString(); - } - - public TextRange getMutableTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.MUTABLE); - } - - public TextRange getConvertTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.CONVERT); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlInstantiationPolicy.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlInstantiationPolicy.java deleted file mode 100644 index b3b1263b2b..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlInstantiationPolicy.java +++ /dev/null @@ -1,61 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Instantiation Policy</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlInstantiationPolicy() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlInstantiationPolicy extends AbstractJpaEObject implements JpaEObject -{ - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlInstantiationPolicy() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_INSTANTIATION_POLICY; - } - -} // XmlInstantiationPolicy diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetch.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetch.java deleted file mode 100644 index a7e87df09c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetch.java +++ /dev/null @@ -1,75 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlJoinFetch.java,v 1.4 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Join Fetch</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch#getJoinFetch <em>Join Fetch</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlJoinFetch extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Join Fetch</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Join Fetch</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #setJoinFetch(XmlJoinFetchType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch_JoinFetch() - * @model - * @generated - */ - XmlJoinFetchType getJoinFetch(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetch#getJoinFetch <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #getJoinFetch() - * @generated - */ - void setJoinFetch(XmlJoinFetchType value); - - /** - * Return the {@link TextRange} for the join-fetch element. - */ - TextRange getJoinFetchTextRange(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetchType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetchType.java deleted file mode 100644 index 58b690ea4d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlJoinFetchType.java +++ /dev/null @@ -1,237 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlJoinFetchType.java,v 1.3 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * - * A representation of the literals of the enumeration '<em><b>Xml Join Fetch Type</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetchType() - * @model - * @generated - */ -public enum XmlJoinFetchType implements Enumerator -{ - /** - * The '<em><b>INNER</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #INNER_VALUE - * @generated - * @ordered - */ - INNER(0, "INNER", "INNER"), - - /** - * The '<em><b>OUTER</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #OUTER_VALUE - * @generated - * @ordered - */ - OUTER(1, "OUTER", "OUTER"); - - /** - * The '<em><b>INNER</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>INNER</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #INNER - * @model - * @generated - * @ordered - */ - public static final int INNER_VALUE = 0; - - /** - * The '<em><b>OUTER</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>OUTER</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #OUTER - * @model - * @generated - * @ordered - */ - public static final int OUTER_VALUE = 1; - - /** - * An array of all the '<em><b>Xml Join Fetch Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final XmlJoinFetchType[] VALUES_ARRAY = - new XmlJoinFetchType[] - { - INNER, - OUTER, - }; - - /** - * A public read-only list of all the '<em><b>Xml Join Fetch Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<XmlJoinFetchType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Xml Join Fetch Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlJoinFetchType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlJoinFetchType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Join Fetch Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlJoinFetchType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlJoinFetchType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Join Fetch Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlJoinFetchType get(int value) - { - switch (value) - { - case INNER_VALUE: return INNER; - case OUTER_VALUE: return OUTER; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private XmlJoinFetchType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //XmlJoinFetchType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToMany.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToMany.java deleted file mode 100644 index 97e072a79c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToMany.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Many To Many</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToMany#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToMany() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlManyToMany extends org.eclipse.jpt.core.resource.orm.XmlManyToMany, XmlJoinFetch, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToMany_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlManyToMany diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToManyImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToManyImpl.java deleted file mode 100644 index e1bf1ef086..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToManyImpl.java +++ /dev/null @@ -1,421 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Many To Many</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToManyImpl() - * @model kind="class" - * @generated - */ -public class XmlManyToManyImpl extends org.eclipse.jpt.core.resource.orm.XmlManyToManyImpl implements XmlManyToMany -{ - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlJoinFetchType JOIN_FETCH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJoinFetch() <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJoinFetch() - * @generated - * @ordered - */ - protected XmlJoinFetchType joinFetch = JOIN_FETCH_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlManyToManyImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_MANY_TO_MANY_IMPL; - } - - /** - * Returns the value of the '<em><b>Join Fetch</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Join Fetch</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #setJoinFetch(XmlJoinFetchType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch_JoinFetch() - * @model - * @generated - */ - public XmlJoinFetchType getJoinFetch() - { - return joinFetch; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl#getJoinFetch <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #getJoinFetch() - * @generated - */ - public void setJoinFetch(XmlJoinFetchType newJoinFetch) - { - XmlJoinFetchType oldJoinFetch = joinFetch; - joinFetch = newJoinFetch == null ? JOIN_FETCH_EDEFAULT : newJoinFetch; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH, oldJoinFetch, joinFetch)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToManyImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToMany_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH: - return getJoinFetch(); - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH: - setJoinFetch((XmlJoinFetchType)newValue); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH: - setJoinFetch(JOIN_FETCH_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH: - return joinFetch != JOIN_FETCH_EDEFAULT; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlJoinFetch.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH: return EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlManyToMany.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_MANY_TO_MANY__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 == XmlJoinFetch.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH: return EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlManyToMany.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_MANY__PROPERTIES: return EclipseLinkOrmPackage.XML_MANY_TO_MANY_IMPL__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(" (joinFetch: "); - result.append(joinFetch); - result.append(')'); - return result.toString(); - } - - public TextRange getJoinFetchTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.JOIN_FETCH); - } -} // XmlManyToMany diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOne.java deleted file mode 100644 index 606b8bc7f9..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOne.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Many To One</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOne#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOne() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlManyToOne extends org.eclipse.jpt.core.resource.orm.XmlManyToOne, XmlJoinFetch, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOne_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlManyToOne diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOneImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOneImpl.java deleted file mode 100644 index 7c1ae0fb2c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlManyToOneImpl.java +++ /dev/null @@ -1,421 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Many To One</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOneImpl() - * @model kind="class" - * @generated - */ -public class XmlManyToOneImpl extends org.eclipse.jpt.core.resource.orm.XmlManyToOneImpl implements XmlManyToOne -{ - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlJoinFetchType JOIN_FETCH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJoinFetch() <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJoinFetch() - * @generated - * @ordered - */ - protected XmlJoinFetchType joinFetch = JOIN_FETCH_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlManyToOneImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_MANY_TO_ONE_IMPL; - } - - /** - * Returns the value of the '<em><b>Join Fetch</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Join Fetch</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #setJoinFetch(XmlJoinFetchType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch_JoinFetch() - * @model - * @generated - */ - public XmlJoinFetchType getJoinFetch() - { - return joinFetch; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl#getJoinFetch <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #getJoinFetch() - * @generated - */ - public void setJoinFetch(XmlJoinFetchType newJoinFetch) - { - XmlJoinFetchType oldJoinFetch = joinFetch; - joinFetch = newJoinFetch == null ? JOIN_FETCH_EDEFAULT : newJoinFetch; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH, oldJoinFetch, joinFetch)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlManyToOneImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlManyToOne_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH: - return getJoinFetch(); - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH: - setJoinFetch((XmlJoinFetchType)newValue); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH: - setJoinFetch(JOIN_FETCH_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH: - return joinFetch != JOIN_FETCH_EDEFAULT; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlJoinFetch.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH: return EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlManyToOne.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_MANY_TO_ONE__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 == XmlJoinFetch.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH: return EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlManyToOne.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_MANY_TO_ONE__PROPERTIES: return EclipseLinkOrmPackage.XML_MANY_TO_ONE_IMPL__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(" (joinFetch: "); - result.append(joinFetch); - result.append(')'); - return result.toString(); - } - - public TextRange getJoinFetchTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.JOIN_FETCH); - } -} // XmlManyToOne diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMappedSuperclass.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMappedSuperclass.java deleted file mode 100644 index ea1cd21dc2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMappedSuperclass.java +++ /dev/null @@ -1,1283 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Mapped Superclass</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getOptimisticLocking <em>Optimistic Locking</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCopyPolicy <em>Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCloneCopyPolicy <em>Clone Copy Policy</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getProperties <em>Properties</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass() - * @model kind="class" - * @generated - */ -public class XmlMappedSuperclass extends org.eclipse.jpt.core.resource.orm.XmlMappedSuperclass implements XmlReadOnly, XmlCustomizerHolder, XmlChangeTrackingHolder, XmlCacheHolder, XmlConvertersHolder -{ - /** - * The default value of the '{@link #getReadOnly() <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReadOnly() - * @generated - * @ordered - */ - protected static final Boolean READ_ONLY_EDEFAULT = null; - - /** - * The cached value of the '{@link #getReadOnly() <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReadOnly() - * @generated - * @ordered - */ - protected Boolean readOnly = READ_ONLY_EDEFAULT; - - /** - * The cached value of the '{@link #getCustomizer() <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCustomizer() - * @generated - * @ordered - */ - protected XmlCustomizer customizer; - - /** - * The cached value of the '{@link #getChangeTracking() <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getChangeTracking() - * @generated - * @ordered - */ - protected XmlChangeTracking changeTracking; - - /** - * The cached value of the '{@link #getCache() <em>Cache</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCache() - * @generated - * @ordered - */ - protected XmlCache cache; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final ExistenceType EXISTENCE_CHECKING_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExistenceChecking() <em>Existence Checking</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExistenceChecking() - * @generated - * @ordered - */ - protected ExistenceType existenceChecking = EXISTENCE_CHECKING_EDEFAULT; - - /** - * The cached value of the '{@link #getConverters() <em>Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverters() - * @generated - * @ordered - */ - protected EList<XmlConverter> converters; - - /** - * The cached value of the '{@link #getTypeConverters() <em>Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlTypeConverter> typeConverters; - - /** - * The cached value of the '{@link #getObjectTypeConverters() <em>Object Type Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverters() - * @generated - * @ordered - */ - protected EList<XmlObjectTypeConverter> objectTypeConverters; - - /** - * The cached value of the '{@link #getStructConverters() <em>Struct Converters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverters() - * @generated - * @ordered - */ - protected EList<XmlStructConverter> structConverters; - - /** - * The cached value of the '{@link #getOptimisticLocking() <em>Optimistic Locking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getOptimisticLocking() - * @generated - * @ordered - */ - protected XmlOptimisticLocking optimisticLocking; - - /** - * The cached value of the '{@link #getCopyPolicy() <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy copyPolicy; - - /** - * The cached value of the '{@link #getInstantiationCopyPolicy() <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getInstantiationCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy instantiationCopyPolicy; - - /** - * The cached value of the '{@link #getCloneCopyPolicy() <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCloneCopyPolicy() - * @generated - * @ordered - */ - protected XmlCopyPolicy cloneCopyPolicy; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * The default value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected static final Boolean EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getExcludeDefaultMappings() - * @generated - * @ordered - */ - protected Boolean excludeDefaultMappings = EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlMappedSuperclass() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_MAPPED_SUPERCLASS; - } - - /** - * 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.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly_ReadOnly() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getReadOnly() - { - return readOnly; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getReadOnly <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Read Only</em>' attribute. - * @see #getReadOnly() - * @generated - */ - public void setReadOnly(Boolean newReadOnly) - { - Boolean oldReadOnly = readOnly; - readOnly = newReadOnly; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY, oldReadOnly, readOnly)); - } - - /** - * Returns the value of the '<em><b>Customizer</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Customizer</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>Customizer</em>' containment reference. - * @see #setCustomizer(XmlCustomizer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCustomizerHolder_Customizer() - * @model containment="true" - * @generated - */ - public XmlCustomizer getCustomizer() - { - return customizer; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCustomizer(XmlCustomizer newCustomizer, NotificationChain msgs) - { - XmlCustomizer oldCustomizer = customizer; - customizer = newCustomizer; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER, oldCustomizer, newCustomizer); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCustomizer <em>Customizer</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Customizer</em>' containment reference. - * @see #getCustomizer() - * @generated - */ - public void setCustomizer(XmlCustomizer newCustomizer) - { - if (newCustomizer != customizer) - { - NotificationChain msgs = null; - if (customizer != null) - msgs = ((InternalEObject)customizer).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER, null, msgs); - if (newCustomizer != null) - msgs = ((InternalEObject)newCustomizer).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER, null, msgs); - msgs = basicSetCustomizer(newCustomizer, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER, newCustomizer, newCustomizer)); - } - - /** - * Returns the value of the '<em><b>Change Tracking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Change Tracking</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>Change Tracking</em>' containment reference. - * @see #setChangeTracking(XmlChangeTracking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlChangeTrackingHolder_ChangeTracking() - * @model containment="true" - * @generated - */ - public XmlChangeTracking getChangeTracking() - { - return changeTracking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetChangeTracking(XmlChangeTracking newChangeTracking, NotificationChain msgs) - { - XmlChangeTracking oldChangeTracking = changeTracking; - changeTracking = newChangeTracking; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING, oldChangeTracking, newChangeTracking); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getChangeTracking <em>Change Tracking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Change Tracking</em>' containment reference. - * @see #getChangeTracking() - * @generated - */ - public void setChangeTracking(XmlChangeTracking newChangeTracking) - { - if (newChangeTracking != changeTracking) - { - NotificationChain msgs = null; - if (changeTracking != null) - msgs = ((InternalEObject)changeTracking).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING, null, msgs); - if (newChangeTracking != null) - msgs = ((InternalEObject)newChangeTracking).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING, null, msgs); - msgs = basicSetChangeTracking(newChangeTracking, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING, newChangeTracking, newChangeTracking)); - } - - /** - * Returns the value of the '<em><b>Cache</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Cache</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>Cache</em>' containment reference. - * @see #setCache(XmlCache) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_Cache() - * @model containment="true" - * @generated - */ - public XmlCache getCache() - { - return cache; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCache(XmlCache newCache, NotificationChain msgs) - { - XmlCache oldCache = cache; - cache = newCache; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE, oldCache, newCache); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCache <em>Cache</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Cache</em>' containment reference. - * @see #getCache() - * @generated - */ - public void setCache(XmlCache newCache) - { - if (newCache != cache) - { - NotificationChain msgs = null; - if (cache != null) - msgs = ((InternalEObject)cache).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE, null, msgs); - if (newCache != null) - msgs = ((InternalEObject)newCache).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE, null, msgs); - msgs = basicSetCache(newCache, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE, newCache, newCache)); - } - - /** - * Returns the value of the '<em><b>Existence Checking</b></em>' attribute. - * The default value is <code>""</code>. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Existence Checking</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #setExistenceChecking(ExistenceType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlCacheHolder_ExistenceChecking() - * @model default="" - * @generated - */ - public ExistenceType getExistenceChecking() - { - return existenceChecking; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getExistenceChecking <em>Existence Checking</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Existence Checking</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.ExistenceType - * @see #getExistenceChecking() - * @generated - */ - public void setExistenceChecking(ExistenceType newExistenceChecking) - { - ExistenceType oldExistenceChecking = existenceChecking; - existenceChecking = newExistenceChecking == null ? EXISTENCE_CHECKING_EDEFAULT : newExistenceChecking; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING, oldExistenceChecking, existenceChecking)); - } - - /** - * Returns the value of the '<em><b>Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Converters</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>Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_Converters() - * @model containment="true" - * @generated - */ - public EList<XmlConverter> getConverters() - { - if (converters == null) - { - converters = new EObjectContainmentEList<XmlConverter>(XmlConverter.class, this, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS); - } - return converters; - } - - /** - * Returns the value of the '<em><b>Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type Converters</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>Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_TypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlTypeConverter> getTypeConverters() - { - if (typeConverters == null) - { - typeConverters = new EObjectContainmentEList<XmlTypeConverter>(XmlTypeConverter.class, this, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS); - } - return typeConverters; - } - - /** - * Returns the value of the '<em><b>Object Type Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type Converters</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>Object Type Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_ObjectTypeConverters() - * @model containment="true" - * @generated - */ - public EList<XmlObjectTypeConverter> getObjectTypeConverters() - { - if (objectTypeConverters == null) - { - objectTypeConverters = new EObjectContainmentEList<XmlObjectTypeConverter>(XmlObjectTypeConverter.class, this, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS); - } - return objectTypeConverters; - } - - /** - * Returns the value of the '<em><b>Struct Converters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct Converters</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>Struct Converters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertersHolder_StructConverters() - * @model containment="true" - * @generated - */ - public EList<XmlStructConverter> getStructConverters() - { - if (structConverters == null) - { - structConverters = new EObjectContainmentEList<XmlStructConverter>(XmlStructConverter.class, this, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS); - } - return structConverters; - } - - /** - * Returns the value of the '<em><b>Optimistic Locking</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Optimistic Locking</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>Optimistic Locking</em>' containment reference. - * @see #setOptimisticLocking(XmlOptimisticLocking) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_OptimisticLocking() - * @model containment="true" - * @generated - */ - public XmlOptimisticLocking getOptimisticLocking() - { - return optimisticLocking; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetOptimisticLocking(XmlOptimisticLocking newOptimisticLocking, NotificationChain msgs) - { - XmlOptimisticLocking oldOptimisticLocking = optimisticLocking; - optimisticLocking = newOptimisticLocking; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING, oldOptimisticLocking, newOptimisticLocking); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getOptimisticLocking <em>Optimistic Locking</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Optimistic Locking</em>' containment reference. - * @see #getOptimisticLocking() - * @generated - */ - public void setOptimisticLocking(XmlOptimisticLocking newOptimisticLocking) - { - if (newOptimisticLocking != optimisticLocking) - { - NotificationChain msgs = null; - if (optimisticLocking != null) - msgs = ((InternalEObject)optimisticLocking).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING, null, msgs); - if (newOptimisticLocking != null) - msgs = ((InternalEObject)newOptimisticLocking).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING, null, msgs); - msgs = basicSetOptimisticLocking(newOptimisticLocking, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING, newOptimisticLocking, newOptimisticLocking)); - } - - /** - * Returns the value of the '<em><b>Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Copy Policy</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>Copy Policy</em>' containment reference. - * @see #setCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_CopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCopyPolicy() - { - return copyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCopyPolicy(XmlCopyPolicy newCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCopyPolicy = copyPolicy; - copyPolicy = newCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY, oldCopyPolicy, newCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCopyPolicy <em>Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Copy Policy</em>' containment reference. - * @see #getCopyPolicy() - * @generated - */ - public void setCopyPolicy(XmlCopyPolicy newCopyPolicy) - { - if (newCopyPolicy != copyPolicy) - { - NotificationChain msgs = null; - if (copyPolicy != null) - msgs = ((InternalEObject)copyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY, null, msgs); - if (newCopyPolicy != null) - msgs = ((InternalEObject)newCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY, null, msgs); - msgs = basicSetCopyPolicy(newCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY, newCopyPolicy, newCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Instantiation Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Instantiation Copy Policy</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>Instantiation Copy Policy</em>' containment reference. - * @see #setInstantiationCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_InstantiationCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getInstantiationCopyPolicy() - { - return instantiationCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldInstantiationCopyPolicy = instantiationCopyPolicy; - instantiationCopyPolicy = newInstantiationCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY, oldInstantiationCopyPolicy, newInstantiationCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getInstantiationCopyPolicy <em>Instantiation Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Instantiation Copy Policy</em>' containment reference. - * @see #getInstantiationCopyPolicy() - * @generated - */ - public void setInstantiationCopyPolicy(XmlCopyPolicy newInstantiationCopyPolicy) - { - if (newInstantiationCopyPolicy != instantiationCopyPolicy) - { - NotificationChain msgs = null; - if (instantiationCopyPolicy != null) - msgs = ((InternalEObject)instantiationCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY, null, msgs); - if (newInstantiationCopyPolicy != null) - msgs = ((InternalEObject)newInstantiationCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY, null, msgs); - msgs = basicSetInstantiationCopyPolicy(newInstantiationCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY, newInstantiationCopyPolicy, newInstantiationCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Clone Copy Policy</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Clone Copy Policy</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>Clone Copy Policy</em>' containment reference. - * @see #setCloneCopyPolicy(XmlCopyPolicy) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_CloneCopyPolicy() - * @model containment="true" - * @generated - */ - public XmlCopyPolicy getCloneCopyPolicy() - { - return cloneCopyPolicy; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy, NotificationChain msgs) - { - XmlCopyPolicy oldCloneCopyPolicy = cloneCopyPolicy; - cloneCopyPolicy = newCloneCopyPolicy; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY, oldCloneCopyPolicy, newCloneCopyPolicy); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getCloneCopyPolicy <em>Clone Copy Policy</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Clone Copy Policy</em>' containment reference. - * @see #getCloneCopyPolicy() - * @generated - */ - public void setCloneCopyPolicy(XmlCopyPolicy newCloneCopyPolicy) - { - if (newCloneCopyPolicy != cloneCopyPolicy) - { - NotificationChain msgs = null; - if (cloneCopyPolicy != null) - msgs = ((InternalEObject)cloneCopyPolicy).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY, null, msgs); - if (newCloneCopyPolicy != null) - msgs = ((InternalEObject)newCloneCopyPolicy).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY, null, msgs); - msgs = basicSetCloneCopyPolicy(newCloneCopyPolicy, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY, newCloneCopyPolicy, newCloneCopyPolicy)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Exclude Default Mappings</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #setExcludeDefaultMappings(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMappedSuperclass_ExcludeDefaultMappings() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getExcludeDefaultMappings() - { - return excludeDefaultMappings; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMappedSuperclass#getExcludeDefaultMappings <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #getExcludeDefaultMappings() - * @generated - */ - public void setExcludeDefaultMappings(Boolean newExcludeDefaultMappings) - { - Boolean oldExcludeDefaultMappings = excludeDefaultMappings; - excludeDefaultMappings = newExcludeDefaultMappings; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS, oldExcludeDefaultMappings, excludeDefaultMappings)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: - return basicSetCustomizer(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: - return basicSetChangeTracking(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: - return basicSetCache(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: - return ((InternalEList<?>)getConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: - return ((InternalEList<?>)getTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: - return ((InternalEList<?>)getObjectTypeConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: - return ((InternalEList<?>)getStructConverters()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING: - return basicSetOptimisticLocking(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY: - return basicSetCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY: - return basicSetInstantiationCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY: - return basicSetCloneCopyPolicy(null, msgs); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY: - return getReadOnly(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: - return getCustomizer(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: - return getChangeTracking(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: - return getCache(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING: - return getExistenceChecking(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: - return getConverters(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: - return getTypeConverters(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: - return getObjectTypeConverters(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: - return getStructConverters(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING: - return getOptimisticLocking(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY: - return getCopyPolicy(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY: - return getInstantiationCopyPolicy(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY: - return getCloneCopyPolicy(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES: - return getProperties(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS: - return getExcludeDefaultMappings(); - } - 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 EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY: - setReadOnly((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: - setCustomizer((XmlCustomizer)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: - setCache((XmlCache)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING: - setExistenceChecking((ExistenceType)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: - getConverters().clear(); - getConverters().addAll((Collection<? extends XmlConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: - getTypeConverters().clear(); - getTypeConverters().addAll((Collection<? extends XmlTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - getObjectTypeConverters().addAll((Collection<? extends XmlObjectTypeConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: - getStructConverters().clear(); - getStructConverters().addAll((Collection<? extends XmlStructConverter>)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING: - setOptimisticLocking((XmlOptimisticLocking)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings((Boolean)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY: - setReadOnly(READ_ONLY_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: - setCustomizer((XmlCustomizer)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: - setChangeTracking((XmlChangeTracking)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: - setCache((XmlCache)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING: - setExistenceChecking(EXISTENCE_CHECKING_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: - getConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: - getTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: - getObjectTypeConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: - getStructConverters().clear(); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING: - setOptimisticLocking((XmlOptimisticLocking)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY: - setCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY: - setInstantiationCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY: - setCloneCopyPolicy((XmlCopyPolicy)null); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES: - getProperties().clear(); - return; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings(EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY: - return READ_ONLY_EDEFAULT == null ? readOnly != null : !READ_ONLY_EDEFAULT.equals(readOnly); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: - return customizer != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: - return changeTracking != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: - return cache != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING: - return existenceChecking != EXISTENCE_CHECKING_EDEFAULT; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: - return converters != null && !converters.isEmpty(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: - return typeConverters != null && !typeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: - return objectTypeConverters != null && !objectTypeConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: - return structConverters != null && !structConverters.isEmpty(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OPTIMISTIC_LOCKING: - return optimisticLocking != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__COPY_POLICY: - return copyPolicy != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__INSTANTIATION_COPY_POLICY: - return instantiationCopyPolicy != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CLONE_COPY_POLICY: - return cloneCopyPolicy != null; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__PROPERTIES: - return properties != null && !properties.isEmpty(); - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXCLUDE_DEFAULT_MAPPINGS: - return EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT == null ? excludeDefaultMappings != null : !EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT.equals(excludeDefaultMappings); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlReadOnly.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY: return EclipseLinkOrmPackage.XML_READ_ONLY__READ_ONLY; - default: return -1; - } - } - if (baseClass == XmlCustomizerHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER: return EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlCacheHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE: return EclipseLinkOrmPackage.XML_CACHE_HOLDER__CACHE; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING: return EclipseLinkOrmPackage.XML_CACHE_HOLDER__EXISTENCE_CHECKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS; - 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 == XmlReadOnly.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_READ_ONLY__READ_ONLY: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__READ_ONLY; - default: return -1; - } - } - if (baseClass == XmlCustomizerHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CUSTOMIZER_HOLDER__CUSTOMIZER: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CUSTOMIZER; - default: return -1; - } - } - if (baseClass == XmlChangeTrackingHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CHANGE_TRACKING_HOLDER__CHANGE_TRACKING: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CHANGE_TRACKING; - default: return -1; - } - } - if (baseClass == XmlCacheHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CACHE_HOLDER__CACHE: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CACHE; - case EclipseLinkOrmPackage.XML_CACHE_HOLDER__EXISTENCE_CHECKING: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__EXISTENCE_CHECKING; - default: return -1; - } - } - if (baseClass == XmlConvertersHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__CONVERTERS: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__OBJECT_TYPE_CONVERTERS: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__OBJECT_TYPE_CONVERTERS; - case EclipseLinkOrmPackage.XML_CONVERTERS_HOLDER__STRUCT_CONVERTERS: return EclipseLinkOrmPackage.XML_MAPPED_SUPERCLASS__STRUCT_CONVERTERS; - 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(" (readOnly: "); - result.append(readOnly); - result.append(", existenceChecking: "); - result.append(existenceChecking); - result.append(", excludeDefaultMappings: "); - result.append(excludeDefaultMappings); - result.append(')'); - return result.toString(); - } - - public TextRange getReadOnlyTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.READ_ONLY); - } -} // XmlMappedSuperclass diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMutable.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMutable.java deleted file mode 100644 index 6e384393aa..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlMutable.java +++ /dev/null @@ -1,72 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlMutable.java,v 1.4 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Mutable</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable#getMutable <em>Mutable</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlMutable extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Mutable</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Mutable</em>' attribute. - * @see #setMutable(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable_Mutable() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - Boolean getMutable(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlMutable#getMutable <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Mutable</em>' attribute. - * @see #getMutable() - * @generated - */ - void setMutable(Boolean value); - - /** - * Return the {@link TextRange} for the mutable attibute. - */ - TextRange getMutableTextRange(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedConverter.java deleted file mode 100644 index bb65759bcc..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedConverter.java +++ /dev/null @@ -1,67 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlNamedConverter.java,v 1.3 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Named Converter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter#getName <em>Name</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlNamedConverter extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter_Name() - * @model - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedConverter#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - -} // XmlNamedConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedStoredProcedureQuery.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedStoredProcedureQuery.java deleted file mode 100644 index b5a7a0e20e..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlNamedStoredProcedureQuery.java +++ /dev/null @@ -1,601 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -import org.eclipse.jpt.core.resource.orm.XmlQueryHint; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Named Stored Procedure Query</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getName <em>Name</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultClass <em>Result Class</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultSetMapping <em>Result Set Mapping</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getProcedureName <em>Procedure Name</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getReturnsResultSet <em>Returns Result Set</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getHints <em>Hints</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getParameters <em>Parameters</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlNamedStoredProcedureQuery extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getResultClass() <em>Result Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getResultClass() - * @generated - * @ordered - */ - protected static final String RESULT_CLASS_EDEFAULT = null; - - /** - * The cached value of the '{@link #getResultClass() <em>Result Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getResultClass() - * @generated - * @ordered - */ - protected String resultClass = RESULT_CLASS_EDEFAULT; - - /** - * The default value of the '{@link #getResultSetMapping() <em>Result Set Mapping</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getResultSetMapping() - * @generated - * @ordered - */ - protected static final String RESULT_SET_MAPPING_EDEFAULT = null; - - /** - * The cached value of the '{@link #getResultSetMapping() <em>Result Set Mapping</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getResultSetMapping() - * @generated - * @ordered - */ - protected String resultSetMapping = RESULT_SET_MAPPING_EDEFAULT; - - /** - * The default value of the '{@link #getProcedureName() <em>Procedure Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProcedureName() - * @generated - * @ordered - */ - protected static final String PROCEDURE_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getProcedureName() <em>Procedure Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProcedureName() - * @generated - * @ordered - */ - protected String procedureName = PROCEDURE_NAME_EDEFAULT; - - /** - * The default value of the '{@link #getReturnsResultSet() <em>Returns Result Set</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReturnsResultSet() - * @generated - * @ordered - */ - protected static final Boolean RETURNS_RESULT_SET_EDEFAULT = null; - - /** - * The cached value of the '{@link #getReturnsResultSet() <em>Returns Result Set</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getReturnsResultSet() - * @generated - * @ordered - */ - protected Boolean returnsResultSet = RETURNS_RESULT_SET_EDEFAULT; - - /** - * The cached value of the '{@link #getHints() <em>Hints</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getHints() - * @generated - * @ordered - */ - protected EList<XmlQueryHint> hints; - - /** - * The cached value of the '{@link #getParameters() <em>Parameters</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getParameters() - * @generated - * @ordered - */ - protected EList<XmlStoredProcedureParameter> parameters; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlNamedStoredProcedureQuery() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_NAMED_STORED_PROCEDURE_QUERY; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_Name() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Result Class</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Result Class</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Result Class</em>' attribute. - * @see #setResultClass(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_ResultClass() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getResultClass() - { - return resultClass; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultClass <em>Result Class</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Result Class</em>' attribute. - * @see #getResultClass() - * @generated - */ - public void setResultClass(String newResultClass) - { - String oldResultClass = resultClass; - resultClass = newResultClass; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS, oldResultClass, resultClass)); - } - - /** - * Returns the value of the '<em><b>Result Set Mapping</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Result Set Mapping</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Result Set Mapping</em>' attribute. - * @see #setResultSetMapping(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_ResultSetMapping() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getResultSetMapping() - { - return resultSetMapping; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getResultSetMapping <em>Result Set Mapping</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Result Set Mapping</em>' attribute. - * @see #getResultSetMapping() - * @generated - */ - public void setResultSetMapping(String newResultSetMapping) - { - String oldResultSetMapping = resultSetMapping; - resultSetMapping = newResultSetMapping; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING, oldResultSetMapping, resultSetMapping)); - } - - /** - * Returns the value of the '<em><b>Procedure Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Procedure Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Procedure Name</em>' attribute. - * @see #setProcedureName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_ProcedureName() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getProcedureName() - { - return procedureName; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getProcedureName <em>Procedure Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Procedure Name</em>' attribute. - * @see #getProcedureName() - * @generated - */ - public void setProcedureName(String newProcedureName) - { - String oldProcedureName = procedureName; - procedureName = newProcedureName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME, oldProcedureName, procedureName)); - } - - /** - * Returns the value of the '<em><b>Returns Result Set</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Returns Result Set</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Returns Result Set</em>' attribute. - * @see #setReturnsResultSet(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_ReturnsResultSet() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getReturnsResultSet() - { - return returnsResultSet; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlNamedStoredProcedureQuery#getReturnsResultSet <em>Returns Result Set</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Returns Result Set</em>' attribute. - * @see #getReturnsResultSet() - * @generated - */ - public void setReturnsResultSet(Boolean newReturnsResultSet) - { - Boolean oldReturnsResultSet = returnsResultSet; - returnsResultSet = newReturnsResultSet; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET, oldReturnsResultSet, returnsResultSet)); - } - - /** - * Returns the value of the '<em><b>Hints</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.core.resource.orm.XmlQueryHint}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Hints</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>Hints</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_Hints() - * @model containment="true" - * @generated - */ - public EList<XmlQueryHint> getHints() - { - if (hints == null) - { - hints = new EObjectContainmentEList<XmlQueryHint>(XmlQueryHint.class, this, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS); - } - return hints; - } - - /** - * Returns the value of the '<em><b>Parameters</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Parameters</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>Parameters</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedStoredProcedureQuery_Parameters() - * @model containment="true" - * @generated - */ - public EList<XmlStoredProcedureParameter> getParameters() - { - if (parameters == null) - { - parameters = new EObjectContainmentEList<XmlStoredProcedureParameter>(XmlStoredProcedureParameter.class, this, EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS); - } - return parameters; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS: - return ((InternalEList<?>)getHints()).basicRemove(otherEnd, msgs); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS: - return ((InternalEList<?>)getParameters()).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 EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS: - return getResultClass(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING: - return getResultSetMapping(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME: - return getProcedureName(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET: - return getReturnsResultSet(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS: - return getHints(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS: - return getParameters(); - } - 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 EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS: - setResultClass((String)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING: - setResultSetMapping((String)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME: - setProcedureName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET: - setReturnsResultSet((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS: - getHints().clear(); - getHints().addAll((Collection<? extends XmlQueryHint>)newValue); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS: - getParameters().clear(); - getParameters().addAll((Collection<? extends XmlStoredProcedureParameter>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS: - setResultClass(RESULT_CLASS_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING: - setResultSetMapping(RESULT_SET_MAPPING_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME: - setProcedureName(PROCEDURE_NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET: - setReturnsResultSet(RETURNS_RESULT_SET_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS: - getHints().clear(); - return; - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS: - getParameters().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_CLASS: - return RESULT_CLASS_EDEFAULT == null ? resultClass != null : !RESULT_CLASS_EDEFAULT.equals(resultClass); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RESULT_SET_MAPPING: - return RESULT_SET_MAPPING_EDEFAULT == null ? resultSetMapping != null : !RESULT_SET_MAPPING_EDEFAULT.equals(resultSetMapping); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PROCEDURE_NAME: - return PROCEDURE_NAME_EDEFAULT == null ? procedureName != null : !PROCEDURE_NAME_EDEFAULT.equals(procedureName); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__RETURNS_RESULT_SET: - return RETURNS_RESULT_SET_EDEFAULT == null ? returnsResultSet != null : !RETURNS_RESULT_SET_EDEFAULT.equals(returnsResultSet); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__HINTS: - return hints != null && !hints.isEmpty(); - case EclipseLinkOrmPackage.XML_NAMED_STORED_PROCEDURE_QUERY__PARAMETERS: - return parameters != null && !parameters.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", resultClass: "); - result.append(resultClass); - result.append(", resultSetMapping: "); - result.append(resultSetMapping); - result.append(", procedureName: "); - result.append(procedureName); - result.append(", returnsResultSet: "); - result.append(returnsResultSet); - result.append(')'); - return result.toString(); - } - -} // XmlNamedStoredProcedureQuery diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverter.java deleted file mode 100644 index 2809208aad..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverter.java +++ /dev/null @@ -1,140 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Object Type CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDataType <em>Data Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getObjectType <em>Object Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getConversionValues <em>Conversion Values</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDefaultObjectValue <em>Default Object Value</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlObjectTypeConverter extends XmlNamedConverter -{ - /** - * Returns the value of the '<em><b>Conversion Values</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Conversion Values</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>Conversion Values</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_ConversionValues() - * @model containment="true" - * @generated - */ - EList<XmlConversionValue> getConversionValues(); - - /** - * Returns the value of the '<em><b>Default Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Default Object Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Default Object Value</em>' attribute. - * @see #setDefaultObjectValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_DefaultObjectValue() - * @model - * @generated - */ - String getDefaultObjectValue(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDefaultObjectValue <em>Default Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Default Object Value</em>' attribute. - * @see #getDefaultObjectValue() - * @generated - */ - void setDefaultObjectValue(String value); - - /** - * Returns the value of the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data 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>Data Type</em>' attribute. - * @see #setDataType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_DataType() - * @model - * @generated - */ - String getDataType(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getDataType <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Type</em>' attribute. - * @see #getDataType() - * @generated - */ - void setDataType(String value); - - /** - * Returns the value of the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object 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>Object Type</em>' attribute. - * @see #setObjectType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_ObjectType() - * @model - * @generated - */ - String getObjectType(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverter#getObjectType <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type</em>' attribute. - * @see #getObjectType() - * @generated - */ - void setObjectType(String value); - -} // XmlObjectTypeConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverterImpl.java deleted file mode 100644 index 2f0d7b5c02..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlObjectTypeConverterImpl.java +++ /dev/null @@ -1,467 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.common.AbstractJpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Object Type CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverterImpl() - * @model kind="class" - * @generated - */ -public class XmlObjectTypeConverterImpl extends AbstractJpaEObject implements XmlObjectTypeConverter -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getDataType() <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataType() - * @generated - * @ordered - */ - protected static final String DATA_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDataType() <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataType() - * @generated - * @ordered - */ - protected String dataType = DATA_TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getObjectType() <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectType() - * @generated - * @ordered - */ - protected static final String OBJECT_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getObjectType() <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectType() - * @generated - * @ordered - */ - protected String objectType = OBJECT_TYPE_EDEFAULT; - - /** - * The cached value of the '{@link #getConversionValues() <em>Conversion Values</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConversionValues() - * @generated - * @ordered - */ - protected EList<XmlConversionValue> conversionValues; - - /** - * The default value of the '{@link #getDefaultObjectValue() <em>Default Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDefaultObjectValue() - * @generated - * @ordered - */ - protected static final String DEFAULT_OBJECT_VALUE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDefaultObjectValue() <em>Default Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDefaultObjectValue() - * @generated - * @ordered - */ - protected String defaultObjectValue = DEFAULT_OBJECT_VALUE_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlObjectTypeConverterImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_OBJECT_TYPE_CONVERTER_IMPL; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter_Name() - * @model - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data 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>Data Type</em>' attribute. - * @see #setDataType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_DataType() - * @model - * @generated - */ - public String getDataType() - { - return dataType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl#getDataType <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Type</em>' attribute. - * @see #getDataType() - * @generated - */ - public void setDataType(String newDataType) - { - String oldDataType = dataType; - dataType = newDataType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE, oldDataType, dataType)); - } - - /** - * Returns the value of the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object 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>Object Type</em>' attribute. - * @see #setObjectType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_ObjectType() - * @model - * @generated - */ - public String getObjectType() - { - return objectType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl#getObjectType <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type</em>' attribute. - * @see #getObjectType() - * @generated - */ - public void setObjectType(String newObjectType) - { - String oldObjectType = objectType; - objectType = newObjectType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE, oldObjectType, objectType)); - } - - /** - * Returns the value of the '<em><b>Conversion Values</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlConversionValue}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Conversion Values</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>Conversion Values</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_ConversionValues() - * @model containment="true" - * @generated - */ - public EList<XmlConversionValue> getConversionValues() - { - if (conversionValues == null) - { - conversionValues = new EObjectContainmentEList<XmlConversionValue>(XmlConversionValue.class, this, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES); - } - return conversionValues; - } - - /** - * Returns the value of the '<em><b>Default Object Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Default Object Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Default Object Value</em>' attribute. - * @see #setDefaultObjectValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlObjectTypeConverter_DefaultObjectValue() - * @model - * @generated - */ - public String getDefaultObjectValue() - { - return defaultObjectValue; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlObjectTypeConverterImpl#getDefaultObjectValue <em>Default Object Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Default Object Value</em>' attribute. - * @see #getDefaultObjectValue() - * @generated - */ - public void setDefaultObjectValue(String newDefaultObjectValue) - { - String oldDefaultObjectValue = defaultObjectValue; - defaultObjectValue = newDefaultObjectValue; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE, oldDefaultObjectValue, defaultObjectValue)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES: - return ((InternalEList<?>)getConversionValues()).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 EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE: - return getDataType(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - return getObjectType(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES: - return getConversionValues(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE: - return getDefaultObjectValue(); - } - 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 EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE: - setDataType((String)newValue); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - setObjectType((String)newValue); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES: - getConversionValues().clear(); - getConversionValues().addAll((Collection<? extends XmlConversionValue>)newValue); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE: - setDefaultObjectValue((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE: - setDataType(DATA_TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - setObjectType(OBJECT_TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES: - getConversionValues().clear(); - return; - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE: - setDefaultObjectValue(DEFAULT_OBJECT_VALUE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DATA_TYPE: - return DATA_TYPE_EDEFAULT == null ? dataType != null : !DATA_TYPE_EDEFAULT.equals(dataType); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - return OBJECT_TYPE_EDEFAULT == null ? objectType != null : !OBJECT_TYPE_EDEFAULT.equals(objectType); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__CONVERSION_VALUES: - return conversionValues != null && !conversionValues.isEmpty(); - case EclipseLinkOrmPackage.XML_OBJECT_TYPE_CONVERTER_IMPL__DEFAULT_OBJECT_VALUE: - return DEFAULT_OBJECT_VALUE_EDEFAULT == null ? defaultObjectValue != null : !DEFAULT_OBJECT_VALUE_EDEFAULT.equals(defaultObjectValue); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", dataType: "); - result.append(dataType); - result.append(", objectType: "); - result.append(objectType); - result.append(", defaultObjectValue: "); - result.append(defaultObjectValue); - result.append(')'); - return result.toString(); - } - -} // XmlObjectTypeConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToMany.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToMany.java deleted file mode 100644 index cad74716f2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToMany.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml One To Many</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToMany#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToMany() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlOneToMany extends org.eclipse.jpt.core.resource.orm.XmlOneToMany, XmlPrivateOwned, XmlJoinFetch, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToMany_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlOneToMany diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToManyImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToManyImpl.java deleted file mode 100644 index 9d06e5a2a4..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToManyImpl.java +++ /dev/null @@ -1,508 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml One To Many</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToManyImpl() - * @model kind="class" - * @generated - */ -public class XmlOneToManyImpl extends org.eclipse.jpt.core.resource.orm.XmlOneToManyImpl implements XmlOneToMany -{ - /** - * The default value of the '{@link #isPrivateOwned() <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isPrivateOwned() - * @generated - * @ordered - */ - protected static final boolean PRIVATE_OWNED_EDEFAULT = false; - - /** - * The cached value of the '{@link #isPrivateOwned() <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isPrivateOwned() - * @generated - * @ordered - */ - protected boolean privateOwned = PRIVATE_OWNED_EDEFAULT; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlJoinFetchType JOIN_FETCH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJoinFetch() <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJoinFetch() - * @generated - * @ordered - */ - protected XmlJoinFetchType joinFetch = JOIN_FETCH_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlOneToManyImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ONE_TO_MANY_IMPL; - } - - /** - * Returns the value of the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Private Owned</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Private Owned</em>' attribute. - * @see #setPrivateOwned(boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned_PrivateOwned() - * @model dataType="org.eclipse.emf.ecore.xml.type.Boolean" - * @generated - */ - public boolean isPrivateOwned() - { - return privateOwned; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl#isPrivateOwned <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Private Owned</em>' attribute. - * @see #isPrivateOwned() - * @generated - */ - public void setPrivateOwned(boolean newPrivateOwned) - { - boolean oldPrivateOwned = privateOwned; - privateOwned = newPrivateOwned; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED, oldPrivateOwned, privateOwned)); - } - - /** - * Returns the value of the '<em><b>Join Fetch</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Join Fetch</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #setJoinFetch(XmlJoinFetchType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch_JoinFetch() - * @model - * @generated - */ - public XmlJoinFetchType getJoinFetch() - { - return joinFetch; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl#getJoinFetch <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #getJoinFetch() - * @generated - */ - public void setJoinFetch(XmlJoinFetchType newJoinFetch) - { - XmlJoinFetchType oldJoinFetch = joinFetch; - joinFetch = newJoinFetch == null ? JOIN_FETCH_EDEFAULT : newJoinFetch; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH, oldJoinFetch, joinFetch)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToManyImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToMany_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED: - return isPrivateOwned() ? Boolean.TRUE : Boolean.FALSE; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH: - return getJoinFetch(); - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED: - setPrivateOwned(((Boolean)newValue).booleanValue()); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH: - setJoinFetch((XmlJoinFetchType)newValue); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED: - setPrivateOwned(PRIVATE_OWNED_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH: - setJoinFetch(JOIN_FETCH_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED: - return privateOwned != PRIVATE_OWNED_EDEFAULT; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH: - return joinFetch != JOIN_FETCH_EDEFAULT; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlPrivateOwned.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED: return EclipseLinkOrmPackage.XML_PRIVATE_OWNED__PRIVATE_OWNED; - default: return -1; - } - } - if (baseClass == XmlJoinFetch.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH: return EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlOneToMany.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_ONE_TO_MANY__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 == XmlPrivateOwned.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_PRIVATE_OWNED__PRIVATE_OWNED: return EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__PRIVATE_OWNED; - default: return -1; - } - } - if (baseClass == XmlJoinFetch.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH: return EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlOneToMany.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_MANY__PROPERTIES: return EclipseLinkOrmPackage.XML_ONE_TO_MANY_IMPL__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(" (privateOwned: "); - result.append(privateOwned); - result.append(", joinFetch: "); - result.append(joinFetch); - result.append(')'); - return result.toString(); - } - - public TextRange getPrivateOwnedTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.PRIVATE_OWNED); - } - - public TextRange getJoinFetchTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.JOIN_FETCH); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOne.java deleted file mode 100644 index 8d89a819e2..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOne.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml One To One</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOne#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOne() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlOneToOne extends org.eclipse.jpt.core.resource.orm.XmlOneToOne, XmlPrivateOwned, XmlJoinFetch, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOne_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlOneToOne diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOneImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOneImpl.java deleted file mode 100644 index 5a0dc409df..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOneToOneImpl.java +++ /dev/null @@ -1,508 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml One To One</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOneImpl() - * @model kind="class" - * @generated - */ -public class XmlOneToOneImpl extends org.eclipse.jpt.core.resource.orm.XmlOneToOneImpl implements XmlOneToOne -{ - /** - * The default value of the '{@link #isPrivateOwned() <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isPrivateOwned() - * @generated - * @ordered - */ - protected static final boolean PRIVATE_OWNED_EDEFAULT = false; - - /** - * The cached value of the '{@link #isPrivateOwned() <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isPrivateOwned() - * @generated - * @ordered - */ - protected boolean privateOwned = PRIVATE_OWNED_EDEFAULT; - - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlJoinFetchType JOIN_FETCH_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJoinFetch() <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJoinFetch() - * @generated - * @ordered - */ - protected XmlJoinFetchType joinFetch = JOIN_FETCH_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlOneToOneImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_ONE_TO_ONE_IMPL; - } - - /** - * Returns the value of the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Private Owned</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Private Owned</em>' attribute. - * @see #setPrivateOwned(boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned_PrivateOwned() - * @model dataType="org.eclipse.emf.ecore.xml.type.Boolean" - * @generated - */ - public boolean isPrivateOwned() - { - return privateOwned; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl#isPrivateOwned <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Private Owned</em>' attribute. - * @see #isPrivateOwned() - * @generated - */ - public void setPrivateOwned(boolean newPrivateOwned) - { - boolean oldPrivateOwned = privateOwned; - privateOwned = newPrivateOwned; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED, oldPrivateOwned, privateOwned)); - } - - /** - * Returns the value of the '<em><b>Join Fetch</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Join Fetch</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #setJoinFetch(XmlJoinFetchType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlJoinFetch_JoinFetch() - * @model - * @generated - */ - public XmlJoinFetchType getJoinFetch() - { - return joinFetch; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl#getJoinFetch <em>Join Fetch</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Join Fetch</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlJoinFetchType - * @see #getJoinFetch() - * @generated - */ - public void setJoinFetch(XmlJoinFetchType newJoinFetch) - { - XmlJoinFetchType oldJoinFetch = joinFetch; - joinFetch = newJoinFetch == null ? JOIN_FETCH_EDEFAULT : newJoinFetch; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH, oldJoinFetch, joinFetch)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOneToOneImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOneToOne_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED: - return isPrivateOwned() ? Boolean.TRUE : Boolean.FALSE; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH: - return getJoinFetch(); - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED: - setPrivateOwned(((Boolean)newValue).booleanValue()); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH: - setJoinFetch((XmlJoinFetchType)newValue); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED: - setPrivateOwned(PRIVATE_OWNED_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH: - setJoinFetch(JOIN_FETCH_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED: - return privateOwned != PRIVATE_OWNED_EDEFAULT; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH: - return joinFetch != JOIN_FETCH_EDEFAULT; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlPrivateOwned.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED: return EclipseLinkOrmPackage.XML_PRIVATE_OWNED__PRIVATE_OWNED; - default: return -1; - } - } - if (baseClass == XmlJoinFetch.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH: return EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlOneToOne.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_ONE_TO_ONE__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 == XmlPrivateOwned.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_PRIVATE_OWNED__PRIVATE_OWNED: return EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__PRIVATE_OWNED; - default: return -1; - } - } - if (baseClass == XmlJoinFetch.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_JOIN_FETCH__JOIN_FETCH: return EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__JOIN_FETCH; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlOneToOne.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ONE_TO_ONE__PROPERTIES: return EclipseLinkOrmPackage.XML_ONE_TO_ONE_IMPL__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(" (privateOwned: "); - result.append(privateOwned); - result.append(", joinFetch: "); - result.append(joinFetch); - result.append(')'); - return result.toString(); - } - - public TextRange getPrivateOwnedTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.PRIVATE_OWNED); - } - - public TextRange getJoinFetchTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.JOIN_FETCH); - } -} diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLocking.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLocking.java deleted file mode 100644 index ad8c4861e5..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLocking.java +++ /dev/null @@ -1,349 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -import org.eclipse.jpt.core.resource.orm.XmlColumn; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Optimistic Locking</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getType <em>Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getCascade <em>Cascade</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getSelectedColumns <em>Selected Columns</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlOptimisticLocking extends AbstractJpaEObject implements JpaEObject -{ - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlOptimisticLockingType TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getType() <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getType() - * @generated - * @ordered - */ - protected XmlOptimisticLockingType type = TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getCascade() <em>Cascade</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCascade() - * @generated - * @ordered - */ - protected static final Boolean CASCADE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getCascade() <em>Cascade</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getCascade() - * @generated - * @ordered - */ - protected Boolean cascade = CASCADE_EDEFAULT; - - /** - * The cached value of the '{@link #getSelectedColumns() <em>Selected Columns</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSelectedColumns() - * @generated - * @ordered - */ - protected EList<XmlColumn> selectedColumns; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlOptimisticLocking() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_OPTIMISTIC_LOCKING; - } - - /** - * Returns the value of the '<em><b>Type</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType - * @see #setType(XmlOptimisticLockingType) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking_Type() - * @model - * @generated - */ - public XmlOptimisticLockingType getType() - { - return type; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getType <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLockingType - * @see #getType() - * @generated - */ - public void setType(XmlOptimisticLockingType newType) - { - XmlOptimisticLockingType oldType = type; - type = newType == null ? TYPE_EDEFAULT : newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__TYPE, oldType, type)); - } - - /** - * Returns the value of the '<em><b>Cascade</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Cascade</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Cascade</em>' attribute. - * @see #setCascade(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking_Cascade() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getCascade() - { - return cascade; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlOptimisticLocking#getCascade <em>Cascade</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Cascade</em>' attribute. - * @see #getCascade() - * @generated - */ - public void setCascade(Boolean newCascade) - { - Boolean oldCascade = cascade; - cascade = newCascade; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__CASCADE, oldCascade, cascade)); - } - - /** - * Returns the value of the '<em><b>Selected Columns</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.core.resource.orm.XmlColumn}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Selected Columns</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>Selected Columns</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLocking_SelectedColumns() - * @model containment="true" - * @generated - */ - public EList<XmlColumn> getSelectedColumns() - { - if (selectedColumns == null) - { - selectedColumns = new EObjectContainmentEList<XmlColumn>(XmlColumn.class, this, EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS); - } - return selectedColumns; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS: - return ((InternalEList<?>)getSelectedColumns()).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 EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__TYPE: - return getType(); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__CASCADE: - return getCascade(); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS: - return getSelectedColumns(); - } - 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 EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__TYPE: - setType((XmlOptimisticLockingType)newValue); - return; - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__CASCADE: - setCascade((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS: - getSelectedColumns().clear(); - getSelectedColumns().addAll((Collection<? extends XmlColumn>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__TYPE: - setType(TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__CASCADE: - setCascade(CASCADE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS: - getSelectedColumns().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__TYPE: - return type != TYPE_EDEFAULT; - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__CASCADE: - return CASCADE_EDEFAULT == null ? cascade != null : !CASCADE_EDEFAULT.equals(cascade); - case EclipseLinkOrmPackage.XML_OPTIMISTIC_LOCKING__SELECTED_COLUMNS: - return selectedColumns != null && !selectedColumns.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (type: "); - result.append(type); - result.append(", cascade: "); - result.append(cascade); - result.append(')'); - return result.toString(); - } - -} // XmlOptimisticLocking diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLockingType.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLockingType.java deleted file mode 100644 index 0a7b985f78..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlOptimisticLockingType.java +++ /dev/null @@ -1,294 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import java.util.Arrays; -import java.util.Collections; -import java.util.List; - -import org.eclipse.emf.common.util.Enumerator; - -/** - * <!-- begin-user-doc --> - * A representation of the literals of the enumeration '<em><b>Xml Optimistic Locking Type</b></em>', - * and utility methods for working with them. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlOptimisticLockingType() - * @model - * @generated - */ -public enum XmlOptimisticLockingType implements Enumerator -{ - /** - * The '<em><b>ALL COLUMNS</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #ALL_COLUMNS_VALUE - * @generated - * @ordered - */ - ALL_COLUMNS(0, "ALL_COLUMNS", "ALL_COLUMNS"), - - /** - * The '<em><b>CHANGED COLUMNS</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #CHANGED_COLUMNS_VALUE - * @generated - * @ordered - */ - CHANGED_COLUMNS(1, "CHANGED_COLUMNS", "CHANGED_COLUMNS"), - - /** - * The '<em><b>SELECTED COLUMNS</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #SELECTED_COLUMNS_VALUE - * @generated - * @ordered - */ - SELECTED_COLUMNS(2, "SELECTED_COLUMNS", "SELECTED_COLUMNS"), - - /** - * The '<em><b>VERSION COLUMN</b></em>' literal object. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #VERSION_COLUMN_VALUE - * @generated - * @ordered - */ - VERSION_COLUMN(3, "VERSION_COLUMN", "VERSION_COLUMN"); - - /** - * The '<em><b>ALL COLUMNS</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>ALL COLUMNS</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #ALL_COLUMNS - * @model - * @generated - * @ordered - */ - public static final int ALL_COLUMNS_VALUE = 0; - - /** - * The '<em><b>CHANGED COLUMNS</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>CHANGED COLUMNS</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #CHANGED_COLUMNS - * @model - * @generated - * @ordered - */ - public static final int CHANGED_COLUMNS_VALUE = 1; - - /** - * The '<em><b>SELECTED COLUMNS</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>SELECTED COLUMNS</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #SELECTED_COLUMNS - * @model - * @generated - * @ordered - */ - public static final int SELECTED_COLUMNS_VALUE = 2; - - /** - * The '<em><b>VERSION COLUMN</b></em>' literal value. - * <!-- begin-user-doc --> - * <p> - * If the meaning of '<em><b>VERSION COLUMN</b></em>' literal object isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @see #VERSION_COLUMN - * @model - * @generated - * @ordered - */ - public static final int VERSION_COLUMN_VALUE = 3; - - /** - * An array of all the '<em><b>Xml Optimistic Locking Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private static final XmlOptimisticLockingType[] VALUES_ARRAY = - new XmlOptimisticLockingType[] - { - ALL_COLUMNS, - CHANGED_COLUMNS, - SELECTED_COLUMNS, - VERSION_COLUMN, - }; - - /** - * A public read-only list of all the '<em><b>Xml Optimistic Locking Type</b></em>' enumerators. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static final List<XmlOptimisticLockingType> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); - - /** - * Returns the '<em><b>Xml Optimistic Locking Type</b></em>' literal with the specified literal value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlOptimisticLockingType get(String literal) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlOptimisticLockingType result = VALUES_ARRAY[i]; - if (result.toString().equals(literal)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Optimistic Locking Type</b></em>' literal with the specified name. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlOptimisticLockingType getByName(String name) - { - for (int i = 0; i < VALUES_ARRAY.length; ++i) - { - XmlOptimisticLockingType result = VALUES_ARRAY[i]; - if (result.getName().equals(name)) - { - return result; - } - } - return null; - } - - /** - * Returns the '<em><b>Xml Optimistic Locking Type</b></em>' literal with the specified integer value. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public static XmlOptimisticLockingType get(int value) - { - switch (value) - { - case ALL_COLUMNS_VALUE: return ALL_COLUMNS; - case CHANGED_COLUMNS_VALUE: return CHANGED_COLUMNS; - case SELECTED_COLUMNS_VALUE: return SELECTED_COLUMNS; - case VERSION_COLUMN_VALUE: return VERSION_COLUMN; - } - return null; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final int value; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String name; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private final String literal; - - /** - * Only this class can construct instances. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - private XmlOptimisticLockingType(int value, String name, String literal) - { - this.value = value; - this.name = name; - this.literal = literal; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public int getValue() - { - return value; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getName() - { - return name; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public String getLiteral() - { - return literal; - } - - /** - * Returns the literal value of the enumerator, which is its string representation. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - return literal; - } - -} //XmlOptimisticLockingType diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPersistenceUnitMetadata.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPersistenceUnitMetadata.java deleted file mode 100644 index 366f7f1c56..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPersistenceUnitMetadata.java +++ /dev/null @@ -1,205 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Persistence Unit Metadata</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata#isExcludeDefaultMappings <em>Exclude Default Mappings</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPersistenceUnitMetadata() - * @model kind="class" - * @generated - */ -public class XmlPersistenceUnitMetadata extends org.eclipse.jpt.core.resource.orm.XmlPersistenceUnitMetadata -{ - /** - * The default value of the '{@link #isExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isExcludeDefaultMappings() - * @generated - * @ordered - */ - protected static final boolean EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT = false; - - /** - * The cached value of the '{@link #isExcludeDefaultMappings() <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #isExcludeDefaultMappings() - * @generated - * @ordered - */ - protected boolean excludeDefaultMappings = EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlPersistenceUnitMetadata() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_PERSISTENCE_UNIT_METADATA; - } - - /** - * Returns the value of the '<em><b>Exclude Default Mappings</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Exclude Default Mappings</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #setExcludeDefaultMappings(boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPersistenceUnitMetadata_ExcludeDefaultMappings() - * @model dataType="org.eclipse.emf.ecore.xml.type.Boolean" - * @generated - */ - public boolean isExcludeDefaultMappings() - { - return excludeDefaultMappings; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPersistenceUnitMetadata#isExcludeDefaultMappings <em>Exclude Default Mappings</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Exclude Default Mappings</em>' attribute. - * @see #isExcludeDefaultMappings() - * @generated - */ - public void setExcludeDefaultMappings(boolean newExcludeDefaultMappings) - { - boolean oldExcludeDefaultMappings = excludeDefaultMappings; - excludeDefaultMappings = newExcludeDefaultMappings; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS, oldExcludeDefaultMappings, excludeDefaultMappings)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS: - return isExcludeDefaultMappings() ? Boolean.TRUE : Boolean.FALSE; - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings(((Boolean)newValue).booleanValue()); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS: - setExcludeDefaultMappings(EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PERSISTENCE_UNIT_METADATA__EXCLUDE_DEFAULT_MAPPINGS: - return excludeDefaultMappings != EXCLUDE_DEFAULT_MAPPINGS_EDEFAULT; - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (excludeDefaultMappings: "); - result.append(excludeDefaultMappings); - result.append(')'); - return result.toString(); - } - -} // XmlPersistenceUnitMetadata diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPrivateOwned.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPrivateOwned.java deleted file mode 100644 index d81933b1de..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlPrivateOwned.java +++ /dev/null @@ -1,72 +0,0 @@ -/** - * <copyright> - * </copyright> - * - * $Id: XmlPrivateOwned.java,v 1.4 2009/01/05 21:39:49 kmoore Exp $ - */ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Private Owned</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned#isPrivateOwned <em>Private Owned</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlPrivateOwned extends JpaEObject -{ - /** - * Returns the value of the '<em><b>Private Owned</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Private Owned</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Private Owned</em>' attribute. - * @see #setPrivateOwned(boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlPrivateOwned_PrivateOwned() - * @model dataType="org.eclipse.emf.ecore.xml.type.Boolean" - * @generated - */ - boolean isPrivateOwned(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlPrivateOwned#isPrivateOwned <em>Private Owned</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Private Owned</em>' attribute. - * @see #isPrivateOwned() - * @generated - */ - void setPrivateOwned(boolean value); - - /** - * Return the {@link TextRange} for the private-owned attibute. - */ - TextRange getPrivateOwnedTextRange(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlProperty.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlProperty.java deleted file mode 100644 index bd49c7e3ad..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlProperty.java +++ /dev/null @@ -1,335 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Property</b></em>'. - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getName <em>Name</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValue <em>Value</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValueType <em>Value Type</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlProperty extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getValue() <em>Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getValue() - * @generated - * @ordered - */ - protected static final String VALUE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getValue() <em>Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getValue() - * @generated - * @ordered - */ - protected String value = VALUE_EDEFAULT; - - /** - * The default value of the '{@link #getValueType() <em>Value Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getValueType() - * @generated - * @ordered - */ - protected static final String VALUE_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getValueType() <em>Value Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getValueType() - * @generated - * @ordered - */ - protected String valueType = VALUE_TYPE_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlProperty() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_PROPERTY; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty_Name() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_PROPERTY__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Value</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Value</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Value</em>' attribute. - * @see #setValue(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty_Value() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getValue() - { - return value; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValue <em>Value</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Value</em>' attribute. - * @see #getValue() - * @generated - */ - public void setValue(String newValue) - { - String oldValue = value; - value = newValue; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_PROPERTY__VALUE, oldValue, value)); - } - - /** - * Returns the value of the '<em><b>Value Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Value 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>Value Type</em>' attribute. - * @see #setValueType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlProperty_ValueType() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getValueType() - { - return valueType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty#getValueType <em>Value Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Value Type</em>' attribute. - * @see #getValueType() - * @generated - */ - public void setValueType(String newValueType) - { - String oldValueType = valueType; - valueType = newValueType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_PROPERTY__VALUE_TYPE, oldValueType, valueType)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PROPERTY__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE: - return getValue(); - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE_TYPE: - return getValueType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PROPERTY__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE: - setValue((String)newValue); - return; - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE_TYPE: - setValueType((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PROPERTY__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE: - setValue(VALUE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE_TYPE: - setValueType(VALUE_TYPE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_PROPERTY__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE: - return VALUE_EDEFAULT == null ? value != null : !VALUE_EDEFAULT.equals(value); - case EclipseLinkOrmPackage.XML_PROPERTY__VALUE_TYPE: - return VALUE_TYPE_EDEFAULT == null ? valueType != null : !VALUE_TYPE_EDEFAULT.equals(valueType); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", value: "); - result.append(value); - result.append(", valueType: "); - result.append(valueType); - result.append(')'); - return result.toString(); - } - -} // XmlProperty diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlReadOnly.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlReadOnly.java deleted file mode 100644 index ee1b9327a8..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlReadOnly.java +++ /dev/null @@ -1,75 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.jpt.core.resource.common.JpaEObject; -import org.eclipse.jpt.core.utility.TextRange; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Read Only</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly#getReadOnly <em>Read Only</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly() - * @model kind="class" interface="true" abstract="true" - * @extends JpaEObject - * @generated - */ -public interface XmlReadOnly extends JpaEObject -{ - /** - * 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.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlReadOnly_ReadOnly() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - Boolean getReadOnly(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlReadOnly#getReadOnly <em>Read Only</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Read Only</em>' attribute. - * @see #getReadOnly() - * @generated - */ - void setReadOnly(Boolean value); - - /** - * Return the {@link TextRange} for the read-only attibute. - */ - TextRange getReadOnlyTextRange(); -}
\ No newline at end of file diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStoredProcedureParameter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStoredProcedureParameter.java deleted file mode 100644 index 8cf5b9378d..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStoredProcedureParameter.java +++ /dev/null @@ -1,548 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Stored Procedure Parameter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getDirection <em>Direction</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getName <em>Name</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getQueryParameter <em>Query Parameter</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getType <em>Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcType <em>Jdbc Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcTypeName <em>Jdbc Type Name</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlStoredProcedureParameter extends AbstractJpaEObject implements JpaEObject -{ - /** - * changed this to null and removed the generated flag so emf won't generate over it - * we don't want a default for enums, just null if the tag does not exist - */ - protected static final XmlDirection DIRECTION_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDirection() <em>Direction</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDirection() - * @generated - * @ordered - */ - protected XmlDirection direction = DIRECTION_EDEFAULT; - - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getQueryParameter() <em>Query Parameter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getQueryParameter() - * @generated - * @ordered - */ - protected static final String QUERY_PARAMETER_EDEFAULT = null; - - /** - * The cached value of the '{@link #getQueryParameter() <em>Query Parameter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getQueryParameter() - * @generated - * @ordered - */ - protected String queryParameter = QUERY_PARAMETER_EDEFAULT; - - /** - * The default value of the '{@link #getType() <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getType() - * @generated - * @ordered - */ - protected static final String TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getType() <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getType() - * @generated - * @ordered - */ - protected String type = TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getJdbcType() <em>Jdbc Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJdbcType() - * @generated - * @ordered - */ - protected static final Integer JDBC_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJdbcType() <em>Jdbc Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJdbcType() - * @generated - * @ordered - */ - protected Integer jdbcType = JDBC_TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getJdbcTypeName() <em>Jdbc Type Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJdbcTypeName() - * @generated - * @ordered - */ - protected static final String JDBC_TYPE_NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getJdbcTypeName() <em>Jdbc Type Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getJdbcTypeName() - * @generated - * @ordered - */ - protected String jdbcTypeName = JDBC_TYPE_NAME_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlStoredProcedureParameter() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_STORED_PROCEDURE_PARAMETER; - } - - /** - * Returns the value of the '<em><b>Direction</b></em>' attribute. - * The literals are from the enumeration {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Direction</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Direction</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection - * @see #setDirection(XmlDirection) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_Direction() - * @model - * @generated - */ - public XmlDirection getDirection() - { - return direction; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getDirection <em>Direction</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Direction</em>' attribute. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.XmlDirection - * @see #getDirection() - * @generated - */ - public void setDirection(XmlDirection newDirection) - { - XmlDirection oldDirection = direction; - direction = newDirection == null ? DIRECTION_EDEFAULT : newDirection; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__DIRECTION, oldDirection, direction)); - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_Name() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Query Parameter</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Query Parameter</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Query Parameter</em>' attribute. - * @see #setQueryParameter(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_QueryParameter() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getQueryParameter() - { - return queryParameter; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getQueryParameter <em>Query Parameter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Query Parameter</em>' attribute. - * @see #getQueryParameter() - * @generated - */ - public void setQueryParameter(String newQueryParameter) - { - String oldQueryParameter = queryParameter; - queryParameter = newQueryParameter; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER, oldQueryParameter, queryParameter)); - } - - /** - * Returns the value of the '<em><b>Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Type</em>' attribute. - * @see #setType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_Type() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getType() - { - return type; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getType <em>Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type</em>' attribute. - * @see #getType() - * @generated - */ - public void setType(String newType) - { - String oldType = type; - type = newType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__TYPE, oldType, type)); - } - - /** - * Returns the value of the '<em><b>Jdbc Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Jdbc 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>Jdbc Type</em>' attribute. - * @see #setJdbcType(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_JdbcType() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getJdbcType() - { - return jdbcType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcType <em>Jdbc Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Jdbc Type</em>' attribute. - * @see #getJdbcType() - * @generated - */ - public void setJdbcType(Integer newJdbcType) - { - Integer oldJdbcType = jdbcType; - jdbcType = newJdbcType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE, oldJdbcType, jdbcType)); - } - - /** - * Returns the value of the '<em><b>Jdbc Type Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Jdbc Type Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Jdbc Type Name</em>' attribute. - * @see #setJdbcTypeName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStoredProcedureParameter_JdbcTypeName() - * @model dataType="org.eclipse.emf.ecore.xml.type.String" - * @generated - */ - public String getJdbcTypeName() - { - return jdbcTypeName; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStoredProcedureParameter#getJdbcTypeName <em>Jdbc Type Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Jdbc Type Name</em>' attribute. - * @see #getJdbcTypeName() - * @generated - */ - public void setJdbcTypeName(String newJdbcTypeName) - { - String oldJdbcTypeName = jdbcTypeName; - jdbcTypeName = newJdbcTypeName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME, oldJdbcTypeName, jdbcTypeName)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__DIRECTION: - return getDirection(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER: - return getQueryParameter(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__TYPE: - return getType(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE: - return getJdbcType(); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME: - return getJdbcTypeName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__DIRECTION: - setDirection((XmlDirection)newValue); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER: - setQueryParameter((String)newValue); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__TYPE: - setType((String)newValue); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE: - setJdbcType((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME: - setJdbcTypeName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__DIRECTION: - setDirection(DIRECTION_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER: - setQueryParameter(QUERY_PARAMETER_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__TYPE: - setType(TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE: - setJdbcType(JDBC_TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME: - setJdbcTypeName(JDBC_TYPE_NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__DIRECTION: - return direction != DIRECTION_EDEFAULT; - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__QUERY_PARAMETER: - return QUERY_PARAMETER_EDEFAULT == null ? queryParameter != null : !QUERY_PARAMETER_EDEFAULT.equals(queryParameter); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__TYPE: - return TYPE_EDEFAULT == null ? type != null : !TYPE_EDEFAULT.equals(type); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE: - return JDBC_TYPE_EDEFAULT == null ? jdbcType != null : !JDBC_TYPE_EDEFAULT.equals(jdbcType); - case EclipseLinkOrmPackage.XML_STORED_PROCEDURE_PARAMETER__JDBC_TYPE_NAME: - return JDBC_TYPE_NAME_EDEFAULT == null ? jdbcTypeName != null : !JDBC_TYPE_NAME_EDEFAULT.equals(jdbcTypeName); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (direction: "); - result.append(direction); - result.append(", name: "); - result.append(name); - result.append(", queryParameter: "); - result.append(queryParameter); - result.append(", type: "); - result.append(type); - result.append(", jdbcType: "); - result.append(jdbcType); - result.append(", jdbcTypeName: "); - result.append(jdbcTypeName); - result.append(')'); - return result.toString(); - } - -} // XmlStoredProcedureParameter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverter.java deleted file mode 100644 index 4e4d8510db..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverter.java +++ /dev/null @@ -1,68 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Struct CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter#getConverter <em>Converter</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverter() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlStructConverter extends XmlNamedConverter -{ - /** - * Returns the value of the '<em><b>Converter</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Converter</em>' attribute. - * @see #setConverter(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverter_Converter() - * @model - * @generated - */ - String getConverter(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverter#getConverter <em>Converter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' attribute. - * @see #getConverter() - * @generated - */ - void setConverter(String value); - -} // XmlStructConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverterImpl.java deleted file mode 100644 index c0a2d63d79..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlStructConverterImpl.java +++ /dev/null @@ -1,266 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Struct CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverterImpl() - * @model kind="class" - * @generated - */ -public class XmlStructConverterImpl extends AbstractJpaEObject implements XmlStructConverter -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getConverter() <em>Converter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverter() - * @generated - * @ordered - */ - protected static final String CONVERTER_EDEFAULT = null; - - /** - * The cached value of the '{@link #getConverter() <em>Converter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverter() - * @generated - * @ordered - */ - protected String converter = CONVERTER_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlStructConverterImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_STRUCT_CONVERTER_IMPL; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter_Name() - * @model - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Converter</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Converter</em>' attribute. - * @see #setConverter(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlStructConverter_Converter() - * @model - * @generated - */ - public String getConverter() - { - return converter; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlStructConverterImpl#getConverter <em>Converter</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' attribute. - * @see #getConverter() - * @generated - */ - public void setConverter(String newConverter) - { - String oldConverter = converter; - converter = newConverter; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__CONVERTER, oldConverter, converter)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__CONVERTER: - return getConverter(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__CONVERTER: - setConverter((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__CONVERTER: - setConverter(CONVERTER_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_STRUCT_CONVERTER_IMPL__CONVERTER: - return CONVERTER_EDEFAULT == null ? converter != null : !CONVERTER_EDEFAULT.equals(converter); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", converter: "); - result.append(converter); - result.append(')'); - return result.toString(); - } - -} // XmlStructConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTimeOfDay.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTimeOfDay.java deleted file mode 100644 index 494a7e8110..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTimeOfDay.java +++ /dev/null @@ -1,411 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; -import org.eclipse.jpt.core.resource.common.JpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Time Of Day</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getHour <em>Hour</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMinute <em>Minute</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getSecond <em>Second</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMillisecond <em>Millisecond</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay() - * @model kind="class" - * @extends JpaEObject - * @generated - */ -public class XmlTimeOfDay extends AbstractJpaEObject implements JpaEObject -{ - /** - * The default value of the '{@link #getHour() <em>Hour</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getHour() - * @generated - * @ordered - */ - protected static final Integer HOUR_EDEFAULT = null; - - /** - * The cached value of the '{@link #getHour() <em>Hour</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getHour() - * @generated - * @ordered - */ - protected Integer hour = HOUR_EDEFAULT; - - /** - * The default value of the '{@link #getMinute() <em>Minute</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMinute() - * @generated - * @ordered - */ - protected static final Integer MINUTE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMinute() <em>Minute</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMinute() - * @generated - * @ordered - */ - protected Integer minute = MINUTE_EDEFAULT; - - /** - * The default value of the '{@link #getSecond() <em>Second</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSecond() - * @generated - * @ordered - */ - protected static final Integer SECOND_EDEFAULT = null; - - /** - * The cached value of the '{@link #getSecond() <em>Second</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getSecond() - * @generated - * @ordered - */ - protected Integer second = SECOND_EDEFAULT; - - /** - * The default value of the '{@link #getMillisecond() <em>Millisecond</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMillisecond() - * @generated - * @ordered - */ - protected static final Integer MILLISECOND_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMillisecond() <em>Millisecond</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMillisecond() - * @generated - * @ordered - */ - protected Integer millisecond = MILLISECOND_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlTimeOfDay() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_TIME_OF_DAY; - } - - /** - * Returns the value of the '<em><b>Hour</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Hour</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Hour</em>' attribute. - * @see #setHour(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay_Hour() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getHour() - { - return hour; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getHour <em>Hour</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Hour</em>' attribute. - * @see #getHour() - * @generated - */ - public void setHour(Integer newHour) - { - Integer oldHour = hour; - hour = newHour; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TIME_OF_DAY__HOUR, oldHour, hour)); - } - - /** - * Returns the value of the '<em><b>Minute</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Minute</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Minute</em>' attribute. - * @see #setMinute(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay_Minute() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getMinute() - { - return minute; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMinute <em>Minute</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Minute</em>' attribute. - * @see #getMinute() - * @generated - */ - public void setMinute(Integer newMinute) - { - Integer oldMinute = minute; - minute = newMinute; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TIME_OF_DAY__MINUTE, oldMinute, minute)); - } - - /** - * Returns the value of the '<em><b>Second</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Second</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Second</em>' attribute. - * @see #setSecond(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay_Second() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getSecond() - { - return second; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getSecond <em>Second</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Second</em>' attribute. - * @see #getSecond() - * @generated - */ - public void setSecond(Integer newSecond) - { - Integer oldSecond = second; - second = newSecond; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TIME_OF_DAY__SECOND, oldSecond, second)); - } - - /** - * Returns the value of the '<em><b>Millisecond</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Millisecond</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Millisecond</em>' attribute. - * @see #setMillisecond(Integer) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTimeOfDay_Millisecond() - * @model dataType="org.eclipse.emf.ecore.xml.type.IntObject" - * @generated - */ - public Integer getMillisecond() - { - return millisecond; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTimeOfDay#getMillisecond <em>Millisecond</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Millisecond</em>' attribute. - * @see #getMillisecond() - * @generated - */ - public void setMillisecond(Integer newMillisecond) - { - Integer oldMillisecond = millisecond; - millisecond = newMillisecond; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TIME_OF_DAY__MILLISECOND, oldMillisecond, millisecond)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__HOUR: - return getHour(); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MINUTE: - return getMinute(); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__SECOND: - return getSecond(); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MILLISECOND: - return getMillisecond(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__HOUR: - setHour((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MINUTE: - setMinute((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__SECOND: - setSecond((Integer)newValue); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MILLISECOND: - setMillisecond((Integer)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__HOUR: - setHour(HOUR_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MINUTE: - setMinute(MINUTE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__SECOND: - setSecond(SECOND_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MILLISECOND: - setMillisecond(MILLISECOND_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__HOUR: - return HOUR_EDEFAULT == null ? hour != null : !HOUR_EDEFAULT.equals(hour); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MINUTE: - return MINUTE_EDEFAULT == null ? minute != null : !MINUTE_EDEFAULT.equals(minute); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__SECOND: - return SECOND_EDEFAULT == null ? second != null : !SECOND_EDEFAULT.equals(second); - case EclipseLinkOrmPackage.XML_TIME_OF_DAY__MILLISECOND: - return MILLISECOND_EDEFAULT == null ? millisecond != null : !MILLISECOND_EDEFAULT.equals(millisecond); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (hour: "); - result.append(hour); - result.append(", minute: "); - result.append(minute); - result.append(", second: "); - result.append(second); - result.append(", millisecond: "); - result.append(millisecond); - result.append(')'); - return result.toString(); - } - -} // XmlTimeOfDay diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformation.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformation.java deleted file mode 100644 index 5f7dbcb993..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformation.java +++ /dev/null @@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Transformation</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformation#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformation() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlTransformation extends XmlAttributeMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformation_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlTransformation diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformationImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformationImpl.java deleted file mode 100644 index 542ccead94..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTransformationImpl.java +++ /dev/null @@ -1,321 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.orm.AbstractXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Transformation Impl</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. * - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformationImpl() - * @model kind="class" - * @generated - */ -public class XmlTransformationImpl extends AbstractXmlAttributeMapping implements XmlTransformation -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlTransformationImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_TRANSFORMATION_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTransformationImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTransformation_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlTransformation.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_TRANSFORMATION__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlTransformation.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_TRANSFORMATION__PROPERTIES: return EclipseLinkOrmPackage.XML_TRANSFORMATION_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - public String getMappingKey() { - return EclipseLinkMappingKeys.TRANSFORMATION_ATTRIBUTE_MAPPING_KEY; - } -} // XmlTransformationImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverter.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverter.java deleted file mode 100644 index 0961865166..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverter.java +++ /dev/null @@ -1,95 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Type CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getDataType <em>Data Type</em>}</li> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getObjectType <em>Object Type</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlTypeConverter extends XmlNamedConverter -{ - /** - * Returns the value of the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data 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>Data Type</em>' attribute. - * @see #setDataType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter_DataType() - * @model - * @generated - */ - String getDataType(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getDataType <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Type</em>' attribute. - * @see #getDataType() - * @generated - */ - void setDataType(String value); - - /** - * Returns the value of the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object 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>Object Type</em>' attribute. - * @see #setObjectType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter_ObjectType() - * @model - * @generated - */ - String getObjectType(); - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverter#getObjectType <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type</em>' attribute. - * @see #getObjectType() - * @generated - */ - void setObjectType(String value); - -} // XmlTypeConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverterImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverterImpl.java deleted file mode 100644 index d66bd0f0fd..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlTypeConverterImpl.java +++ /dev/null @@ -1,333 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.jpt.core.resource.common.AbstractJpaEObject; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Type CustomConverter</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverterImpl() - * @model kind="class" - * @generated - */ -public class XmlTypeConverterImpl extends AbstractJpaEObject implements XmlTypeConverter -{ - /** - * The default value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * The default value of the '{@link #getDataType() <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataType() - * @generated - * @ordered - */ - protected static final String DATA_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getDataType() <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getDataType() - * @generated - * @ordered - */ - protected String dataType = DATA_TYPE_EDEFAULT; - - /** - * The default value of the '{@link #getObjectType() <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectType() - * @generated - * @ordered - */ - protected static final String OBJECT_TYPE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getObjectType() <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectType() - * @generated - * @ordered - */ - protected String objectType = OBJECT_TYPE_EDEFAULT; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlTypeConverterImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_TYPE_CONVERTER_IMPL; - } - - /** - * Returns the value of the '<em><b>Name</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Name</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Name</em>' attribute. - * @see #setName(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlNamedConverter_Name() - * @model - * @generated - */ - public String getName() - { - return name; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl#getName <em>Name</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Name</em>' attribute. - * @see #getName() - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__NAME, oldName, name)); - } - - /** - * Returns the value of the '<em><b>Data Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Data 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>Data Type</em>' attribute. - * @see #setDataType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter_DataType() - * @model - * @generated - */ - public String getDataType() - { - return dataType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl#getDataType <em>Data Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Data Type</em>' attribute. - * @see #getDataType() - * @generated - */ - public void setDataType(String newDataType) - { - String oldDataType = dataType; - dataType = newDataType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__DATA_TYPE, oldDataType, dataType)); - } - - /** - * Returns the value of the '<em><b>Object Type</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object 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>Object Type</em>' attribute. - * @see #setObjectType(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlTypeConverter_ObjectType() - * @model - * @generated - */ - public String getObjectType() - { - return objectType; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlTypeConverterImpl#getObjectType <em>Object Type</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type</em>' attribute. - * @see #getObjectType() - * @generated - */ - public void setObjectType(String newObjectType) - { - String oldObjectType = objectType; - objectType = newObjectType; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE, oldObjectType, objectType)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__NAME: - return getName(); - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__DATA_TYPE: - return getDataType(); - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - return getObjectType(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__NAME: - setName((String)newValue); - return; - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__DATA_TYPE: - setDataType((String)newValue); - return; - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - setObjectType((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__NAME: - setName(NAME_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__DATA_TYPE: - setDataType(DATA_TYPE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - setObjectType(OBJECT_TYPE_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__DATA_TYPE: - return DATA_TYPE_EDEFAULT == null ? dataType != null : !DATA_TYPE_EDEFAULT.equals(dataType); - case EclipseLinkOrmPackage.XML_TYPE_CONVERTER_IMPL__OBJECT_TYPE: - return OBJECT_TYPE_EDEFAULT == null ? objectType != null : !OBJECT_TYPE_EDEFAULT.equals(objectType); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(", dataType: "); - result.append(dataType); - result.append(", objectType: "); - result.append(objectType); - result.append(')'); - return result.toString(); - } - -} // XmlTypeConverter diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOne.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOne.java deleted file mode 100644 index fd53b42636..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOne.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.jpt.core.resource.orm.XmlAttributeMapping; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Variable One To One</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOne#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOne() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlVariableOneToOne extends XmlAttributeMapping, XmlAccessMethodsHolder -{ - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOne_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); - -} // XmlVariableOneToOne diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOneImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOneImpl.java deleted file mode 100644 index 87021c921c..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVariableOneToOneImpl.java +++ /dev/null @@ -1,329 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2009 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.resource.orm.AbstractXmlAttributeMapping; -import org.eclipse.jpt.eclipselink.core.EclipseLinkMappingKeys; - -/** - * <!-- begin-user-doc --> - * A representation of the model object '<em><b>Xml Variable One To One Impl</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.2 - * @since 2.2 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOneImpl() - * @model kind="class" - * @generated - */ -public class XmlVariableOneToOneImpl extends AbstractXmlAttributeMapping implements XmlVariableOneToOne -{ - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlVariableOneToOneImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_VARIABLE_ONE_TO_ONE_IMPL; - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVariableOneToOneImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVariableOneToOne_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES); - } - return properties; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlVariableOneToOne.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE__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 == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlVariableOneToOne.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE__PROPERTIES: return EclipseLinkOrmPackage.XML_VARIABLE_ONE_TO_ONE_IMPL__PROPERTIES; - default: return -1; - } - } - return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); - } - - public String getMappingKey() { - return EclipseLinkMappingKeys.VARIABLE_ONE_TO_ONE_ATTRIBUTE_MAPPING_KEY; - } -} // XmlVariableOneToOneImpl diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersion.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersion.java deleted file mode 100644 index 73e295a5d0..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersion.java +++ /dev/null @@ -1,60 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -import org.eclipse.emf.common.util.EList; - - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Version</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * <p> - * The following features are supported: - * <ul> - * <li>{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersion#getProperties <em>Properties</em>}</li> - * </ul> - * </p> - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersion() - * @model kind="class" interface="true" abstract="true" - * @generated - */ -public interface XmlVersion extends org.eclipse.jpt.core.resource.orm.XmlVersion, XmlMutable, XmlConvertibleMapping, XmlAccessMethodsHolder -{ - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersion_Properties() - * @model containment="true" - * @generated - */ - EList<XmlProperty> getProperties(); -} // XmlVersion diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersionImpl.java b/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersionImpl.java deleted file mode 100644 index b6d9706180..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.core/src/org/eclipse/jpt/eclipselink/core/resource/orm/XmlVersionImpl.java +++ /dev/null @@ -1,859 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.core.resource.orm; - -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.jpt.core.utility.TextRange; -import org.eclipse.jpt.eclipselink.core.internal.resource.orm.translators.EclipseLinkOrmXmlMapper; - -/** - * <!-- begin-user-doc --> - * - * A representation of the model object '<em><b>Xml Version</b></em>'. - * - * Provisional API: This interface is part of an interim API that is still - * under development and expected to change significantly before reaching - * stability. It is available at this early stage to solicit feedback from - * pioneering adopters on the understanding that any code that uses this API - * will almost certainly be broken (repeatedly) as the API evolves. - * - * @version 2.1 - * @since 2.1 - * - * <!-- end-user-doc --> - * - * - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersionImpl() - * @model kind="class" - * @generated - */ -public class XmlVersionImpl extends org.eclipse.jpt.core.resource.orm.XmlVersionImpl implements XmlVersion -{ - /** - * The default value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected static final Boolean MUTABLE_EDEFAULT = null; - - /** - * The cached value of the '{@link #getMutable() <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getMutable() - * @generated - * @ordered - */ - protected Boolean mutable = MUTABLE_EDEFAULT; - - /** - * The cached value of the '{@link #getConverter() <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConverter() - * @generated - * @ordered - */ - protected XmlConverter converter; - - /** - * The cached value of the '{@link #getTypeConverter() <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getTypeConverter() - * @generated - * @ordered - */ - protected XmlTypeConverter typeConverter; - - /** - * The cached value of the '{@link #getObjectTypeConverter() <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getObjectTypeConverter() - * @generated - * @ordered - */ - protected XmlObjectTypeConverter objectTypeConverter; - - /** - * The cached value of the '{@link #getStructConverter() <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getStructConverter() - * @generated - * @ordered - */ - protected XmlStructConverter structConverter; - - /** - * The default value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected static final String CONVERT_EDEFAULT = null; - - /** - * The cached value of the '{@link #getConvert() <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getConvert() - * @generated - * @ordered - */ - protected String convert = CONVERT_EDEFAULT; - - /** - * The cached value of the '{@link #getAccessMethods() <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getAccessMethods() - * @generated - * @ordered - */ - protected XmlAccessMethods accessMethods; - - /** - * The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see #getProperties() - * @generated - * @ordered - */ - protected EList<XmlProperty> properties; - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - protected XmlVersionImpl() - { - super(); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - protected EClass eStaticClass() - { - return EclipseLinkOrmPackage.Literals.XML_VERSION_IMPL; - } - - /** - * Returns the value of the '<em><b>Mutable</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Mutable</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Mutable</em>' attribute. - * @see #setMutable(Boolean) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlMutable_Mutable() - * @model dataType="org.eclipse.emf.ecore.xml.type.BooleanObject" - * @generated - */ - public Boolean getMutable() - { - return mutable; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getMutable <em>Mutable</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Mutable</em>' attribute. - * @see #getMutable() - * @generated - */ - public void setMutable(Boolean newMutable) - { - Boolean oldMutable = mutable; - mutable = newMutable; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE, oldMutable, mutable)); - } - - /** - * Returns the value of the '<em><b>Convert</b></em>' attribute. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Convert</em>' attribute isn't clear, - * there really should be more of a description here... - * </p> - * <!-- end-user-doc --> - * @return the value of the '<em>Convert</em>' attribute. - * @see #setConvert(String) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConvertibleMapping_Convert() - * @model - * @generated - */ - public String getConvert() - { - return convert; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getConvert <em>Convert</em>}' attribute. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Convert</em>' attribute. - * @see #getConvert() - * @generated - */ - public void setConvert(String newConvert) - { - String oldConvert = convert; - convert = newConvert; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT, oldConvert, convert)); - } - - /** - * Returns the value of the '<em><b>Access Methods</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Access Methods</em>' containment reference. - * @see #setAccessMethods(XmlAccessMethods) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlAccessMethodsHolder_AccessMethods() - * @model containment="true" - * @generated - */ - public XmlAccessMethods getAccessMethods() - { - return accessMethods; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetAccessMethods(XmlAccessMethods newAccessMethods, NotificationChain msgs) - { - XmlAccessMethods oldAccessMethods = accessMethods; - accessMethods = newAccessMethods; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS, oldAccessMethods, newAccessMethods); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getAccessMethods <em>Access Methods</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Access Methods</em>' containment reference. - * @see #getAccessMethods() - * @generated - */ - public void setAccessMethods(XmlAccessMethods newAccessMethods) - { - if (newAccessMethods != accessMethods) - { - NotificationChain msgs = null; - if (accessMethods != null) - msgs = ((InternalEObject)accessMethods).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS, null, msgs); - if (newAccessMethods != null) - msgs = ((InternalEObject)newAccessMethods).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS, null, msgs); - msgs = basicSetAccessMethods(newAccessMethods, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS, newAccessMethods, newAccessMethods)); - } - - /** - * Returns the value of the '<em><b>Properties</b></em>' containment reference list. - * The list contents are of type {@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlProperty}. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>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>Properties</em>' containment reference list. - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlVersion_Properties() - * @model containment="true" - * @generated - */ - public EList<XmlProperty> getProperties() - { - if (properties == null) - { - properties = new EObjectContainmentEList<XmlProperty>(XmlProperty.class, this, EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES); - } - return properties; - } - - /** - * Returns the value of the '<em><b>Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>CustomConverter</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>Converter</em>' containment reference. - * @see #setConverter(XmlConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_Converter() - * @model containment="true" - * @generated - */ - public XmlConverter getConverter() - { - return converter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetConverter(XmlConverter newConverter, NotificationChain msgs) - { - XmlConverter oldConverter = converter; - converter = newConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER, oldConverter, newConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getConverter <em>Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Converter</em>' containment reference. - * @see #getConverter() - * @generated - */ - public void setConverter(XmlConverter newConverter) - { - if (newConverter != converter) - { - NotificationChain msgs = null; - if (converter != null) - msgs = ((InternalEObject)converter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER, null, msgs); - if (newConverter != null) - msgs = ((InternalEObject)newConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER, null, msgs); - msgs = basicSetConverter(newConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER, newConverter, newConverter)); - } - - /** - * Returns the value of the '<em><b>Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Type CustomConverter</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>Type Converter</em>' containment reference. - * @see #setTypeConverter(XmlTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_TypeConverter() - * @model containment="true" - * @generated - */ - public XmlTypeConverter getTypeConverter() - { - return typeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetTypeConverter(XmlTypeConverter newTypeConverter, NotificationChain msgs) - { - XmlTypeConverter oldTypeConverter = typeConverter; - typeConverter = newTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER, oldTypeConverter, newTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getTypeConverter <em>Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Type Converter</em>' containment reference. - * @see #getTypeConverter() - * @generated - */ - public void setTypeConverter(XmlTypeConverter newTypeConverter) - { - if (newTypeConverter != typeConverter) - { - NotificationChain msgs = null; - if (typeConverter != null) - msgs = ((InternalEObject)typeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER, null, msgs); - if (newTypeConverter != null) - msgs = ((InternalEObject)newTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER, null, msgs); - msgs = basicSetTypeConverter(newTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER, newTypeConverter, newTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Object Type Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Object Type CustomConverter</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>Object Type Converter</em>' containment reference. - * @see #setObjectTypeConverter(XmlObjectTypeConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_ObjectTypeConverter() - * @model containment="true" - * @generated - */ - public XmlObjectTypeConverter getObjectTypeConverter() - { - return objectTypeConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter, NotificationChain msgs) - { - XmlObjectTypeConverter oldObjectTypeConverter = objectTypeConverter; - objectTypeConverter = newObjectTypeConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER, oldObjectTypeConverter, newObjectTypeConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getObjectTypeConverter <em>Object Type Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Object Type Converter</em>' containment reference. - * @see #getObjectTypeConverter() - * @generated - */ - public void setObjectTypeConverter(XmlObjectTypeConverter newObjectTypeConverter) - { - if (newObjectTypeConverter != objectTypeConverter) - { - NotificationChain msgs = null; - if (objectTypeConverter != null) - msgs = ((InternalEObject)objectTypeConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - if (newObjectTypeConverter != null) - msgs = ((InternalEObject)newObjectTypeConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER, null, msgs); - msgs = basicSetObjectTypeConverter(newObjectTypeConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER, newObjectTypeConverter, newObjectTypeConverter)); - } - - /** - * Returns the value of the '<em><b>Struct Converter</b></em>' containment reference. - * <!-- begin-user-doc --> - * <p> - * If the meaning of the '<em>Struct CustomConverter</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>Struct Converter</em>' containment reference. - * @see #setStructConverter(XmlStructConverter) - * @see org.eclipse.jpt.eclipselink.core.resource.orm.EclipseLinkOrmPackage#getXmlConverterHolder_StructConverter() - * @model containment="true" - * @generated - */ - public XmlStructConverter getStructConverter() - { - return structConverter; - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - public NotificationChain basicSetStructConverter(XmlStructConverter newStructConverter, NotificationChain msgs) - { - XmlStructConverter oldStructConverter = structConverter; - structConverter = newStructConverter; - if (eNotificationRequired()) - { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER, oldStructConverter, newStructConverter); - if (msgs == null) msgs = notification; else msgs.add(notification); - } - return msgs; - } - - /** - * Sets the value of the '{@link org.eclipse.jpt.eclipselink.core.resource.orm.XmlVersionImpl#getStructConverter <em>Struct Converter</em>}' containment reference. - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @param value the new value of the '<em>Struct Converter</em>' containment reference. - * @see #getStructConverter() - * @generated - */ - public void setStructConverter(XmlStructConverter newStructConverter) - { - if (newStructConverter != structConverter) - { - NotificationChain msgs = null; - if (structConverter != null) - msgs = ((InternalEObject)structConverter).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER, null, msgs); - if (newStructConverter != null) - msgs = ((InternalEObject)newStructConverter).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER, null, msgs); - msgs = basicSetStructConverter(newStructConverter, msgs); - if (msgs != null) msgs.dispatch(); - } - else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER, newStructConverter, newStructConverter)); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: - return basicSetConverter(null, msgs); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: - return basicSetTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: - return basicSetObjectTypeConverter(null, msgs); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: - return basicSetStructConverter(null, msgs); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: - return basicSetAccessMethods(null, msgs); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: - return ((InternalEList<?>)getProperties()).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 EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE: - return getMutable(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: - return getConverter(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: - return getTypeConverter(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: - return getObjectTypeConverter(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: - return getStructConverter(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT: - return getConvert(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: - return getAccessMethods(); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: - return getProperties(); - } - 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 EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE: - setMutable((Boolean)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: - setConverter((XmlConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT: - setConvert((String)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)newValue); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: - getProperties().clear(); - getProperties().addAll((Collection<? extends XmlProperty>)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE: - setMutable(MUTABLE_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: - setConverter((XmlConverter)null); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: - setTypeConverter((XmlTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: - setObjectTypeConverter((XmlObjectTypeConverter)null); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: - setStructConverter((XmlStructConverter)null); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT: - setConvert(CONVERT_EDEFAULT); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: - setAccessMethods((XmlAccessMethods)null); - return; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: - getProperties().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE: - return MUTABLE_EDEFAULT == null ? mutable != null : !MUTABLE_EDEFAULT.equals(mutable); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: - return converter != null; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: - return typeConverter != null; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: - return objectTypeConverter != null; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: - return structConverter != null; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT: - return CONVERT_EDEFAULT == null ? convert != null : !CONVERT_EDEFAULT.equals(convert); - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: - return accessMethods != null; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: - return properties != null && !properties.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @generated - */ - @Override - public int eBaseStructuralFeatureID(int derivedFeatureID, Class<?> baseClass) - { - if (baseClass == XmlMutable.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE: return EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT: return EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlVersion.class) - { - switch (derivedFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION_IMPL__PROPERTIES: return EclipseLinkOrmPackage.XML_VERSION__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 == XmlMutable.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_MUTABLE__MUTABLE: return EclipseLinkOrmPackage.XML_VERSION_IMPL__MUTABLE; - default: return -1; - } - } - if (baseClass == XmlConverterHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__CONVERTER: return EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_VERSION_IMPL__TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__OBJECT_TYPE_CONVERTER: return EclipseLinkOrmPackage.XML_VERSION_IMPL__OBJECT_TYPE_CONVERTER; - case EclipseLinkOrmPackage.XML_CONVERTER_HOLDER__STRUCT_CONVERTER: return EclipseLinkOrmPackage.XML_VERSION_IMPL__STRUCT_CONVERTER; - default: return -1; - } - } - if (baseClass == XmlConvertibleMapping.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_CONVERTIBLE_MAPPING__CONVERT: return EclipseLinkOrmPackage.XML_VERSION_IMPL__CONVERT; - default: return -1; - } - } - if (baseClass == XmlAccessMethodsHolder.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_ACCESS_METHODS_HOLDER__ACCESS_METHODS: return EclipseLinkOrmPackage.XML_VERSION_IMPL__ACCESS_METHODS; - default: return -1; - } - } - if (baseClass == XmlVersion.class) - { - switch (baseFeatureID) - { - case EclipseLinkOrmPackage.XML_VERSION__PROPERTIES: return EclipseLinkOrmPackage.XML_VERSION_IMPL__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(" (mutable: "); - result.append(mutable); - result.append(", convert: "); - result.append(convert); - result.append(')'); - return result.toString(); - } - - public TextRange getMutableTextRange() { - return getAttributeTextRange(EclipseLinkOrmXmlMapper.MUTABLE); - } - - public TextRange getConvertTextRange() { - return getElementTextRange(EclipseLinkOrmXmlMapper.CONVERT); - } -} |