TDI-27656 : several ways to reduce the size of the file:_java.xml

git-svn-id: http://talendforge.org/svn/tos/trunk@118448 f6f1c999-d317-4740-80b0-e6d1abc6f99e
This commit is contained in:
ycbai
2014-06-11 03:45:13 +00:00
parent c92a1ea27c
commit 024e6fc360
19 changed files with 908 additions and 37 deletions

View File

@@ -176,8 +176,14 @@ public class CopyObjectAction {
List<IRepositoryViewObject> allVersion = factory.getAllVersion(originalItem.getProperty().getId());
if (allVersion.size() == 1) {
copySingleVersionItem(originalItem, path);
Item curItem = originalItem;
for (IRepositoryViewObject obj : allVersion) {
if (obj.getVersion().equals(originalItem.getProperty().getVersion())) {
curItem = obj.getProperty().getItem();
break;
}
}
copySingleVersionItem(curItem, path);
} else if (allVersion.size() > 1) {
PastSelectorDialog dialog = new PastSelectorDialog(Display.getCurrent().getActiveShell(), allVersion, sourceNode);
if (dialog.open() == Window.OK) {

View File

@@ -12,13 +12,14 @@
<element name="extension">
<annotation>
<appInfo>
<appinfo>
<meta.element />
</appInfo>
</appinfo>
</annotation>
<complexType>
<sequence minOccurs="0" maxOccurs="unbounded">
<element ref="libraryNeeded"/>
<element ref="libraryNeededGroup"/>
</sequence>
<attribute name="point" type="string" use="required">
<annotation>
@@ -39,9 +40,9 @@
<documentation>
</documentation>
<appInfo>
<appinfo>
<meta.attribute translatable="true"/>
</appInfo>
</appinfo>
</annotation>
</attribute>
</complexType>
@@ -49,11 +50,25 @@
<element name="libraryNeeded">
<annotation>
<appInfo>
<appinfo>
<meta.element labelAttribute="name"/>
</appInfo>
</appinfo>
</annotation>
<complexType>
<attribute name="id" type="string">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
<attribute name="bundleID" type="string">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
<attribute name="name" type="string" use="required">
<annotation>
<documentation>
@@ -73,9 +88,9 @@
<documentation>
</documentation>
<appInfo>
<appinfo>
<meta.attribute translatable="true"/>
</appInfo>
</appinfo>
</annotation>
</attribute>
<attribute name="message" type="string">
@@ -83,9 +98,9 @@
<documentation>
</documentation>
<appInfo>
<appinfo>
<meta.attribute translatable="true"/>
</appInfo>
</appinfo>
</annotation>
</attribute>
<attribute name="language" type="string">
@@ -105,6 +120,60 @@
</complexType>
</element>
<element name="libraryNeededGroup">
<complexType>
<sequence minOccurs="0" maxOccurs="unbounded">
<element ref="library" minOccurs="0" maxOccurs="unbounded"/>
<element ref="group" minOccurs="0" maxOccurs="unbounded"/>
</sequence>
<attribute name="id" type="string" use="required">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
<attribute name="name" type="string" use="required">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
<attribute name="description" type="string">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
</complexType>
</element>
<element name="library">
<complexType>
<attribute name="id" type="string" use="required">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
</complexType>
</element>
<element name="group">
<complexType>
<attribute name="id" type="string" use="required">
<annotation>
<documentation>
</documentation>
</annotation>
</attribute>
</complexType>
</element>
<annotation>
<appinfo>
<meta.section type="since"/>

View File

@@ -25,6 +25,8 @@ import org.talend.core.runtime.CoreRuntimePlugin;
*/
public class ModuleNeeded {
private String id;
private String context;
private String moduleName;
@@ -101,6 +103,10 @@ public class ModuleNeeded {
return requiredIf;
}
public void setRequiredIf(String requiredIf) {
this.requiredIf = requiredIf;
}
/**
* Check if the library is required depends the condition of "required if". Note that if the flag "required=true" in
* the xml of component, it will never check in the required_if.
@@ -256,6 +262,14 @@ public class ModuleNeeded {
this.mrRequired = mrRequired;
}
public String getId() {
return this.id;
}
public void setId(String id) {
this.id = id;
}
@Override
public String toString() {
if (bundleName == null) {

View File

@@ -508,6 +508,17 @@ public abstract class AContextualAction extends Action implements ITreeContextua
return isUnderDBConnection(node.getParent());
}
protected boolean isUnderValidationRuleConnection(IRepositoryNode repNode) {
if (repNode == null) {
return false;
}
if ((repNode.getType() == ENodeType.SYSTEM_FOLDER || repNode.getType() == ENodeType.STABLE_SYSTEM_FOLDER)
&& repNode.getProperties(EProperties.CONTENT_TYPE) == ERepositoryObjectType.METADATA_VALIDATION_RULES) {
return true;
}
return isUnderValidationRuleConnection(repNode.getParent());
}
/**
* Display a "Save job" prompt dialog if the job eidtor of the selectedNode is unsaved.
*/

View File

@@ -1,8 +1,9 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Test
Bundle-SymbolicName: org.talend.librariesmanager.test
Bundle-SymbolicName: org.talend.librariesmanager.test;singleton:=true
Bundle-Version: 1.0.0.qualifier
Fragment-Host: org.talend.librariesmanager
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Require-Bundle: org.junit4;bundle-version="4.8.1"
Require-Bundle: org.junit4;bundle-version="4.8.1",
org.talend.testutils

View File

@@ -1,4 +1,5 @@
source.. = src/
output.. = bin/
bin.includes = META-INF/,\
.
.,\
fragment.xml

View File

@@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<fragment>
<extension
point="org.talend.core.runtime.librariesNeeded">
<libraryNeededGroup
description="A test jars group."
id="test-jars-group"
name="Test JARS Group">
<library
id="test_jar1">
</library>
<library
id="test_jar2">
</library>
<library
id="test_jar3">
</library>
</libraryNeededGroup>
</extension>
<extension
point="org.talend.core.runtime.librariesNeeded">
<libraryNeeded
context="org.talend.librariesmanager.test"
id="test_jar1"
language="java"
message="test librariess"
name="test_jar1.jar"
required="true">
</libraryNeeded>
</extension>
<extension
point="org.talend.core.runtime.librariesNeeded">
<libraryNeeded
context="org.talend.librariesmanager.test"
id="test_jar2"
language="java"
message="test librariess"
name="test_jar2.jar"
required="true">
</libraryNeeded>
</extension>
<extension
point="org.talend.core.runtime.librariesNeeded">
<libraryNeeded
context="org.talend.librariesmanager.test"
id="test_jar3"
language="java"
message="test librariess"
name="test_jar3.jar"
required="true">
</libraryNeeded>
</extension>
</fragment>

View File

@@ -0,0 +1,66 @@
// ============================================================================
//
// Copyright (C) 2006-2014 Talend Inc. - www.talend.com
//
// This source code is available under agreement available at
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
//
// You should have received a copy of the agreement
// along with this program; if not, write to Talend SA
// 9 rue Pages 92150 Suresnes, France
//
// ============================================================================
package org.talend.librariesmanager.model;
import static org.junit.Assert.*;
import java.util.List;
import junit.framework.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.powermock.modules.junit4.PowerMockRunner;
import org.talend.core.model.general.ModuleNeeded;
/**
* created by ycbai on 2014-5-8 Detailled comment
*
*/
@RunWith(PowerMockRunner.class)
public class ExtensionModuleManagerTest {
private ExtensionModuleManager manager;
@BeforeClass
public void setUp() throws Exception {
manager = ExtensionModuleManager.getInstance();
}
@Test
public void testGetModuleNeeded() {
/*
* Get single module from id.
*/
List<ModuleNeeded> moduleNeededs = manager.getModuleNeeded("test-jar1"); //$NON-NLS-1$
Assert.assertTrue(moduleNeededs != null && moduleNeededs.size() > 0
&& "test-jar1.jar".equals(moduleNeededs.get(0).getModuleName())); //$NON-NLS-1$
/*
* Get single module from name.
*/
moduleNeededs = manager.getModuleNeeded("test-jar1.jar"); //$NON-NLS-1$
Assert.assertTrue(moduleNeededs != null && moduleNeededs.size() > 0 && "test-jar1".equals(moduleNeededs.get(0).getId())); //$NON-NLS-1$
/*
* Get modules from group.
*/
moduleNeededs = manager.getModuleNeeded("test-jars-group"); //$NON-NLS-1$
assertNotNull(moduleNeededs);
Assert.assertTrue(moduleNeededs.size() == 3);
Assert.assertTrue("test-jar1".equals(moduleNeededs.get(0).getId())); //$NON-NLS-1$
Assert.assertTrue("test-jar2".equals(moduleNeededs.get(1).getId())); //$NON-NLS-1$
Assert.assertTrue("test-jar3".equals(moduleNeededs.get(2).getId())); //$NON-NLS-1$
}
}

View File

@@ -0,0 +1,225 @@
// ============================================================================
//
// Copyright (C) 2006-2014 Talend Inc. - www.talend.com
//
// This source code is available under agreement available at
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
//
// You should have received a copy of the agreement
// along with this program; if not, write to Talend SA
// 9 rue Pages 92150 Suresnes, France
//
// ============================================================================
package org.talend.librariesmanager.model;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.apache.commons.lang.StringUtils;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IContributor;
import org.talend.commons.utils.workbench.extensions.ExtensionImplementationProvider;
import org.talend.commons.utils.workbench.extensions.ExtensionPointLimiterImpl;
import org.talend.commons.utils.workbench.extensions.IExtensionPointLimiter;
import org.talend.core.model.general.ModuleNeeded;
import org.talend.designer.core.model.utils.emf.component.IMPORTType;
import org.talend.librariesmanager.i18n.Messages;
/**
*
* created by ycbai on 2014-5-7 Detailled comment
*
*/
public class ExtensionModuleManager {
public final static String EXT_ID = "org.talend.core.runtime.librariesNeeded"; //$NON-NLS-1$
public final static String MODULE_ELE = "libraryNeeded"; //$NON-NLS-1$
public final static String MODULE_GROUP_ELE = "libraryNeededGroup"; //$NON-NLS-1$
public final static String LIBRARY_ELE = "library"; //$NON-NLS-1$
public final static String GROUP_ELE = "group"; //$NON-NLS-1$
public final static String ID_ATTR = "id"; //$NON-NLS-1$
public final static String NAME_ATTR = "name"; //$NON-NLS-1$
public final static String CONTEXT_ATTR = "context"; //$NON-NLS-1$
public final static String MESSAGE_ATTR = "message"; //$NON-NLS-1$
public final static String REQUIRED_ATTR = "required"; //$NON-NLS-1$
public final static String URIPATH_ATTR = "uripath"; //$NON-NLS-1$
public final static String DESC_ATTR = "description"; //$NON-NLS-1$
public final static String PATH_SEP = "/"; //$NON-NLS-1$
public final static String URIPATH_PREFIX = "platform:/plugin/"; //$NON-NLS-1$
public final static String URIPATH_PREFIX_INTERNAL = "platform:/base/plugins/"; //$NON-NLS-1$
public final static String DEFAULT_LIB_FOLDER = "lib"; //$NON-NLS-1$
private static ExtensionModuleManager manager = new ExtensionModuleManager();
private static Map<String, ModuleNeeded> id2moduleMap = new HashMap<String, ModuleNeeded>();
private static Map<String, ModuleNeeded> name2moduleMap = new HashMap<String, ModuleNeeded>();
private ExtensionModuleManager() {
}
public static synchronized final ExtensionModuleManager getInstance() {
return manager;
}
public List<ModuleNeeded> getModuleNeeded(String id) {
return getModuleNeeded(id, false);
}
public List<ModuleNeeded> getModuleNeeded(String id, boolean isGroup) {
List<ModuleNeeded> importNeedsList = new ArrayList<ModuleNeeded>();
if (id == null) {
return importNeedsList;
}
if (isGroup) {
collectGroupModules(id, importNeedsList);
} else {
collectSingleModule(id, importNeedsList);
}
return importNeedsList;
}
public List<ModuleNeeded> getModuleNeededForComponent(String context, IMPORTType importType) {
List<ModuleNeeded> importNeedsList = new ArrayList<ModuleNeeded>();
String id = null;
boolean isGroup = false;
String module = StringUtils.trimToNull(importType.getMODULE());
String moduleGroup = StringUtils.trimToNull(importType.getMODULEGROUP());
if (module != null) {
id = module;
} else if (moduleGroup != null) {
id = moduleGroup;
isGroup = true;
}
List<ModuleNeeded> modulesNeeded = getModuleNeeded(id, isGroup);
for (ModuleNeeded moduleNeeded : modulesNeeded) {
String msg = importType.getMESSAGE();
if (msg == null) {
msg = Messages.getString("modules.required"); //$NON-NLS-1$
}
moduleNeeded.setContext(context);
moduleNeeded.setInformationMsg(msg);
moduleNeeded.setRequired(importType.isREQUIRED());
moduleNeeded.setMrRequired(importType.isMRREQUIRED());
moduleNeeded.setRequiredIf(importType.getREQUIREDIF());
moduleNeeded.setShow(importType.isSHOW());
ModulesNeededProvider.initBundleID(importType, moduleNeeded);
importNeedsList.add(moduleNeeded);
}
return importNeedsList;
}
private void collectSingleModule(String id, List<ModuleNeeded> importNeedsList) {
if (id == null || importNeedsList == null) {
return;
}
IExtensionPointLimiter extensionPoint = new ExtensionPointLimiterImpl(EXT_ID, MODULE_ELE);
List<IConfigurationElement> extension = ExtensionImplementationProvider.getInstanceV2(extensionPoint);
// Find the module definition by id first.
ModuleNeeded moduleNeeded = collectModuleAndMap(extension, id2moduleMap, id);
if (moduleNeeded == null) { // If cannot find it then find it by name.
moduleNeeded = collectModuleAndMap(extension, name2moduleMap, id, true);
}
if (moduleNeeded != null) {
importNeedsList.add(moduleNeeded);
}
}
private ModuleNeeded collectModuleAndMap(List<IConfigurationElement> extension, Map<String, ModuleNeeded> moduleMap, String id) {
return collectModuleAndMap(extension, moduleMap, id, false);
}
private ModuleNeeded collectModuleAndMap(List<IConfigurationElement> extension, Map<String, ModuleNeeded> moduleMap,
String id, boolean byName) {
ModuleNeeded moduleNeeded = moduleMap.get(id);
if (moduleNeeded == null) {
for (IConfigurationElement configElement : extension) {
String moduleIdOrName = configElement.getAttribute(ID_ATTR);
if (byName) {
moduleIdOrName = configElement.getAttribute(NAME_ATTR);
}
if (id.equals(moduleIdOrName)) {
moduleNeeded = ModulesNeededProvider.createModuleNeededInstance(configElement);
moduleMap.put(id, moduleNeeded);
break;
}
}
}
return moduleNeeded;
}
private void collectGroupModules(String groupId, List<ModuleNeeded> importNeedsList) {
if (groupId == null || importNeedsList == null) {
return;
}
IExtensionPointLimiter extensionPoint = new ExtensionPointLimiterImpl(EXT_ID, MODULE_GROUP_ELE);
List<IConfigurationElement> extension = ExtensionImplementationProvider.getInstanceV2(extensionPoint);
for (IConfigurationElement configElement : extension) {
String moduleGroupId = configElement.getAttribute(ID_ATTR);
if (groupId.equals(moduleGroupId)) {
IConfigurationElement[] childrenEle = configElement.getChildren();
for (IConfigurationElement childEle : childrenEle) {
String eleName = childEle.getName();
if (LIBRARY_ELE.equals(eleName)) {
collectSingleModule(childEle.getAttribute(ID_ATTR), importNeedsList);
} else if (GROUP_ELE.equals(eleName)) {
collectGroupModules(childEle.getAttribute(ID_ATTR), importNeedsList);
}
}
}
}
}
/**
* If uripath is null we will seek the jar from /lib/${jarName} from the contributor plugin of the lib extension
* point.
* <p>
*
* DOC ycbai Comment method "getFormalModulePath".
*
* @param uriPath
* @param current
* @return the formal module path which start with "platform:/plugin/" or "platform:/base/plugins/".
*/
public String getFormalModulePath(String uriPath, IConfigurationElement current) {
StringBuffer expectJarPath = new StringBuffer();
if (StringUtils.trimToNull(uriPath) == null) {
String jarName = current.getAttribute(NAME_ATTR);
IContributor contributor = current.getContributor();
expectJarPath.append(URIPATH_PREFIX);
expectJarPath.append(contributor.getName());
expectJarPath.append(PATH_SEP);
expectJarPath.append(DEFAULT_LIB_FOLDER);
expectJarPath.append(PATH_SEP);
expectJarPath.append(jarName);
} else {
if (!uriPath.startsWith(URIPATH_PREFIX) && !uriPath.startsWith(URIPATH_PREFIX_INTERNAL)) {
expectJarPath.append(URIPATH_PREFIX);
}
expectJarPath.append(uriPath);
}
return expectJarPath.toString();
}
}

View File

@@ -274,18 +274,7 @@ public class ModulesNeededProvider {
EList emfImportList = info.getImportType();
for (int i = 0; i < emfImportList.size(); i++) {
IMPORTType importType = (IMPORTType) emfImportList.get(i);
String msg = importType.getMESSAGE();
if (msg == null) {
msg = Messages.getString("modules.required");
}
List<String> list = getInstallURL(importType);
ModuleNeeded componentImportNeeds = new ModuleNeeded(key, importType.getMODULE(), msg,
importType.isREQUIRED(), list, importType.getREQUIREDIF());
initBundleID(importType, componentImportNeeds);
componentImportNeeds.setMrRequired(importType.isMRREQUIRED());
componentImportNeeds.setShow(importType.isSHOW());
componentImportNeeds.setModuleLocaion(importType.getUrlPath());
importNeedsList.add(componentImportNeeds);
collectModuleNeeded(key, importType, importNeedsList);
}
}
}
@@ -305,6 +294,37 @@ public class ModulesNeededProvider {
}
}
public static void collectModuleNeeded(String context, IMPORTType importType, List<ModuleNeeded> importNeedsList) {
boolean foundModule = createModuleNeededForComponentFromExtension(context, importType, importNeedsList);
if (!foundModule) { // If cannot find the jar from extension point then do it like before.
createModuleNeededForComponent(context, importType, importNeedsList);
}
}
private static boolean createModuleNeededForComponentFromExtension(String context, IMPORTType importType,
List<ModuleNeeded> importNeedsList) {
List<ModuleNeeded> importModuleNeeded = ExtensionModuleManager.getInstance().getModuleNeededForComponent(context,
importType);
importNeedsList.addAll(importModuleNeeded);
return importModuleNeeded.size() > 0;
}
public static void createModuleNeededForComponent(String context, IMPORTType importType, List<ModuleNeeded> importNeedsList) {
String msg = importType.getMESSAGE();
if (msg == null) {
msg = Messages.getString("modules.required"); //$NON-NLS-1$
}
List<String> list = getInstallURL(importType);
ModuleNeeded moduleNeeded = new ModuleNeeded(context, importType.getMODULE(), msg, importType.isREQUIRED(), list,
importType.getREQUIREDIF());
initBundleID(importType, moduleNeeded);
moduleNeeded.setMrRequired(importType.isMRREQUIRED());
moduleNeeded.setShow(importType.isSHOW());
moduleNeeded.setModuleLocaion(importType.getUrlPath());
importNeedsList.add(moduleNeeded);
}
public static List<String> getInstallURL(IMPORTType importType) {
List<String> list = new ArrayList<String>();
EList emfInstall = importType.getURL();
@@ -608,13 +628,16 @@ public class ModulesNeededProvider {
* @return
*/
public static ModuleNeeded createModuleNeededInstance(IConfigurationElement current) {
String context = current.getAttribute("context"); //$NON-NLS-1$
String name = current.getAttribute("name"); //$NON-NLS-1$
String message = current.getAttribute("message"); //$NON-NLS-1$
boolean required = new Boolean(current.getAttribute("required")); //$NON-NLS-1$
String uripath = current.getAttribute("uripath");
String id = current.getAttribute(ExtensionModuleManager.ID_ATTR);
String context = current.getAttribute(ExtensionModuleManager.CONTEXT_ATTR);
String name = current.getAttribute(ExtensionModuleManager.NAME_ATTR);
String message = current.getAttribute(ExtensionModuleManager.MESSAGE_ATTR);
boolean required = new Boolean(current.getAttribute(ExtensionModuleManager.REQUIRED_ATTR));
String uripath = current.getAttribute(ExtensionModuleManager.URIPATH_ATTR);
uripath = ExtensionModuleManager.getInstance().getFormalModulePath(uripath, current);
ModuleNeeded module = new ModuleNeeded(context, name, message, required);
module.setModuleLocaion(uripath);
module.setId(id);
return module;
}

View File

@@ -881,6 +881,13 @@
<details key="name" value="IMPORTS_._type"/>
<details key="kind" value="elementOnly"/>
</eAnnotations>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="rEQUIREDIF" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">
<details key="kind" value="attribute"/>
<details key="name" value="REQUIRED_IF"/>
<details key="namespace" value="##targetNamespace"/>
</eAnnotations>
</eStructuralFeatures>
<eStructuralFeatures xsi:type="ecore:EReference" name="iMPORT" upperBound="-1"
eType="#//IMPORTType" containment="true" resolveProxies="false">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">
@@ -889,6 +896,14 @@
<details key="namespace" value="##targetNamespace"/>
</eAnnotations>
</eStructuralFeatures>
<eStructuralFeatures xsi:type="ecore:EReference" name="iMPORTS" upperBound="-1"
eType="#//IMPORTSType" containment="true" resolveProxies="false">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">
<details key="kind" value="element"/>
<details key="name" value="IMPORTS"/>
<details key="namespace" value="##targetNamespace"/>
</eAnnotations>
</eStructuralFeatures>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="IMPORTType">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">
@@ -976,6 +991,13 @@
<details key="namespace" value="##targetNamespace"/>
</eAnnotations>
</eStructuralFeatures>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="mODULEGROUP" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">
<details key="kind" value="attribute"/>
<details key="name" value="MODULE_GROUP"/>
<details key="namespace" value="##targetNamespace"/>
</eAnnotations>
</eStructuralFeatures>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="INSTALLType">
<eAnnotations source="http:///org/eclipse/emf/ecore/util/ExtendedMetaData">

View File

@@ -136,7 +136,9 @@
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//HEADERType/sUPPORTS_DB_TYPE"/>
</genClasses>
<genClasses ecoreClass="Component.ecore#//IMPORTSType">
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//IMPORTSType/rEQUIREDIF"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Component.ecore#//IMPORTSType/iMPORT"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Component.ecore#//IMPORTSType/iMPORTS"/>
</genClasses>
<genClasses ecoreClass="Component.ecore#//IMPORTType">
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Component.ecore#//IMPORTType/iNSTALL"/>
@@ -150,6 +152,7 @@
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//IMPORTType/urlPath"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//IMPORTType/rEQUIREDIF"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//IMPORTType/mRREQUIRED"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//IMPORTType/mODULEGROUP"/>
</genClasses>
<genClasses ecoreClass="Component.ecore#//INSTALLType">
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Component.ecore#//INSTALLType/cOMMAND"/>

View File

@@ -197,8 +197,12 @@
</xsd:complexType>
<xsd:complexType ecore:name="IMPORTSType" name="IMPORTS_._type">
<xsd:sequence>
<xsd:element ecore:name="iMPORT" maxOccurs="unbounded" minOccurs="0" name="IMPORT" type="IMPORT_._type"/>
<xsd:choice minOccurs="0" maxOccurs="unbounded">
<xsd:element ecore:name="iMPORT" maxOccurs="unbounded" minOccurs="0" name="IMPORT" type="IMPORT_._type"/>
<xsd:element ecore:name="iMPORTS" maxOccurs="unbounded" minOccurs="0" name="IMPORTS" type="IMPORTS_._type"/>
</xsd:choice>
</xsd:sequence>
<xsd:attribute ecore:name="rEQUIREDIF" name="REQUIRED_IF" type="ecore:EString"/>
</xsd:complexType>
<xsd:complexType ecore:name="IMPORTType" name="IMPORT_._type">
<xsd:sequence>
@@ -214,6 +218,7 @@
<xsd:attribute ecore:name="urlPath" name="UrlPath" type="xsd:string"/>
<xsd:attribute ecore:name="rEQUIREDIF" name="REQUIRED_IF" type="ecore:EString"/>
<xsd:attribute default="false" ecore:name="mRREQUIRED" name="MRREQUIRED" type="xsd:boolean"/>
<xsd:attribute ecore:name="mODULEGROUP" name="MODULE_GROUP" type="xsd:string"/>
</xsd:complexType>
<xsd:complexType ecore:name="INSTALLType" name="INSTALL_._type">
<xsd:sequence>

View File

@@ -1217,6 +1217,15 @@ public interface ComponentPackage extends EPackage {
*/
int IMPORTS_TYPE = 13;
/**
* The feature id for the '<em><b>REQUIREDIF</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int IMPORTS_TYPE__REQUIREDIF = 0;
/**
* The feature id for the '<em><b>IMPORT</b></em>' containment reference list.
* <!-- begin-user-doc -->
@@ -1224,7 +1233,16 @@ public interface ComponentPackage extends EPackage {
* @generated
* @ordered
*/
int IMPORTS_TYPE__IMPORT = 0;
int IMPORTS_TYPE__IMPORT = 1;
/**
* The feature id for the '<em><b>IMPORTS</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int IMPORTS_TYPE__IMPORTS = 2;
/**
* The number of structural features of the '<em>IMPORTS Type</em>' class.
@@ -1233,7 +1251,7 @@ public interface ComponentPackage extends EPackage {
* @generated
* @ordered
*/
int IMPORTS_TYPE_FEATURE_COUNT = 1;
int IMPORTS_TYPE_FEATURE_COUNT = 3;
/**
* The meta object id for the '{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl <em>IMPORT Type</em>}' class.
@@ -1344,6 +1362,15 @@ public interface ComponentPackage extends EPackage {
*/
int IMPORT_TYPE__MRREQUIRED = 10;
/**
* The feature id for the '<em><b>MODULEGROUP</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int IMPORT_TYPE__MODULEGROUP = 11;
/**
* The number of structural features of the '<em>IMPORT Type</em>' class.
* <!-- begin-user-doc -->
@@ -1351,7 +1378,7 @@ public interface ComponentPackage extends EPackage {
* @generated
* @ordered
*/
int IMPORT_TYPE_FEATURE_COUNT = 11;
int IMPORT_TYPE_FEATURE_COUNT = 12;
/**
* The meta object id for the '{@link org.talend.designer.core.model.utils.emf.component.impl.INSTALLTypeImpl <em>INSTALL Type</em>}' class.
@@ -3664,6 +3691,17 @@ public interface ComponentPackage extends EPackage {
*/
EClass getIMPORTSType();
/**
* Returns the meta object for the attribute '{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getREQUIREDIF <em>REQUIREDIF</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>REQUIREDIF</em>'.
* @see org.talend.designer.core.model.utils.emf.component.IMPORTSType#getREQUIREDIF()
* @see #getIMPORTSType()
* @generated
*/
EAttribute getIMPORTSType_REQUIREDIF();
/**
* Returns the meta object for the containment reference list '{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getIMPORT <em>IMPORT</em>}'.
* <!-- begin-user-doc -->
@@ -3675,6 +3713,17 @@ public interface ComponentPackage extends EPackage {
*/
EReference getIMPORTSType_IMPORT();
/**
* Returns the meta object for the containment reference list '{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getIMPORTS <em>IMPORTS</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference list '<em>IMPORTS</em>'.
* @see org.talend.designer.core.model.utils.emf.component.IMPORTSType#getIMPORTS()
* @see #getIMPORTSType()
* @generated
*/
EReference getIMPORTSType_IMPORTS();
/**
* Returns the meta object for class '{@link org.talend.designer.core.model.utils.emf.component.IMPORTType <em>IMPORT Type</em>}'.
* <!-- begin-user-doc -->
@@ -3795,6 +3844,17 @@ public interface ComponentPackage extends EPackage {
*/
EAttribute getIMPORTType_MRREQUIRED();
/**
* Returns the meta object for the attribute '{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getMODULEGROUP <em>MODULEGROUP</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>MODULEGROUP</em>'.
* @see org.talend.designer.core.model.utils.emf.component.IMPORTType#getMODULEGROUP()
* @see #getIMPORTType()
* @generated
*/
EAttribute getIMPORTType_MODULEGROUP();
/**
* Returns the meta object for the attribute '{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getBundleID <em>Bundle ID</em>}'.
* <!-- begin-user-doc -->
@@ -5851,6 +5911,14 @@ public interface ComponentPackage extends EPackage {
*/
EClass IMPORTS_TYPE = eINSTANCE.getIMPORTSType();
/**
* The meta object literal for the '<em><b>REQUIREDIF</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute IMPORTS_TYPE__REQUIREDIF = eINSTANCE.getIMPORTSType_REQUIREDIF();
/**
* The meta object literal for the '<em><b>IMPORT</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
@@ -5859,6 +5927,14 @@ public interface ComponentPackage extends EPackage {
*/
EReference IMPORTS_TYPE__IMPORT = eINSTANCE.getIMPORTSType_IMPORT();
/**
* The meta object literal for the '<em><b>IMPORTS</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference IMPORTS_TYPE__IMPORTS = eINSTANCE.getIMPORTSType_IMPORTS();
/**
* The meta object literal for the '{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl <em>IMPORT Type</em>}' class.
* <!-- begin-user-doc -->
@@ -5949,6 +6025,14 @@ public interface ComponentPackage extends EPackage {
*/
EAttribute IMPORT_TYPE__MRREQUIRED = eINSTANCE.getIMPORTType_MRREQUIRED();
/**
* The meta object literal for the '<em><b>MODULEGROUP</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute IMPORT_TYPE__MODULEGROUP = eINSTANCE.getIMPORTType_MODULEGROUP();
/**
* The meta object literal for the '<em><b>Bundle ID</b></em>' attribute feature.
* <!-- begin-user-doc -->

View File

@@ -17,7 +17,9 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getREQUIREDIF <em>REQUIREDIF</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getIMPORT <em>IMPORT</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getIMPORTS <em>IMPORTS</em>}</li>
* </ul>
* </p>
*
@@ -26,6 +28,32 @@ import org.eclipse.emf.ecore.EObject;
* @generated
*/
public interface IMPORTSType extends EObject {
/**
* Returns the value of the '<em><b>REQUIREDIF</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>REQUIREDIF</em>' attribute isn't clear,
* there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
* @return the value of the '<em>REQUIREDIF</em>' attribute.
* @see #setREQUIREDIF(String)
* @see org.talend.designer.core.model.utils.emf.component.ComponentPackage#getIMPORTSType_REQUIREDIF()
* @model extendedMetaData="kind='attribute' name='REQUIRED_IF' namespace='##targetNamespace'"
* @generated
*/
String getREQUIREDIF();
/**
* Sets the value of the '{@link org.talend.designer.core.model.utils.emf.component.IMPORTSType#getREQUIREDIF <em>REQUIREDIF</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>REQUIREDIF</em>' attribute.
* @see #getREQUIREDIF()
* @generated
*/
void setREQUIREDIF(String value);
/**
* Returns the value of the '<em><b>IMPORT</b></em>' containment reference list.
* The list contents are of type {@link org.talend.designer.core.model.utils.emf.component.IMPORTType}.
@@ -43,4 +71,21 @@ public interface IMPORTSType extends EObject {
*/
EList getIMPORT();
/**
* Returns the value of the '<em><b>IMPORTS</b></em>' containment reference list.
* The list contents are of type {@link org.talend.designer.core.model.utils.emf.component.IMPORTSType}.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>IMPORTS</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>IMPORTS</em>' containment reference list.
* @see org.talend.designer.core.model.utils.emf.component.ComponentPackage#getIMPORTSType_IMPORTS()
* @model type="org.talend.designer.core.model.utils.emf.component.IMPORTSType" containment="true"
* extendedMetaData="kind='element' name='IMPORTS' namespace='##targetNamespace'"
* @generated
*/
EList getIMPORTS();
} // IMPORTSType

View File

@@ -29,6 +29,7 @@ import org.eclipse.emf.ecore.EObject;
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getUrlPath <em>Url Path</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getREQUIREDIF <em>REQUIREDIF</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#isMRREQUIRED <em>MRREQUIRED</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getMODULEGROUP <em>MODULEGROUP</em>}</li>
* </ul>
* </p>
*
@@ -341,6 +342,32 @@ public interface IMPORTType extends EObject {
*/
void setMRREQUIRED(boolean value);
/**
* Returns the value of the '<em><b>MODULEGROUP</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>MODULEGROUP</em>' attribute isn't clear,
* there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
* @return the value of the '<em>MODULEGROUP</em>' attribute.
* @see #setMODULEGROUP(String)
* @see org.talend.designer.core.model.utils.emf.component.ComponentPackage#getIMPORTType_MODULEGROUP()
* @model extendedMetaData="kind='attribute' name='MODULE_GROUP' namespace='##targetNamespace'"
* @generated
*/
String getMODULEGROUP();
/**
* Sets the value of the '{@link org.talend.designer.core.model.utils.emf.component.IMPORTType#getMODULEGROUP <em>MODULEGROUP</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>MODULEGROUP</em>' attribute.
* @see #getMODULEGROUP()
* @generated
*/
void setMODULEGROUP(String value);
/**
* Returns the value of the '<em><b>Bundle ID</b></em>' attribute.
* <!-- begin-user-doc -->

View File

@@ -1370,13 +1370,31 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
return importsTypeEClass;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EAttribute getIMPORTSType_REQUIREDIF() {
return (EAttribute)importsTypeEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EReference getIMPORTSType_IMPORT() {
return (EReference)importsTypeEClass.getEStructuralFeatures().get(0);
return (EReference)importsTypeEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EReference getIMPORTSType_IMPORTS() {
return (EReference)importsTypeEClass.getEStructuralFeatures().get(2);
}
/**
@@ -1478,6 +1496,15 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
return (EAttribute)importTypeEClass.getEStructuralFeatures().get(10);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EAttribute getIMPORTType_MODULEGROUP() {
return (EAttribute)importTypeEClass.getEStructuralFeatures().get(11);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -2542,7 +2569,9 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
createEAttribute(headerTypeEClass, HEADER_TYPE__SUPPORTS_DB_TYPE);
importsTypeEClass = createEClass(IMPORTS_TYPE);
createEAttribute(importsTypeEClass, IMPORTS_TYPE__REQUIREDIF);
createEReference(importsTypeEClass, IMPORTS_TYPE__IMPORT);
createEReference(importsTypeEClass, IMPORTS_TYPE__IMPORTS);
importTypeEClass = createEClass(IMPORT_TYPE);
createEReference(importTypeEClass, IMPORT_TYPE__INSTALL);
@@ -2556,6 +2585,7 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
createEAttribute(importTypeEClass, IMPORT_TYPE__URL_PATH);
createEAttribute(importTypeEClass, IMPORT_TYPE__REQUIREDIF);
createEAttribute(importTypeEClass, IMPORT_TYPE__MRREQUIRED);
createEAttribute(importTypeEClass, IMPORT_TYPE__MODULEGROUP);
installTypeEClass = createEClass(INSTALL_TYPE);
createEAttribute(installTypeEClass, INSTALL_TYPE__COMMAND);
@@ -2831,7 +2861,9 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
initEAttribute(getHEADERType_SUPPORTS_DB_TYPE(), theXMLTypePackage.getBoolean(), "sUPPORTS_DB_TYPE", "false", 0, 1, HEADERType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(importsTypeEClass, IMPORTSType.class, "IMPORTSType", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getIMPORTSType_REQUIREDIF(), ecorePackage.getEString(), "rEQUIREDIF", null, 0, 1, IMPORTSType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getIMPORTSType_IMPORT(), this.getIMPORTType(), null, "iMPORT", null, 0, -1, IMPORTSType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getIMPORTSType_IMPORTS(), this.getIMPORTSType(), null, "iMPORTS", null, 0, -1, IMPORTSType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(importTypeEClass, IMPORTType.class, "IMPORTType", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getIMPORTType_INSTALL(), this.getINSTALLType(), null, "iNSTALL", null, 0, -1, IMPORTType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
@@ -2845,6 +2877,7 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
initEAttribute(getIMPORTType_UrlPath(), theXMLTypePackage.getString(), "urlPath", null, 0, 1, IMPORTType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getIMPORTType_REQUIREDIF(), ecorePackage.getEString(), "rEQUIREDIF", null, 0, 1, IMPORTType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getIMPORTType_MRREQUIRED(), theXMLTypePackage.getBoolean(), "mRREQUIRED", null, 0, 1, IMPORTType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getIMPORTType_MODULEGROUP(), ecorePackage.getEString(), "mODULEGROUP", null, 0, 1, IMPORTType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(installTypeEClass, INSTALLType.class, "INSTALLType", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getINSTALLType_COMMAND(), theXMLTypePackage.getString(), "cOMMAND", null, 1, 1, INSTALLType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
@@ -3878,6 +3911,14 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
"name", "IMPORTS_._type",
"kind", "elementOnly"
});
addAnnotation
(getIMPORTSType_REQUIREDIF(),
source,
new String[] {
"kind", "attribute",
"name", "REQUIRED_IF",
"namespace", "##targetNamespace"
});
addAnnotation
(getIMPORTSType_IMPORT(),
source,
@@ -3886,6 +3927,14 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
"name", "IMPORT",
"namespace", "##targetNamespace"
});
addAnnotation
(getIMPORTSType_IMPORTS(),
source,
new String[] {
"kind", "element",
"name", "IMPORTS",
"namespace", "##targetNamespace"
});
addAnnotation
(importTypeEClass,
source,
@@ -3981,6 +4030,14 @@ public class ComponentPackageImpl extends EPackageImpl implements ComponentPacka
"name", "MRREQUIRED",
"namespace", "##targetNamespace"
});
addAnnotation
(getIMPORTType_MODULEGROUP(),
source,
new String[] {
"kind", "attribute",
"name", "MODULE_GROUP",
"namespace", "##targetNamespace"
});
addAnnotation
(installTypeEClass,
source,

View File

@@ -8,10 +8,12 @@ package org.talend.designer.core.model.utils.emf.component.impl;
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.impl.EObjectImpl;
import org.eclipse.emf.ecore.util.EObjectContainmentEList;
import org.eclipse.emf.ecore.util.InternalEList;
@@ -26,13 +28,33 @@ import org.talend.designer.core.model.utils.emf.component.IMPORTType;
* <p>
* The following features are implemented:
* <ul>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTSTypeImpl#getREQUIREDIF <em>REQUIREDIF</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTSTypeImpl#getIMPORT <em>IMPORT</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTSTypeImpl#getIMPORTS <em>IMPORTS</em>}</li>
* </ul>
* </p>
*
* @generated
*/
public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
/**
* The default value of the '{@link #getREQUIREDIF() <em>REQUIREDIF</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getREQUIREDIF()
* @generated
* @ordered
*/
protected static final String REQUIREDIF_EDEFAULT = null;
/**
* The cached value of the '{@link #getREQUIREDIF() <em>REQUIREDIF</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getREQUIREDIF()
* @generated
* @ordered
*/
protected String rEQUIREDIF = REQUIREDIF_EDEFAULT;
/**
* The cached value of the '{@link #getIMPORT() <em>IMPORT</em>}' containment reference list.
* <!-- begin-user-doc -->
@@ -43,6 +65,16 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
*/
protected EList iMPORT;
/**
* The cached value of the '{@link #getIMPORTS() <em>IMPORTS</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getIMPORTS()
* @generated
* @ordered
*/
protected EList iMPORTS;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -62,6 +94,27 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
return ComponentPackage.Literals.IMPORTS_TYPE;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String getREQUIREDIF() {
return rEQUIREDIF;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setREQUIREDIF(String newREQUIREDIF) {
String oldREQUIREDIF = rEQUIREDIF;
rEQUIREDIF = newREQUIREDIF;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ComponentPackage.IMPORTS_TYPE__REQUIREDIF, oldREQUIREDIF, rEQUIREDIF));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -74,6 +127,18 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
return iMPORT;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public EList getIMPORTS() {
if (iMPORTS == null) {
iMPORTS = new EObjectContainmentEList(IMPORTSType.class, this, ComponentPackage.IMPORTS_TYPE__IMPORTS);
}
return iMPORTS;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -84,6 +149,8 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
switch (featureID) {
case ComponentPackage.IMPORTS_TYPE__IMPORT:
return ((InternalEList)getIMPORT()).basicRemove(otherEnd, msgs);
case ComponentPackage.IMPORTS_TYPE__IMPORTS:
return ((InternalEList)getIMPORTS()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -96,8 +163,12 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
case ComponentPackage.IMPORTS_TYPE__REQUIREDIF:
return getREQUIREDIF();
case ComponentPackage.IMPORTS_TYPE__IMPORT:
return getIMPORT();
case ComponentPackage.IMPORTS_TYPE__IMPORTS:
return getIMPORTS();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -111,10 +182,17 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case ComponentPackage.IMPORTS_TYPE__REQUIREDIF:
setREQUIREDIF((String)newValue);
return;
case ComponentPackage.IMPORTS_TYPE__IMPORT:
getIMPORT().clear();
getIMPORT().addAll((Collection)newValue);
return;
case ComponentPackage.IMPORTS_TYPE__IMPORTS:
getIMPORTS().clear();
getIMPORTS().addAll((Collection)newValue);
return;
}
super.eSet(featureID, newValue);
}
@@ -127,9 +205,15 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
@Override
public void eUnset(int featureID) {
switch (featureID) {
case ComponentPackage.IMPORTS_TYPE__REQUIREDIF:
setREQUIREDIF(REQUIREDIF_EDEFAULT);
return;
case ComponentPackage.IMPORTS_TYPE__IMPORT:
getIMPORT().clear();
return;
case ComponentPackage.IMPORTS_TYPE__IMPORTS:
getIMPORTS().clear();
return;
}
super.eUnset(featureID);
}
@@ -142,10 +226,29 @@ public class IMPORTSTypeImpl extends EObjectImpl implements IMPORTSType {
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
case ComponentPackage.IMPORTS_TYPE__REQUIREDIF:
return REQUIREDIF_EDEFAULT == null ? rEQUIREDIF != null : !REQUIREDIF_EDEFAULT.equals(rEQUIREDIF);
case ComponentPackage.IMPORTS_TYPE__IMPORT:
return iMPORT != null && !iMPORT.isEmpty();
case ComponentPackage.IMPORTS_TYPE__IMPORTS:
return iMPORTS != null && !iMPORTS.isEmpty();
}
return super.eIsSet(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String toString() {
if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (rEQUIREDIF: ");
result.append(rEQUIREDIF);
result.append(')');
return result.toString();
}
} //IMPORTSTypeImpl

View File

@@ -45,6 +45,7 @@ import org.talend.designer.core.model.utils.emf.component.INSTALLType;
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl#getUrlPath <em>Url Path</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl#getREQUIREDIF <em>REQUIREDIF</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl#isMRREQUIRED <em>MRREQUIRED</em>}</li>
* <li>{@link org.talend.designer.core.model.utils.emf.component.impl.IMPORTTypeImpl#getMODULEGROUP <em>MODULEGROUP</em>}</li>
* </ul>
* </p>
*
@@ -269,6 +270,26 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
*/
protected boolean mRREQUIRED = MRREQUIRED_EDEFAULT;
/**
* The default value of the '{@link #getMODULEGROUP() <em>MODULEGROUP</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getMODULEGROUP()
* @generated
* @ordered
*/
protected static final String MODULEGROUP_EDEFAULT = null;
/**
* The cached value of the '{@link #getMODULEGROUP() <em>MODULEGROUP</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getMODULEGROUP()
* @generated
* @ordered
*/
protected String mODULEGROUP = MODULEGROUP_EDEFAULT;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -530,6 +551,27 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
eNotify(new ENotificationImpl(this, Notification.SET, ComponentPackage.IMPORT_TYPE__MRREQUIRED, oldMRREQUIRED, mRREQUIRED));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String getMODULEGROUP() {
return mODULEGROUP;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setMODULEGROUP(String newMODULEGROUP) {
String oldMODULEGROUP = mODULEGROUP;
mODULEGROUP = newMODULEGROUP;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ComponentPackage.IMPORT_TYPE__MODULEGROUP, oldMODULEGROUP, mODULEGROUP));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
@@ -595,6 +637,8 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
return getREQUIREDIF();
case ComponentPackage.IMPORT_TYPE__MRREQUIRED:
return isMRREQUIRED() ? Boolean.TRUE : Boolean.FALSE;
case ComponentPackage.IMPORT_TYPE__MODULEGROUP:
return getMODULEGROUP();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -643,6 +687,9 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
case ComponentPackage.IMPORT_TYPE__MRREQUIRED:
setMRREQUIRED(((Boolean)newValue).booleanValue());
return;
case ComponentPackage.IMPORT_TYPE__MODULEGROUP:
setMODULEGROUP((String)newValue);
return;
}
super.eSet(featureID, newValue);
}
@@ -688,6 +735,9 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
case ComponentPackage.IMPORT_TYPE__MRREQUIRED:
setMRREQUIRED(MRREQUIRED_EDEFAULT);
return;
case ComponentPackage.IMPORT_TYPE__MODULEGROUP:
setMODULEGROUP(MODULEGROUP_EDEFAULT);
return;
}
super.eUnset(featureID);
}
@@ -722,6 +772,8 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
return REQUIREDIF_EDEFAULT == null ? rEQUIREDIF != null : !REQUIREDIF_EDEFAULT.equals(rEQUIREDIF);
case ComponentPackage.IMPORT_TYPE__MRREQUIRED:
return mRREQUIRED != MRREQUIRED_EDEFAULT;
case ComponentPackage.IMPORT_TYPE__MODULEGROUP:
return MODULEGROUP_EDEFAULT == null ? mODULEGROUP != null : !MODULEGROUP_EDEFAULT.equals(mODULEGROUP);
}
return super.eIsSet(featureID);
}
@@ -756,6 +808,8 @@ public class IMPORTTypeImpl extends EObjectImpl implements IMPORTType {
result.append(rEQUIREDIF);
result.append(", mRREQUIRED: ");
result.append(mRREQUIRED);
result.append(", mODULEGROUP: ");
result.append(mODULEGROUP);
result.append(')');
return result.toString();
}