Class PrimitivePropertyListElementGenerator
java.lang.Object
de.hybris.platform.odata2services.odata.schema.property.AbstractPropertyListElementGenerator
de.hybris.platform.odata2services.odata.schema.property.PrimitivePropertyListElementGenerator
- All Implemented Interfaces:
SchemaElementGenerator<List<org.apache.olingo.odata2.api.edm.provider.Property>,TypeDescriptor>
Generates properties for simple primitive attributes type along with the integration key property in the EDMX schema.
-
Constructor Summary
ConstructorsConstructorDescriptionPrimitivePropertyListElementGenerator(@NotNull SchemaElementGenerator<org.apache.olingo.odata2.api.edm.provider.SimpleProperty, TypeAttributeDescriptor> propertyGenerator, @NotNull IntegrationKeyPropertyElementGenerator keyGenerator) To instantiate thePrimitivePropertyListElementGenerator. -
Method Summary
Modifier and TypeMethodDescriptionList<org.apache.olingo.odata2.api.edm.provider.Property>generateAdditionalProperties(TypeDescriptor typeDescriptor) Allows subclass to have a hook to add additional properties(i.e.protected booleanisApplicable(TypeAttributeDescriptor descriptor) Allows subclasses to have a hook into the decision of whether an attribute should be presented as a simple property.Methods inherited from class de.hybris.platform.odata2services.odata.schema.property.AbstractPropertyListElementGenerator
generate, generateSimpleProperties
-
Constructor Details
-
PrimitivePropertyListElementGenerator
public PrimitivePropertyListElementGenerator(@NotNull @NotNull SchemaElementGenerator<org.apache.olingo.odata2.api.edm.provider.SimpleProperty, TypeAttributeDescriptor> propertyGenerator, @NotNull @NotNull IntegrationKeyPropertyElementGenerator keyGenerator) To instantiate thePrimitivePropertyListElementGenerator.- Parameters:
propertyGenerator- a non-null simple property generatorkeyGenerator- a non-null integration key property generator
-
-
Method Details
-
generateAdditionalProperties
public List<org.apache.olingo.odata2.api.edm.provider.Property> generateAdditionalProperties(TypeDescriptor typeDescriptor) Description copied from class:AbstractPropertyListElementGeneratorAllows subclass to have a hook to add additional properties(i.e. key or language properties)- Specified by:
generateAdditionalPropertiesin classAbstractPropertyListElementGenerator- Parameters:
typeDescriptor- describes integration object item, for which simple EDM properties need to be generated.- Returns:
- a list of additional properties if available
-
isApplicable
Description copied from class:AbstractPropertyListElementGeneratorAllows subclasses to have a hook into the decision of whether an attribute should be presented as a simple property. This class already checks whether the attribute is simple, i.e. it's a primitive and not a collection, before checking this method.- Specified by:
isApplicablein classAbstractPropertyListElementGenerator- Parameters:
descriptor- an attribute descriptor to decided about whether it should be presented as EDM property or not.- Returns:
true, if the attribute should be converted to a property;false, otherwise. This default implementation always returnstrue.
-