diff options
Diffstat (limited to 'extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java')
-rw-r--r-- | extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java b/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java index 8ec3ac0ecd5..bc26d9f06ce 100644 --- a/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java +++ b/extraplugins/layers/org.eclipse.papyrus.layers.stackmodel/src/org/eclipse/papyrus/layers/stackmodel/layers/util/PropertyUtils.java @@ -4,7 +4,7 @@ * are made available under the terms 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 ******************************************************************************/ @@ -18,39 +18,42 @@ import org.eclipse.papyrus.layers.stackmodel.layers.Type; /** * Utility for {@link Property} + * * @author cedric dumoulin * */ public class PropertyUtils { protected static final PropertyUtils INSTANCE; - + /** * Initialize the instance */ static { INSTANCE = new PropertyUtils(); } - + /** * Get an instance of the class. + * * @return */ public static PropertyUtils getInstance() { return INSTANCE; } - + /** * Create a property with the specified name and type. + * * @param name * @param typeClass * @return */ - public Property createProperty( String name, EClass typeClass) { - + public Property createProperty(String name, EClass typeClass) { + Property property = LayersFactory.eINSTANCE.createProperty(); property.setName(name); - Type type = (Type)LayersFactory.eINSTANCE.create(typeClass); + Type type = (Type) LayersFactory.eINSTANCE.create(typeClass); property.setType(type); return property; } |