diff options
Diffstat (limited to 'jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/details/orm/AbstractOrmEclipseLinkMappedSuperclassComposite.java')
-rw-r--r-- | jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/details/orm/AbstractOrmEclipseLinkMappedSuperclassComposite.java | 109 |
1 files changed, 0 insertions, 109 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/details/orm/AbstractOrmEclipseLinkMappedSuperclassComposite.java b/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/details/orm/AbstractOrmEclipseLinkMappedSuperclassComposite.java deleted file mode 100644 index 530c96f4b3..0000000000 --- a/jpa/plugins/org.eclipse.jpt.eclipselink.ui/src/org/eclipse/jpt/eclipselink/ui/internal/details/orm/AbstractOrmEclipseLinkMappedSuperclassComposite.java +++ /dev/null @@ -1,109 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2008, 2010 Oracle. All rights reserved. - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0, which accompanies this distribution - * and is available at http://www.eclipse.org/legal/epl-v10.html. - * - * Contributors: - * Oracle - initial API and implementation - ******************************************************************************/ -package org.eclipse.jpt.eclipselink.ui.internal.details.orm; - -import org.eclipse.jpt.core.context.AccessHolder; -import org.eclipse.jpt.eclipselink.core.context.orm.OrmEclipseLinkConverterContainer; -import org.eclipse.jpt.eclipselink.core.context.orm.OrmEclipseLinkCaching; -import org.eclipse.jpt.eclipselink.core.context.orm.OrmEclipseLinkMappedSuperclass; -import org.eclipse.jpt.eclipselink.ui.internal.details.EclipseLinkMappedSuperclassAdvancedComposite; -import org.eclipse.jpt.eclipselink.ui.internal.details.EclipseLinkUiDetailsMessages; -import org.eclipse.jpt.ui.WidgetFactory; -import org.eclipse.jpt.ui.details.JpaComposite; -import org.eclipse.jpt.ui.internal.details.AbstractMappedSuperclassComposite; -import org.eclipse.jpt.ui.internal.details.AccessTypeComposite; -import org.eclipse.jpt.ui.internal.details.IdClassComposite; -import org.eclipse.jpt.ui.internal.details.orm.MetadataCompleteComposite; -import org.eclipse.jpt.ui.internal.details.orm.OrmJavaClassChooser; -import org.eclipse.jpt.utility.internal.model.value.PropertyAspectAdapter; -import org.eclipse.jpt.utility.model.value.PropertyValueModel; -import org.eclipse.swt.widgets.Composite; - -public abstract class AbstractOrmEclipseLinkMappedSuperclassComposite<T extends OrmEclipseLinkMappedSuperclass> - extends AbstractMappedSuperclassComposite<T> - implements JpaComposite -{ - protected AbstractOrmEclipseLinkMappedSuperclassComposite( - PropertyValueModel<? extends T> subjectHolder, - Composite parent, WidgetFactory widgetFactory) { - - super(subjectHolder, parent, widgetFactory); - } - - - @Override - protected void initializeLayout(Composite container) { - this.initializeMappedSuperclassCollapsibleSection(container); - this.initializeCachingCollapsibleSection(container); - this.initializeConvertersCollapsibleSection(container); - this.initializeAdvancedCollapsibleSection(container); - } - - @Override - protected void initializeMappedSuperclassSection(Composite container) { - new OrmJavaClassChooser(this, getSubjectHolder(), container); - new AccessTypeComposite(this, buildAccessHolder(), container); - new IdClassComposite(this, buildIdClassReferenceHolder(), container); - new MetadataCompleteComposite(this, getSubjectHolder(), container); - } - - protected void initializeCachingCollapsibleSection(Composite container) { - container = addCollapsibleSection( - container, - EclipseLinkUiDetailsMessages.EclipseLinkTypeMappingComposite_caching); - this.initializeCachingSection(container, buildCachingHolder()); - } - - protected void initializeCachingSection(Composite container, PropertyValueModel<OrmEclipseLinkCaching> cachingHolder) { - new OrmEclipseLinkCachingComposite(this, cachingHolder, container); - } - - protected PropertyValueModel<AccessHolder> buildAccessHolder() { - return new PropertyAspectAdapter<T, AccessHolder>(getSubjectHolder()) { - @Override - protected AccessHolder buildValue_() { - return this.subject.getPersistentType(); - } - }; - } - - private PropertyAspectAdapter<T, OrmEclipseLinkCaching> buildCachingHolder() { - return new PropertyAspectAdapter<T, OrmEclipseLinkCaching>(getSubjectHolder()) { - @Override - protected OrmEclipseLinkCaching buildValue_() { - return this.subject.getCaching(); - } - }; - } - - protected void initializeConvertersCollapsibleSection(Composite container) { - container = addCollapsibleSection( - container, - EclipseLinkUiDetailsMessages.EclipseLinkTypeMappingComposite_converters); - this.initializeConvertersSection(container, buildConverterContainerModel()); - } - - protected void initializeConvertersSection(Composite container, PropertyValueModel<OrmEclipseLinkConverterContainer> converterHolder) { - new OrmEclipseLinkConvertersComposite(this, converterHolder, container); - } - - private PropertyValueModel<OrmEclipseLinkConverterContainer> buildConverterContainerModel() { - return new PropertyAspectAdapter<T, OrmEclipseLinkConverterContainer>(getSubjectHolder()) { - @Override - protected OrmEclipseLinkConverterContainer buildValue_() { - return this.subject.getConverterContainer(); - } - }; - } - - protected void initializeAdvancedCollapsibleSection(Composite container) { - new EclipseLinkMappedSuperclassAdvancedComposite(this, container); - } -} |