Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCedric Dumoulin2013-10-29 13:12:45 +0000
committerCedric Dumoulin2014-01-27 13:54:21 +0000
commit8a90e1eda0a789fea36d7250d55b718d46083eb6 (patch)
tree15e262b232b465297af40534479ea58f44b06ad1 /extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java
parent011aecb533b6240e9203bace7a397ec561faab1c (diff)
downloadorg.eclipse.papyrus-8a90e1eda0a789fea36d7250d55b718d46083eb6.tar.gz
org.eclipse.papyrus-8a90e1eda0a789fea36d7250d55b718d46083eb6.tar.xz
org.eclipse.papyrus-8a90e1eda0a789fea36d7250d55b718d46083eb6.zip
organize imports
Diffstat (limited to 'extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java')
-rw-r--r--extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java194
1 files changed, 97 insertions, 97 deletions
diff --git a/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java b/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java
index 1a071d622e2..a5214e40c83 100644
--- a/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java
+++ b/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/loaders/RegistriesLoader.java
@@ -1,97 +1,97 @@
-/*******************************************************************************
- * Copyright (c) 2013 CEA LIST.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Cedric Dumoulin Cedric.dumoulin@lifl.fr
- ******************************************************************************/
-package org.eclipse.papyrus.layers.stackmodel.layers.loaders;
-
-import org.eclipse.papyrus.layers.configmodel.layersconfig.LayerOperatorConfig;
-import org.eclipse.papyrus.layers.configmodel.layersconfig.OperatorBinding;
-import org.eclipse.papyrus.layers.configmodel.layersconfig.OperatorConfig;
-import org.eclipse.papyrus.layers.stackmodel.InstanciationException;
-import org.eclipse.papyrus.layers.stackmodel.NotFoundException;
-import org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptor;
-import org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptorRegistry;
-import org.eclipse.papyrus.layers.stackmodel.layers.Property;
-import org.eclipse.papyrus.layers.stackmodel.layers.PropertyOperator;
-import org.eclipse.papyrus.layers.stackmodel.layers.PropertyRegistry;
-
-
-/**
- * A loader used to load various Registries from a unique {@link LayersConfigModel}.
- * @author cedric dumoulin
- *
- */
-public class RegistriesLoader implements ILayerOperatorDescriptorRegistryLoader {
-
- /**
- * The model used to load the registries.
- *
- */
- protected LayersConfigModel model;
-
- /**
- * Constructor.
- *
- * @param model
- */
- public RegistriesLoader(LayersConfigModel model) {
- this.model = model;
- }
-
- /**
- * Load the {@link LayerOperatorDescriptorRegistryLoader} from the {@link LayersConfigModel}.
- *
- * @see org.eclipse.papyrus.layers.stackmodel.layers.loaders.ILayerOperatorDescriptorRegistryLoader#loadLayerOperatorDescriptorRegistry(org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptorRegistry, org.eclipse.papyrus.layers.stackmodel.layers.PropertyRegistry)
- *
- * @param descriptorRegistry
- * @param propertyRegistry
- */
- @Override
- public void loadLayerOperatorDescriptorRegistry(LayerOperatorDescriptorRegistry descriptorRegistry, PropertyRegistry propertyRegistry) {
-
- // Load LayerOperators
- for( LayerOperatorConfig layerOperatorConfig : model.getAllLayerOperatorConfig() ) {
- try {
- LayerOperatorDescriptor descriptor = layerOperatorConfig.createLayersOperatorDescriptor();
- descriptorRegistry.addLayerOperatorDescriptor(descriptor);
- } catch (InstanciationException e) {
- System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
- e.printStackTrace();
- }
- }
-
- // Load operators
- for( OperatorConfig operatorConfig : model.getAllOperatorConfig()) {
- try {
- PropertyOperator operator = operatorConfig.createOperatorDescriptor();
- descriptorRegistry.addPropertyOperator(operator);
- } catch (InstanciationException e) {
- System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
- e.printStackTrace();
- }
-
- }
-
- // Populate LayerOperator with operators
- for( OperatorBinding binding : model.getAllOperatorBinding()) {
- try {
- Property property = propertyRegistry.getProperty(binding.getPropertyId().getName());
- String layerDescriptorName = binding.getLayerOperatorConfig().getName();
- String operatorName = binding.getOperator().getName();
- descriptorRegistry.attachOperatorToDescriptor(property, operatorName, layerDescriptorName);
- } catch (NotFoundException e) {
- System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
- e.printStackTrace();
- }
-
- }
-
- }
-
-}
+/*******************************************************************************
+ * Copyright (c) 2013 CEA LIST.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Cedric Dumoulin Cedric.dumoulin@lifl.fr
+ ******************************************************************************/
+package org.eclipse.papyrus.layers.stackmodel.layers.loaders;
+
+import org.eclipse.papyrus.layers.configmodel.layersconfig.LayerOperatorConfig;
+import org.eclipse.papyrus.layers.configmodel.layersconfig.OperatorBinding;
+import org.eclipse.papyrus.layers.configmodel.layersconfig.OperatorConfig;
+import org.eclipse.papyrus.layers.stackmodel.InstanciationException;
+import org.eclipse.papyrus.layers.stackmodel.NotFoundException;
+import org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptor;
+import org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptorRegistry;
+import org.eclipse.papyrus.layers.stackmodel.layers.Property;
+import org.eclipse.papyrus.layers.stackmodel.layers.PropertyOperator;
+import org.eclipse.papyrus.layers.stackmodel.layers.PropertyRegistry;
+
+
+/**
+ * A loader used to load various Registries from a unique {@link LayersConfigModel}.
+ * @author cedric dumoulin
+ *
+ */
+public class RegistriesLoader implements ILayerOperatorDescriptorRegistryLoader {
+
+ /**
+ * The model used to load the registries.
+ *
+ */
+ protected LayersConfigModel model;
+
+ /**
+ * Constructor.
+ *
+ * @param model
+ */
+ public RegistriesLoader(LayersConfigModel model) {
+ this.model = model;
+ }
+
+ /**
+ * Load the {@link LayerOperatorDescriptorRegistry} from the {@link LayersConfigModel}.
+ *
+ * @see org.eclipse.papyrus.layers.stackmodel.layers.loaders.ILayerOperatorDescriptorRegistryLoader#loadLayerOperatorDescriptorRegistry(org.eclipse.papyrus.layers.stackmodel.layers.LayerOperatorDescriptorRegistry, org.eclipse.papyrus.layers.stackmodel.layers.PropertyRegistry)
+ *
+ * @param descriptorRegistry
+ * @param propertyRegistry
+ */
+ @Override
+ public void loadLayerOperatorDescriptorRegistry(LayerOperatorDescriptorRegistry descriptorRegistry, PropertyRegistry propertyRegistry) {
+
+ // Load LayerOperators
+ for( LayerOperatorConfig layerOperatorConfig : model.getAllLayerOperatorConfig() ) {
+ try {
+ LayerOperatorDescriptor descriptor = layerOperatorConfig.createLayersOperatorDescriptor();
+ descriptorRegistry.addLayerOperatorDescriptor(descriptor);
+ } catch (InstanciationException e) {
+ System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
+ e.printStackTrace();
+ }
+ }
+
+ // Load operators
+ for( OperatorConfig operatorConfig : model.getAllOperatorConfig()) {
+ try {
+ PropertyOperator operator = operatorConfig.createOperatorDescriptor();
+ descriptorRegistry.addPropertyOperator(operator);
+ } catch (InstanciationException e) {
+ System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
+ e.printStackTrace();
+ }
+
+ }
+
+ // Populate LayerOperator with operators
+ for( OperatorBinding binding : model.getAllOperatorBinding()) {
+ try {
+ Property property = propertyRegistry.getProperty(binding.getPropertyId().getName());
+ String layerDescriptorName = binding.getLayerOperatorConfig().getName();
+ String operatorName = binding.getOperator().getName();
+ descriptorRegistry.attachOperatorToDescriptor(property, operatorName, layerDescriptorName);
+ } catch (NotFoundException e) {
+ System.err.println("LOG - " + this.getClass().getName() + " - " + e.getMessage());
+ e.printStackTrace();
+ }
+
+ }
+
+ }
+
+}

Back to the top