You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@olingo.apache.org by ch...@apache.org on 2015/10/16 14:14:07 UTC

[2/4] olingo-odata4 git commit: [OLINGO-786] Make annotaion csdl classes spec compliant`

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlExpression.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlExpression.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlExpression.java
new file mode 100644
index 0000000..6c9e88c
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlExpression.java
@@ -0,0 +1,58 @@
+/*
+ * 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.annotation;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAbstractEdmItem;
+
+public abstract class CsdlExpression extends CsdlAbstractEdmItem {
+
+  private static final long serialVersionUID = 4731101778893577444L;
+
+  /**
+   * Return true if the expression is constant
+   * @return true if the expression is constant
+   */
+  public boolean isConstant() {
+    return this instanceof CsdlConstantExpression;
+  }
+
+  /**
+   * Casts the expression to {@link org.apache.olingo.commons.api.edm.annotation.CsdlConstantExpression}
+   * @return Constant Expression
+   */
+  public CsdlConstantExpression asConstant() {
+    return isConstant() ? (CsdlConstantExpression) this : null;
+  }
+
+  /**
+   * Return true if the expression is dynamic
+   * @return true if the expression is dynamic
+   */
+  public boolean isDynamic() {
+    return this instanceof CsdlDynamicExpression;
+  }
+
+  /**
+   * Cast the expression to {@link org.apache.olingo.commons.api.edm.annotation.CsdlDynamicExpression}
+   * @return Dynamic Expression
+   */
+  public CsdlDynamicExpression asDynamic() {
+    return isDynamic() ? (CsdlDynamicExpression) this : null;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIf.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIf.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIf.java
new file mode 100644
index 0000000..b010fb7
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIf.java
@@ -0,0 +1,95 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * Represents a edm:If expression
+ */
+public class CsdlIf extends CsdlDynamicExpression implements CsdlAnnotatable {
+
+  private static final long serialVersionUID = -8571383625077590656L;
+
+  private CsdlExpression guard;
+  private CsdlExpression _then;
+  private CsdlExpression _else;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+  
+  public CsdlIf setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+
+  /**
+   * Returns the first expression of the edm:If expression.
+   * This expression represents the condition of the if expression
+   *
+   * @return First expression of the if expression
+   */
+  public CsdlExpression getGuard() {
+    return guard;
+  }
+
+  public CsdlIf setGuard(final CsdlExpression guard) {
+    this.guard = guard;
+    return this;
+  }
+
+  /**
+   * Return the second expression of the edm:If expression.
+   * If the condition of the condition is evaluated to true,
+   * this expression as to be executed.
+   *
+   * @return Second Expression of the edm:If expression
+   */
+  public CsdlExpression getThen() {
+    return _then;
+  }
+
+  public CsdlIf setThen(final CsdlExpression _then) {
+    this._then = _then;
+    return this;
+  }
+
+  /**
+   * Return the third expression of the edm:If expression.
+   * If the condition of the condition is evaluated to false,
+   * this expression as to be executed.
+   *
+   * @return Third Expression of the edm:If expression
+   */
+  public CsdlExpression getElse() {
+    return _else;
+  }
+
+  public CsdlIf setElse(final CsdlExpression _else) {
+    this._else = _else;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIsOf.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIsOf.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIsOf.java
new file mode 100644
index 0000000..4236e1a
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlIsOf.java
@@ -0,0 +1,131 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.geo.SRID;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * The edm:IsOf expression evaluates a child expression and returns a Boolean value indicating whether
+ * the child expression returns the specified type
+ */
+public class CsdlIsOf extends CsdlDynamicExpression implements CsdlAnnotatable {
+
+  private static final long serialVersionUID = -893355856129761174L;
+
+  private String type;
+  private Integer maxLength;
+  private Integer precision;
+  private Integer scale;
+  private SRID srid;
+  private CsdlExpression value;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+  
+  public CsdlIsOf setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+  /**
+   * The type which is checked again the child expression
+   * @return EdmType type
+   */
+  public String getType() {
+    return type;
+  }
+
+  public CsdlIsOf setType(final String type) {
+    this.type = type;
+    return this;
+  }
+
+  /**
+   * Facet MaxLength
+   * @return fact MaxLength
+   */
+  public Integer getMaxLength() {
+    return maxLength;
+  }
+
+  public CsdlIsOf setMaxLength(final Integer maxLength) {
+    this.maxLength = maxLength;
+    return this;
+  }
+
+  /**
+   * Facet Precision
+   * @return fact Precision
+   */
+  public Integer getPrecision() {
+    return precision;
+  }
+
+  public CsdlIsOf setPrecision(final Integer precision) {
+    this.precision = precision;
+return this;
+  }
+
+  /**
+   * Facet Scale
+   * @return facet Scale
+   */
+  public Integer getScale() {
+    return scale;
+  }
+
+  public CsdlIsOf setScale(final Integer scale) {
+    this.scale = scale;
+    return this;
+  }
+
+  /**
+   * Facet SRID
+   * @return facet SRID
+   */
+  public SRID getSrid() {
+    return srid;
+  }
+
+  public CsdlIsOf setSrid(final SRID srid) {
+    this.srid = srid;
+    return this;
+  }
+
+  /**
+   * Returns the child expression
+   * @return Returns the child expression
+   */
+  public CsdlExpression getValue() {
+    return value;
+  }
+
+  public CsdlIsOf setValue(final CsdlExpression value) {
+    this.value = value;
+    return this;
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElement.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElement.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElement.java
new file mode 100644
index 0000000..dfbd09e
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElement.java
@@ -0,0 +1,74 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * The edm:LabeledElement expression assigns a name to a child expression. The value of the child expression can
+ * then be reused elsewhere with an edm:LabeledElementReference (See {@link CsdlLabeledElementReference}) expression.
+ */
+public class CsdlLabeledElement extends CsdlDynamicExpression implements CsdlAnnotatable{
+
+  private static final long serialVersionUID = -5885321101447070204L;
+
+  private String name;
+  private CsdlExpression value;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+  
+  public CsdlLabeledElement setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+  
+  /**
+   * Returns the assigned name
+   * @return assigned name
+   */
+  public String getName() {
+    return name;
+  }
+
+  public CsdlLabeledElement setName(final String name) {
+    this.name = name;
+    return this;
+  }
+
+  /**
+   * Returns the child expression
+   *
+   * @return child expression
+   */
+  public CsdlExpression getValue() {
+    return value;
+  }
+
+  public CsdlLabeledElement setValue(final CsdlExpression value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElementReference.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElementReference.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElementReference.java
new file mode 100644
index 0000000..a309c49
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLabeledElementReference.java
@@ -0,0 +1,42 @@
+/*
+ * 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.annotation;
+
+/**
+ * The edm:LabeledElementReference expression returns the value of an
+ * edm:LabeledElement (see {@link LabeledElement}) expression.
+ */
+public class CsdlLabeledElementReference extends CsdlDynamicExpression {
+  private static final long serialVersionUID = -4793707024628773226L;
+
+  private String value;
+
+  /**
+   * Returns the value of the edm:LabeledElement expression
+   * @return value of the edm:LabeledElement expression
+   */
+  public String getValue() {
+    return value;
+  }
+
+  public CsdlLabeledElementReference setValue(final String value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLogicalOrComparisonExpression.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLogicalOrComparisonExpression.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLogicalOrComparisonExpression.java
new file mode 100644
index 0000000..3fcf6a2
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlLogicalOrComparisonExpression.java
@@ -0,0 +1,150 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+public class CsdlLogicalOrComparisonExpression extends CsdlDynamicExpression implements CsdlAnnotatable {
+
+  private static final long serialVersionUID = -8268617065621508270L;
+
+  private final LogicalOrComparisonExpressionType type;
+  private CsdlExpression left;
+  private CsdlExpression right;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  public CsdlLogicalOrComparisonExpression(LogicalOrComparisonExpressionType type) {
+    this.type = type;
+  }
+
+  /**
+   * Type of the constant expression
+   */
+  public enum LogicalOrComparisonExpressionType {
+    // Logical Operators
+    /**
+     * Type Edm.And must have two operands which must evaluate to a boolean value
+     */
+    And,
+    /**
+     * Type Edm.Or must have two operands which must evaluate to a boolean value
+     */
+    Or,
+    /**
+     * Type Edm.Or must have one operand
+     */
+    Not,
+
+    // Comparison Operators
+    /**
+     * Type Edm.Eq must have two operands which must evaluate to a boolean value
+     */
+    Eq,
+    /**
+     * Type Edm.Ne must have two operands which must evaluate to a boolean value
+     */
+    Ne,
+    /**
+     * Type Edm.Gt must have two operands which must evaluate to a boolean value
+     */
+    Gt,
+    /**
+     * Type Edm.Ge must have two operands which must evaluate to a boolean value
+     */
+    Ge,
+    /**
+     * Type Edm.Lt must have two operands which must evaluate to a boolean value
+     */
+    Lt,
+    /**
+     * Type Edm.Le must have two operands which must evaluate to a boolean value
+     */
+    Le;
+
+    /**
+     * Creates a new type by a given string e.g. "And".
+     * Will NOT throw an IlligalArgumentException for invalid types. If needed use the valueOf method.
+     * @param value Type as string
+     * @return Type type
+     */
+    public static LogicalOrComparisonExpressionType fromString(final String value) {
+      LogicalOrComparisonExpressionType result = null;
+      try {
+        result = valueOf(value);
+      } catch (IllegalArgumentException e) {
+        // ignore
+      }
+      return result;
+    }
+  }
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+
+  public CsdlLogicalOrComparisonExpression setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+
+  /**
+   * Returns the type of the logical expression
+   * @return type of the logical expression
+   */
+  public LogicalOrComparisonExpressionType getType() {
+    return type;
+  }
+
+  /**
+   * The left expression. In case this is of type Edm.Not the left expression will be the same as the right expression.
+   * @return The left expression.
+   */
+  public CsdlExpression getLeft() {
+    return left;
+  }
+
+  public CsdlLogicalOrComparisonExpression setLeft(CsdlExpression left) {
+    this.left = left;
+    if (getType() == LogicalOrComparisonExpressionType.Not) {
+      this.right = left;
+    }
+    return this;
+  }
+
+  /**
+   * The right expression. In case this is of type Edm.Not the left expression will be the same as the right expression.
+   * @return The right expression.
+   */
+  public CsdlExpression getRight() {
+    return right;
+  }
+
+  public CsdlLogicalOrComparisonExpression setRight(CsdlExpression right) {
+    this.right = right;
+    if (getType() == LogicalOrComparisonExpressionType.Not) {
+      this.left = right;
+    }
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNavigationPropertyPath.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNavigationPropertyPath.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNavigationPropertyPath.java
new file mode 100644
index 0000000..a5ee684
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNavigationPropertyPath.java
@@ -0,0 +1,43 @@
+/*
+ * 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.annotation;
+
+/**
+ * The edm:NavigationPropertyPath expression provides a value for terms or term properties that specify the
+ * built-in abstract type Edm.NavigationPropertyPath
+ */
+public class CsdlNavigationPropertyPath extends CsdlDynamicExpression {
+  private static final long serialVersionUID = -8047231485537503181L;
+  
+  private String value;
+
+  /**
+   * Returns the navigation property path itself.
+   *
+   * @return navigation property
+   */
+  public String getValue() {
+    return value;
+  }
+
+  public CsdlNavigationPropertyPath setValue(final String value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNull.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNull.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNull.java
new file mode 100644
index 0000000..5350f2e
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlNull.java
@@ -0,0 +1,45 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * The edm:Null expression returns an untyped null value.
+ */
+public class CsdlNull extends CsdlDynamicExpression implements CsdlAnnotatable {
+
+  private static final long serialVersionUID = 3696395405429914435L;
+
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+
+  public CsdlNull setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPath.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPath.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPath.java
new file mode 100644
index 0000000..244aa72
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPath.java
@@ -0,0 +1,44 @@
+/*
+ * 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.annotation;
+
+/**
+ *  The edm:Path expression enables a value to be obtained by traversing an object graph. 
+ *  It can be used in annotations that target entity containers, entity sets, entity types, complex types, 
+ *  navigation properties of structured types, and properties of structured types.
+ */
+public class CsdlPath extends CsdlDynamicExpression {
+  private static final long serialVersionUID = 6458406537881061846L;
+  
+  private String value;
+
+  /**
+   * Returns the target value of the expression
+   *
+   * @return target value of the expression
+   */
+  public String getValue() {
+    return value;
+  }
+
+  public CsdlPath setValue(final String value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyPath.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyPath.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyPath.java
new file mode 100644
index 0000000..9a8689b
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyPath.java
@@ -0,0 +1,42 @@
+/*
+ * 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.annotation;
+
+/**
+ * The edm:PropertyPath expression provides a value for terms or term properties that specify the built-in
+ * abstract type Edm.PropertyPath.
+ */
+public class CsdlPropertyPath extends CsdlDynamicExpression {
+  private static final long serialVersionUID = -8182384289259575448L;
+
+  private String value;
+
+  /**
+   * Returns the property path itself.
+   * @return the property path itself
+   */
+  public String getValue() {
+    return value;
+  }
+
+  public CsdlPropertyPath setValue(final String value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyValue.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyValue.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyValue.java
new file mode 100644
index 0000000..2be2891
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlPropertyValue.java
@@ -0,0 +1,76 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+
+/**
+ * The edm:PropertyValue element supplies a value to a property on the type instantiated by an 
+ * edm:Record expression (See {@link org.apache.olingo.commons.api.edm.annotation.EdmRecord}). 
+ * The value is obtained by evaluating an expression.
+ */
+public class CsdlPropertyValue extends CsdlDynamicExpression implements CsdlAnnotatable{
+
+  private static final long serialVersionUID = -6671376680245613990L;
+
+  private String property;
+  private CsdlExpression value;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+  
+  public CsdlPropertyValue setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+  
+  /**
+   * Property name
+   * @return Property name
+   */
+  public String getProperty() {
+    return property;
+  }
+
+  public CsdlPropertyValue setProperty(final String property) {
+    this.property = property;
+    return this;
+  }
+
+  /**
+   * Evaluated value of the expression (property value)
+   * @return evaluated value of the expression
+   */
+  public CsdlExpression getValue() {
+    return value;
+  }
+
+  public CsdlPropertyValue setValue(final CsdlExpression value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlRecord.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlRecord.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlRecord.java
new file mode 100644
index 0000000..da9271d
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlRecord.java
@@ -0,0 +1,73 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * The edm:Record expression enables a new entity type or complex type instance to be constructed.
+ * A record expression contains zero or more edm:PropertyValue (See {@link CsdlRecord} )elements.
+ */
+public class CsdlRecord extends CsdlDynamicExpression implements CsdlAnnotatable {
+
+  private static final long serialVersionUID = 8557849619469577884L;
+  private String type;
+  private List<CsdlPropertyValue> propertyValues = new ArrayList<CsdlPropertyValue>();
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+
+  public CsdlRecord setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+
+  /**
+   * Returns the entity type or complex type to be constructed.
+   * @return Entity type or complex type
+   */
+  public String getType() {
+    return type;
+  }
+
+  public CsdlRecord setType(final String type) {
+    this.type = type;
+    return this;
+  }
+
+  /**
+   * List of edm:PropertyValues (See {@link CsdlPropertyValue}
+   * @return List of edm:PropertyValues (See
+   */
+  public List<CsdlPropertyValue> getPropertyValues() {
+    return propertyValues;
+  }
+
+  public CsdlRecord setPropertyValues(List<CsdlPropertyValue> propertyValues) {
+    this.propertyValues = propertyValues;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlUrlRef.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlUrlRef.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlUrlRef.java
new file mode 100644
index 0000000..1d2dc7b
--- /dev/null
+++ b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/CsdlUrlRef.java
@@ -0,0 +1,59 @@
+/*
+ * 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.annotation;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
+import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
+
+/**
+ * The edm:UrlRef expression enables a value to be obtained by sending a GET request to the value of
+ * the UrlRef expression.
+ */
+public class CsdlUrlRef extends CsdlDynamicExpression implements CsdlAnnotatable{
+
+  private static final long serialVersionUID = 3781479172952387841L;
+  private CsdlExpression value;
+  private List<CsdlAnnotation> annotations = new ArrayList<CsdlAnnotation>();
+
+  @Override
+  public List<CsdlAnnotation> getAnnotations() {
+    return annotations;
+  }
+  
+  public CsdlUrlRef setAnnotations(List<CsdlAnnotation> annotations) {
+    this.annotations = annotations;
+    return this;
+  }
+
+  /**
+   * Returns a expression of type Edm.String
+   * @return expression of type Edm.String
+   */
+  public CsdlExpression getValue() {
+    return value;
+  }
+
+  public CsdlUrlRef setValue(final CsdlExpression value) {
+    this.value = value;
+    return this;
+  }
+}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/DynamicAnnotationExpression.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/DynamicAnnotationExpression.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/DynamicAnnotationExpression.java
deleted file mode 100644
index f209c7a..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/DynamicAnnotationExpression.java
+++ /dev/null
@@ -1,241 +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.annotation;
-
-/**
- * Represents a dynamic expression
- */
-public interface DynamicAnnotationExpression extends AnnotationExpression {
-
-  /**
-   * Returns true if the expression is a logical edm:Not expression
-   * @return true if the expression is a logical edm:Not expression
-   */
-  boolean isNot();
-
-  /**
-   * Casts the expression to a {@link Not} expression
-   * @return Not expression
-   */
-  Not asNot();
-
-  /**
-   * Returns true iff the annotation is an expression with two operands.
-   * If so, the expression is one of:
-   * <ul>
-   *  <li>And</li>
-   *  <li>Or</li>
-   *  <li>Eq</li>
-   *  <li>Ne</li>
-   *  <li>Gt</li>
-   *  <li>Ge</li>
-   *  <li>Lt</li>
-   *  <li>Le</li>
-   *
-   * @return true iff the annotation is an expression with two operands.
-   */
-  boolean isTwoParamsOp();
-
-  /**
-   * Casts the expression as {@link TwoParamsOpDynamicAnnotationExpression}
-   * @return TwoParamsOpDynamicAnnotationExpression two params op dynamic annotation expression
-   */
-  TwoParamsOpDynamicAnnotationExpression asTwoParamsOp();
-
-  /**
-   * Returns true if the expression is a edm:AnnotationPath expression
-   * @return true if the expression is a edm:AnnotationPath expression
-   */
-  boolean isAnnotationPath();
-
-  /**
-   * Casts the expression to a {@link AnnotationPath} expression
-   * @return AnnotationPath expression
-   */
-  AnnotationPath asAnnotationPath();
-
-  /**
-   * Returns true if the expression is a edm:Apply expression
-   * @return true if the expression is a edm:Apply expression
-   */
-  boolean isApply();
-
-  /**
-   * Casts the expression to a {@link Apply} expression
-   * @return Apply expression
-   */
-  Apply asApply();
-
-  /**
-   * Returns true if the expression is a edm:Cast expression
-   * @return true if the expression is a edm:Cast expression
-   */
-  boolean isCast();
-
-  /**
-   * Casts the expression to a {@link Cast} expression
-   * @return Cast expression
-   */
-  Cast asCast();
-
-  /**
-   * Returns true if the expression is a edm:Collection expression
-   * @return true if the expression is a edm:Collection expression
-   */
-  boolean isCollection();
-
-  /**
-   * Casts the expression to a {@link Collection} expression
-   * @return Collection expression
-   */
-  Collection asCollection();
-
-  /**
-   * Returns true if the expression is a edm:If expression
-   * @return true if the expression is a edm:If expression
-   */
-  boolean isIf();
-
-  /**
-   * Casts the expression to a {@link If} expression
-   * @return If expression
-   */
-  If asIf();
-
-  /**
-   * Returns true if the expression is a edm:IsOf expression
-   * @return true if the expression is a edm:IsOf expression
-   */
-  boolean isIsOf();
-
-  /**
-   * Casts the expression to a {@link IsOf} expression
-   * @return IsOf expression
-   */
-  IsOf asIsOf();
-
-  /**
-   * Returns true if the expression is a edm:LabeledElement expression
-   * @return true if the expression is a edm:LabeledElement expression
-   */
-  boolean isLabeledElement();
-
-  /**
-   * Casts the expression to a {@link LabeledElement} expression
-   * @return LabeledElement expression
-   */
-  LabeledElement asLabeledElement();
-
-  /**
-   * Returns true if the expression is a edm:LabeledElementReference expression
-   * @return true if the expression is a edm:LabeledElementReference expression
-   */
-  boolean isLabeledElementReference();
-
-  /**
-   * Casts the expression to a {@link LabeledElementReference} expression
-   * @return LabeledElementReference expression
-   */
-  LabeledElementReference asLabeledElementReference();
-
-  /**
-   * Returns true if the expression is a edm:Null expression
-   * @return true if the expression is a edm:Null expression
-   */
-  boolean isNull();
-
-  /**
-   * Casts the expression to a {@link Null} expression
-   * @return Null expression
-   */
-  Null asNull();
-
-  /**
-   * Returns true if the expression is a edm:NavigationPropertyPath expression
-   * @return true if the expression is a edm:NavigationPropertyPath expression
-   */
-  boolean isNavigationPropertyPath();
-
-  /**
-   * Casts the expression to a {@link NavigationPropertyPath} expression
-   * @return NavigationPropertyPath expression
-   */
-  NavigationPropertyPath asNavigationPropertyPath();
-
-  /**
-   * Returns true if the expression is a edm:Path expression
-   * @return true if the expression is a edm:Path expression
-   */
-  boolean isPath();
-
-  /**
-   * Casts the expression to a {@link Path} expression
-   * @return Path expression
-   */
-  Path asPath();
-
-  /**
-   * Returns true if the expression is a edm:PropertyPath expression
-   * @return true if the expression is a edm:PropertyPath expression
-   */
-  boolean isPropertyPath();
-
-  /**
-   * Casts the expression to a {@link PropertyPath} expression
-   * @return PropertyPath expression
-   */
-  PropertyPath asPropertyPath();
-
-  /**
-   * Returns true if the expression is a edm:PropertyValue expression
-   * @return true if the expression is a edm:PropertyValue expression
-   */
-  boolean isPropertyValue();
-
-  /**
-   * Casts the expression to a {@link PropertyValue} expression
-   * @return PropertyValue expression
-   */
-  PropertyValue asPropertyValue();
-
-  /**
-   * Returns true if the expression is a edm:Record expression
-   * @return true if the expression is a edm:Record expression
-   */
-  boolean isRecord();
-
-  /**
-   * Casts the expression to a {@link Record} expression
-   * @return Record expression
-   */
-  Record asRecord();
-
-  /**
-   * Returns true if the expression is a edm:UrlRef expression
-   * @return true if the expression is a edm:UrlRef expression
-   */
-  boolean isUrlRef();
-
-  /**
-   * Casts the expression to a {@link UrlRef} expression
-   * @return UrlRef expression
-   */
-  UrlRef asUrlRef();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/If.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/If.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/If.java
deleted file mode 100644
index 50be557..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/If.java
+++ /dev/null
@@ -1,54 +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.annotation;
-
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- * Represents a edm:If expression
- */
-public interface If extends DynamicAnnotationExpression, CsdlAnnotatable {
-
-  /**
-   * Returns the first expression of the edm:If expression.
-   * This expression represents the condition of the if expression
-   *
-   * @return First expression of the if expression
-   */
-  AnnotationExpression getGuard();
-
-  /**
-   * Return the second expression of the edm:If expression.
-   * If the condition of the condition is evaluated to true,
-   * this expression as to be executed.
-   *
-   * @return Second Expression of the edm:If expression
-   */
-  AnnotationExpression getThen();
-
-  /**
-   * Return the third expression of the edm:If expression.
-   * If the condition of the condition is evaluated to false,
-   * this expression as to be executed.
-   *
-   * @return Third Expression of the edm:If expression
-   */
-  AnnotationExpression getElse();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/IsOf.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/IsOf.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/IsOf.java
deleted file mode 100644
index ef08189..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/IsOf.java
+++ /dev/null
@@ -1,66 +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.annotation;
-
-import org.apache.olingo.commons.api.edm.geo.SRID;
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- *  The edm:IsOf expression evaluates a child expression and returns a Boolean value indicating whether 
- *  the child expression returns the specified type
- */
-public interface IsOf extends DynamicAnnotationExpression, CsdlAnnotatable {
-
-  /**
-   * Facet MaxLength
-   * @return fact MaxLength
-   */
-  Integer getMaxLength();
-
-  /**
-   * Facet Precision
-   * @return fact Precision
-   */
-  Integer getPrecision();
-
-  /**
-   * Facet Scale
-   * @return facet Scale
-   */
-  Integer getScale();
-
-  /**
-   * Facet SRID
-   * @return facet SRID
-   */
-  SRID getSrid();
-
-  /**
-   * The type which is checked again the child expression
-   * @return EdmType type
-   */
-  String getType();
-
-  /**
-   * Returns true if the child expression returns the specified typed 
-   * @return Returns true if the child expression returns the specified typed 
-   */
-  DynamicAnnotationExpression getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElement.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElement.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElement.java
deleted file mode 100644
index 0a1977d..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElement.java
+++ /dev/null
@@ -1,42 +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.annotation;
-
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- * The edm:LabeledElement expression assigns a name to a child expression. The value of the child expression can 
- * then be reused elsewhere with an edm:LabeledElementReference (See {@link LabeledElementReference}) expression.
- */
-public interface LabeledElement extends DynamicAnnotationExpression, CsdlAnnotatable {
-
-  /**
-   * Returns the assigned name
-   * @return assigned name
-   */
-  String getName();
-
-  /**
-   * Returns the child expression
-   *
-   * @return child expression
-   */
-  DynamicAnnotationExpression getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElementReference.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElementReference.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElementReference.java
deleted file mode 100644
index 5d4adf1..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/LabeledElementReference.java
+++ /dev/null
@@ -1,33 +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.annotation;
-
-/**
- *  The edm:LabeledElementReference expression returns the value of an 
- *  edm:LabeledElement (see {@link LabeledElement}) expression.
- */
-public interface LabeledElementReference extends DynamicAnnotationExpression {
-
-  /**
-   * Returns the value of the edm:LabeledElement expression
-   * @return value of the edm:LabeledElement expression
-   */
-  String getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/NavigationPropertyPath.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/NavigationPropertyPath.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/NavigationPropertyPath.java
deleted file mode 100644
index 9c7d5b1..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/NavigationPropertyPath.java
+++ /dev/null
@@ -1,33 +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.annotation;
-
-/**
- * The edm:NavigationPropertyPath expression provides a value for terms or term properties that specify the 
- * built-in abstract type Edm.NavigationPropertyPath
- */
-public interface NavigationPropertyPath extends DynamicAnnotationExpression {
-  /**
-   * Returns the navigation property path itself.
-   *
-   * @return navigation property
-   */
-  String getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Not.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Not.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Not.java
deleted file mode 100644
index 4dfebde..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Not.java
+++ /dev/null
@@ -1,31 +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.annotation;
-
-/**
- * Represents a logical edm:Le expression
- */
-public interface Not extends DynamicAnnotationExpression {
-
-  /**
-   * Returns a boolean value
-   * @return either true or false
-   */
-  DynamicAnnotationExpression getExpression();
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Null.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Null.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Null.java
deleted file mode 100644
index 84fafde..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Null.java
+++ /dev/null
@@ -1,28 +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.annotation;
-
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- * The edm:Null expression returns an untyped null value.
- */
-public interface Null extends DynamicAnnotationExpression, CsdlAnnotatable {
-  // No additional methods needed for now.
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Path.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Path.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Path.java
deleted file mode 100644
index abc4689..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Path.java
+++ /dev/null
@@ -1,35 +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.annotation;
-
-/**
- *  The edm:Path expression enables a value to be obtained by traversing an object graph. 
- *  It can be used in annotations that target entity containers, entity sets, entity types, complex types, 
- *  navigation properties of structured types, and properties of structured types.
- */
-public interface Path extends DynamicAnnotationExpression {
-
-  /**
-   * Returns the target value of the expression
-   *
-   * @return target value of the expression
-   */
-  String getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyPath.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyPath.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyPath.java
deleted file mode 100644
index d8c1e7e..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyPath.java
+++ /dev/null
@@ -1,33 +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.annotation;
-
-/**
- * The edm:PropertyPath expression provides a value for terms or term properties that specify the built-in 
- * abstract type Edm.PropertyPath.
- */
-public interface PropertyPath extends DynamicAnnotationExpression {
-
-  /**
-   * Returns the property path itself.
-   * @return the property path itself
-   */
-  String getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyValue.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyValue.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyValue.java
deleted file mode 100644
index 41447e9..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/PropertyValue.java
+++ /dev/null
@@ -1,42 +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.annotation;
-
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- * The edm:PropertyValue element supplies a value to a property on the type instantiated by an 
- * edm:Record expression (See {@link org.apache.olingo.commons.api.edm.annotation.EdmRecord}). 
- * The value is obtained by evaluating an expression.
- */
-public interface PropertyValue extends DynamicAnnotationExpression, CsdlAnnotatable {
-
-  /**
-   * Property name
-   * @return Property name
-   */
-  String getProperty();
-
-  /**
-   * Evaluated value of the expression (property value)
-   * @return evaluated value of the expression
-   */
-  AnnotationExpression getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Record.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Record.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Record.java
deleted file mode 100644
index db042e4..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/Record.java
+++ /dev/null
@@ -1,43 +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.annotation;
-
-import java.util.List;
-
-import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
-
-/**
- * The edm:Record expression enables a new entity type or complex type instance to be constructed.
- * A record expression contains zero or more edm:PropertyValue (See {@link Record} )elements.
- */
-public interface Record extends DynamicAnnotationExpression, CsdlAnnotatable {
-
-  /**
-   * List of edm:PropertyValues (See {@link PropertyValue}
-   * @return List of edm:PropertyValues (See
-   */
-  List<PropertyValue> getPropertyValues();
-
-  /**
-   * Returns the entity type or complex type to be constructed.
-   * @return Entity type or complex type
-   */
-  String getType();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/TwoParamsOpDynamicAnnotationExpression.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/TwoParamsOpDynamicAnnotationExpression.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/TwoParamsOpDynamicAnnotationExpression.java
deleted file mode 100644
index 91f49af..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/TwoParamsOpDynamicAnnotationExpression.java
+++ /dev/null
@@ -1,96 +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.annotation;
-
-/**
- * Represents a generic expression with two child exprssions
- */
-public interface TwoParamsOpDynamicAnnotationExpression extends DynamicAnnotationExpression {
-
-  /**
-   * Type (Operator) of the expression
-   */
-  public static enum Type {
-    /**
-     * Logical And
-     */
-    And,
-    /**
-     * Logical Or
-     */
-    Or,
-    /**
-     * Equals
-     */
-    Eq,
-    /**
-     * Not equals
-     */
-    Ne,
-    /**
-     * Greater than
-     */
-    Gt,
-    /**
-     * Greater or equals than
-     */
-    Ge,
-    /**
-     * Less than
-     */
-    Lt,
-    /**
-     * Less or equals than
-     */
-    Le;
-
-    /**
-     * Creates the type(Operator) of a expressin
-     * @param value Value of the operator like "And" or "Eq"
-     * @return Type(Operator) of the expression
-     */
-    public static Type fromString(final String value) {
-      Type result = null;
-      for (Type type : values()) {
-        if (value.equals(type.name())) {
-          result = type;
-        }
-      }
-      return result;
-    }
-  }
-
-  /**
-   * Returns the type of the expression result
-   * @return Type of the result
-   */
-  Type getType();
-
-  /**
-   * Returns the first expression (left child)
-   * @return Child expression
-   */
-  DynamicAnnotationExpression getLeftExpression();
-
-  /**
-   * Returns the second expression (right child)
-   * @return Child expression
-   */
-  DynamicAnnotationExpression getRightExpression();
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/UrlRef.java
----------------------------------------------------------------------
diff --git a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/UrlRef.java b/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/UrlRef.java
deleted file mode 100644
index c6bd824..0000000
--- a/lib/commons-api/src/main/java/org/apache/olingo/commons/api/edm/provider/annotation/UrlRef.java
+++ /dev/null
@@ -1,33 +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.annotation;
-
-/**
- * The edm:UrlRef expression enables a value to be obtained by sending a GET request to the value of 
- * the UrlRef expression. 
- */
-public interface UrlRef extends DynamicAnnotationExpression {
-
-  /**
-   * Returns a expression of type Edm.String
-   * @return expression of type Edm.String
-   */
-  AnnotationExpression getValue();
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/EdmAnnotationImpl.java
----------------------------------------------------------------------
diff --git a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/EdmAnnotationImpl.java b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/EdmAnnotationImpl.java
index d867885..53fbfde 100644
--- a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/EdmAnnotationImpl.java
+++ b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/EdmAnnotationImpl.java
@@ -31,9 +31,9 @@ import org.apache.olingo.commons.api.edm.annotation.EdmDynamicAnnotationExpressi
 import org.apache.olingo.commons.api.edm.annotation.EdmPropertyValue;
 import org.apache.olingo.commons.api.edm.provider.CsdlAnnotatable;
 import org.apache.olingo.commons.api.edm.provider.CsdlAnnotation;
-import org.apache.olingo.commons.api.edm.provider.annotation.AnnotationExpression;
-import org.apache.olingo.commons.api.edm.provider.annotation.DynamicAnnotationExpression;
-import org.apache.olingo.commons.api.edm.provider.annotation.PropertyValue;
+import org.apache.olingo.commons.api.edm.provider.annotation.CsdlDynamicExpression;
+import org.apache.olingo.commons.api.edm.provider.annotation.CsdlExpression;
+import org.apache.olingo.commons.api.edm.provider.annotation.CsdlPropertyValue;
 import org.apache.olingo.commons.core.edm.annotation.EdmAndImpl;
 import org.apache.olingo.commons.core.edm.annotation.EdmAnnotationPathImpl;
 import org.apache.olingo.commons.core.edm.annotation.EdmApplyImpl;
@@ -84,7 +84,7 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
     return annotation.getQualifier();
   }
 
-  private EdmAnnotationExpression getExpression(final AnnotationExpression exp) {
+  private EdmAnnotationExpression getExpression(final CsdlExpression exp) {
     EdmAnnotationExpression _expression = null;
 
     if (exp.isConstant()) {
@@ -96,59 +96,60 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
     return _expression;
   }
 
-  private EdmDynamicAnnotationExpression getDynamicExpression(final DynamicAnnotationExpression exp) {
+  private EdmDynamicAnnotationExpression getDynamicExpression(final CsdlDynamicExpression exp) {
     EdmDynamicAnnotationExpression _expression = null;
 
-    if (exp.isNot()) {
-      _expression = new EdmNotImpl(getDynamicExpression(exp.asNot().getExpression()));
-    } else if (exp.isTwoParamsOp()) {
-      switch (exp.asTwoParamsOp().getType()) {
+    if (exp.isLogicalOrComparison()) {
+      switch (exp.asLogicalOrComparison().getType()) {
+      case Not:
+        _expression = new EdmNotImpl(getExpression(exp.asLogicalOrComparison().getLeft()));
+        break;
       case And:
         _expression = new EdmAndImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Or:
         _expression = new EdmOrImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Eq:
         _expression = new EdmEqImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Ne:
         _expression = new EdmNeImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Ge:
         _expression = new EdmGeImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Gt:
         _expression = new EdmGtImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Le:
         _expression = new EdmLeImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       case Lt:
         _expression = new EdmLtImpl(
-            getDynamicExpression(exp.asTwoParamsOp().getLeftExpression()),
-            getDynamicExpression(exp.asTwoParamsOp().getRightExpression()));
+            getExpression(exp.asLogicalOrComparison().getLeft()),
+            getExpression(exp.asLogicalOrComparison().getRight()));
         break;
 
       default:
@@ -158,7 +159,7 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
     } else if (exp.isApply()) {
       final List<EdmAnnotationExpression> parameters =
           new ArrayList<EdmAnnotationExpression>(exp.asApply().getParameters().size());
-      for (AnnotationExpression param : exp.asApply().getParameters()) {
+      for (CsdlExpression param : exp.asApply().getParameters()) {
         parameters.add(getExpression(param));
       }
       _expression = new EdmApplyImpl(exp.asApply().getFunction(), parameters);
@@ -167,7 +168,7 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
     } else if (exp.isCollection()) {
       final List<EdmAnnotationExpression> items =
           new ArrayList<EdmAnnotationExpression>(exp.asCollection().getItems().size());
-      for (AnnotationExpression param : exp.asCollection().getItems()) {
+      for (CsdlExpression param : exp.asCollection().getItems()) {
         items.add(getExpression(param));
       }
       _expression = new EdmCollectionImpl(items);
@@ -177,10 +178,10 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
           getExpression(exp.asIf().getThen()),
           getExpression(exp.asIf().getElse()));
     } else if (exp.isIsOf()) {
-      _expression = new EdmIsOfImpl(edm, exp.asIsOf(), getDynamicExpression(exp.asIsOf().getValue()));
+      _expression = new EdmIsOfImpl(edm, exp.asIsOf(), getDynamicExpression(exp.asIsOf().getValue().asDynamic()));
     } else if (exp.isLabeledElement()) {
       _expression = new EdmLabeledElementImpl(
-          exp.asLabeledElement().getName(), getDynamicExpression(exp.asLabeledElement().getValue()));
+          exp.asLabeledElement().getName(), getDynamicExpression(exp.asLabeledElement().getValue().asDynamic()));
     } else if (exp.isLabeledElementReference()) {
       _expression = new EdmLabeledElementReferenceImpl(exp.asLabeledElementReference().getValue());
     } else if (exp.isNull()) {
@@ -197,7 +198,7 @@ public class EdmAnnotationImpl extends AbstractEdmAnnotatable implements EdmAnno
     } else if (exp.isRecord()) {
       final List<EdmPropertyValue> propertyValues =
           new ArrayList<EdmPropertyValue>(exp.asRecord().getPropertyValues().size());
-      for (PropertyValue propertyValue : exp.asRecord().getPropertyValues()) {
+      for (CsdlPropertyValue propertyValue : exp.asRecord().getPropertyValues()) {
         propertyValues.add(new EdmPropertyValueImpl(
             propertyValue.getProperty(), getExpression(propertyValue.getValue())));
       }

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/AbstractEdmTwoParamsOpDynamicAnnotationExpression.java
----------------------------------------------------------------------
diff --git a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/AbstractEdmTwoParamsOpDynamicAnnotationExpression.java b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/AbstractEdmTwoParamsOpDynamicAnnotationExpression.java
index 78bb35a..2c5a289 100644
--- a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/AbstractEdmTwoParamsOpDynamicAnnotationExpression.java
+++ b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/AbstractEdmTwoParamsOpDynamicAnnotationExpression.java
@@ -18,30 +18,31 @@
  */
 package org.apache.olingo.commons.core.edm.annotation;
 
+import org.apache.olingo.commons.api.edm.annotation.EdmAnnotationExpression;
 import org.apache.olingo.commons.api.edm.annotation.EdmDynamicAnnotationExpression;
 import org.apache.olingo.commons.api.edm.annotation.EdmTwoParamsOpDynamicAnnotationExpression;
 
 public abstract class AbstractEdmTwoParamsOpDynamicAnnotationExpression
 extends AbstractEdmDynamicAnnotationExpression implements EdmTwoParamsOpDynamicAnnotationExpression {
 
-  private final EdmDynamicAnnotationExpression left;
+  private final EdmAnnotationExpression left;
 
-  private final EdmDynamicAnnotationExpression right;
+  private final EdmAnnotationExpression right;
 
   public AbstractEdmTwoParamsOpDynamicAnnotationExpression(
-      final EdmDynamicAnnotationExpression left, final EdmDynamicAnnotationExpression right) {
+      final EdmAnnotationExpression left, final EdmAnnotationExpression right) {
 
     this.left = left;
     this.right = right;
   }
 
   @Override
-  public EdmDynamicAnnotationExpression getLeftExpression() {
+  public EdmAnnotationExpression getLeftExpression() {
     return left;
   }
 
   @Override
-  public EdmDynamicAnnotationExpression getRightExpression() {
+  public EdmAnnotationExpression getRightExpression() {
     return right;
   }
 }

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmAndImpl.java
----------------------------------------------------------------------
diff --git a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmAndImpl.java b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmAndImpl.java
index 02e4b48..0b75297 100644
--- a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmAndImpl.java
+++ b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmAndImpl.java
@@ -19,11 +19,12 @@
 package org.apache.olingo.commons.core.edm.annotation;
 
 import org.apache.olingo.commons.api.edm.annotation.EdmAnd;
+import org.apache.olingo.commons.api.edm.annotation.EdmAnnotationExpression;
 import org.apache.olingo.commons.api.edm.annotation.EdmDynamicAnnotationExpression;
 
 public class EdmAndImpl extends AbstractEdmTwoParamsOpDynamicAnnotationExpression implements EdmAnd {
 
-  public EdmAndImpl(final EdmDynamicAnnotationExpression left, final EdmDynamicAnnotationExpression right) {
+  public EdmAndImpl(final EdmAnnotationExpression left, final EdmAnnotationExpression right) {
     super(left, right);
   }
 

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/67ccbf9d/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmCastImpl.java
----------------------------------------------------------------------
diff --git a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmCastImpl.java b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmCastImpl.java
index 086bdf2..8989200 100644
--- a/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmCastImpl.java
+++ b/lib/commons-core/src/main/java/org/apache/olingo/commons/core/edm/annotation/EdmCastImpl.java
@@ -23,20 +23,20 @@ import org.apache.olingo.commons.api.edm.EdmType;
 import org.apache.olingo.commons.api.edm.annotation.EdmCast;
 import org.apache.olingo.commons.api.edm.annotation.EdmDynamicAnnotationExpression;
 import org.apache.olingo.commons.api.edm.geo.SRID;
-import org.apache.olingo.commons.api.edm.provider.annotation.Cast;
+import org.apache.olingo.commons.api.edm.provider.annotation.CsdlCast;
 import org.apache.olingo.commons.core.edm.EdmTypeInfo;
 
 public class EdmCastImpl extends AbstractEdmAnnotatableDynamicAnnotationExpression implements EdmCast {
 
   private final Edm edm;
 
-  private final Cast cast;
+  private final CsdlCast cast;
 
   private final EdmDynamicAnnotationExpression value;
 
   private EdmType type;
 
-  public EdmCastImpl(final Edm edm, final Cast cast, final EdmDynamicAnnotationExpression value) {
+  public EdmCastImpl(final Edm edm, final CsdlCast cast, final EdmDynamicAnnotationExpression value) {
     this.edm = edm;
     this.cast = cast;
     this.value = value;