[OLINGO-564] Renamed 'edm.provider.*' classes
This commit is contained in:
parent
cbbe3da695
commit
2318953c26
|
@ -20,7 +20,7 @@ package org.apache.olingo.client.api.edm.xml;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
|
||||
public interface DataServices {
|
||||
|
||||
|
@ -28,5 +28,5 @@ public interface DataServices {
|
|||
|
||||
String getMaxDataServiceVersion();
|
||||
|
||||
List<Schema> getSchemas();
|
||||
List<CsdlSchema> getSchemas();
|
||||
}
|
||||
|
|
|
@ -21,9 +21,9 @@ package org.apache.olingo.client.api.edm.xml;
|
|||
import java.net.URI;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface Reference extends Annotatable {
|
||||
public interface Reference extends CsdlAnnotatable {
|
||||
|
||||
URI getUri();
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.client.api.edm.xml;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
|
||||
/**
|
||||
* Entry point for access information about EDM metadata.
|
||||
|
@ -34,7 +34,7 @@ public interface XMLMetadata {
|
|||
* @param index index of the Schema to return
|
||||
* @return the Schema at the specified position in the EdM metadata document
|
||||
*/
|
||||
Schema getSchema(final int index);
|
||||
CsdlSchema getSchema(final int index);
|
||||
|
||||
/**
|
||||
* Returns the Schema with the specified key (namespace or alias) in the EdM metadata document.
|
||||
|
@ -42,16 +42,16 @@ public interface XMLMetadata {
|
|||
* @param key namespace or alias
|
||||
* @return the Schema with the specified key in the EdM metadata document
|
||||
*/
|
||||
Schema getSchema(final String key);
|
||||
CsdlSchema getSchema(final String key);
|
||||
|
||||
/**
|
||||
* Returns all Schema objects defined in the EdM metadata document.
|
||||
*
|
||||
* @return all Schema objects defined in the EdM metadata document
|
||||
*/
|
||||
List<Schema> getSchemas();
|
||||
List<CsdlSchema> getSchemas();
|
||||
|
||||
Map<String, Schema> getSchemaByNsOrAlias();
|
||||
Map<String, CsdlSchema> getSchemaByNsOrAlias();
|
||||
|
||||
List<Reference> getReferences();
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.apache.olingo.commons.api.domain.ODataError;
|
|||
import org.apache.olingo.commons.api.domain.ODataProperty;
|
||||
import org.apache.olingo.commons.api.domain.ODataServiceDocument;
|
||||
import org.apache.olingo.commons.api.edm.Edm;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
import org.apache.olingo.commons.api.format.ODataFormat;
|
||||
import org.apache.olingo.commons.api.serialization.ODataDeserializerException;
|
||||
|
||||
|
@ -55,7 +55,7 @@ public interface ODataReader {
|
|||
* <tt><edmx:Reference/></tt>) metadata document
|
||||
* @return metadata representation.
|
||||
*/
|
||||
Edm readMetadata(Map<String, Schema> xmlSchemas);
|
||||
Edm readMetadata(Map<String, CsdlSchema> xmlSchemas);
|
||||
|
||||
/**
|
||||
* Parses an OData service document.
|
||||
|
|
|
@ -31,9 +31,9 @@ import org.apache.olingo.client.api.edm.xml.Include;
|
|||
import org.apache.olingo.client.api.edm.xml.IncludeAnnotations;
|
||||
import org.apache.olingo.client.api.edm.xml.Reference;
|
||||
import org.apache.olingo.client.api.edm.xml.XMLMetadata;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
import org.apache.olingo.commons.api.format.ODataFormat;
|
||||
|
||||
public class XMLMetadataRequestImpl
|
||||
|
@ -62,7 +62,7 @@ public class XMLMetadataRequestImpl
|
|||
|
||||
// edmx:Include
|
||||
for (Include include : reference.getIncludes()) {
|
||||
final Schema includedSchema = includeMetadata.getSchema(include.getNamespace());
|
||||
final CsdlSchema includedSchema = includeMetadata.getSchema(include.getNamespace());
|
||||
if (includedSchema != null) {
|
||||
response.getBody().getSchemas().add(includedSchema);
|
||||
if (StringUtils.isNotBlank(include.getAlias())) {
|
||||
|
@ -73,14 +73,14 @@ public class XMLMetadataRequestImpl
|
|||
|
||||
// edmx:IncludeAnnotations
|
||||
for (IncludeAnnotations include : reference.getIncludeAnnotations()) {
|
||||
for (Schema schema : includeMetadata.getSchemas()) {
|
||||
for (CsdlSchema schema : includeMetadata.getSchemas()) {
|
||||
// create empty schema that will be fed with edm:Annotations that match the criteria in IncludeAnnotations
|
||||
final Schema forInclusion = new Schema();
|
||||
final CsdlSchema forInclusion = new CsdlSchema();
|
||||
forInclusion.setNamespace(schema.getNamespace());
|
||||
forInclusion.setAlias(schema.getAlias());
|
||||
|
||||
// process all edm:Annotations in each schema of the included document
|
||||
for (Annotations annotationGroup : schema.getAnnotationGroups()) {
|
||||
for (CsdlAnnotations annotationGroup : schema.getAnnotationGroups()) {
|
||||
// take into account only when (TargetNamespace was either not provided or matches) and
|
||||
// (Qualifier was either not provided or matches)
|
||||
if ((StringUtils.isBlank(include.getTargetNamespace())
|
||||
|
@ -89,11 +89,11 @@ public class XMLMetadataRequestImpl
|
|||
&& (StringUtils.isBlank(include.getQualifier())
|
||||
|| include.getQualifier().equals(annotationGroup.getQualifier()))) {
|
||||
|
||||
final Annotations toBeIncluded = new Annotations();
|
||||
final CsdlAnnotations toBeIncluded = new CsdlAnnotations();
|
||||
toBeIncluded.setTarget(annotationGroup.getTarget());
|
||||
toBeIncluded.setQualifier(annotationGroup.getQualifier());
|
||||
// only import annotations with terms matching the given TermNamespace
|
||||
for (Annotation annotation : annotationGroup.getAnnotations()) {
|
||||
for (CsdlAnnotation annotation : annotationGroup.getAnnotations()) {
|
||||
if (include.getTermNamespace().equals(StringUtils.substringBeforeLast(annotation.getTerm(), "."))) {
|
||||
toBeIncluded.getAnnotations().add(annotation);
|
||||
}
|
||||
|
|
|
@ -24,36 +24,36 @@ import java.util.Map;
|
|||
|
||||
import org.apache.olingo.commons.api.ODataException;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmProvider;
|
||||
import org.apache.olingo.commons.api.edm.provider.Action;
|
||||
import org.apache.olingo.commons.api.edm.provider.ActionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.AliasInfo;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.ComplexType;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityContainerInfo;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntitySet;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityType;
|
||||
import org.apache.olingo.commons.api.edm.provider.EnumType;
|
||||
import org.apache.olingo.commons.api.edm.provider.Function;
|
||||
import org.apache.olingo.commons.api.edm.provider.FunctionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.Singleton;
|
||||
import org.apache.olingo.commons.api.edm.provider.Term;
|
||||
import org.apache.olingo.commons.api.edm.provider.TypeDefinition;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmProvider;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAction;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlActionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAliasInfo;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlComplexType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityContainerInfo;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntitySet;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEnumType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunction;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunctionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSingleton;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlTerm;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlTypeDefinition;
|
||||
|
||||
public class ClientEdmProvider extends AbstractEdmProvider {
|
||||
public class ClientEdmProvider extends CsdlAbstractEdmProvider {
|
||||
|
||||
private final Map<String, Schema> xmlSchemas;
|
||||
private final Map<String, CsdlSchema> xmlSchemas;
|
||||
|
||||
public ClientEdmProvider(Map<String, Schema> xmlSchemas) {
|
||||
public ClientEdmProvider(Map<String, CsdlSchema> xmlSchemas) {
|
||||
this.xmlSchemas = xmlSchemas;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(enumTypeName.getNamespace());
|
||||
public CsdlEnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(enumTypeName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEnumType(enumTypeName.getName());
|
||||
}
|
||||
|
@ -61,8 +61,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public TypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(typeDefinitionName.getNamespace());
|
||||
public CsdlTypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(typeDefinitionName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getTypeDefinition(typeDefinitionName.getName());
|
||||
}
|
||||
|
@ -70,8 +70,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public EntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(entityTypeName.getNamespace());
|
||||
public CsdlEntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(entityTypeName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEntityType(entityTypeName.getName());
|
||||
}
|
||||
|
@ -79,8 +79,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public ComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(complexTypeName.getNamespace());
|
||||
public CsdlComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(complexTypeName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getComplexType(complexTypeName.getName());
|
||||
}
|
||||
|
@ -88,8 +88,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Action> getActions(final FullQualifiedName actionName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(actionName.getNamespace());
|
||||
public List<CsdlAction> getActions(final FullQualifiedName actionName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(actionName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getActions(actionName.getName());
|
||||
}
|
||||
|
@ -97,8 +97,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Function> getFunctions(final FullQualifiedName functionName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(functionName.getNamespace());
|
||||
public List<CsdlFunction> getFunctions(final FullQualifiedName functionName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(functionName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getFunctions(functionName.getName());
|
||||
}
|
||||
|
@ -106,8 +106,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Term getTerm(final FullQualifiedName termName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(termName.getNamespace());
|
||||
public CsdlTerm getTerm(final FullQualifiedName termName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(termName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getTerm(termName.getName());
|
||||
}
|
||||
|
@ -115,9 +115,9 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public EntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
public CsdlEntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
throws ODataException {
|
||||
Schema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
CsdlSchema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEntityContainer().getEntitySet(entitySetName);
|
||||
}
|
||||
|
@ -125,9 +125,9 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Singleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
public CsdlSingleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
throws ODataException {
|
||||
Schema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
CsdlSchema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEntityContainer().getSingleton(singletonName);
|
||||
}
|
||||
|
@ -135,9 +135,9 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public ActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
public CsdlActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
throws ODataException {
|
||||
Schema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
CsdlSchema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEntityContainer().getActionImport(actionImportName);
|
||||
}
|
||||
|
@ -145,9 +145,9 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public FunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
public CsdlFunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
throws ODataException {
|
||||
Schema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
CsdlSchema schema = xmlSchemas.get(entityContainer.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getEntityContainer().getFunctionImport(functionImportName);
|
||||
}
|
||||
|
@ -155,10 +155,11 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public EntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName) throws ODataException {
|
||||
for (Schema schema : xmlSchemas.values()) {
|
||||
public CsdlEntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName)
|
||||
throws ODataException {
|
||||
for (CsdlSchema schema : xmlSchemas.values()) {
|
||||
if (schema.getEntityContainer() != null) {
|
||||
return new EntityContainerInfo().setContainerName(entityContainerName).setExtendsContainer(
|
||||
return new CsdlEntityContainerInfo().setContainerName(entityContainerName).setExtendsContainer(
|
||||
schema.getEntityContainer().getExtendsContainerFQN());
|
||||
}
|
||||
}
|
||||
|
@ -166,24 +167,24 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<AliasInfo> getAliasInfos() throws ODataException {
|
||||
ArrayList<AliasInfo> aliasInfo = new ArrayList<AliasInfo>();
|
||||
for (Schema schema : xmlSchemas.values()) {
|
||||
public List<CsdlAliasInfo> getAliasInfos() throws ODataException {
|
||||
ArrayList<CsdlAliasInfo> aliasInfo = new ArrayList<CsdlAliasInfo>();
|
||||
for (CsdlSchema schema : xmlSchemas.values()) {
|
||||
if (schema.getAlias() != null) {
|
||||
aliasInfo.add(new AliasInfo().setNamespace(schema.getNamespace()).setAlias(schema.getAlias()));
|
||||
aliasInfo.add(new CsdlAliasInfo().setNamespace(schema.getNamespace()).setAlias(schema.getAlias()));
|
||||
}
|
||||
}
|
||||
return aliasInfo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Schema> getSchemas() throws ODataException {
|
||||
return new ArrayList<Schema>(xmlSchemas.values());
|
||||
public List<CsdlSchema> getSchemas() throws ODataException {
|
||||
return new ArrayList<CsdlSchema>(xmlSchemas.values());
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityContainer getEntityContainer() throws ODataException {
|
||||
for (Schema schema : xmlSchemas.values()) {
|
||||
public CsdlEntityContainer getEntityContainer() throws ODataException {
|
||||
for (CsdlSchema schema : xmlSchemas.values()) {
|
||||
if (schema.getEntityContainer() != null) {
|
||||
return schema.getEntityContainer();
|
||||
}
|
||||
|
@ -192,8 +193,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Annotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException {
|
||||
Schema schema = xmlSchemas.get(targetName.getNamespace());
|
||||
public CsdlAnnotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException {
|
||||
CsdlSchema schema = xmlSchemas.get(targetName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getAnnotationGroup(targetName.getName());
|
||||
}
|
||||
|
@ -201,8 +202,8 @@ public class ClientEdmProvider extends AbstractEdmProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Annotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException {
|
||||
final Schema schema = xmlSchemas.get(annotatedName.getNamespace());
|
||||
public CsdlAnnotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException {
|
||||
final CsdlSchema schema = xmlSchemas.get(annotatedName.getNamespace());
|
||||
if (schema != null) {
|
||||
return schema.getAnnotatables().get(annotatedName.getName());
|
||||
}
|
||||
|
|
|
@ -26,13 +26,13 @@ import org.apache.commons.lang3.StringUtils;
|
|||
import org.apache.olingo.client.api.edm.xml.Edmx;
|
||||
import org.apache.olingo.client.api.edm.xml.Reference;
|
||||
import org.apache.olingo.client.api.edm.xml.XMLMetadata;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
|
||||
/**
|
||||
* Entry point for access information about EDM metadata.
|
||||
*/
|
||||
public class ClientXMLMetadata extends AbstractEdmItem implements XMLMetadata {
|
||||
public class ClientXMLMetadata extends CsdlAbstractEdmItem implements XMLMetadata {
|
||||
|
||||
private static final long serialVersionUID = 6025723060298454901L;
|
||||
protected final Edmx edmx;
|
||||
|
@ -42,24 +42,24 @@ public class ClientXMLMetadata extends AbstractEdmItem implements XMLMetadata {
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Schema> getSchemas() {
|
||||
public List<CsdlSchema> getSchemas() {
|
||||
return this.edmx.getDataServices().getSchemas();
|
||||
}
|
||||
|
||||
@Override
|
||||
public Schema getSchema(final int index) {
|
||||
public CsdlSchema getSchema(final int index) {
|
||||
return getSchemas().get(index);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Schema getSchema(final String key) {
|
||||
public CsdlSchema getSchema(final String key) {
|
||||
return getSchemaByNsOrAlias().get(key);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Schema> getSchemaByNsOrAlias() {
|
||||
final Map<String, Schema> schemaByNsOrAlias = new HashMap<String, Schema>();
|
||||
for (Schema schema : getSchemas()) {
|
||||
public Map<String, CsdlSchema> getSchemaByNsOrAlias() {
|
||||
final Map<String, CsdlSchema> schemaByNsOrAlias = new HashMap<String, CsdlSchema>();
|
||||
for (CsdlSchema schema : getSchemas()) {
|
||||
schemaByNsOrAlias.put(schema.getNamespace(), schema);
|
||||
if (StringUtils.isNotBlank(schema.getAlias())) {
|
||||
schemaByNsOrAlias.put(schema.getAlias(), schema);
|
||||
|
|
|
@ -21,18 +21,18 @@ package org.apache.olingo.client.core.edm.xml;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
|
||||
abstract class AbstractClientAnnotatableDynamicAnnotationExpression
|
||||
extends AbstractClientDynamicAnnotationExpression implements Annotatable {
|
||||
extends AbstractClientDynamicAnnotationExpression implements CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -450668773857358139L;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -18,12 +18,12 @@
|
|||
*/
|
||||
package org.apache.olingo.client.core.edm.xml;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.AnnotationExpression;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.ConstantAnnotationExpression;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.DynamicAnnotationExpression;
|
||||
|
||||
abstract class AbstractClientAnnotationExpression extends AbstractEdmItem implements AnnotationExpression {
|
||||
abstract class AbstractClientAnnotationExpression extends CsdlAbstractEdmItem implements AnnotationExpression {
|
||||
|
||||
private static final long serialVersionUID = -4238652997159205377L;
|
||||
|
||||
|
|
|
@ -22,14 +22,14 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.Action;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAction;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientAction.ActionDeserializer.class)
|
||||
class ClientAction extends Action {
|
||||
class ClientAction extends CsdlAction {
|
||||
|
||||
private static final long serialVersionUID = 5321541275349234088L;
|
||||
|
||||
|
|
|
@ -22,12 +22,12 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.ActionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlActionImport;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientActionImport.ActionImportDeserializer.class)
|
||||
class ClientActionImport extends ActionImport {
|
||||
class ClientActionImport extends CsdlActionImport {
|
||||
|
||||
private static final long serialVersionUID = 2971468441177647068L;
|
||||
|
||||
|
|
|
@ -23,19 +23,19 @@ import java.io.IOException;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
@JsonDeserialize(using = ClientAnnotation.AnnotationDeserializer.class)
|
||||
class ClientAnnotation extends Annotation {
|
||||
class ClientAnnotation extends CsdlAnnotation {
|
||||
|
||||
private static final long serialVersionUID = 5464714417411058033L;
|
||||
|
||||
static class AnnotationDeserializer extends AbstractClientEdmDeserializer<Annotation> {
|
||||
static class AnnotationDeserializer extends AbstractClientEdmDeserializer<CsdlAnnotation> {
|
||||
|
||||
@Override
|
||||
protected Annotation doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlAnnotation doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ClientAnnotation annotation = new ClientAnnotation();
|
||||
|
|
|
@ -21,14 +21,14 @@ package org.apache.olingo.client.core.edm.xml;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotations;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientAnnotations.AnnotationsDeserializer.class)
|
||||
class ClientAnnotations extends Annotations {
|
||||
class ClientAnnotations extends CsdlAnnotations {
|
||||
|
||||
private static final long serialVersionUID = -5961207981571644200L;
|
||||
|
||||
|
|
|
@ -22,21 +22,21 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.ComplexType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlComplexType;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientComplexType.ComplexTypeDeserializer.class)
|
||||
class ClientComplexType extends ComplexType {
|
||||
class ClientComplexType extends CsdlComplexType {
|
||||
|
||||
private static final long serialVersionUID = 4076944306925840115L;
|
||||
|
||||
static class ComplexTypeDeserializer extends AbstractClientEdmDeserializer<ComplexType> {
|
||||
static class ComplexTypeDeserializer extends AbstractClientEdmDeserializer<CsdlComplexType> {
|
||||
|
||||
@Override
|
||||
protected ComplexType doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlComplexType doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ClientComplexType complexType = new ClientComplexType();
|
||||
|
|
|
@ -26,17 +26,17 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.client.api.edm.xml.DataServices;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
@JsonDeserialize(using = ClientDataServices.DataServicesDeserializer.class)
|
||||
class ClientDataServices extends AbstractEdmItem implements DataServices {
|
||||
class ClientDataServices extends CsdlAbstractEdmItem implements DataServices {
|
||||
|
||||
private static final long serialVersionUID = 4200317286476885204L;
|
||||
|
||||
private final List<Schema> schemas = new ArrayList<Schema>();
|
||||
private final List<CsdlSchema> schemas = new ArrayList<CsdlSchema>();
|
||||
|
||||
private String dataServiceVersion;
|
||||
|
||||
|
@ -61,7 +61,7 @@ class ClientDataServices extends AbstractEdmItem implements DataServices {
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Schema> getSchemas() {
|
||||
public List<CsdlSchema> getSchemas() {
|
||||
return schemas;
|
||||
}
|
||||
|
||||
|
|
|
@ -28,12 +28,12 @@ import com.fasterxml.jackson.databind.DeserializationContext;
|
|||
import org.apache.olingo.client.api.edm.xml.DataServices;
|
||||
import org.apache.olingo.client.api.edm.xml.Edmx;
|
||||
import org.apache.olingo.client.api.edm.xml.Reference;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
@JsonDeserialize(using = ClientEdmx.EdmxDeserializer.class)
|
||||
public class ClientEdmx extends AbstractEdmItem implements Edmx {
|
||||
public class ClientEdmx extends CsdlAbstractEdmItem implements Edmx {
|
||||
|
||||
private static final long serialVersionUID = -6293476719276092572L;
|
||||
|
||||
|
|
|
@ -21,14 +21,14 @@ package org.apache.olingo.client.core.edm.xml;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityContainer;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientEntityContainer.EntityContainerDeserializer.class)
|
||||
class ClientEntityContainer extends EntityContainer {
|
||||
class ClientEntityContainer extends CsdlEntityContainer {
|
||||
|
||||
private static final long serialVersionUID = 5631432527646955795L;
|
||||
|
||||
|
|
|
@ -25,19 +25,19 @@ import java.util.List;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.PropertyRef;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlPropertyRef;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
@JsonDeserialize(using = ClientEntityKey.EntityKeyDeserializer.class)
|
||||
class ClientEntityKey extends AbstractEdmItem {
|
||||
class ClientEntityKey extends CsdlAbstractEdmItem {
|
||||
|
||||
private static final long serialVersionUID = 520227585458843347L;
|
||||
|
||||
private final List<PropertyRef> propertyRefs = new ArrayList<PropertyRef>();
|
||||
private final List<CsdlPropertyRef> propertyRefs = new ArrayList<CsdlPropertyRef>();
|
||||
|
||||
public List<PropertyRef> getPropertyRefs() {
|
||||
public List<CsdlPropertyRef> getPropertyRefs() {
|
||||
return propertyRefs;
|
||||
}
|
||||
|
||||
|
|
|
@ -22,20 +22,20 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntitySet;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntitySet;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientEntitySet.EntitySetDeserializer.class)
|
||||
class ClientEntitySet extends EntitySet {
|
||||
class ClientEntitySet extends CsdlEntitySet {
|
||||
|
||||
private static final long serialVersionUID = -5553885465204370676L;
|
||||
|
||||
static class EntitySetDeserializer extends AbstractClientEdmDeserializer<EntitySet> {
|
||||
static class EntitySetDeserializer extends AbstractClientEdmDeserializer<CsdlEntitySet> {
|
||||
@Override
|
||||
protected EntitySet doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlEntitySet doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ClientEntitySet entitySet = new ClientEntitySet();
|
||||
|
|
|
@ -22,20 +22,20 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityType;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientEntityType.EntityTypeDeserializer.class)
|
||||
class ClientEntityType extends EntityType {
|
||||
class ClientEntityType extends CsdlEntityType {
|
||||
|
||||
private static final long serialVersionUID = -3986417775876689669L;
|
||||
|
||||
static class EntityTypeDeserializer extends AbstractClientEdmDeserializer<EntityType> {
|
||||
static class EntityTypeDeserializer extends AbstractClientEdmDeserializer<CsdlEntityType> {
|
||||
@Override
|
||||
protected EntityType doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlEntityType doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ClientEntityType entityType = new ClientEntityType();
|
||||
|
|
|
@ -22,21 +22,21 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.EnumMember;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEnumMember;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientEnumMember.EnumMemberDeserializer.class)
|
||||
class ClientEnumMember extends EnumMember {
|
||||
class ClientEnumMember extends CsdlEnumMember {
|
||||
|
||||
private static final long serialVersionUID = -6138606817225829791L;
|
||||
|
||||
static class EnumMemberDeserializer extends AbstractClientEdmDeserializer<EnumMember> {
|
||||
static class EnumMemberDeserializer extends AbstractClientEdmDeserializer<CsdlEnumMember> {
|
||||
@Override
|
||||
protected EnumMember doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlEnumMember doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final EnumMember member = new EnumMember();
|
||||
final CsdlEnumMember member = new CsdlEnumMember();
|
||||
|
||||
for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
|
||||
final JsonToken token = jp.getCurrentToken();
|
||||
|
|
|
@ -22,14 +22,14 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.EnumType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEnumType;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientEnumType.EnumTypeDeserializer.class)
|
||||
class ClientEnumType extends EnumType {
|
||||
class ClientEnumType extends CsdlEnumType {
|
||||
|
||||
private static final long serialVersionUID = 9191189755592743333L;
|
||||
|
||||
|
|
|
@ -22,14 +22,14 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.Function;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunction;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientFunction.FunctionDeserializer.class)
|
||||
class ClientFunction extends Function {
|
||||
class ClientFunction extends CsdlFunction {
|
||||
|
||||
private static final long serialVersionUID = -5494898295282843362L;
|
||||
|
||||
|
|
|
@ -22,14 +22,14 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.FunctionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunctionImport;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientFunctionImport.FunctionImportDeserializer.class)
|
||||
class ClientFunctionImport extends FunctionImport {
|
||||
class ClientFunctionImport extends CsdlFunctionImport {
|
||||
|
||||
private static final long serialVersionUID = -1686801084142932402L;
|
||||
|
||||
|
|
|
@ -23,12 +23,12 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.client.api.edm.xml.Include;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientInclude.IncludeDeserializer.class)
|
||||
class ClientInclude extends AbstractEdmItem implements Include {
|
||||
class ClientInclude extends CsdlAbstractEdmItem implements Include {
|
||||
|
||||
private static final long serialVersionUID = -5450008299655584221L;
|
||||
|
||||
|
|
|
@ -23,12 +23,12 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.client.api.edm.xml.IncludeAnnotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientIncludeAnnotations.IncludeAnnotationsDeserializer.class)
|
||||
class ClientIncludeAnnotations extends AbstractEdmItem implements IncludeAnnotations {
|
||||
class ClientIncludeAnnotations extends CsdlAbstractEdmItem implements IncludeAnnotations {
|
||||
|
||||
private static final long serialVersionUID = -8157841387011422396L;
|
||||
|
||||
|
|
|
@ -22,24 +22,24 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.provider.NavigationProperty;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlNavigationProperty;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientNavigationProperty.NavigationPropertyDeserializer.class)
|
||||
class ClientNavigationProperty extends NavigationProperty {
|
||||
class ClientNavigationProperty extends CsdlNavigationProperty {
|
||||
|
||||
private static final long serialVersionUID = 6240231735592427582L;
|
||||
|
||||
static class NavigationPropertyDeserializer extends AbstractClientEdmDeserializer<NavigationProperty> {
|
||||
static class NavigationPropertyDeserializer extends AbstractClientEdmDeserializer<CsdlNavigationProperty> {
|
||||
|
||||
@Override
|
||||
protected NavigationProperty doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlNavigationProperty doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final NavigationProperty property = new ClientNavigationProperty();
|
||||
final CsdlNavigationProperty property = new ClientNavigationProperty();
|
||||
|
||||
for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
|
||||
final JsonToken token = jp.getCurrentToken();
|
||||
|
|
|
@ -22,30 +22,31 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.NavigationPropertyBinding;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlNavigationPropertyBinding;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientNavigationPropertyBinding.NavigationPropertyBindingDeserializer.class)
|
||||
class ClientNavigationPropertyBinding extends NavigationPropertyBinding {
|
||||
class ClientNavigationPropertyBinding extends CsdlNavigationPropertyBinding {
|
||||
|
||||
private static final long serialVersionUID = -7056978592235483660L;
|
||||
|
||||
@Override
|
||||
public NavigationPropertyBinding setPath(final String path) {
|
||||
public CsdlNavigationPropertyBinding setPath(final String path) {
|
||||
super.setPath(path);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public NavigationPropertyBinding setTarget(final String target) {
|
||||
public CsdlNavigationPropertyBinding setTarget(final String target) {
|
||||
super.setTarget(target);
|
||||
return this;
|
||||
}
|
||||
|
||||
static class NavigationPropertyBindingDeserializer extends AbstractClientEdmDeserializer<NavigationPropertyBinding> {
|
||||
static class NavigationPropertyBindingDeserializer extends
|
||||
AbstractClientEdmDeserializer<CsdlNavigationPropertyBinding> {
|
||||
@Override
|
||||
protected NavigationPropertyBinding doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlNavigationPropertyBinding doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ClientNavigationPropertyBinding member = new ClientNavigationPropertyBinding();
|
||||
|
|
|
@ -22,28 +22,28 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.OnDelete;
|
||||
import org.apache.olingo.commons.api.edm.provider.OnDeleteAction;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlOnDelete;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlOnDeleteAction;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientOnDelete.OnDeleteDeserializer.class)
|
||||
class ClientOnDelete extends OnDelete {
|
||||
class ClientOnDelete extends CsdlOnDelete {
|
||||
|
||||
private static final long serialVersionUID = -7130889202653716784L;
|
||||
|
||||
static class OnDeleteDeserializer extends AbstractClientEdmDeserializer<OnDelete> {
|
||||
static class OnDeleteDeserializer extends AbstractClientEdmDeserializer<CsdlOnDelete> {
|
||||
@Override
|
||||
protected OnDelete doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlOnDelete doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final OnDelete ondelete = new ClientOnDelete();
|
||||
final CsdlOnDelete ondelete = new ClientOnDelete();
|
||||
|
||||
for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
|
||||
final JsonToken token = jp.getCurrentToken();
|
||||
if (token == JsonToken.FIELD_NAME) {
|
||||
if ("Action".equals(jp.getCurrentName())) {
|
||||
OnDeleteAction action = OnDeleteAction.valueOf(jp.nextTextValue());
|
||||
CsdlOnDeleteAction action = CsdlOnDeleteAction.valueOf(jp.nextTextValue());
|
||||
ondelete.setAction(action);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,14 +23,14 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.Parameter;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlParameter;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientParameter.ParameterDeserializer.class)
|
||||
class ClientParameter extends Parameter {
|
||||
class ClientParameter extends CsdlParameter {
|
||||
|
||||
private static final long serialVersionUID = 7119478691341167904L;
|
||||
|
||||
|
|
|
@ -23,14 +23,14 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.Property;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlProperty;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientProperty.PropertyDeserializer.class)
|
||||
class ClientProperty extends Property {
|
||||
class ClientProperty extends CsdlProperty {
|
||||
|
||||
private static final long serialVersionUID = -4521766603286651372L;
|
||||
|
||||
|
|
|
@ -22,21 +22,21 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.PropertyRef;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlPropertyRef;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientPropertyRef.PropertyRefDeserializer.class)
|
||||
class ClientPropertyRef extends PropertyRef {
|
||||
class ClientPropertyRef extends CsdlPropertyRef {
|
||||
|
||||
private static final long serialVersionUID = 1504095609268590326L;
|
||||
|
||||
static class PropertyRefDeserializer extends AbstractClientEdmDeserializer<PropertyRef> {
|
||||
static class PropertyRefDeserializer extends AbstractClientEdmDeserializer<CsdlPropertyRef> {
|
||||
@Override
|
||||
protected PropertyRef doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlPropertyRef doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final PropertyRef propertyRef = new ClientPropertyRef();
|
||||
final CsdlPropertyRef propertyRef = new ClientPropertyRef();
|
||||
|
||||
for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
|
||||
final JsonToken token = jp.getCurrentToken();
|
||||
|
|
|
@ -29,23 +29,23 @@ import com.fasterxml.jackson.databind.DeserializationContext;
|
|||
import org.apache.olingo.client.api.edm.xml.Include;
|
||||
import org.apache.olingo.client.api.edm.xml.IncludeAnnotations;
|
||||
import org.apache.olingo.client.api.edm.xml.Reference;
|
||||
import org.apache.olingo.commons.api.edm.provider.AbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
@JsonDeserialize(using = ClientReference.ReferenceDeserializer.class)
|
||||
class ClientReference extends AbstractEdmItem implements Reference {
|
||||
class ClientReference extends CsdlAbstractEdmItem implements Reference {
|
||||
|
||||
private static final long serialVersionUID = 7720274712545267654L;
|
||||
|
||||
private URI uri;
|
||||
private final List<Include> includes = new ArrayList<Include>();
|
||||
private final List<IncludeAnnotations> includeAnnotations = new ArrayList<IncludeAnnotations>();
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
|
|
|
@ -22,21 +22,21 @@ import com.fasterxml.jackson.core.JsonParser;
|
|||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import org.apache.olingo.commons.api.edm.provider.ReferentialConstraint;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlReferentialConstraint;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientReferentialConstraint.ReferentialConstraintDeserializer.class)
|
||||
class ClientReferentialConstraint extends ReferentialConstraint {
|
||||
class ClientReferentialConstraint extends CsdlReferentialConstraint {
|
||||
|
||||
private static final long serialVersionUID = -5822115908069878139L;
|
||||
|
||||
static class ReferentialConstraintDeserializer extends AbstractClientEdmDeserializer<ReferentialConstraint> {
|
||||
static class ReferentialConstraintDeserializer extends AbstractClientEdmDeserializer<CsdlReferentialConstraint> {
|
||||
@Override
|
||||
protected ReferentialConstraint doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
protected CsdlReferentialConstraint doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
|
||||
throws IOException {
|
||||
|
||||
final ReferentialConstraint refConst = new ClientReferentialConstraint();
|
||||
final CsdlReferentialConstraint refConst = new ClientReferentialConstraint();
|
||||
|
||||
for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
|
||||
final JsonToken token = jp.getCurrentToken();
|
||||
|
|
|
@ -23,14 +23,14 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.ReturnType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlReturnType;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientReturnType.ReturnTypeDeserializer.class)
|
||||
class ClientReturnType extends ReturnType {
|
||||
class ClientReturnType extends CsdlReturnType {
|
||||
|
||||
private static final long serialVersionUID = 6261092793901735110L;
|
||||
|
||||
|
|
|
@ -21,14 +21,14 @@ package org.apache.olingo.client.core.edm.xml;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientSchema.SchemaDeserializer.class)
|
||||
class ClientSchema extends Schema {
|
||||
class ClientSchema extends CsdlSchema {
|
||||
|
||||
private static final long serialVersionUID = 1911087363912024939L;
|
||||
|
||||
|
|
|
@ -21,14 +21,14 @@ package org.apache.olingo.client.core.edm.xml;
|
|||
import com.fasterxml.jackson.core.JsonParser;
|
||||
import com.fasterxml.jackson.core.JsonToken;
|
||||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.olingo.commons.api.edm.provider.Singleton;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSingleton;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientSingleton.SingletonDeserializer.class)
|
||||
class ClientSingleton extends Singleton {
|
||||
class ClientSingleton extends CsdlSingleton {
|
||||
|
||||
private static final long serialVersionUID = 1656749615107151921L;
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@ import com.fasterxml.jackson.databind.DeserializationContext;
|
|||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.Term;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlTerm;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
|
@ -32,7 +32,7 @@ import java.io.IOException;
|
|||
import java.util.Arrays;
|
||||
|
||||
@JsonDeserialize(using = ClientTerm.TermDeserializer.class)
|
||||
class ClientTerm extends Term {
|
||||
class ClientTerm extends CsdlTerm {
|
||||
|
||||
private static final long serialVersionUID = -8350072064720586186L;
|
||||
|
||||
|
|
|
@ -23,14 +23,14 @@ import com.fasterxml.jackson.core.JsonToken;
|
|||
import com.fasterxml.jackson.databind.DeserializationContext;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.TypeDefinition;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlTypeDefinition;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@JsonDeserialize(using = ClientTypeDefinition.TypeDefinitionDeserializer.class)
|
||||
class ClientTypeDefinition extends TypeDefinition {
|
||||
class ClientTypeDefinition extends CsdlTypeDefinition {
|
||||
|
||||
private static final long serialVersionUID = -902407149079419602L;
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ import org.apache.olingo.commons.api.domain.ODataServiceDocument;
|
|||
import org.apache.olingo.commons.api.domain.ODataValue;
|
||||
import org.apache.olingo.commons.api.edm.Edm;
|
||||
import org.apache.olingo.commons.api.edm.EdmPrimitiveTypeKind;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
import org.apache.olingo.commons.api.format.ODataFormat;
|
||||
import org.apache.olingo.commons.api.serialization.ODataDeserializerException;
|
||||
import org.apache.olingo.commons.core.edm.EdmProviderImpl;
|
||||
|
@ -67,7 +67,7 @@ public class ODataReaderImpl implements ODataReader {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Edm readMetadata(final Map<String, Schema> xmlSchemas) {
|
||||
public Edm readMetadata(final Map<String, CsdlSchema> xmlSchemas) {
|
||||
ClientEdmProvider prov = new ClientEdmProvider(xmlSchemas);
|
||||
return new EdmProviderImpl(prov);
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ import org.apache.olingo.commons.api.edm.EdmEnumType;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.geo.Geospatial;
|
||||
import org.apache.olingo.commons.api.edm.geo.Point;
|
||||
import org.apache.olingo.commons.api.edm.provider.EnumType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEnumType;
|
||||
import org.apache.olingo.commons.core.edm.EdmEnumTypeImpl;
|
||||
import org.junit.Test;
|
||||
|
||||
|
@ -51,7 +51,7 @@ public class URIEscapeTest {
|
|||
@Test
|
||||
public void _enum() throws UnsupportedEncodingException {
|
||||
final EdmEnumType pattern =
|
||||
new EdmEnumTypeImpl(null, new FullQualifiedName("Sales", "Pattern"), new EnumType());
|
||||
new EdmEnumTypeImpl(null, new FullQualifiedName("Sales", "Pattern"), new CsdlEnumType());
|
||||
|
||||
assertEquals("Sales.Pattern'Yellow'", URIUtils.escape( pattern.toUriLiteral("Yellow")));
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ import org.apache.olingo.client.core.AbstractTest;
|
|||
import org.apache.olingo.commons.api.Constants;
|
||||
import org.apache.olingo.commons.api.edm.EdmEnumType;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.provider.EnumType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEnumType;
|
||||
import org.apache.olingo.commons.core.edm.EdmEnumTypeImpl;
|
||||
import org.junit.Test;
|
||||
|
||||
|
@ -55,7 +55,7 @@ public class FilterFactoryTest extends AbstractTest {
|
|||
@Test
|
||||
public void has() {
|
||||
final EdmEnumType pattern =
|
||||
new EdmEnumTypeImpl(null, new FullQualifiedName("Sales", "Pattern"), new EnumType());
|
||||
new EdmEnumTypeImpl(null, new FullQualifiedName("Sales", "Pattern"), new CsdlEnumType());
|
||||
final URIFilter filter = getFilterFactory().has(getFilterArgFactory().property("style"), pattern, "Yellow");
|
||||
|
||||
assertEquals("(style has Sales.Pattern'Yellow')", filter.build());
|
||||
|
|
|
@ -48,16 +48,16 @@ import org.apache.olingo.commons.api.edm.EdmTypeDefinition;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.annotation.EdmUrlRef;
|
||||
import org.apache.olingo.commons.api.edm.constants.EdmTypeKind;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.ComplexType;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.EntityType;
|
||||
import org.apache.olingo.commons.api.edm.provider.Function;
|
||||
import org.apache.olingo.commons.api.edm.provider.FunctionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.Schema;
|
||||
import org.apache.olingo.commons.api.edm.provider.Singleton;
|
||||
import org.apache.olingo.commons.api.edm.provider.Term;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotations;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlComplexType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlEntityType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunction;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlFunctionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSchema;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlSingleton;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlTerm;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.Apply;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.Collection;
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.ConstantAnnotationExpression;
|
||||
|
@ -145,7 +145,7 @@ public class MetadataTest extends AbstractTest {
|
|||
assertNotNull(metadata);
|
||||
|
||||
assertFalse(metadata.getSchema(0).getAnnotationGroups().isEmpty());
|
||||
final Annotations annots = metadata.getSchema(0).getAnnotationGroup("ODataDemo.DemoService/Suppliers");
|
||||
final CsdlAnnotations annots = metadata.getSchema(0).getAnnotationGroup("ODataDemo.DemoService/Suppliers");
|
||||
assertNotNull(annots);
|
||||
assertFalse(annots.getAnnotations().isEmpty());
|
||||
assertEquals(ConstantAnnotationExpression.Type.String,
|
||||
|
@ -185,13 +185,13 @@ public class MetadataTest extends AbstractTest {
|
|||
toMetadata(getClass().getResourceAsStream("northwind-metadata.xml"));
|
||||
assertNotNull(metadata);
|
||||
|
||||
final Schema first = metadata.getSchema("NorthwindModel");
|
||||
final CsdlSchema first = metadata.getSchema("NorthwindModel");
|
||||
assertNotNull(first);
|
||||
|
||||
final Schema second = metadata.getSchema("ODataWebExperimental.Northwind.Model");
|
||||
final CsdlSchema second = metadata.getSchema("ODataWebExperimental.Northwind.Model");
|
||||
assertNotNull(second);
|
||||
|
||||
final EntityContainer entityContainer = second.getEntityContainer();
|
||||
final CsdlEntityContainer entityContainer = second.getEntityContainer();
|
||||
assertNotNull(entityContainer);
|
||||
assertEquals("NorthwindEntities", entityContainer.getName());
|
||||
}
|
||||
|
@ -208,31 +208,31 @@ public class MetadataTest extends AbstractTest {
|
|||
assertFalse(metadata.getReferences().isEmpty());
|
||||
assertEquals("Org.OData.Measures.V1", metadata.getReferences().get(1).getIncludes().get(0).getNamespace());
|
||||
|
||||
final EntityType product = metadata.getSchema(0).getEntityType("Product");
|
||||
final CsdlEntityType product = metadata.getSchema(0).getEntityType("Product");
|
||||
assertTrue(product.hasStream());
|
||||
assertEquals("UoM.ISOCurrency", product.getProperty("Price").getAnnotations().get(0).getTerm());
|
||||
assertEquals("Products", product.getNavigationProperty("Supplier").getPartner());
|
||||
|
||||
final EntityType category = metadata.getSchema(0).getEntityType("Category");
|
||||
final CsdlEntityType category = metadata.getSchema(0).getEntityType("Category");
|
||||
assertNotNull(category);
|
||||
|
||||
final ComplexType address = metadata.getSchema(0).getComplexType("Address");
|
||||
final CsdlComplexType address = metadata.getSchema(0).getComplexType("Address");
|
||||
assertFalse(address.getNavigationProperty("Country").getReferentialConstraints().isEmpty());
|
||||
assertEquals("Name",
|
||||
address.getNavigationProperty("Country").getReferentialConstraints().get(0).getReferencedProperty());
|
||||
|
||||
final Function productsByRating = metadata.getSchema(0).getFunctions("ProductsByRating").get(0);
|
||||
final CsdlFunction productsByRating = metadata.getSchema(0).getFunctions("ProductsByRating").get(0);
|
||||
assertNotNull(productsByRating.getParameter("Rating"));
|
||||
assertEquals("Edm.Int32", productsByRating.getParameter("Rating").getType());
|
||||
assertEquals("ODataDemo.Product", productsByRating.getReturnType().getType());
|
||||
assertTrue(productsByRating.getReturnType().isCollection());
|
||||
|
||||
final Singleton contoso = metadata.getSchema(0).getEntityContainer().getSingleton("Contoso");
|
||||
final CsdlSingleton contoso = metadata.getSchema(0).getEntityContainer().getSingleton("Contoso");
|
||||
assertNotNull(contoso);
|
||||
assertFalse(contoso.getNavigationPropertyBindings().isEmpty());
|
||||
assertEquals("Products", contoso.getNavigationPropertyBindings().get(0).getPath());
|
||||
|
||||
final FunctionImport functionImport = metadata.getSchema(0).getEntityContainer().
|
||||
final CsdlFunctionImport functionImport = metadata.getSchema(0).getEntityContainer().
|
||||
getFunctionImport("ProductsByRating");
|
||||
assertNotNull(functionImport);
|
||||
assertEquals(metadata.getSchema(0).getNamespace() + "." + productsByRating.getName(),
|
||||
|
@ -286,7 +286,7 @@ public class MetadataTest extends AbstractTest {
|
|||
assertNotNull(metadata);
|
||||
|
||||
// Check displayName
|
||||
final Annotation displayName = metadata.getSchema(0).getAnnotationGroup("ODataDemo.Supplier").
|
||||
final CsdlAnnotation displayName = metadata.getSchema(0).getAnnotationGroup("ODataDemo.Supplier").
|
||||
getAnnotation("Vocabulary1.DisplayName");
|
||||
assertNotNull(displayName);
|
||||
assertTrue(displayName.getExpression().isDynamic());
|
||||
|
@ -308,7 +308,7 @@ public class MetadataTest extends AbstractTest {
|
|||
assertEquals("Address/CountryName", thirdArg.getValue());
|
||||
|
||||
// Check Tags
|
||||
final Annotation tags = metadata.getSchema(0).getAnnotationGroup("ODataDemo.Product").
|
||||
final CsdlAnnotation tags = metadata.getSchema(0).getAnnotationGroup("ODataDemo.Product").
|
||||
getAnnotation("Vocabulary1.Tags");
|
||||
assertNotNull(tags);
|
||||
assertTrue(tags.getExpression().isDynamic());
|
||||
|
@ -347,10 +347,10 @@ public class MetadataTest extends AbstractTest {
|
|||
toMetadata(getClass().getResourceAsStream("fromdoc4-metadata.xml"));
|
||||
assertNotNull(metadata);
|
||||
|
||||
final Annotations group = metadata.getSchema(0).getAnnotationGroups().get(0);
|
||||
final CsdlAnnotations group = metadata.getSchema(0).getAnnotationGroups().get(0);
|
||||
assertNotNull(group);
|
||||
|
||||
Annotation annotation = group.getAnnotations().get(0);
|
||||
CsdlAnnotation annotation = group.getAnnotations().get(0);
|
||||
assertTrue(annotation.getExpression().isDynamic());
|
||||
assertTrue(annotation.getExpression().asDynamic().isCast());
|
||||
assertEquals("Edm.Decimal", annotation.getExpression().asDynamic().asCast().getType());
|
||||
|
@ -402,11 +402,11 @@ public class MetadataTest extends AbstractTest {
|
|||
final XMLMetadata metadata = getClient().getDeserializer(ODataFormat.XML).
|
||||
toMetadata(input);
|
||||
|
||||
Schema schema = metadata.getSchema("Capabilities");
|
||||
CsdlSchema schema = metadata.getSchema("Capabilities");
|
||||
assertNotNull(schema);
|
||||
assertEquals(23, schema.getTerms().size());
|
||||
|
||||
final Term deleteRestrictions = schema.getTerm("DeleteRestrictions");
|
||||
final CsdlTerm deleteRestrictions = schema.getTerm("DeleteRestrictions");
|
||||
assertNotNull(deleteRestrictions);
|
||||
assertEquals("Capabilities.DeleteRestrictionsType", deleteRestrictions.getType());
|
||||
}
|
||||
|
|
|
@ -1,116 +0,0 @@
|
|||
/*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.ODataException;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public abstract class AbstractEdmProvider implements EdmProvider {
|
||||
|
||||
@Override
|
||||
public EnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public TypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Action> getActions(final FullQualifiedName actionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Function> getFunctions(final FullQualifiedName functionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Term getTerm(final FullQualifiedName termName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Singleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<AliasInfo> getAliasInfos() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Schema> getSchemas() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityContainer getEntityContainer() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Annotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Annotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
}
|
|
@ -28,16 +28,16 @@ import org.apache.commons.lang3.builder.HashCodeBuilder;
|
|||
import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
public abstract class AbstractEdmItem implements Serializable {
|
||||
public abstract class CsdlAbstractEdmItem implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 241190986363884784L;
|
||||
|
||||
protected <T extends Named> T getOneByName(final String name, final Collection<T> items) {
|
||||
protected <T extends CsdlNamed> T getOneByName(final String name, final Collection<T> items) {
|
||||
final List<T> result = getAllByName(name, items);
|
||||
return result.isEmpty() ? null : result.get(0);
|
||||
}
|
||||
|
||||
protected <T extends Named> List<T> getAllByName(final String name, final Collection<T> items) {
|
||||
protected <T extends CsdlNamed> List<T> getAllByName(final String name, final Collection<T> items) {
|
||||
final List<T> result = new ArrayList<T>();
|
||||
for (T type : items) {
|
||||
if (name.equals(type.getName())) {
|
|
@ -0,0 +1,117 @@
|
|||
/*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.ODataException;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public abstract class CsdlAbstractEdmProvider implements CsdlEdmProvider {
|
||||
|
||||
@Override
|
||||
public CsdlEnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlTypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlEntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CsdlAction> getActions(final FullQualifiedName actionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CsdlFunction> getFunctions(final FullQualifiedName functionName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlTerm getTerm(final FullQualifiedName termName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlEntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlSingleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlFunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlEntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName)
|
||||
throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CsdlAliasInfo> getAliasInfos() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CsdlSchema> getSchemas() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlEntityContainer getEntityContainer() throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlAnnotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CsdlAnnotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException {
|
||||
return null;
|
||||
}
|
||||
}
|
|
@ -20,36 +20,36 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public class Action extends Operation {
|
||||
public class CsdlAction extends CsdlOperation {
|
||||
|
||||
private static final long serialVersionUID = 211295197043448841L;
|
||||
|
||||
@Override
|
||||
public Action setName(final String name) {
|
||||
public CsdlAction setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Action setBound(final boolean isBound) {
|
||||
public CsdlAction setBound(final boolean isBound) {
|
||||
this.isBound = isBound;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Action setEntitySetPath(final String entitySetPath) {
|
||||
public CsdlAction setEntitySetPath(final String entitySetPath) {
|
||||
this.entitySetPath = entitySetPath;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Action setParameters(final List<Parameter> parameters) {
|
||||
public CsdlAction setParameters(final List<CsdlParameter> parameters) {
|
||||
this.parameters = parameters;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Action setReturnType(final ReturnType returnType) {
|
||||
public CsdlAction setReturnType(final CsdlReturnType returnType) {
|
||||
this.returnType = returnType;
|
||||
return this;
|
||||
}
|
|
@ -21,20 +21,20 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
|
||||
public class ActionImport extends OperationImport {
|
||||
public class CsdlActionImport extends CsdlOperationImport {
|
||||
|
||||
private static final long serialVersionUID = 9186148718228340987L;
|
||||
|
||||
private FullQualifiedName action;
|
||||
|
||||
@Override
|
||||
public ActionImport setName(final String name) {
|
||||
public CsdlActionImport setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ActionImport setEntitySet(final String entitySet) {
|
||||
public CsdlActionImport setEntitySet(final String entitySet) {
|
||||
this.entitySet = entitySet;
|
||||
return this;
|
||||
}
|
||||
|
@ -47,12 +47,12 @@ public class ActionImport extends OperationImport {
|
|||
return action;
|
||||
}
|
||||
|
||||
public ActionImport setAction(final String action) {
|
||||
public CsdlActionImport setAction(final String action) {
|
||||
this.action = new FullQualifiedName(action);
|
||||
return this;
|
||||
}
|
||||
|
||||
public ActionImport setAction(final FullQualifiedName action) {
|
||||
public CsdlActionImport setAction(final FullQualifiedName action) {
|
||||
this.action = action;
|
||||
return this;
|
||||
}
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
public class AliasInfo {
|
||||
public class CsdlAliasInfo {
|
||||
|
||||
private String namespace;
|
||||
|
||||
|
@ -28,7 +28,7 @@ public class AliasInfo {
|
|||
return namespace;
|
||||
}
|
||||
|
||||
public AliasInfo setNamespace(final String namespace) {
|
||||
public CsdlAliasInfo setNamespace(final String namespace) {
|
||||
this.namespace = namespace;
|
||||
return this;
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ public class AliasInfo {
|
|||
return alias;
|
||||
}
|
||||
|
||||
public AliasInfo setAlias(final String alias) {
|
||||
public CsdlAliasInfo setAlias(final String alias) {
|
||||
this.alias = alias;
|
||||
return this;
|
||||
}
|
|
@ -20,7 +20,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public interface Annotatable {
|
||||
public interface CsdlAnnotatable {
|
||||
|
||||
List<Annotation> getAnnotations();
|
||||
List<CsdlAnnotation> getAnnotations();
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.provider.annotation.AnnotationExpression;
|
||||
|
||||
public class Annotation extends AbstractEdmItem implements Annotatable {
|
||||
public class CsdlAnnotation extends CsdlAbstractEdmItem implements CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -7137313445729486860L;
|
||||
|
||||
|
@ -31,7 +31,7 @@ public class Annotation extends AbstractEdmItem implements Annotatable {
|
|||
|
||||
private String qualifier;
|
||||
|
||||
private List<Annotation> annotation = new ArrayList<Annotation>();
|
||||
private List<CsdlAnnotation> annotation = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
private AnnotationExpression annotationExpression;
|
||||
|
||||
|
@ -47,7 +47,7 @@ public class Annotation extends AbstractEdmItem implements Annotatable {
|
|||
return term;
|
||||
}
|
||||
|
||||
public Annotation setTerm(final String term) {
|
||||
public CsdlAnnotation setTerm(final String term) {
|
||||
this.term = term;
|
||||
return this;
|
||||
}
|
||||
|
@ -56,7 +56,7 @@ public class Annotation extends AbstractEdmItem implements Annotatable {
|
|||
return qualifier;
|
||||
}
|
||||
|
||||
public Annotation setQualifier(final String qualifier) {
|
||||
public CsdlAnnotation setQualifier(final String qualifier) {
|
||||
this.qualifier = qualifier;
|
||||
return this;
|
||||
}
|
||||
|
@ -65,13 +65,13 @@ public class Annotation extends AbstractEdmItem implements Annotatable {
|
|||
// return annotation;
|
||||
// }
|
||||
|
||||
public Annotation setAnnotations(final List<Annotation> annotation) {
|
||||
public CsdlAnnotation setAnnotations(final List<CsdlAnnotation> annotation) {
|
||||
this.annotation = annotation;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotation;
|
||||
}
|
||||
}
|
|
@ -21,11 +21,11 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class Annotations extends AbstractEdmItem implements Annotatable{
|
||||
public class CsdlAnnotations extends CsdlAbstractEdmItem implements CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 8283036066408166150L;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
private String target;
|
||||
|
||||
|
@ -35,7 +35,7 @@ public class Annotations extends AbstractEdmItem implements Annotatable{
|
|||
return target;
|
||||
}
|
||||
|
||||
public Annotations setTarget(final String target) {
|
||||
public CsdlAnnotations setTarget(final String target) {
|
||||
this.target = target;
|
||||
return this;
|
||||
}
|
||||
|
@ -44,19 +44,19 @@ public class Annotations extends AbstractEdmItem implements Annotatable{
|
|||
return qualifier;
|
||||
}
|
||||
|
||||
public Annotations setQualifier(final String qualifier) {
|
||||
public CsdlAnnotations setQualifier(final String qualifier) {
|
||||
this.qualifier = qualifier;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
public Annotation getAnnotation(final String term) {
|
||||
Annotation result = null;
|
||||
for (Annotation annotation : getAnnotations()) {
|
||||
public CsdlAnnotation getAnnotation(final String term) {
|
||||
CsdlAnnotation result = null;
|
||||
for (CsdlAnnotation annotation : getAnnotations()) {
|
||||
if (term.equals(annotation.getTerm())) {
|
||||
result = annotation;
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public abstract class BindingTarget extends AbstractEdmItem implements Named, Annotatable {
|
||||
public abstract class CsdlBindingTarget extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -7011724617956042182L;
|
||||
|
||||
|
@ -31,15 +31,16 @@ public abstract class BindingTarget extends AbstractEdmItem implements Named, An
|
|||
|
||||
protected FullQualifiedName type;
|
||||
|
||||
protected List<NavigationPropertyBinding> navigationPropertyBindings = new ArrayList<NavigationPropertyBinding>();
|
||||
protected List<CsdlNavigationPropertyBinding> navigationPropertyBindings =
|
||||
new ArrayList<CsdlNavigationPropertyBinding>();
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public BindingTarget setName(final String name) {
|
||||
public CsdlBindingTarget setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -52,27 +53,28 @@ public abstract class BindingTarget extends AbstractEdmItem implements Named, An
|
|||
return type;
|
||||
}
|
||||
|
||||
public BindingTarget setType(final String type) {
|
||||
public CsdlBindingTarget setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
||||
public BindingTarget setType(final FullQualifiedName type) {
|
||||
public CsdlBindingTarget setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<NavigationPropertyBinding> getNavigationPropertyBindings() {
|
||||
public List<CsdlNavigationPropertyBinding> getNavigationPropertyBindings() {
|
||||
return navigationPropertyBindings;
|
||||
}
|
||||
|
||||
public BindingTarget setNavigationPropertyBindings(final List<NavigationPropertyBinding> navigationPropertyBindings) {
|
||||
public CsdlBindingTarget setNavigationPropertyBindings(
|
||||
final List<CsdlNavigationPropertyBinding> navigationPropertyBindings) {
|
||||
this.navigationPropertyBindings = navigationPropertyBindings;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
|
@ -22,48 +22,48 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class ComplexType extends StructuralType {
|
||||
public class CsdlComplexType extends CsdlStructuralType {
|
||||
|
||||
private static final long serialVersionUID = 1089771609327713928L;
|
||||
|
||||
@Override
|
||||
public ComplexType setName(final String name) {
|
||||
public CsdlComplexType setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setOpenType(final boolean isOpenType) {
|
||||
public CsdlComplexType setOpenType(final boolean isOpenType) {
|
||||
this.isOpenType = isOpenType;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setBaseType(final String baseType) {
|
||||
public CsdlComplexType setBaseType(final String baseType) {
|
||||
this.baseType = new FullQualifiedName(baseType);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setBaseType(final FullQualifiedName baseType) {
|
||||
public CsdlComplexType setBaseType(final FullQualifiedName baseType) {
|
||||
this.baseType = baseType;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setAbstract(final boolean isAbstract) {
|
||||
public CsdlComplexType setAbstract(final boolean isAbstract) {
|
||||
this.isAbstract = isAbstract;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setProperties(final List<Property> properties) {
|
||||
public CsdlComplexType setProperties(final List<CsdlProperty> properties) {
|
||||
this.properties = properties;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ComplexType setNavigationProperties(final List<NavigationProperty> navigationProperties) {
|
||||
public CsdlComplexType setNavigationProperties(final List<CsdlNavigationProperty> navigationProperties) {
|
||||
this.navigationProperties = navigationProperties;
|
||||
return this;
|
||||
}
|
|
@ -0,0 +1,179 @@
|
|||
/*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.ODataException;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public interface CsdlEdmProvider {
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlEnumType} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param enumTypeName
|
||||
* @return {@link CsdlEnumType} for given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlEnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlTypeDefinition} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param typeDefinitionName
|
||||
* @return {@link CsdlTypeDefinition} for given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlTypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlEntityType} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityTypeName
|
||||
* @return {@link CsdlEntityType} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlEntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link CsdlComplexType} or <b>null</b> if nothing is found.
|
||||
*
|
||||
* @param complexTypeName
|
||||
* @return {@link CsdlComplexType} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all {@link CsdlAction} for the FullQualifiedname
|
||||
* or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param actionName
|
||||
* @return List of {@link CsdlAction} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<CsdlAction> getActions(final FullQualifiedName actionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all {@link CsdlFunction} for the FullQualifiedname or <b>null</b> if nothing is
|
||||
* found
|
||||
*
|
||||
* @param functionName
|
||||
* @return List of {@link CsdlFunction} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<CsdlFunction> getFunctions(final FullQualifiedName functionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link CsdlTerm} for the FullQualifiedName or <b>null</b> if nothing is found.
|
||||
* @param termName the name of the Term
|
||||
* @return {@link CsdlTerm} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlTerm getTerm(final FullQualifiedName termName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlEntitySet} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this EntitySet is contained in
|
||||
* @param entitySetName
|
||||
* @return {@link CsdlEntitySet} for the given container and entityset name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlEntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlSingleton} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this Singleton is contained in
|
||||
* @param singletonName
|
||||
* @return {@link CsdlSingleton} for given container and singleton name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlSingleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlActionImport} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this ActionImport is contained in
|
||||
* @param actionImportName
|
||||
* @return {@link CsdlActionImport} for the given container and ActionImport name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link CsdlFunctionImport} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this FunctionImport is contained in
|
||||
* @param functionImportName
|
||||
* @return {@link CsdlFunctionImport} for the given container name and function import name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlFunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link CsdlEntityContainerInfo} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainerName (null for default container)
|
||||
* @return {@link CsdlEntityContainerInfo} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public CsdlEntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all namespaces which have an alias
|
||||
*
|
||||
* @return List of alias info
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<CsdlAliasInfo> getAliasInfos() throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a collection of all {@link CsdlSchema}
|
||||
*
|
||||
* @return List<{@link Schema}>
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<CsdlSchema> getSchemas() throws ODataException;
|
||||
|
||||
/**
|
||||
* Returns the entity container of this edm
|
||||
* @return {@link CsdlEntityContainer} of this edm
|
||||
*/
|
||||
public CsdlEntityContainer getEntityContainer() throws ODataException;
|
||||
|
||||
/**
|
||||
* @param targetName
|
||||
* @return {@link CsdlAnnotations} group for the given Target
|
||||
*/
|
||||
public CsdlAnnotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException;
|
||||
|
||||
/**
|
||||
* @param annotatedName
|
||||
* @return Annotatble element by target name
|
||||
*/
|
||||
public CsdlAnnotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException;
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class EntityContainer extends AbstractEdmItem implements Named, Annotatable {
|
||||
public class CsdlEntityContainer extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 5384682515007129458L;
|
||||
|
||||
|
@ -31,22 +31,22 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
|
||||
private FullQualifiedName extendsContainer;
|
||||
|
||||
private List<EntitySet> entitySets = new ArrayList<EntitySet>();
|
||||
private List<CsdlEntitySet> entitySets = new ArrayList<CsdlEntitySet>();
|
||||
|
||||
private List<ActionImport> actionImports = new ArrayList<ActionImport>();
|
||||
private List<CsdlActionImport> actionImports = new ArrayList<CsdlActionImport>();
|
||||
|
||||
private List<FunctionImport> functionImports = new ArrayList<FunctionImport>();
|
||||
private List<CsdlFunctionImport> functionImports = new ArrayList<CsdlFunctionImport>();
|
||||
|
||||
private List<Singleton> singletons = new ArrayList<Singleton>();
|
||||
private List<CsdlSingleton> singletons = new ArrayList<CsdlSingleton>();
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
// Annotations
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public EntityContainer setName(final String name) {
|
||||
public CsdlEntityContainer setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -62,25 +62,25 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
return extendsContainer;
|
||||
}
|
||||
|
||||
public EntityContainer setExtendsContainer(final String extendsContainer) {
|
||||
public CsdlEntityContainer setExtendsContainer(final String extendsContainer) {
|
||||
this.extendsContainer = new FullQualifiedName(extendsContainer);
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<EntitySet> getEntitySets() {
|
||||
public List<CsdlEntitySet> getEntitySets() {
|
||||
return entitySets;
|
||||
}
|
||||
|
||||
public EntitySet getEntitySet(final String name) {
|
||||
public CsdlEntitySet getEntitySet(final String name) {
|
||||
return getOneByName(name, getEntitySets());
|
||||
}
|
||||
|
||||
public EntityContainer setEntitySets(final List<EntitySet> entitySets) {
|
||||
public CsdlEntityContainer setEntitySets(final List<CsdlEntitySet> entitySets) {
|
||||
this.entitySets = entitySets;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<ActionImport> getActionImports() {
|
||||
public List<CsdlActionImport> getActionImports() {
|
||||
return actionImports;
|
||||
}
|
||||
|
||||
|
@ -90,7 +90,7 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
* @param name name.
|
||||
* @return action import.
|
||||
*/
|
||||
public ActionImport getActionImport(final String name) {
|
||||
public CsdlActionImport getActionImport(final String name) {
|
||||
return getOneByName(name, getActionImports());
|
||||
}
|
||||
|
||||
|
@ -100,16 +100,16 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
* @param name name.
|
||||
* @return action imports.
|
||||
*/
|
||||
public List<ActionImport> getActionImports(final String name) {
|
||||
public List<CsdlActionImport> getActionImports(final String name) {
|
||||
return getAllByName(name, getActionImports());
|
||||
}
|
||||
|
||||
public EntityContainer setActionImports(final List<ActionImport> actionImports) {
|
||||
public CsdlEntityContainer setActionImports(final List<CsdlActionImport> actionImports) {
|
||||
this.actionImports = actionImports;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<FunctionImport> getFunctionImports() {
|
||||
public List<CsdlFunctionImport> getFunctionImports() {
|
||||
return functionImports;
|
||||
}
|
||||
|
||||
|
@ -119,7 +119,7 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
* @param name name.
|
||||
* @return function import.
|
||||
*/
|
||||
public FunctionImport getFunctionImport(final String name) {
|
||||
public CsdlFunctionImport getFunctionImport(final String name) {
|
||||
return getOneByName(name, getFunctionImports());
|
||||
}
|
||||
|
||||
|
@ -129,30 +129,30 @@ public class EntityContainer extends AbstractEdmItem implements Named, Annotatab
|
|||
* @param name name.
|
||||
* @return function imports.
|
||||
*/
|
||||
public List<FunctionImport> getFunctionImports(final String name) {
|
||||
public List<CsdlFunctionImport> getFunctionImports(final String name) {
|
||||
return getAllByName(name, getFunctionImports());
|
||||
}
|
||||
|
||||
public EntityContainer setFunctionImports(final List<FunctionImport> functionImports) {
|
||||
public CsdlEntityContainer setFunctionImports(final List<CsdlFunctionImport> functionImports) {
|
||||
this.functionImports = functionImports;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Singleton> getSingletons() {
|
||||
public List<CsdlSingleton> getSingletons() {
|
||||
return singletons;
|
||||
}
|
||||
|
||||
public Singleton getSingleton(final String name) {
|
||||
public CsdlSingleton getSingleton(final String name) {
|
||||
return getOneByName(name, getSingletons());
|
||||
}
|
||||
|
||||
public EntityContainer setSingletons(final List<Singleton> singletons) {
|
||||
public CsdlEntityContainer setSingletons(final List<CsdlSingleton> singletons) {
|
||||
this.singletons = singletons;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
|
@ -20,7 +20,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class EntityContainerInfo {
|
||||
public class CsdlEntityContainerInfo {
|
||||
|
||||
private FullQualifiedName containerName;
|
||||
|
||||
|
@ -30,7 +30,7 @@ public class EntityContainerInfo {
|
|||
return containerName;
|
||||
}
|
||||
|
||||
public EntityContainerInfo setContainerName(final FullQualifiedName containerName) {
|
||||
public CsdlEntityContainerInfo setContainerName(final FullQualifiedName containerName) {
|
||||
this.containerName = containerName;
|
||||
return this;
|
||||
}
|
||||
|
@ -39,7 +39,7 @@ public class EntityContainerInfo {
|
|||
return extendsContainer;
|
||||
}
|
||||
|
||||
public EntityContainerInfo setExtendsContainer(final FullQualifiedName extendsContainer) {
|
||||
public CsdlEntityContainerInfo setExtendsContainer(final FullQualifiedName extendsContainer) {
|
||||
this.extendsContainer = extendsContainer;
|
||||
return this;
|
||||
}
|
|
@ -22,7 +22,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class EntitySet extends BindingTarget {
|
||||
public class CsdlEntitySet extends CsdlBindingTarget {
|
||||
|
||||
private static final long serialVersionUID = 5291570018480936643L;
|
||||
|
||||
|
@ -30,25 +30,26 @@ public class EntitySet extends BindingTarget {
|
|||
private boolean includeInServiceDocument = true;
|
||||
|
||||
@Override
|
||||
public EntitySet setName(final String name) {
|
||||
public CsdlEntitySet setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntitySet setNavigationPropertyBindings(final List<NavigationPropertyBinding> navigationPropertyBindings) {
|
||||
public CsdlEntitySet setNavigationPropertyBindings(
|
||||
final List<CsdlNavigationPropertyBinding> navigationPropertyBindings) {
|
||||
this.navigationPropertyBindings = navigationPropertyBindings;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntitySet setType(final String type) {
|
||||
public CsdlEntitySet setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntitySet setType(final FullQualifiedName type) {
|
||||
public CsdlEntitySet setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
@ -57,7 +58,7 @@ public class EntitySet extends BindingTarget {
|
|||
return includeInServiceDocument;
|
||||
}
|
||||
|
||||
public EntitySet setIncludeInServiceDocument(final boolean includeInServiceDocument) {
|
||||
public CsdlEntitySet setIncludeInServiceDocument(final boolean includeInServiceDocument) {
|
||||
this.includeInServiceDocument = includeInServiceDocument;
|
||||
return this;
|
||||
}
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
public class EntitySetPath {
|
||||
public class CsdlEntitySetPath {
|
||||
|
||||
private String bindingParameter;
|
||||
|
||||
|
@ -28,7 +28,7 @@ public class EntitySetPath {
|
|||
return bindingParameter;
|
||||
}
|
||||
|
||||
public EntitySetPath setBindingParameter(final String bindingParameter) {
|
||||
public CsdlEntitySetPath setBindingParameter(final String bindingParameter) {
|
||||
this.bindingParameter = bindingParameter;
|
||||
return this;
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ public class EntitySetPath {
|
|||
return path;
|
||||
}
|
||||
|
||||
public EntitySetPath setPath(final String path) {
|
||||
public CsdlEntitySetPath setPath(final String path) {
|
||||
this.path = path;
|
||||
return this;
|
||||
}
|
|
@ -22,11 +22,11 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class EntityType extends StructuralType {
|
||||
public class CsdlEntityType extends CsdlStructuralType {
|
||||
|
||||
private static final long serialVersionUID = -1564752618679704024L;
|
||||
|
||||
private List<PropertyRef> key;
|
||||
private List<CsdlPropertyRef> key;
|
||||
|
||||
private boolean hasStream = false;
|
||||
|
||||
|
@ -34,58 +34,58 @@ public class EntityType extends StructuralType {
|
|||
return hasStream;
|
||||
}
|
||||
|
||||
public EntityType setHasStream(final boolean hasStream) {
|
||||
public CsdlEntityType setHasStream(final boolean hasStream) {
|
||||
this.hasStream = hasStream;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<PropertyRef> getKey() {
|
||||
public List<CsdlPropertyRef> getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
public EntityType setKey(final List<PropertyRef> key) {
|
||||
public CsdlEntityType setKey(final List<CsdlPropertyRef> key) {
|
||||
this.key = key;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setName(final String name) {
|
||||
public CsdlEntityType setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setOpenType(final boolean isOpenType) {
|
||||
public CsdlEntityType setOpenType(final boolean isOpenType) {
|
||||
this.isOpenType = isOpenType;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setBaseType(final String baseType) {
|
||||
public CsdlEntityType setBaseType(final String baseType) {
|
||||
this.baseType = new FullQualifiedName(baseType);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setBaseType(final FullQualifiedName baseType) {
|
||||
public CsdlEntityType setBaseType(final FullQualifiedName baseType) {
|
||||
this.baseType = baseType;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setAbstract(final boolean isAbstract) {
|
||||
public CsdlEntityType setAbstract(final boolean isAbstract) {
|
||||
this.isAbstract = isAbstract;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setProperties(final List<Property> properties) {
|
||||
public CsdlEntityType setProperties(final List<CsdlProperty> properties) {
|
||||
this.properties = properties;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EntityType setNavigationProperties(final List<NavigationProperty> navigationProperties) {
|
||||
public CsdlEntityType setNavigationProperties(final List<CsdlNavigationProperty> navigationProperties) {
|
||||
this.navigationProperties = navigationProperties;
|
||||
return this;
|
||||
}
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class EnumMember extends AbstractEdmItem implements Named, Annotatable{
|
||||
public class CsdlEnumMember extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 5618984420582832094L;
|
||||
|
||||
|
@ -29,13 +29,13 @@ public class EnumMember extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private String value;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public EnumMember setName(final String name) {
|
||||
public CsdlEnumMember setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -44,13 +44,13 @@ public class EnumMember extends AbstractEdmItem implements Named, Annotatable{
|
|||
return value;
|
||||
}
|
||||
|
||||
public EnumMember setValue(final String value) {
|
||||
public CsdlEnumMember setValue(final String value) {
|
||||
this.value = value;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
||||
public class CsdlEnumType extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -718032622783883403L;
|
||||
|
||||
|
@ -33,15 +33,15 @@ public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
|||
|
||||
private FullQualifiedName underlyingType;
|
||||
|
||||
private List<EnumMember> members = new ArrayList<EnumMember>();
|
||||
private List<CsdlEnumMember> members = new ArrayList<CsdlEnumMember>();
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public EnumType setName(final String name) {
|
||||
public CsdlEnumType setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -50,7 +50,7 @@ public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
|||
return isFlags;
|
||||
}
|
||||
|
||||
public EnumType setFlags(final boolean isFlags) {
|
||||
public CsdlEnumType setFlags(final boolean isFlags) {
|
||||
this.isFlags = isFlags;
|
||||
return this;
|
||||
}
|
||||
|
@ -62,25 +62,25 @@ public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
|||
return null;
|
||||
}
|
||||
|
||||
public EnumType setUnderlyingType(final String underlyingType) {
|
||||
public CsdlEnumType setUnderlyingType(final String underlyingType) {
|
||||
this.underlyingType = new FullQualifiedName(underlyingType);
|
||||
return this;
|
||||
}
|
||||
|
||||
public EnumType setUnderlyingType(final FullQualifiedName underlyingType) {
|
||||
public CsdlEnumType setUnderlyingType(final FullQualifiedName underlyingType) {
|
||||
this.underlyingType = underlyingType;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
public List<EnumMember> getMembers() {
|
||||
public List<CsdlEnumMember> getMembers() {
|
||||
return members;
|
||||
}
|
||||
|
||||
public EnumMember getMember(final String name) {
|
||||
EnumMember result = null;
|
||||
public CsdlEnumMember getMember(final String name) {
|
||||
CsdlEnumMember result = null;
|
||||
if (getMembers() != null) {
|
||||
for (EnumMember member : getMembers()) {
|
||||
for (CsdlEnumMember member : getMembers()) {
|
||||
if (name.equals(member.getName())) {
|
||||
result = member;
|
||||
}
|
||||
|
@ -89,10 +89,10 @@ public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
|||
return result;
|
||||
}
|
||||
|
||||
public EnumMember getMember(final Integer value) {
|
||||
EnumMember result = null;
|
||||
public CsdlEnumMember getMember(final Integer value) {
|
||||
CsdlEnumMember result = null;
|
||||
if (getMembers() != null) {
|
||||
for (EnumMember member : getMembers()) {
|
||||
for (CsdlEnumMember member : getMembers()) {
|
||||
if (String.valueOf(value).equals(member.getValue())) {
|
||||
result = member;
|
||||
}
|
||||
|
@ -101,13 +101,13 @@ public class EnumType extends AbstractEdmItem implements Named, Annotatable {
|
|||
return result;
|
||||
}
|
||||
|
||||
public EnumType setMembers(final List<EnumMember> members) {
|
||||
public CsdlEnumType setMembers(final List<CsdlEnumMember> members) {
|
||||
this.members = members;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -18,6 +18,6 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
public class Expression {
|
||||
public class CsdlExpression {
|
||||
//TODO: Expression implementation
|
||||
}
|
|
@ -20,7 +20,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
public class Function extends Operation {
|
||||
public class CsdlFunction extends CsdlOperation {
|
||||
|
||||
private static final long serialVersionUID = 673858921468578957L;
|
||||
|
||||
|
@ -30,37 +30,37 @@ public class Function extends Operation {
|
|||
return isComposable;
|
||||
}
|
||||
|
||||
public Function setComposable(final boolean isComposable) {
|
||||
public CsdlFunction setComposable(final boolean isComposable) {
|
||||
this.isComposable = isComposable;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Function setName(final String name) {
|
||||
public CsdlFunction setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Function setBound(final boolean isBound) {
|
||||
public CsdlFunction setBound(final boolean isBound) {
|
||||
this.isBound = isBound;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Function setEntitySetPath(final String entitySetPath) {
|
||||
public CsdlFunction setEntitySetPath(final String entitySetPath) {
|
||||
this.entitySetPath = entitySetPath;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Function setParameters(final List<Parameter> parameters) {
|
||||
public CsdlFunction setParameters(final List<CsdlParameter> parameters) {
|
||||
this.parameters = parameters;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Function setReturnType(final ReturnType returnType) {
|
||||
public CsdlFunction setReturnType(final CsdlReturnType returnType) {
|
||||
this.returnType = returnType;
|
||||
return this;
|
||||
}
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
|
||||
public class FunctionImport extends OperationImport {
|
||||
public class CsdlFunctionImport extends CsdlOperationImport {
|
||||
|
||||
private static final long serialVersionUID = 8479762299534736719L;
|
||||
|
||||
|
@ -36,13 +36,13 @@ public class FunctionImport extends OperationImport {
|
|||
}
|
||||
|
||||
@Override
|
||||
public FunctionImport setName(final String name) {
|
||||
public CsdlFunctionImport setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FunctionImport setEntitySet(final String entitySet) {
|
||||
public CsdlFunctionImport setEntitySet(final String entitySet) {
|
||||
this.entitySet = entitySet;
|
||||
return this;
|
||||
}
|
||||
|
@ -56,12 +56,12 @@ public class FunctionImport extends OperationImport {
|
|||
}
|
||||
|
||||
|
||||
public FunctionImport setFunction(final FullQualifiedName function) {
|
||||
public CsdlFunctionImport setFunction(final FullQualifiedName function) {
|
||||
this.function = function;
|
||||
return this;
|
||||
}
|
||||
|
||||
public FunctionImport setFunction(final String function) {
|
||||
public CsdlFunctionImport setFunction(final String function) {
|
||||
this.function = new FullQualifiedName(function);
|
||||
return this;
|
||||
}
|
||||
|
@ -70,7 +70,7 @@ public class FunctionImport extends OperationImport {
|
|||
return includeInServiceDocument;
|
||||
}
|
||||
|
||||
public FunctionImport setIncludeInServiceDocument(final boolean includeInServiceDocument) {
|
||||
public CsdlFunctionImport setIncludeInServiceDocument(final boolean includeInServiceDocument) {
|
||||
this.includeInServiceDocument = includeInServiceDocument;
|
||||
return this;
|
||||
}
|
|
@ -24,7 +24,7 @@ import org.apache.olingo.commons.api.edm.EdmMapping;
|
|||
* Content of this class does not appear within the CSDL metadata document. This class is used to perform server
|
||||
* internal mapping for edm primitive types to java types.
|
||||
*/
|
||||
public class Mapping implements EdmMapping {
|
||||
public class CsdlMapping implements EdmMapping {
|
||||
|
||||
private Class<?> mappedJavaClass;
|
||||
|
||||
|
@ -34,7 +34,7 @@ public class Mapping implements EdmMapping {
|
|||
* @param mappedJavaClass class to which is mapped
|
||||
* @return this for method chaining
|
||||
*/
|
||||
public Mapping setMappedJavaClass(Class<?> mappedJavaClass) {
|
||||
public CsdlMapping setMappedJavaClass(Class<?> mappedJavaClass) {
|
||||
this.mappedJavaClass = mappedJavaClass;
|
||||
return this;
|
||||
}
|
|
@ -20,7 +20,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
import java.io.Serializable;
|
||||
|
||||
public interface Named extends Serializable {
|
||||
public interface CsdlNamed extends Serializable {
|
||||
|
||||
String getName();
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class NavigationProperty extends AbstractEdmItem implements Named, Annotatable{
|
||||
public class CsdlNavigationProperty extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -788021920718310799L;
|
||||
|
||||
|
@ -37,14 +37,14 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
|
||||
private boolean containsTarget = false;
|
||||
|
||||
private List<ReferentialConstraint> referentialConstraints = new ArrayList<ReferentialConstraint>();
|
||||
private List<CsdlReferentialConstraint> referentialConstraints = new ArrayList<CsdlReferentialConstraint>();
|
||||
|
||||
// Facets
|
||||
private boolean nullable = true;
|
||||
|
||||
private OnDelete onDelete;
|
||||
private CsdlOnDelete onDelete;
|
||||
|
||||
private List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -54,12 +54,12 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
return isCollection;
|
||||
}
|
||||
|
||||
public NavigationProperty setCollection(final boolean isCollection) {
|
||||
public CsdlNavigationProperty setCollection(final boolean isCollection) {
|
||||
this.isCollection = isCollection;
|
||||
return this;
|
||||
}
|
||||
|
||||
public NavigationProperty setName(final String name) {
|
||||
public CsdlNavigationProperty setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -75,12 +75,12 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
return null;
|
||||
}
|
||||
|
||||
public NavigationProperty setType(final FullQualifiedName type) {
|
||||
public CsdlNavigationProperty setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
||||
public NavigationProperty setType(final String type) {
|
||||
public CsdlNavigationProperty setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
@ -89,7 +89,7 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
return partner;
|
||||
}
|
||||
|
||||
public NavigationProperty setPartner(final String partner) {
|
||||
public CsdlNavigationProperty setPartner(final String partner) {
|
||||
this.partner = partner;
|
||||
return this;
|
||||
}
|
||||
|
@ -98,16 +98,17 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
return containsTarget;
|
||||
}
|
||||
|
||||
public NavigationProperty setContainsTarget(final boolean containsTarget) {
|
||||
public CsdlNavigationProperty setContainsTarget(final boolean containsTarget) {
|
||||
this.containsTarget = containsTarget;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<ReferentialConstraint> getReferentialConstraints() {
|
||||
public List<CsdlReferentialConstraint> getReferentialConstraints() {
|
||||
return referentialConstraints;
|
||||
}
|
||||
|
||||
public NavigationProperty setReferentialConstraints(final List<ReferentialConstraint> referentialConstraints) {
|
||||
public CsdlNavigationProperty setReferentialConstraints(
|
||||
final List<CsdlReferentialConstraint> referentialConstraints) {
|
||||
this.referentialConstraints = referentialConstraints;
|
||||
return this;
|
||||
}
|
||||
|
@ -116,22 +117,22 @@ public class NavigationProperty extends AbstractEdmItem implements Named, Annota
|
|||
return nullable;
|
||||
}
|
||||
|
||||
public NavigationProperty setNullable(final Boolean nullable) {
|
||||
public CsdlNavigationProperty setNullable(final Boolean nullable) {
|
||||
this.nullable = nullable;
|
||||
return this;
|
||||
}
|
||||
|
||||
public OnDelete getOnDelete() {
|
||||
public CsdlOnDelete getOnDelete() {
|
||||
return onDelete;
|
||||
}
|
||||
|
||||
public NavigationProperty setOnDelete(final OnDelete onDelete) {
|
||||
public CsdlNavigationProperty setOnDelete(final CsdlOnDelete onDelete) {
|
||||
this.onDelete = onDelete;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -19,7 +19,7 @@
|
|||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
|
||||
public class NavigationPropertyBinding extends AbstractEdmItem {
|
||||
public class CsdlNavigationPropertyBinding extends CsdlAbstractEdmItem {
|
||||
|
||||
private static final long serialVersionUID = 770380971233808502L;
|
||||
|
||||
|
@ -31,7 +31,7 @@ public class NavigationPropertyBinding extends AbstractEdmItem {
|
|||
return path;
|
||||
}
|
||||
|
||||
public NavigationPropertyBinding setPath(final String path) {
|
||||
public CsdlNavigationPropertyBinding setPath(final String path) {
|
||||
this.path = path;
|
||||
return this;
|
||||
}
|
||||
|
@ -40,7 +40,7 @@ public class NavigationPropertyBinding extends AbstractEdmItem {
|
|||
return target;
|
||||
}
|
||||
|
||||
public NavigationPropertyBinding setTarget(final String target) {
|
||||
public CsdlNavigationPropertyBinding setTarget(final String target) {
|
||||
this.target = target;
|
||||
return this;
|
||||
}
|
|
@ -20,17 +20,17 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
|
||||
|
||||
|
||||
public class OnDelete extends AbstractEdmItem {
|
||||
public class CsdlOnDelete extends CsdlAbstractEdmItem {
|
||||
|
||||
private static final long serialVersionUID = -7130889202653716784L;
|
||||
|
||||
private OnDeleteAction action = OnDeleteAction.None;
|
||||
private CsdlOnDeleteAction action = CsdlOnDeleteAction.None;
|
||||
|
||||
public OnDeleteAction getAction() {
|
||||
public CsdlOnDeleteAction getAction() {
|
||||
return action;
|
||||
}
|
||||
|
||||
public OnDelete setAction(final OnDeleteAction action) {
|
||||
public CsdlOnDelete setAction(final CsdlOnDeleteAction action) {
|
||||
this.action = action;
|
||||
return this;
|
||||
}
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
public enum OnDeleteAction {
|
||||
public enum CsdlOnDeleteAction {
|
||||
|
||||
Cascade,
|
||||
None,
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public abstract class Operation extends AbstractEdmItem implements Named, Annotatable{
|
||||
public abstract class CsdlOperation extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -3842411084067064086L;
|
||||
|
||||
|
@ -31,17 +31,17 @@ public abstract class Operation extends AbstractEdmItem implements Named, Annota
|
|||
|
||||
protected String entitySetPath;
|
||||
|
||||
protected List<Parameter> parameters = new ArrayList<Parameter>();
|
||||
protected List<CsdlParameter> parameters = new ArrayList<CsdlParameter>();
|
||||
|
||||
protected ReturnType returnType;
|
||||
protected CsdlReturnType returnType;
|
||||
|
||||
protected final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
protected final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public Operation setName(final String name) {
|
||||
public CsdlOperation setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -50,7 +50,7 @@ public abstract class Operation extends AbstractEdmItem implements Named, Annota
|
|||
return isBound;
|
||||
}
|
||||
|
||||
public Operation setBound(final boolean isBound) {
|
||||
public CsdlOperation setBound(final boolean isBound) {
|
||||
this.isBound = isBound;
|
||||
return this;
|
||||
}
|
||||
|
@ -59,34 +59,34 @@ public abstract class Operation extends AbstractEdmItem implements Named, Annota
|
|||
return entitySetPath;
|
||||
}
|
||||
|
||||
public Operation setEntitySetPath(final String entitySetPath) {
|
||||
public CsdlOperation setEntitySetPath(final String entitySetPath) {
|
||||
this.entitySetPath = entitySetPath;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Parameter> getParameters() {
|
||||
public List<CsdlParameter> getParameters() {
|
||||
return parameters;
|
||||
}
|
||||
|
||||
public Parameter getParameter(String name) {
|
||||
public CsdlParameter getParameter(String name) {
|
||||
return getOneByName(name, getParameters());
|
||||
}
|
||||
|
||||
public Operation setParameters(final List<Parameter> parameters) {
|
||||
public CsdlOperation setParameters(final List<CsdlParameter> parameters) {
|
||||
this.parameters = parameters;
|
||||
return this;
|
||||
}
|
||||
|
||||
public ReturnType getReturnType() {
|
||||
public CsdlReturnType getReturnType() {
|
||||
return returnType;
|
||||
}
|
||||
|
||||
public Operation setReturnType(final ReturnType returnType) {
|
||||
public CsdlOperation setReturnType(final CsdlReturnType returnType) {
|
||||
this.returnType = returnType;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -21,19 +21,19 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public abstract class OperationImport extends AbstractEdmItem implements Named, Annotatable{
|
||||
public abstract class CsdlOperationImport extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -8928186067970681061L;
|
||||
|
||||
protected String name;
|
||||
protected String entitySet;
|
||||
protected final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
protected final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public OperationImport setName(final String name) {
|
||||
public CsdlOperationImport setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -42,13 +42,13 @@ public abstract class OperationImport extends AbstractEdmItem implements Named,
|
|||
return entitySet;
|
||||
}
|
||||
|
||||
public OperationImport setEntitySet(final String entitySet) {
|
||||
public CsdlOperationImport setEntitySet(final String entitySet) {
|
||||
this.entitySet = entitySet;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -24,7 +24,7 @@ import java.util.List;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
|
||||
public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
||||
public class CsdlParameter extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -7360900923880732015L;
|
||||
|
||||
|
@ -34,7 +34,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private boolean isCollection;
|
||||
|
||||
private Mapping mapping;
|
||||
private CsdlMapping mapping;
|
||||
|
||||
// Facets
|
||||
private boolean nullable = true;
|
||||
|
@ -47,13 +47,13 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private SRID srid;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public Parameter setName(final String name) {
|
||||
public CsdlParameter setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -66,12 +66,12 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return type;
|
||||
}
|
||||
|
||||
public Parameter setType(final String type) {
|
||||
public CsdlParameter setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Parameter setType(final FullQualifiedName type) {
|
||||
public CsdlParameter setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return isCollection;
|
||||
}
|
||||
|
||||
public Parameter setCollection(final boolean isCollection) {
|
||||
public CsdlParameter setCollection(final boolean isCollection) {
|
||||
this.isCollection = isCollection;
|
||||
return this;
|
||||
}
|
||||
|
@ -89,7 +89,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return nullable;
|
||||
}
|
||||
|
||||
public Parameter setNullable(final boolean nullable) {
|
||||
public CsdlParameter setNullable(final boolean nullable) {
|
||||
this.nullable = nullable;
|
||||
return this;
|
||||
}
|
||||
|
@ -98,7 +98,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return maxLength;
|
||||
}
|
||||
|
||||
public Parameter setMaxLength(final Integer maxLength) {
|
||||
public CsdlParameter setMaxLength(final Integer maxLength) {
|
||||
this.maxLength = maxLength;
|
||||
return this;
|
||||
}
|
||||
|
@ -107,7 +107,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return precision;
|
||||
}
|
||||
|
||||
public Parameter setPrecision(final Integer precision) {
|
||||
public CsdlParameter setPrecision(final Integer precision) {
|
||||
this.precision = precision;
|
||||
return this;
|
||||
}
|
||||
|
@ -116,7 +116,7 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return scale;
|
||||
}
|
||||
|
||||
public Parameter setScale(final Integer scale) {
|
||||
public CsdlParameter setScale(final Integer scale) {
|
||||
this.scale = scale;
|
||||
return this;
|
||||
}
|
||||
|
@ -125,21 +125,21 @@ public class Parameter extends AbstractEdmItem implements Named, Annotatable{
|
|||
return srid;
|
||||
}
|
||||
|
||||
public Parameter setSrid(final SRID srid) {
|
||||
public CsdlParameter setSrid(final SRID srid) {
|
||||
this.srid = srid;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
public Mapping getMapping() {
|
||||
public CsdlMapping getMapping() {
|
||||
return mapping;
|
||||
}
|
||||
|
||||
public Parameter setMapping(final Mapping mapping) {
|
||||
public CsdlParameter setMapping(final CsdlMapping mapping) {
|
||||
this.mapping = mapping;
|
||||
return this;
|
||||
}
|
|
@ -24,7 +24,7 @@ import java.util.List;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
|
||||
public class Property extends AbstractEdmItem implements Named, Annotatable{
|
||||
public class CsdlProperty extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -4224390853690843450L;
|
||||
|
||||
|
@ -36,7 +36,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private String mimeType;
|
||||
|
||||
private Mapping mapping;
|
||||
private CsdlMapping mapping;
|
||||
|
||||
// Facets
|
||||
private String defaultValue;
|
||||
|
@ -53,14 +53,14 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private SRID srid;
|
||||
|
||||
private List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public Property setName(final String name) {
|
||||
public CsdlProperty setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -69,7 +69,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return type;
|
||||
}
|
||||
|
||||
public Property setType(final String type) {
|
||||
public CsdlProperty setType(final String type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
@ -78,7 +78,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return new FullQualifiedName(type);
|
||||
}
|
||||
|
||||
public Property setType(FullQualifiedName fqnName){
|
||||
public CsdlProperty setType(FullQualifiedName fqnName){
|
||||
this.type = fqnName.getFullQualifiedNameAsString();
|
||||
return this;
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return collection;
|
||||
}
|
||||
|
||||
public Property setCollection(final boolean isCollection) {
|
||||
public CsdlProperty setCollection(final boolean isCollection) {
|
||||
collection = isCollection;
|
||||
return this;
|
||||
}
|
||||
|
@ -96,7 +96,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return defaultValue;
|
||||
}
|
||||
|
||||
public Property setDefaultValue(final String defaultValue) {
|
||||
public CsdlProperty setDefaultValue(final String defaultValue) {
|
||||
this.defaultValue = defaultValue;
|
||||
return this;
|
||||
}
|
||||
|
@ -105,7 +105,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return nullable;
|
||||
}
|
||||
|
||||
public Property setNullable(final boolean nullable) {
|
||||
public CsdlProperty setNullable(final boolean nullable) {
|
||||
this.nullable = nullable;
|
||||
return this;
|
||||
}
|
||||
|
@ -114,7 +114,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return maxLength;
|
||||
}
|
||||
|
||||
public Property setMaxLength(final Integer maxLength) {
|
||||
public CsdlProperty setMaxLength(final Integer maxLength) {
|
||||
this.maxLength = maxLength;
|
||||
return this;
|
||||
}
|
||||
|
@ -123,7 +123,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return precision;
|
||||
}
|
||||
|
||||
public Property setPrecision(final Integer precision) {
|
||||
public CsdlProperty setPrecision(final Integer precision) {
|
||||
this.precision = precision;
|
||||
return this;
|
||||
}
|
||||
|
@ -132,7 +132,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return scale;
|
||||
}
|
||||
|
||||
public Property setScale(final Integer scale) {
|
||||
public CsdlProperty setScale(final Integer scale) {
|
||||
this.scale = scale;
|
||||
return this;
|
||||
}
|
||||
|
@ -141,7 +141,7 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return unicode;
|
||||
}
|
||||
|
||||
public Property setUnicode(final boolean unicode) {
|
||||
public CsdlProperty setUnicode(final boolean unicode) {
|
||||
this.unicode = unicode;
|
||||
return this;
|
||||
}
|
||||
|
@ -150,26 +150,26 @@ public class Property extends AbstractEdmItem implements Named, Annotatable{
|
|||
return mimeType;
|
||||
}
|
||||
|
||||
public Property setMimeType(final String mimeType) {
|
||||
public CsdlProperty setMimeType(final String mimeType) {
|
||||
this.mimeType = mimeType;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Mapping getMapping() {
|
||||
public CsdlMapping getMapping() {
|
||||
return mapping;
|
||||
}
|
||||
|
||||
public Property setMapping(final Mapping mapping) {
|
||||
public CsdlProperty setMapping(final CsdlMapping mapping) {
|
||||
this.mapping = mapping;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
public Property setSrid(final SRID srid) {
|
||||
public CsdlProperty setSrid(final SRID srid) {
|
||||
this.srid = srid;
|
||||
return this;
|
||||
}
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
public class PropertyRef extends AbstractEdmItem implements Named{
|
||||
public class CsdlPropertyRef extends CsdlAbstractEdmItem implements CsdlNamed {
|
||||
|
||||
private static final long serialVersionUID = 9082892362895660037L;
|
||||
|
||||
|
@ -30,7 +30,7 @@ public class PropertyRef extends AbstractEdmItem implements Named{
|
|||
return name;
|
||||
}
|
||||
|
||||
public PropertyRef setName(final String name) {
|
||||
public CsdlPropertyRef setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -39,7 +39,7 @@ public class PropertyRef extends AbstractEdmItem implements Named{
|
|||
return alias;
|
||||
}
|
||||
|
||||
public PropertyRef setAlias(final String alias) {
|
||||
public CsdlPropertyRef setAlias(final String alias) {
|
||||
this.alias = alias;
|
||||
return this;
|
||||
}
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class ReferentialConstraint extends AbstractEdmItem implements Annotatable {
|
||||
public class CsdlReferentialConstraint extends CsdlAbstractEdmItem implements CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -7467707499798840075L;
|
||||
|
||||
|
@ -29,13 +29,13 @@ public class ReferentialConstraint extends AbstractEdmItem implements Annotatabl
|
|||
|
||||
private String referencedProperty;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getProperty() {
|
||||
return property;
|
||||
}
|
||||
|
||||
public ReferentialConstraint setProperty(final String property) {
|
||||
public CsdlReferentialConstraint setProperty(final String property) {
|
||||
this.property = property;
|
||||
return this;
|
||||
}
|
||||
|
@ -44,13 +44,13 @@ public class ReferentialConstraint extends AbstractEdmItem implements Annotatabl
|
|||
return referencedProperty;
|
||||
}
|
||||
|
||||
public ReferentialConstraint setReferencedProperty(final String referencedProperty) {
|
||||
public CsdlReferentialConstraint setReferencedProperty(final String referencedProperty) {
|
||||
this.referencedProperty = referencedProperty;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -21,7 +21,7 @@ package org.apache.olingo.commons.api.edm.provider;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
|
||||
public class ReturnType extends AbstractEdmItem{
|
||||
public class CsdlReturnType extends CsdlAbstractEdmItem {
|
||||
|
||||
private static final long serialVersionUID = 4816954124986010965L;
|
||||
|
||||
|
@ -48,12 +48,12 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return type;
|
||||
}
|
||||
|
||||
public ReturnType setType(final String type) {
|
||||
public CsdlReturnType setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
||||
public ReturnType setType(final FullQualifiedName type) {
|
||||
public CsdlReturnType setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return isCollection;
|
||||
}
|
||||
|
||||
public ReturnType setCollection(final boolean isCollection) {
|
||||
public CsdlReturnType setCollection(final boolean isCollection) {
|
||||
this.isCollection = isCollection;
|
||||
return this;
|
||||
}
|
||||
|
@ -71,7 +71,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return nullable;
|
||||
}
|
||||
|
||||
public ReturnType setNullable(final boolean nullable) {
|
||||
public CsdlReturnType setNullable(final boolean nullable) {
|
||||
this.nullable = nullable;
|
||||
return this;
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return maxLength;
|
||||
}
|
||||
|
||||
public ReturnType setMaxLength(final Integer maxLength) {
|
||||
public CsdlReturnType setMaxLength(final Integer maxLength) {
|
||||
this.maxLength = maxLength;
|
||||
return this;
|
||||
}
|
||||
|
@ -89,7 +89,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return precision;
|
||||
}
|
||||
|
||||
public ReturnType setPrecision(final Integer precision) {
|
||||
public CsdlReturnType setPrecision(final Integer precision) {
|
||||
this.precision = precision;
|
||||
return this;
|
||||
}
|
||||
|
@ -98,7 +98,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return scale;
|
||||
}
|
||||
|
||||
public ReturnType setScale(final Integer scale) {
|
||||
public CsdlReturnType setScale(final Integer scale) {
|
||||
this.scale = scale;
|
||||
return this;
|
||||
}
|
||||
|
@ -107,7 +107,7 @@ public class ReturnType extends AbstractEdmItem{
|
|||
return srid;
|
||||
}
|
||||
|
||||
public ReturnType setSrid(final SRID srid) {
|
||||
public CsdlReturnType setSrid(final SRID srid) {
|
||||
this.srid = srid;
|
||||
return this;
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public class Schema extends AbstractEdmItem implements Annotatable{
|
||||
public class CsdlSchema extends CsdlAbstractEdmItem implements CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = -1527213201328056750L;
|
||||
|
||||
|
@ -31,34 +31,34 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
|
||||
private String alias;
|
||||
|
||||
private List<EnumType> enumTypes = new ArrayList<EnumType>();
|
||||
private List<CsdlEnumType> enumTypes = new ArrayList<CsdlEnumType>();
|
||||
|
||||
private List<TypeDefinition> typeDefinitions = new ArrayList<TypeDefinition>();
|
||||
private List<CsdlTypeDefinition> typeDefinitions = new ArrayList<CsdlTypeDefinition>();
|
||||
|
||||
private List<EntityType> entityTypes = new ArrayList<EntityType>();
|
||||
private List<CsdlEntityType> entityTypes = new ArrayList<CsdlEntityType>();
|
||||
|
||||
private List<ComplexType> complexTypes = new ArrayList<ComplexType>();
|
||||
private List<CsdlComplexType> complexTypes = new ArrayList<CsdlComplexType>();
|
||||
|
||||
private List<Action> actions = new ArrayList<Action>();
|
||||
private List<CsdlAction> actions = new ArrayList<CsdlAction>();
|
||||
|
||||
private List<Function> functions = new ArrayList<Function>();
|
||||
private List<CsdlFunction> functions = new ArrayList<CsdlFunction>();
|
||||
|
||||
private EntityContainer entityContainer;
|
||||
private CsdlEntityContainer entityContainer;
|
||||
|
||||
private List<Term> terms = new ArrayList<Term>();
|
||||
private List<CsdlTerm> terms = new ArrayList<CsdlTerm>();
|
||||
|
||||
private final List<Annotations> annotationGroups = new ArrayList<Annotations>();
|
||||
private final List<CsdlAnnotations> annotationGroups = new ArrayList<CsdlAnnotations>();
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
private Map<String, Annotatable> annotatables;
|
||||
private Map<String, CsdlAnnotatable> annotatables;
|
||||
|
||||
|
||||
public String getNamespace() {
|
||||
return namespace;
|
||||
}
|
||||
|
||||
public Schema setNamespace(final String namespace) {
|
||||
public CsdlSchema setNamespace(final String namespace) {
|
||||
this.namespace = namespace;
|
||||
return this;
|
||||
}
|
||||
|
@ -67,64 +67,64 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
return alias;
|
||||
}
|
||||
|
||||
public Schema setAlias(final String alias) {
|
||||
public CsdlSchema setAlias(final String alias) {
|
||||
this.alias = alias;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<EnumType> getEnumTypes() {
|
||||
public List<CsdlEnumType> getEnumTypes() {
|
||||
return enumTypes;
|
||||
}
|
||||
|
||||
public EnumType getEnumType(final String name) {
|
||||
public CsdlEnumType getEnumType(final String name) {
|
||||
return getOneByName(name, getEnumTypes());
|
||||
}
|
||||
|
||||
public Schema setEnumTypes(final List<EnumType> enumTypes) {
|
||||
public CsdlSchema setEnumTypes(final List<CsdlEnumType> enumTypes) {
|
||||
this.enumTypes = enumTypes;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<TypeDefinition> getTypeDefinitions() {
|
||||
public List<CsdlTypeDefinition> getTypeDefinitions() {
|
||||
return typeDefinitions;
|
||||
}
|
||||
|
||||
public TypeDefinition getTypeDefinition(final String name) {
|
||||
public CsdlTypeDefinition getTypeDefinition(final String name) {
|
||||
return getOneByName(name, getTypeDefinitions());
|
||||
}
|
||||
|
||||
public Schema setTypeDefinitions(final List<TypeDefinition> typeDefinitions) {
|
||||
public CsdlSchema setTypeDefinitions(final List<CsdlTypeDefinition> typeDefinitions) {
|
||||
this.typeDefinitions = typeDefinitions;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<EntityType> getEntityTypes() {
|
||||
public List<CsdlEntityType> getEntityTypes() {
|
||||
return entityTypes;
|
||||
}
|
||||
|
||||
public EntityType getEntityType(final String name) {
|
||||
public CsdlEntityType getEntityType(final String name) {
|
||||
return getOneByName(name, getEntityTypes());
|
||||
}
|
||||
|
||||
public Schema setEntityTypes(final List<EntityType> entityTypes) {
|
||||
public CsdlSchema setEntityTypes(final List<CsdlEntityType> entityTypes) {
|
||||
this.entityTypes = entityTypes;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<ComplexType> getComplexTypes() {
|
||||
public List<CsdlComplexType> getComplexTypes() {
|
||||
return complexTypes;
|
||||
}
|
||||
|
||||
public ComplexType getComplexType(final String name) {
|
||||
public CsdlComplexType getComplexType(final String name) {
|
||||
return getOneByName(name, getComplexTypes());
|
||||
}
|
||||
|
||||
public Schema setComplexTypes(final List<ComplexType> complexTypes) {
|
||||
public CsdlSchema setComplexTypes(final List<CsdlComplexType> complexTypes) {
|
||||
this.complexTypes = complexTypes;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Action> getActions() {
|
||||
public List<CsdlAction> getActions() {
|
||||
return actions;
|
||||
}
|
||||
|
||||
|
@ -133,16 +133,16 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
* @param name
|
||||
* @return a list of actions
|
||||
*/
|
||||
public List<Action> getActions(final String name) {
|
||||
public List<CsdlAction> getActions(final String name) {
|
||||
return getAllByName(name, getActions());
|
||||
}
|
||||
|
||||
public Schema setActions(final List<Action> actions) {
|
||||
public CsdlSchema setActions(final List<CsdlAction> actions) {
|
||||
this.actions = actions;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Function> getFunctions() {
|
||||
public List<CsdlFunction> getFunctions() {
|
||||
return functions;
|
||||
}
|
||||
|
||||
|
@ -151,45 +151,45 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
* @param name
|
||||
* @return a list of functions
|
||||
*/
|
||||
public List<Function> getFunctions(final String name) {
|
||||
public List<CsdlFunction> getFunctions(final String name) {
|
||||
return getAllByName(name, getFunctions());
|
||||
}
|
||||
|
||||
public Schema setFunctions(final List<Function> functions) {
|
||||
public CsdlSchema setFunctions(final List<CsdlFunction> functions) {
|
||||
this.functions = functions;
|
||||
return this;
|
||||
}
|
||||
|
||||
public EntityContainer getEntityContainer() {
|
||||
public CsdlEntityContainer getEntityContainer() {
|
||||
return entityContainer;
|
||||
}
|
||||
|
||||
public Schema setEntityContainer(final EntityContainer entityContainer) {
|
||||
public CsdlSchema setEntityContainer(final CsdlEntityContainer entityContainer) {
|
||||
this.entityContainer = entityContainer;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Term> getTerms() {
|
||||
public List<CsdlTerm> getTerms() {
|
||||
return terms;
|
||||
}
|
||||
|
||||
public Term getTerm(final String name) {
|
||||
public CsdlTerm getTerm(final String name) {
|
||||
return getOneByName(name, getTerms());
|
||||
}
|
||||
|
||||
|
||||
public Schema setTerms(final List<Term> terms) {
|
||||
public CsdlSchema setTerms(final List<CsdlTerm> terms) {
|
||||
this.terms = terms;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Annotations> getAnnotationGroups() {
|
||||
public List<CsdlAnnotations> getAnnotationGroups() {
|
||||
return annotationGroups;
|
||||
}
|
||||
|
||||
public Annotations getAnnotationGroup(final String target) {
|
||||
Annotations result = null;
|
||||
for (Annotations annots : getAnnotationGroups()) {
|
||||
public CsdlAnnotations getAnnotationGroup(final String target) {
|
||||
CsdlAnnotations result = null;
|
||||
for (CsdlAnnotations annots : getAnnotationGroups()) {
|
||||
if (target.equals(annots.getTarget())) {
|
||||
result = annots;
|
||||
}
|
||||
|
@ -197,9 +197,9 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
return result;
|
||||
}
|
||||
|
||||
public Annotation getAnnotation(final String term) {
|
||||
Annotation result = null;
|
||||
for (Annotation annot : getAnnotations()) {
|
||||
public CsdlAnnotation getAnnotation(final String term) {
|
||||
CsdlAnnotation result = null;
|
||||
for (CsdlAnnotation annot : getAnnotations()) {
|
||||
if (term.equals(annot.getTerm())) {
|
||||
result = annot;
|
||||
}
|
||||
|
@ -207,55 +207,55 @@ public class Schema extends AbstractEdmItem implements Annotatable{
|
|||
return result;
|
||||
}
|
||||
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
public Map<String, Annotatable> getAnnotatables() {
|
||||
public Map<String, CsdlAnnotatable> getAnnotatables() {
|
||||
if (annotatables == null) {
|
||||
annotatables = new HashMap<String, Annotatable>();
|
||||
for (Annotations annotationGroup : getAnnotationGroups()) {
|
||||
annotatables = new HashMap<String, CsdlAnnotatable>();
|
||||
for (CsdlAnnotations annotationGroup : getAnnotationGroups()) {
|
||||
annotatables.put(null, annotationGroup);
|
||||
}
|
||||
for (Annotation annotation : getAnnotations()) {
|
||||
for (CsdlAnnotation annotation : getAnnotations()) {
|
||||
annotatables.put(annotation.getTerm(), annotation);
|
||||
}
|
||||
for (Action action : getActions()) {
|
||||
for (CsdlAction action : getActions()) {
|
||||
annotatables.put(action.getName(), action);
|
||||
}
|
||||
for (ComplexType complexType : getComplexTypes()) {
|
||||
for (CsdlComplexType complexType : getComplexTypes()) {
|
||||
annotatables.put(complexType.getName(), complexType);
|
||||
}
|
||||
for (EntityType entityType : getEntityTypes()) {
|
||||
for (CsdlEntityType entityType : getEntityTypes()) {
|
||||
annotatables.put(entityType.getName(), entityType);
|
||||
}
|
||||
for (EnumType enumType : getEnumTypes()) {
|
||||
for (CsdlEnumType enumType : getEnumTypes()) {
|
||||
annotatables.put(enumType.getName(), enumType);
|
||||
}
|
||||
for (Function function : getFunctions()) {
|
||||
for (CsdlFunction function : getFunctions()) {
|
||||
annotatables.put(function.getName(), function);
|
||||
}
|
||||
for (Term term : getTerms()) {
|
||||
for (CsdlTerm term : getTerms()) {
|
||||
annotatables.put(term.getName(), term);
|
||||
}
|
||||
for (TypeDefinition typedef : getTypeDefinitions()) {
|
||||
for (CsdlTypeDefinition typedef : getTypeDefinitions()) {
|
||||
annotatables.put(typedef.getName(), typedef);
|
||||
}
|
||||
if (entityContainer != null) {
|
||||
annotatables.put(entityContainer.getName(), entityContainer);
|
||||
for (Annotation annotation : entityContainer.getAnnotations()) {
|
||||
for (CsdlAnnotation annotation : entityContainer.getAnnotations()) {
|
||||
annotatables.put(annotation.getTerm(), annotation);
|
||||
}
|
||||
for (ActionImport actionImport : entityContainer.getActionImports()) {
|
||||
for (CsdlActionImport actionImport : entityContainer.getActionImports()) {
|
||||
annotatables.put(actionImport.getName(), actionImport);
|
||||
}
|
||||
for (FunctionImport functionImport : entityContainer.getFunctionImports()) {
|
||||
for (CsdlFunctionImport functionImport : entityContainer.getFunctionImports()) {
|
||||
annotatables.put(functionImport.getName(), functionImport);
|
||||
}
|
||||
for (EntitySet entitySet : entityContainer.getEntitySets()) {
|
||||
for (CsdlEntitySet entitySet : entityContainer.getEntitySets()) {
|
||||
annotatables.put(entitySet.getName(), entitySet);
|
||||
}
|
||||
for (Singleton singleton : entityContainer.getSingletons()) {
|
||||
for (CsdlSingleton singleton : entityContainer.getSingletons()) {
|
||||
annotatables.put(singleton.getName(), singleton);
|
||||
}
|
||||
}
|
|
@ -22,30 +22,31 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public class Singleton extends BindingTarget {
|
||||
public class CsdlSingleton extends CsdlBindingTarget {
|
||||
|
||||
private static final long serialVersionUID = -3997943079062565895L;
|
||||
|
||||
@Override
|
||||
public Singleton setName(final String name) {
|
||||
public CsdlSingleton setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Singleton setType(final String type) {
|
||||
public CsdlSingleton setType(final String type) {
|
||||
this.type = new FullQualifiedName(type);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Singleton setType(final FullQualifiedName type) {
|
||||
public CsdlSingleton setType(final FullQualifiedName type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Singleton setNavigationPropertyBindings(final List<NavigationPropertyBinding> navigationPropertyBindings) {
|
||||
public CsdlSingleton setNavigationPropertyBindings(
|
||||
final List<CsdlNavigationPropertyBinding> navigationPropertyBindings) {
|
||||
this.navigationPropertyBindings = navigationPropertyBindings;
|
||||
return this;
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public abstract class StructuralType extends AbstractEdmItem implements Named, Annotatable {
|
||||
public abstract class CsdlStructuralType extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 8662852373514258646L;
|
||||
|
||||
|
@ -35,17 +35,17 @@ public abstract class StructuralType extends AbstractEdmItem implements Named, A
|
|||
|
||||
protected boolean isAbstract;
|
||||
|
||||
protected List<Property> properties = new ArrayList<Property>();
|
||||
protected List<CsdlProperty> properties = new ArrayList<CsdlProperty>();
|
||||
|
||||
protected List<NavigationProperty> navigationProperties = new ArrayList<NavigationProperty>();
|
||||
protected List<CsdlNavigationProperty> navigationProperties = new ArrayList<CsdlNavigationProperty>();
|
||||
|
||||
protected final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
protected final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public StructuralType setName(final String name) {
|
||||
public CsdlStructuralType setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -54,7 +54,7 @@ public abstract class StructuralType extends AbstractEdmItem implements Named, A
|
|||
return isOpenType;
|
||||
}
|
||||
|
||||
public StructuralType setOpenType(final boolean isOpenType) {
|
||||
public CsdlStructuralType setOpenType(final boolean isOpenType) {
|
||||
this.isOpenType = isOpenType;
|
||||
return this;
|
||||
}
|
||||
|
@ -70,12 +70,12 @@ public abstract class StructuralType extends AbstractEdmItem implements Named, A
|
|||
return baseType;
|
||||
}
|
||||
|
||||
public StructuralType setBaseType(final String baseType) {
|
||||
public CsdlStructuralType setBaseType(final String baseType) {
|
||||
this.baseType = new FullQualifiedName(baseType);
|
||||
return this;
|
||||
}
|
||||
|
||||
public StructuralType setBaseType(final FullQualifiedName baseType) {
|
||||
public CsdlStructuralType setBaseType(final FullQualifiedName baseType) {
|
||||
this.baseType = baseType;
|
||||
return this;
|
||||
}
|
||||
|
@ -84,39 +84,39 @@ public abstract class StructuralType extends AbstractEdmItem implements Named, A
|
|||
return isAbstract;
|
||||
}
|
||||
|
||||
public StructuralType setAbstract(final boolean isAbstract) {
|
||||
public CsdlStructuralType setAbstract(final boolean isAbstract) {
|
||||
this.isAbstract = isAbstract;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Property> getProperties() {
|
||||
public List<CsdlProperty> getProperties() {
|
||||
return properties;
|
||||
}
|
||||
|
||||
public Property getProperty(String name) {
|
||||
public CsdlProperty getProperty(String name) {
|
||||
return getOneByName(name, properties);
|
||||
}
|
||||
|
||||
public StructuralType setProperties(final List<Property> properties) {
|
||||
public CsdlStructuralType setProperties(final List<CsdlProperty> properties) {
|
||||
this.properties = properties;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<NavigationProperty> getNavigationProperties() {
|
||||
public List<CsdlNavigationProperty> getNavigationProperties() {
|
||||
return navigationProperties;
|
||||
}
|
||||
|
||||
public NavigationProperty getNavigationProperty(String name) {
|
||||
public CsdlNavigationProperty getNavigationProperty(String name) {
|
||||
return getOneByName(name, navigationProperties);
|
||||
}
|
||||
|
||||
public StructuralType setNavigationProperties(final List<NavigationProperty> navigationProperties) {
|
||||
public CsdlStructuralType setNavigationProperties(final List<CsdlNavigationProperty> navigationProperties) {
|
||||
this.navigationProperties = navigationProperties;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -23,7 +23,7 @@ import java.util.List;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
|
||||
public class Term extends AbstractEdmItem implements Named, Annotatable{
|
||||
public class CsdlTerm extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 3843929000407818103L;
|
||||
|
||||
|
@ -50,13 +50,13 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
|
||||
private SRID srid;
|
||||
|
||||
private List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public Term setName(final String name) {
|
||||
public CsdlTerm setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return type;
|
||||
}
|
||||
|
||||
public Term setType(final String type) {
|
||||
public CsdlTerm setType(final String type) {
|
||||
this.type = type;
|
||||
return this;
|
||||
}
|
||||
|
@ -74,7 +74,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return baseTerm;
|
||||
}
|
||||
|
||||
public Term setBaseTerm(final String baseTerm) {
|
||||
public CsdlTerm setBaseTerm(final String baseTerm) {
|
||||
this.baseTerm = baseTerm;
|
||||
return this;
|
||||
}
|
||||
|
@ -83,7 +83,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return appliesTo;
|
||||
}
|
||||
|
||||
public Term setAppliesTo(final List<String> appliesTo) {
|
||||
public CsdlTerm setAppliesTo(final List<String> appliesTo) {
|
||||
this.appliesTo = appliesTo;
|
||||
return this;
|
||||
}
|
||||
|
@ -92,7 +92,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return isCollection;
|
||||
}
|
||||
|
||||
public Term setCollection(final boolean isCollection) {
|
||||
public CsdlTerm setCollection(final boolean isCollection) {
|
||||
this.isCollection = isCollection;
|
||||
return this;
|
||||
}
|
||||
|
@ -101,7 +101,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return defaultValue;
|
||||
}
|
||||
|
||||
public Term setDefaultValue(final String defaultValue) {
|
||||
public CsdlTerm setDefaultValue(final String defaultValue) {
|
||||
this.defaultValue = defaultValue;
|
||||
return this;
|
||||
}
|
||||
|
@ -110,7 +110,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return nullable;
|
||||
}
|
||||
|
||||
public Term setNullable(final boolean nullable) {
|
||||
public CsdlTerm setNullable(final boolean nullable) {
|
||||
this.nullable = nullable;
|
||||
return this;
|
||||
}
|
||||
|
@ -119,7 +119,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return maxLength;
|
||||
}
|
||||
|
||||
public Term setMaxLength(final Integer maxLength) {
|
||||
public CsdlTerm setMaxLength(final Integer maxLength) {
|
||||
this.maxLength = maxLength;
|
||||
return this;
|
||||
}
|
||||
|
@ -128,7 +128,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return precision;
|
||||
}
|
||||
|
||||
public Term setPrecision(final Integer precision) {
|
||||
public CsdlTerm setPrecision(final Integer precision) {
|
||||
this.precision = precision;
|
||||
return this;
|
||||
}
|
||||
|
@ -137,16 +137,16 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return scale;
|
||||
}
|
||||
|
||||
public Term setScale(final Integer scale) {
|
||||
public CsdlTerm setScale(final Integer scale) {
|
||||
this.scale = scale;
|
||||
return this;
|
||||
}
|
||||
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
|
||||
public Term setAnnotations(final List<Annotation> annotations) {
|
||||
public CsdlTerm setAnnotations(final List<CsdlAnnotation> annotations) {
|
||||
this.annotations = annotations;
|
||||
return this;
|
||||
}
|
||||
|
@ -155,7 +155,7 @@ public class Term extends AbstractEdmItem implements Named, Annotatable{
|
|||
return srid;
|
||||
}
|
||||
|
||||
public Term setSrid(final SRID srid) {
|
||||
public CsdlTerm setSrid(final SRID srid) {
|
||||
this.srid = srid;
|
||||
return this;
|
||||
}
|
|
@ -24,7 +24,7 @@ import java.util.List;
|
|||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
|
||||
public class TypeDefinition extends AbstractEdmItem implements Named, Annotatable {
|
||||
public class CsdlTypeDefinition extends CsdlAbstractEdmItem implements CsdlNamed, CsdlAnnotatable {
|
||||
|
||||
private static final long serialVersionUID = 3718980071229613048L;
|
||||
|
||||
|
@ -43,13 +43,13 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
|
||||
private SRID srid;
|
||||
|
||||
private final List<Annotation> annotations = new ArrayList<Annotation>();
|
||||
private final List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public TypeDefinition setName(final String name) {
|
||||
public CsdlTypeDefinition setName(final String name) {
|
||||
this.name = name;
|
||||
return this;
|
||||
}
|
||||
|
@ -61,12 +61,12 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return null;
|
||||
}
|
||||
|
||||
public TypeDefinition setUnderlyingType(final String underlyingType) {
|
||||
public CsdlTypeDefinition setUnderlyingType(final String underlyingType) {
|
||||
this.underlyingType = new FullQualifiedName(underlyingType);
|
||||
return this;
|
||||
}
|
||||
|
||||
public TypeDefinition setUnderlyingType(final FullQualifiedName underlyingType) {
|
||||
public CsdlTypeDefinition setUnderlyingType(final FullQualifiedName underlyingType) {
|
||||
this.underlyingType = underlyingType;
|
||||
return this;
|
||||
}
|
||||
|
@ -75,7 +75,7 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return maxLength;
|
||||
}
|
||||
|
||||
public TypeDefinition setMaxLength(final Integer maxLength) {
|
||||
public CsdlTypeDefinition setMaxLength(final Integer maxLength) {
|
||||
this.maxLength = maxLength;
|
||||
return this;
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return precision;
|
||||
}
|
||||
|
||||
public TypeDefinition setPrecision(final Integer precision) {
|
||||
public CsdlTypeDefinition setPrecision(final Integer precision) {
|
||||
this.precision = precision;
|
||||
return this;
|
||||
}
|
||||
|
@ -93,7 +93,7 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return scale;
|
||||
}
|
||||
|
||||
public TypeDefinition setScale(final Integer scale) {
|
||||
public CsdlTypeDefinition setScale(final Integer scale) {
|
||||
this.scale = scale;
|
||||
return this;
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return unicode;
|
||||
}
|
||||
|
||||
public TypeDefinition setUnicode(final boolean unicode) {
|
||||
public CsdlTypeDefinition setUnicode(final boolean unicode) {
|
||||
this.unicode = unicode;
|
||||
return this;
|
||||
}
|
||||
|
@ -111,13 +111,13 @@ public class TypeDefinition extends AbstractEdmItem implements Named, Annotatabl
|
|||
return srid;
|
||||
}
|
||||
|
||||
public TypeDefinition setSrid(final SRID srid) {
|
||||
public CsdlTypeDefinition setSrid(final SRID srid) {
|
||||
this.srid = srid;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Annotation> getAnnotations() {
|
||||
public List<CsdlAnnotation> getAnnotations() {
|
||||
return annotations;
|
||||
}
|
||||
}
|
|
@ -1,177 +0,0 @@
|
|||
/*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.ODataException;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
|
||||
public interface EdmProvider {
|
||||
|
||||
/**
|
||||
* This method should return an {@link EnumType} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param enumTypeName
|
||||
* @return {@link EnumType} for given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public EnumType getEnumType(final FullQualifiedName enumTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link TypeDefinition} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param typeDefinitionName
|
||||
* @return {@link TypeDefinition} for given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public TypeDefinition getTypeDefinition(final FullQualifiedName typeDefinitionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link EntityType} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityTypeName
|
||||
* @return {@link EntityType} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public EntityType getEntityType(final FullQualifiedName entityTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link ComplexType} or <b>null</b> if nothing is found.
|
||||
*
|
||||
* @param complexTypeName
|
||||
* @return {@link ComplexType} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public ComplexType getComplexType(final FullQualifiedName complexTypeName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all {@link Action} for the FullQualifiedname or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param actionName
|
||||
* @return List of {@link Action} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<Action> getActions(final FullQualifiedName actionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all {@link Function} for the FullQualifiedname or <b>null</b> if nothing is
|
||||
* found
|
||||
*
|
||||
* @param functionName
|
||||
* @return List of {@link Function} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<Function> getFunctions(final FullQualifiedName functionName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link Term} for the FullQualifiedName or <b>null</b> if nothing is found.
|
||||
* @param termName the name of the Term
|
||||
* @return {@link Term} or null
|
||||
* @throws ODataException
|
||||
*/
|
||||
public Term getTerm(final FullQualifiedName termName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link EntitySet} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this EntitySet is contained in
|
||||
* @param entitySetName
|
||||
* @return {@link EntitySet} for the given container and entityset name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public EntitySet getEntitySet(final FullQualifiedName entityContainer, final String entitySetName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link Singleton} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this Singleton is contained in
|
||||
* @param singletonName
|
||||
* @return {@link Singleton} for given container and singleton name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public Singleton getSingleton(final FullQualifiedName entityContainer, final String singletonName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link ActionImport} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this ActionImport is contained in
|
||||
* @param actionImportName
|
||||
* @return {@link ActionImport} for the given container and ActionImport name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public ActionImport getActionImport(final FullQualifiedName entityContainer, final String actionImportName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a {@link FunctionImport} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainer this FunctionImport is contained in
|
||||
* @param functionImportName
|
||||
* @return {@link FunctionImport} for the given container name and function import name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public FunctionImport getFunctionImport(final FullQualifiedName entityContainer, final String functionImportName)
|
||||
throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return an {@link EntityContainerInfo} or <b>null</b> if nothing is found
|
||||
*
|
||||
* @param entityContainerName (null for default container)
|
||||
* @return {@link EntityContainerInfo} for the given name
|
||||
* @throws ODataException
|
||||
*/
|
||||
public EntityContainerInfo getEntityContainerInfo(final FullQualifiedName entityContainerName) throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a list of all namespaces which have an alias
|
||||
*
|
||||
* @return List of alias info
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<AliasInfo> getAliasInfos() throws ODataException;
|
||||
|
||||
/**
|
||||
* This method should return a collection of all {@link Schema}
|
||||
*
|
||||
* @return List<{@link Schema}>
|
||||
* @throws ODataException
|
||||
*/
|
||||
public List<Schema> getSchemas() throws ODataException;
|
||||
|
||||
/**
|
||||
* Returns the entity container of this edm
|
||||
* @return {@link EntityContainer} of this edm
|
||||
*/
|
||||
public EntityContainer getEntityContainer() throws ODataException;
|
||||
|
||||
/**
|
||||
* @param targetName
|
||||
* @return {@link Annotations} group for the given Target
|
||||
*/
|
||||
public Annotations getAnnotationsGroup(FullQualifiedName targetName) throws ODataException;
|
||||
|
||||
/**
|
||||
* @param annotatedName
|
||||
* @return Annotatble element by target name
|
||||
*/
|
||||
public Annotatable getAnnoatatable(FullQualifiedName annotatedName) throws ODataException;
|
||||
}
|
|
@ -20,9 +20,9 @@ package org.apache.olingo.commons.api.edm.provider.annotation;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface Apply extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface Apply extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
String getFunction();
|
||||
|
||||
|
|
|
@ -19,9 +19,9 @@
|
|||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface Cast extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface Cast extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
Integer getMaxLength();
|
||||
|
||||
|
|
|
@ -18,9 +18,9 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface If extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface If extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
AnnotationExpression getGuard();
|
||||
|
||||
|
|
|
@ -19,9 +19,9 @@
|
|||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.geo.SRID;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface IsOf extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface IsOf extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
Integer getMaxLength();
|
||||
|
||||
|
|
|
@ -18,9 +18,9 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface LabeledElement extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface LabeledElement extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
String getName();
|
||||
|
||||
|
|
|
@ -18,8 +18,8 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface Null extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface Null extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
//No additional methods needed for now.
|
||||
}
|
||||
|
|
|
@ -18,9 +18,9 @@
|
|||
*/
|
||||
package org.apache.olingo.commons.api.edm.provider.annotation;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface PropertyValue extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface PropertyValue extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
String getProperty();
|
||||
|
||||
|
|
|
@ -20,9 +20,9 @@ package org.apache.olingo.commons.api.edm.provider.annotation;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public interface Record extends DynamicAnnotationExpression, Annotatable {
|
||||
public interface Record extends DynamicAnnotationExpression, CsdlAnnotatable {
|
||||
|
||||
List<PropertyValue> getPropertyValues();
|
||||
|
||||
|
|
|
@ -22,8 +22,8 @@ import org.apache.olingo.commons.api.edm.Edm;
|
|||
import org.apache.olingo.commons.api.edm.EdmAnnotatable;
|
||||
import org.apache.olingo.commons.api.edm.EdmAnnotation;
|
||||
import org.apache.olingo.commons.api.edm.EdmTerm;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
|
@ -31,11 +31,11 @@ import java.util.List;
|
|||
|
||||
public abstract class AbstractEdmAnnotatable implements EdmAnnotatable {
|
||||
|
||||
private final Annotatable annotatable;
|
||||
private final CsdlAnnotatable annotatable;
|
||||
private List<EdmAnnotation> annotations;
|
||||
protected final Edm edm;
|
||||
|
||||
public AbstractEdmAnnotatable(final Edm edm, final Annotatable annotatable) {
|
||||
public AbstractEdmAnnotatable(final Edm edm, final CsdlAnnotatable annotatable) {
|
||||
this.edm = edm;
|
||||
this.annotatable = annotatable;
|
||||
}
|
||||
|
@ -57,7 +57,7 @@ public abstract class AbstractEdmAnnotatable implements EdmAnnotatable {
|
|||
if (annotations == null) {
|
||||
final List<EdmAnnotation> annotationsLocal = new ArrayList<EdmAnnotation>();
|
||||
if (annotatable != null) {
|
||||
for (Annotation annotation : annotatable.getAnnotations()) {
|
||||
for (CsdlAnnotation annotation : annotatable.getAnnotations()) {
|
||||
annotationsLocal.add(new EdmAnnotationImpl(edm, annotation));
|
||||
}
|
||||
|
||||
|
|
|
@ -30,17 +30,17 @@ import org.apache.olingo.commons.api.edm.EdmEntityType;
|
|||
import org.apache.olingo.commons.api.edm.EdmException;
|
||||
import org.apache.olingo.commons.api.edm.EdmNavigationPropertyBinding;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.provider.BindingTarget;
|
||||
import org.apache.olingo.commons.api.edm.provider.NavigationPropertyBinding;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlBindingTarget;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlNavigationPropertyBinding;
|
||||
|
||||
public abstract class AbstractEdmBindingTarget extends AbstractEdmNamed implements EdmBindingTarget {
|
||||
|
||||
private final BindingTarget target;
|
||||
private final CsdlBindingTarget target;
|
||||
private final EdmEntityContainer container;
|
||||
|
||||
private List<EdmNavigationPropertyBinding> navigationPropertyBindings;
|
||||
|
||||
public AbstractEdmBindingTarget(final Edm edm, final EdmEntityContainer container, final BindingTarget target) {
|
||||
public AbstractEdmBindingTarget(final Edm edm, final EdmEntityContainer container, final CsdlBindingTarget target) {
|
||||
super(edm, target.getName(), target);
|
||||
this.container = container;
|
||||
this.target = target;
|
||||
|
@ -49,11 +49,11 @@ public abstract class AbstractEdmBindingTarget extends AbstractEdmNamed implemen
|
|||
@Override
|
||||
public List<EdmNavigationPropertyBinding> getNavigationPropertyBindings() {
|
||||
if (navigationPropertyBindings == null) {
|
||||
List<NavigationPropertyBinding> providerBindings = target.getNavigationPropertyBindings();
|
||||
List<CsdlNavigationPropertyBinding> providerBindings = target.getNavigationPropertyBindings();
|
||||
final List<EdmNavigationPropertyBinding> navigationPropertyBindingsLocal =
|
||||
new ArrayList<EdmNavigationPropertyBinding>();
|
||||
if (providerBindings != null) {
|
||||
for (NavigationPropertyBinding binding : providerBindings) {
|
||||
for (CsdlNavigationPropertyBinding binding : providerBindings) {
|
||||
navigationPropertyBindingsLocal.add(new EdmNavigationPropertyBindingImpl(binding.getPath(),
|
||||
binding.getTarget()));
|
||||
}
|
||||
|
|
|
@ -20,13 +20,13 @@ package org.apache.olingo.commons.core.edm;
|
|||
|
||||
import org.apache.olingo.commons.api.edm.Edm;
|
||||
import org.apache.olingo.commons.api.edm.EdmNamed;
|
||||
import org.apache.olingo.commons.api.edm.provider.Annotatable;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
|
||||
|
||||
public abstract class AbstractEdmNamed extends AbstractEdmAnnotatable implements EdmNamed {
|
||||
|
||||
private final String name;
|
||||
|
||||
public AbstractEdmNamed(final Edm edm, final String name, final Annotatable annotatable) {
|
||||
public AbstractEdmNamed(final Edm edm, final String name, final CsdlAnnotatable annotatable) {
|
||||
super(edm, annotatable);
|
||||
this.name = name;
|
||||
}
|
||||
|
|
|
@ -33,17 +33,17 @@ import org.apache.olingo.commons.api.edm.EdmParameter;
|
|||
import org.apache.olingo.commons.api.edm.EdmReturnType;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.constants.EdmTypeKind;
|
||||
import org.apache.olingo.commons.api.edm.provider.Operation;
|
||||
import org.apache.olingo.commons.api.edm.provider.Parameter;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlOperation;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlParameter;
|
||||
|
||||
public abstract class AbstractEdmOperation extends EdmTypeImpl implements EdmOperation {
|
||||
|
||||
private final Operation operation;
|
||||
private final CsdlOperation operation;
|
||||
private Map<String, EdmParameter> parameters;
|
||||
private List<String> parameterNames;
|
||||
private EdmReturnType returnType;
|
||||
|
||||
protected AbstractEdmOperation(final Edm edm, final FullQualifiedName name, final Operation operation,
|
||||
protected AbstractEdmOperation(final Edm edm, final FullQualifiedName name, final CsdlOperation operation,
|
||||
final EdmTypeKind kind) {
|
||||
|
||||
super(edm, name, kind, operation);
|
||||
|
@ -69,10 +69,10 @@ public abstract class AbstractEdmOperation extends EdmTypeImpl implements EdmOpe
|
|||
private void createParameters() {
|
||||
if(parameters == null) {
|
||||
final Map<String, EdmParameter> parametersLocal = new LinkedHashMap<String, EdmParameter>();
|
||||
final List<Parameter> providerParameters = operation.getParameters();
|
||||
final List<CsdlParameter> providerParameters = operation.getParameters();
|
||||
if (providerParameters != null) {
|
||||
final List<String> parameterNamesLocal = new ArrayList<String>(providerParameters.size());
|
||||
for (Parameter parameter : providerParameters) {
|
||||
for (CsdlParameter parameter : providerParameters) {
|
||||
parametersLocal.put(parameter.getName(), new EdmParameterImpl(edm, parameter));
|
||||
parameterNamesLocal.add(parameter.getName());
|
||||
}
|
||||
|
@ -120,7 +120,7 @@ public abstract class AbstractEdmOperation extends EdmTypeImpl implements EdmOpe
|
|||
@Override
|
||||
public FullQualifiedName getBindingParameterTypeFqn() {
|
||||
if (isBound()) {
|
||||
Parameter bindingParameter = operation.getParameters().get(0);
|
||||
CsdlParameter bindingParameter = operation.getParameters().get(0);
|
||||
return bindingParameter.getTypeFQN();
|
||||
}
|
||||
return null;
|
||||
|
@ -129,7 +129,7 @@ public abstract class AbstractEdmOperation extends EdmTypeImpl implements EdmOpe
|
|||
@Override
|
||||
public Boolean isBindingParameterTypeCollection() {
|
||||
if (isBound()) {
|
||||
Parameter bindingParameter = operation.getParameters().get(0);
|
||||
CsdlParameter bindingParameter = operation.getParameters().get(0);
|
||||
return bindingParameter.isCollection();
|
||||
}
|
||||
return null;
|
||||
|
|
|
@ -24,7 +24,7 @@ import org.apache.olingo.commons.api.edm.EdmEntitySet;
|
|||
import org.apache.olingo.commons.api.edm.EdmException;
|
||||
import org.apache.olingo.commons.api.edm.EdmOperationImport;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.provider.OperationImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlOperationImport;
|
||||
|
||||
public abstract class AbstractEdmOperationImport extends AbstractEdmNamed implements EdmOperationImport {
|
||||
|
||||
|
@ -33,7 +33,7 @@ public abstract class AbstractEdmOperationImport extends AbstractEdmNamed implem
|
|||
private EdmEntitySet returnedEntitySet;
|
||||
|
||||
public AbstractEdmOperationImport(final Edm edm, final EdmEntityContainer container,
|
||||
final OperationImport operationImport) {
|
||||
final CsdlOperationImport operationImport) {
|
||||
super(edm, operationImport.getName(), operationImport);
|
||||
this.container = container;
|
||||
if (operationImport.getEntitySet() != null) {
|
||||
|
|
|
@ -27,9 +27,9 @@ import org.apache.olingo.commons.api.edm.EdmStructuredType;
|
|||
import org.apache.olingo.commons.api.edm.EdmType;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.constants.EdmTypeKind;
|
||||
import org.apache.olingo.commons.api.edm.provider.NavigationProperty;
|
||||
import org.apache.olingo.commons.api.edm.provider.Property;
|
||||
import org.apache.olingo.commons.api.edm.provider.StructuralType;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlNavigationProperty;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlProperty;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlStructuralType;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
|
@ -42,7 +42,7 @@ public abstract class AbstractEdmStructuredType extends EdmTypeImpl implements E
|
|||
protected EdmStructuredType baseType;
|
||||
protected FullQualifiedName baseTypeName;
|
||||
|
||||
private final StructuralType providerStructuredType;
|
||||
private final CsdlStructuralType providerStructuredType;
|
||||
|
||||
private List<String> propertyNames;
|
||||
private Map<String, EdmProperty> properties;
|
||||
|
@ -53,7 +53,7 @@ public abstract class AbstractEdmStructuredType extends EdmTypeImpl implements E
|
|||
final Edm edm,
|
||||
final FullQualifiedName typeName,
|
||||
final EdmTypeKind kind,
|
||||
final StructuralType structuredType) {
|
||||
final CsdlStructuralType structuredType) {
|
||||
|
||||
super(edm, typeName, kind, structuredType);
|
||||
this.baseTypeName = structuredType.getBaseTypeFQN();
|
||||
|
@ -158,8 +158,8 @@ public abstract class AbstractEdmStructuredType extends EdmTypeImpl implements E
|
|||
public Map<String, EdmProperty> getProperties() {
|
||||
if (properties == null) {
|
||||
final Map<String, EdmProperty> localPorperties = new LinkedHashMap<String, EdmProperty>();
|
||||
final List<Property> structureTypeProperties = providerStructuredType.getProperties();
|
||||
for (Property property : structureTypeProperties) {
|
||||
final List<CsdlProperty> structureTypeProperties = providerStructuredType.getProperties();
|
||||
for (CsdlProperty property : structureTypeProperties) {
|
||||
localPorperties.put(property.getName(), new EdmPropertyImpl(edm, typeName, property));
|
||||
}
|
||||
properties = Collections.unmodifiableMap(localPorperties);
|
||||
|
@ -171,11 +171,11 @@ public abstract class AbstractEdmStructuredType extends EdmTypeImpl implements E
|
|||
if (navigationProperties == null) {
|
||||
final Map<String, EdmNavigationProperty> localNavigationProperties =
|
||||
new LinkedHashMap<String, EdmNavigationProperty>();
|
||||
final List<NavigationProperty> structuredTypeNavigationProperties =
|
||||
final List<CsdlNavigationProperty> structuredTypeNavigationProperties =
|
||||
providerStructuredType.getNavigationProperties();
|
||||
|
||||
if (structuredTypeNavigationProperties != null) {
|
||||
for (NavigationProperty navigationProperty : structuredTypeNavigationProperties) {
|
||||
for (CsdlNavigationProperty navigationProperty : structuredTypeNavigationProperties) {
|
||||
localNavigationProperties.put(navigationProperty.getName(),
|
||||
new EdmNavigationPropertyImpl(edm, typeName, navigationProperty));
|
||||
}
|
||||
|
|
|
@ -22,11 +22,11 @@ import org.apache.olingo.commons.api.edm.Edm;
|
|||
import org.apache.olingo.commons.api.edm.EdmAction;
|
||||
import org.apache.olingo.commons.api.edm.FullQualifiedName;
|
||||
import org.apache.olingo.commons.api.edm.constants.EdmTypeKind;
|
||||
import org.apache.olingo.commons.api.edm.provider.Action;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlAction;
|
||||
|
||||
public class EdmActionImpl extends AbstractEdmOperation implements EdmAction {
|
||||
|
||||
public EdmActionImpl(final Edm edm, final FullQualifiedName name, final Action action) {
|
||||
public EdmActionImpl(final Edm edm, final FullQualifiedName name, final CsdlAction action) {
|
||||
super(edm, name, action, EdmTypeKind.ACTION);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,13 +22,13 @@ import org.apache.olingo.commons.api.edm.Edm;
|
|||
import org.apache.olingo.commons.api.edm.EdmAction;
|
||||
import org.apache.olingo.commons.api.edm.EdmActionImport;
|
||||
import org.apache.olingo.commons.api.edm.EdmEntityContainer;
|
||||
import org.apache.olingo.commons.api.edm.provider.ActionImport;
|
||||
import org.apache.olingo.commons.api.edm.provider.CsdlActionImport;
|
||||
|
||||
public class EdmActionImportImpl extends AbstractEdmOperationImport implements EdmActionImport {
|
||||
|
||||
private final ActionImport actionImport;
|
||||
private final CsdlActionImport actionImport;
|
||||
|
||||
public EdmActionImportImpl(final Edm edm, final EdmEntityContainer container, final ActionImport actionImport) {
|
||||
public EdmActionImportImpl(final Edm edm, final EdmEntityContainer container, final CsdlActionImport actionImport) {
|
||||
|
||||
super(edm, container, actionImport);
|
||||
this.actionImport = actionImport;
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue