Package com._1c.g5.v8.dt.export.xml
Class BaseQNameProvider
- java.lang.Object
-
- com._1c.g5.v8.dt.export.xml.BaseQNameProvider
-
- All Implemented Interfaces:
IQNameProvider
- Direct Known Subclasses:
FormGraphicalSchemeQNameProvider,GraphicalSchemeQNameProvider,MetadataFeatureNameProvider
public class BaseQNameProvider extends Object implements IQNameProvider
Base implementation ofIQNameProviderIt allows you to define special names for writable features and class names
By default first letter of all feature names will be replaced to uppercase
-
-
Field Summary
Fields Modifier and Type Field Description protected com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EClass,QName>specifiedClassNamesprotected com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EStructuralFeature,QName>specifiedFeatureNamesprotected com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EPackage,String>specifiedPackageNS
-
Constructor Summary
Constructors Constructor Description BaseQNameProvider()Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidfillSpecifiedClassNames(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EClass,QName> builder)Determine map ofEClass-s to specified names, used in XML writersprotected voidfillSpecifiedFeatureNames(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EStructuralFeature,QName> builder)Determine map ofEStructuralFeature-s to specified names, used in XML writersprotected voidfillSpecifiedPackageNsUri(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EPackage,String> builder)Determine map ofEPackage-s to specified namespace uri for every contains element, used in XML writersQNamegetClassQName(org.eclipse.emf.ecore.EClass eClass)Get QName for eClassQNamegetElementQName(org.eclipse.emf.ecore.EStructuralFeature feature)Get QName for featureprotected booleanneedToCapitalizeFirstLetterOfFeatureName()Specifies that all feature names will be writen with first letter in uppercase as default
-
-
-
Field Detail
-
specifiedFeatureNames
protected final com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EStructuralFeature,QName> specifiedFeatureNames
-
specifiedClassNames
protected final com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EClass,QName> specifiedClassNames
-
specifiedPackageNS
protected final com.google.common.collect.ImmutableMap<org.eclipse.emf.ecore.EPackage,String> specifiedPackageNS
-
-
Method Detail
-
getClassQName
public QName getClassQName(org.eclipse.emf.ecore.EClass eClass)
Description copied from interface:IQNameProviderGet QName for eClass- Specified by:
getClassQNamein interfaceIQNameProvider- Parameters:
eClass- theEClassnot null- Returns:
QNamefor write this eClass in xml
-
getElementQName
public QName getElementQName(org.eclipse.emf.ecore.EStructuralFeature feature)
Description copied from interface:IQNameProviderGet QName for feature- Specified by:
getElementQNamein interfaceIQNameProvider- Parameters:
feature- theEStructuralFeaturenot null- Returns:
QNamefor write this feature in xml
-
fillSpecifiedClassNames
protected void fillSpecifiedClassNames(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EClass,QName> builder)
Determine map ofEClass-s to specified names, used in XML writers- Parameters:
builder- map builder, cannot benull
-
fillSpecifiedFeatureNames
protected void fillSpecifiedFeatureNames(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EStructuralFeature,QName> builder)
Determine map ofEStructuralFeature-s to specified names, used in XML writers- Parameters:
builder- map builder, cannot benull
-
fillSpecifiedPackageNsUri
protected void fillSpecifiedPackageNsUri(com.google.common.collect.ImmutableMap.Builder<org.eclipse.emf.ecore.EPackage,String> builder)
Determine map ofEPackage-s to specified namespace uri for every contains element, used in XML writers- Parameters:
builder- map builder, cannot benull
-
needToCapitalizeFirstLetterOfFeatureName
protected boolean needToCapitalizeFirstLetterOfFeatureName()
Specifies that all feature names will be writen with first letter in uppercase as default- Returns:
truefor write first letter of all feature names in uppercase as default,falseto otherwise
-
-