All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openxma.dsl.dom.model.impl.AttributePropertyImpl Maven / Gradle / Ivy

/**
 * 
 * 
 *
 * $Id: AttributePropertyImpl.java 9482 2012-05-10 09:15:20Z fmp $
 */
package org.openxma.dsl.dom.model.impl;

import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
import org.openxma.dsl.dom.DomPackage;
import org.openxma.dsl.dom.model.Attribute;
import org.openxma.dsl.dom.model.AttributeProperty;
import org.openxma.dsl.dom.model.AttributeTextProperty;

/**
 * 
 * An implementation of the model object 'Attribute Property'.
 * 
 * 

*

* * @generated */ public class AttributePropertyImpl extends MinimalEObjectImpl.Container implements AttributeProperty { /** * * * @generated */ protected AttributePropertyImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return DomPackage.Literals.ATTRIBUTE_PROPERTY; } /* * @modified * @return the attributeTextProperty text for attributProperties */ public static AttributeTextProperty getAttributeTextProperty(EList attributProperties) { if (attributProperties != null) { for (AttributeProperty attributProperty: attributProperties) { if (attributProperty instanceof AttributeTextProperty && ((AttributeTextProperty)attributProperty).getLabelText() != null) { return ((AttributeTextProperty)attributProperty); } } } return null; } /* * @modified * @return the attributeTextProperty text for attributProperties that contains the hstore column info */ public static AttributeTextProperty getAttributeHstoreProperty(EList attributProperties) { if (attributProperties != null) { for (AttributeProperty attributProperty: attributProperties) { if (attributProperty instanceof AttributeTextProperty && ((AttributeTextProperty)attributProperty).getHstoreColumn() != null) { return ((AttributeTextProperty)attributProperty); } } } return null; } /* * @modified * @return the label text for attributProperties */ public static String getLabelText(EList attributProperties) { AttributeTextProperty txtProp = getAttributeTextProperty(attributProperties); if (txtProp != null) { return txtProp.getLabelText(); } return null; } /* * @modified * @return the Hstore Column name for attributProperties */ public static String getHstoreColumn(EList attributProperties) { AttributeTextProperty txtProp = getAttributeHstoreProperty(attributProperties); if (txtProp != null) { return txtProp.getHstoreColumn(); } return null; } /* * @modified * @return the tooltip text for attributProperties */ public static String getTooltipText(EList attributProperties) { AttributeTextProperty txtProp = getAttributeTextProperty(attributProperties); if (txtProp != null) { return txtProp.getTooltipText(); } return null; } /* * @modified * @return the unit text for attributProperties */ public static String getUnitText(EList attributProperties) { AttributeTextProperty txtProp = getAttributeTextProperty(attributProperties); if (txtProp != null) { return txtProp.getUnitText(); } return null; } /* * @modified * @return the attribute for attributProperties */ public static Attribute getUnitAttribute(EList attributProperties) { AttributeTextProperty txtProp = getAttributeTextProperty(attributProperties); if (txtProp != null) { return txtProp.getUnitAttribute(); } return null; } } //AttributePropertyImpl




© 2015 - 2024 Weber Informatics LLC | Privacy Policy