You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@olingo.apache.org by il...@apache.org on 2014/03/24 10:41:58 UTC
[09/50] [abbrv] Consistently using package name to differentiate V3
and V4
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataBinder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataBinder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataBinder.java
new file mode 100644
index 0000000..1397c47
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataBinder.java
@@ -0,0 +1,25 @@
+/*
+ * 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.client.api.op.v4;
+
+import org.apache.olingo.client.api.op.CommonODataBinder;
+
+public interface ODataBinder extends CommonODataBinder {
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataDeserializer.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataDeserializer.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataDeserializer.java
new file mode 100644
index 0000000..425e530
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataDeserializer.java
@@ -0,0 +1,31 @@
+/*
+ * 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.client.api.op.v4;
+
+import java.io.InputStream;
+
+import org.apache.olingo.client.api.edm.xml.v4.XMLMetadata;
+import org.apache.olingo.client.api.op.CommonODataDeserializer;
+
+public interface ODataDeserializer extends CommonODataDeserializer {
+
+ @Override
+ XMLMetadata toMetadata(InputStream input);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataReader.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataReader.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataReader.java
new file mode 100644
index 0000000..25d989d
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/op/v4/ODataReader.java
@@ -0,0 +1,25 @@
+/*
+ * 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.client.api.op.v4;
+
+import org.apache.olingo.client.api.op.CommonODataReader;
+
+public interface ODataReader extends CommonODataReader {
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterArgFactory.java
new file mode 100644
index 0000000..dccb051
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterArgFactory.java
@@ -0,0 +1,83 @@
+/*
+ * 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.client.api.uri;
+
+public interface CommonFilterArgFactory {
+
+ FilterArg _null();
+
+ FilterArg add(FilterArg first, FilterArg second);
+
+ FilterArg ceiling(FilterArg param);
+
+ FilterArg concat(FilterArg first, FilterArg second);
+
+ FilterArg day(FilterArg param);
+
+ FilterArg div(FilterArg first, FilterArg second);
+
+ FilterArg endswith(FilterArg first, FilterArg second);
+
+ FilterArg floor(FilterArg param);
+
+ FilterArg hour(FilterArg param);
+
+ FilterArg indexof(FilterArg first, FilterArg second);
+
+ FilterArg isof(FilterArg type);
+
+ FilterArg isof(FilterArg expression, FilterArg type);
+
+ FilterArg length(FilterArg param);
+
+ FilterArg literal(Object value);
+
+ FilterArg minute(FilterArg param);
+
+ FilterArg mod(FilterArg first, FilterArg second);
+
+ FilterArg month(FilterArg param);
+
+ FilterArg mul(FilterArg first, FilterArg second);
+
+ FilterArg property(String propertyPath);
+
+ FilterArg replace(FilterArg first, FilterArg second, FilterArg third);
+
+ FilterArg round(FilterArg param);
+
+ FilterArg second(FilterArg param);
+
+ FilterArg startswith(FilterArg first, FilterArg second);
+
+ FilterArg sub(FilterArg first, FilterArg second);
+
+ FilterArg substring(FilterArg arg, FilterArg pos);
+
+ FilterArg substring(FilterArg arg, FilterArg pos, FilterArg length);
+
+ FilterArg tolower(FilterArg param);
+
+ FilterArg toupper(FilterArg param);
+
+ FilterArg trim(FilterArg param);
+
+ FilterArg year(FilterArg param);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterFactory.java
new file mode 100644
index 0000000..7304721
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonFilterFactory.java
@@ -0,0 +1,61 @@
+/*
+ * 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.client.api.uri;
+
+import java.io.Serializable;
+
+/**
+ * OData filter factory.
+ */
+public interface CommonFilterFactory extends Serializable {
+
+ CommonFilterArgFactory getArgFactory();
+
+ URIFilter match(FilterArg arg);
+
+ URIFilter eq(String key, Object value);
+
+ URIFilter eq(FilterArg left, FilterArg right);
+
+ URIFilter ne(String key, Object value);
+
+ URIFilter ne(FilterArg left, FilterArg right);
+
+ URIFilter gt(String key, Object value);
+
+ URIFilter gt(FilterArg left, FilterArg right);
+
+ URIFilter ge(String key, Object value);
+
+ URIFilter ge(FilterArg left, FilterArg right);
+
+ URIFilter lt(String key, Object value);
+
+ URIFilter lt(FilterArg left, FilterArg right);
+
+ URIFilter le(String key, Object value);
+
+ URIFilter le(FilterArg left, FilterArg right);
+
+ URIFilter and(URIFilter left, URIFilter right);
+
+ URIFilter or(URIFilter left, URIFilter right);
+
+ URIFilter not(URIFilter filter);
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonURIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonURIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonURIBuilder.java
new file mode 100644
index 0000000..3f10262
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/CommonURIBuilder.java
@@ -0,0 +1,224 @@
+/*
+ * 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.client.api.uri;
+
+
+import java.net.URI;
+import java.util.Map;
+
+/**
+ * OData URI builder.
+ */
+public interface CommonURIBuilder<UB extends CommonURIBuilder<?>> {
+
+ /**
+ * Adds the specified query option to the URI.
+ *
+ * @param option query option.
+ * @param value query option value.
+ * @return current URIBuilder instance
+ */
+ UB addQueryOption(QueryOption option, String value);
+
+ /**
+ * Adds the specified (custom) query option to the URI.
+ *
+ * @param option query option.
+ * @param value query option value.
+ * @return current URIBuilder instance
+ */
+ UB addQueryOption(String option, String value);
+
+ /**
+ * Appends EntitySet segment to the URI.
+ *
+ * @param segmentValue segment value.
+ * @return current URIBuilder instance
+ */
+ UB appendEntitySetSegment(String segmentValue);
+
+ /**
+ * Appends key segment to the URI.
+ *
+ * @param val segment value.
+ * @return current URIBuilder instance
+ */
+ UB appendKeySegment(Object val);
+
+ /**
+ * Appends key segment to the URI, for multiple keys.
+ *
+ * @param segmentValues segment values.
+ * @return current URIBuilder instance
+ */
+ UB appendKeySegment(Map<String, Object> segmentValues);
+
+ /**
+ * Appends property segment to the URI.
+ *
+ * @param segmentValue segment value.
+ * @return current URIBuilder instance
+ */
+ UB appendPropertySegment(String segmentValue);
+
+ /**
+ * Appends navigation segment to the URI.
+ *
+ * @param segmentValue segment value.
+ * @return current URIBuilder instance
+ */
+ UB appendNavigationSegment(String segmentValue);
+
+ /**
+ * Appends derived entity type segment to the URI.
+ *
+ * @param segmentValue segment value.
+ * @return current URIBuilder instance
+ */
+ UB appendDerivedEntityTypeSegment(String segmentValue);
+
+ /**
+ * Appends value segment to the URI.
+ *
+ * @return current URIBuilder instance
+ */
+ UB appendValueSegment();
+
+ /**
+ * Appends operation (action or function) segment to the URI.
+ *
+ * @param operation Operation (action or function) name
+ * @param arguments Operation arguments
+ * @return current URIBuilder instance
+ */
+ UB appendOperationCallSegment(String operation, Map<String, Object> arguments);
+
+ /**
+ * Appends metadata segment to the URI.
+ *
+ * @return current URIBuilder instance
+ */
+ UB appendMetadataSegment();
+
+ /**
+ * Appends batch segment to the URI.
+ *
+ * @return current URIBuilder instance
+ */
+ UB appendBatchSegment();
+
+ /**
+ * Adds count query option.
+ *
+ * @return current URIBuilder instance
+ */
+ UB count();
+
+ /**
+ * Adds expand query option.
+ *
+ * @param expandItems items to be expanded in-line
+ * @return current URIBuilder instance
+ * @see QueryOption#EXPAND
+ */
+ UB expand(String... expandItems);
+
+ /**
+ * Adds format query option.
+ *
+ * @param format media type acceptable in a response.
+ * @return current URIBuilder instance
+ * @see QueryOption#FORMAT
+ */
+ UB format(String format);
+
+ /**
+ * Adds filter for filter query option.
+ *
+ * @param filter filter instance (to be obtained via <tt>ODataFilterFactory</tt>): note that <tt>build()</tt> method
+ * will be immediately invoked.
+ * @return current URIBuilder instance
+ * @see QueryOption#FILTER
+ * @see URIFilter
+ * @see org.apache.olingo.client.api.uri.filter.FilterFactory
+ */
+ UB filter(URIFilter filter);
+
+ /**
+ * Adds filter query option.
+ *
+ * @param filter filter string.
+ * @return current URIBuilder instance
+ * @see QueryOption#FILTER
+ */
+ UB filter(String filter);
+
+ /**
+ * Adds select query option.
+ *
+ * @param selectItems select items
+ * @return current URIBuilder instance
+ * @see QueryOption#SELECT
+ */
+ UB select(String... selectItems);
+
+ /**
+ * Adds orderby query option.
+ *
+ * @param order order string.
+ * @return current URIBuilder instance
+ * @see QueryOption#ORDERBY
+ */
+ UB orderBy(String order);
+
+ /**
+ * Adds top query option.
+ *
+ * @param top maximum number of entities to be returned.
+ * @return current URIBuilder instance
+ * @see QueryOption#TOP
+ */
+ UB top(int top);
+
+ /**
+ * Adds skip query option.
+ *
+ * @param skip number of entities to be skipped into the response.
+ * @return current URIBuilder instance
+ * @see QueryOption#SKIP
+ */
+ UB skip(int skip);
+
+ /**
+ * Adds skiptoken query option.
+ *
+ * @param skipToken opaque token.
+ * @return current URIBuilder instance
+ * @see QueryOption#SKIPTOKEN
+ */
+ UB skipToken(String skipToken);
+
+ /**
+ * Build OData URI.
+ *
+ * @return OData URI.
+ */
+ URI build();
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/FilterArg.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/FilterArg.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/FilterArg.java
new file mode 100644
index 0000000..0f27f31
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/FilterArg.java
@@ -0,0 +1,30 @@
+/*
+ * 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.client.api.uri;
+
+/**
+ * Interface for any available filter argument.
+ */
+public interface FilterArg {
+
+ /**
+ * @return String representation of this filter argument.
+ */
+ String build();
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIBuilder.java
deleted file mode 100644
index cfb041b..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIBuilder.java
+++ /dev/null
@@ -1,225 +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.client.api.uri;
-
-import org.apache.olingo.client.api.uri.filter.URIFilter;
-
-import java.net.URI;
-import java.util.Map;
-
-/**
- * OData URI builder.
- */
-public interface URIBuilder<UB extends URIBuilder<?>> {
-
- /**
- * Adds the specified query option to the URI.
- *
- * @param option query option.
- * @param value query option value.
- * @return current URIBuilder instance
- */
- UB addQueryOption(QueryOption option, String value);
-
- /**
- * Adds the specified (custom) query option to the URI.
- *
- * @param option query option.
- * @param value query option value.
- * @return current URIBuilder instance
- */
- UB addQueryOption(String option, String value);
-
- /**
- * Appends EntitySet segment to the URI.
- *
- * @param segmentValue segment value.
- * @return current URIBuilder instance
- */
- UB appendEntitySetSegment(String segmentValue);
-
- /**
- * Appends key segment to the URI.
- *
- * @param val segment value.
- * @return current URIBuilder instance
- */
- UB appendKeySegment(Object val);
-
- /**
- * Appends key segment to the URI, for multiple keys.
- *
- * @param segmentValues segment values.
- * @return current URIBuilder instance
- */
- UB appendKeySegment(Map<String, Object> segmentValues);
-
- /**
- * Appends property segment to the URI.
- *
- * @param segmentValue segment value.
- * @return current URIBuilder instance
- */
- UB appendPropertySegment(String segmentValue);
-
- /**
- * Appends navigation segment to the URI.
- *
- * @param segmentValue segment value.
- * @return current URIBuilder instance
- */
- UB appendNavigationSegment(String segmentValue);
-
- /**
- * Appends derived entity type segment to the URI.
- *
- * @param segmentValue segment value.
- * @return current URIBuilder instance
- */
- UB appendDerivedEntityTypeSegment(String segmentValue);
-
- /**
- * Appends value segment to the URI.
- *
- * @return current URIBuilder instance
- */
- UB appendValueSegment();
-
- /**
- * Appends operation (action or function) segment to the URI.
- *
- * @param operation Operation (action or function) name
- * @param arguments Operation arguments
- * @return current URIBuilder instance
- */
- UB appendOperationCallSegment(String operation, Map<String, Object> arguments);
-
- /**
- * Appends metadata segment to the URI.
- *
- * @return current URIBuilder instance
- */
- UB appendMetadataSegment();
-
- /**
- * Appends batch segment to the URI.
- *
- * @return current URIBuilder instance
- */
- UB appendBatchSegment();
-
- /**
- * Adds count query option.
- *
- * @return current URIBuilder instance
- */
- UB count();
-
- /**
- * Adds expand query option.
- *
- * @param expandItems items to be expanded in-line
- * @return current URIBuilder instance
- * @see QueryOption#EXPAND
- */
- UB expand(String... expandItems);
-
- /**
- * Adds format query option.
- *
- * @param format media type acceptable in a response.
- * @return current URIBuilder instance
- * @see QueryOption#FORMAT
- */
- UB format(String format);
-
- /**
- * Adds filter for filter query option.
- *
- * @param filter filter instance (to be obtained via <tt>ODataFilterFactory</tt>): note that <tt>build()</tt> method
- * will be immediately invoked.
- * @return current URIBuilder instance
- * @see QueryOption#FILTER
- * @see URIFilter
- * @see org.apache.olingo.client.api.uri.filter.FilterFactory
- */
- UB filter(URIFilter filter);
-
- /**
- * Adds filter query option.
- *
- * @param filter filter string.
- * @return current URIBuilder instance
- * @see QueryOption#FILTER
- */
- UB filter(String filter);
-
- /**
- * Adds select query option.
- *
- * @param selectItems select items
- * @return current URIBuilder instance
- * @see QueryOption#SELECT
- */
- UB select(String... selectItems);
-
- /**
- * Adds orderby query option.
- *
- * @param order order string.
- * @return current URIBuilder instance
- * @see QueryOption#ORDERBY
- */
- UB orderBy(String order);
-
- /**
- * Adds top query option.
- *
- * @param top maximum number of entities to be returned.
- * @return current URIBuilder instance
- * @see QueryOption#TOP
- */
- UB top(int top);
-
- /**
- * Adds skip query option.
- *
- * @param skip number of entities to be skipped into the response.
- * @return current URIBuilder instance
- * @see QueryOption#SKIP
- */
- UB skip(int skip);
-
- /**
- * Adds skiptoken query option.
- *
- * @param skipToken opaque token.
- * @return current URIBuilder instance
- * @see QueryOption#SKIPTOKEN
- */
- UB skipToken(String skipToken);
-
- /**
- * Build OData URI.
- *
- * @return OData URI.
- */
- URI build();
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIFilter.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIFilter.java
new file mode 100644
index 0000000..22a0aa7
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/URIFilter.java
@@ -0,0 +1,32 @@
+/*
+ * 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.client.api.uri;
+
+/**
+ * Interface for any available filter; obtain instances via <tt>FilterFactory</tt>.
+ *
+ * @see FilterFactory
+ */
+public interface URIFilter {
+
+ /**
+ * @return String representation of this filter.
+ */
+ String build();
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V3URIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V3URIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V3URIBuilder.java
deleted file mode 100644
index 7d4059b..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V3URIBuilder.java
+++ /dev/null
@@ -1,47 +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.client.api.uri;
-
-public interface V3URIBuilder extends URIBuilder<V3URIBuilder> {
-
- public enum InlineCount {
-
- allpages,
- none
-
- }
-
- /**
- * Appends links segment to the URI.
- *
- * @param segmentValue segment value
- * @return current URIBuilder instance
- */
- V3URIBuilder appendLinksSegment(String segmentValue);
-
- /**
- * Adds inlinecount query option.
- *
- * @param inlineCount value
- * @return current URIBuilder instance
- * @see QueryOption#INLINECOUNT
- */
- V3URIBuilder inlineCount(InlineCount inlineCount);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V4URIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V4URIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V4URIBuilder.java
deleted file mode 100644
index d98beb3..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/V4URIBuilder.java
+++ /dev/null
@@ -1,87 +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.client.api.uri;
-
-public interface V4URIBuilder extends URIBuilder<V4URIBuilder> {
-
- /**
- * Appends Singleton segment to the URI.
- *
- * @param segmentValue segment value.
- * @return current URIBuilder instance
- */
- V4URIBuilder appendSingletonSegment(String segmentValue);
-
- /**
- * Appends entity-id segment to the URI.
- *
- * @param segmentValue segment value
- * @return current URIBuilder instance
- */
- V4URIBuilder appendEntityIdSegment(String segmentValue);
-
- /**
- * Appends ref segment to the URI.
- *
- * @return current URIBuilder instance
- */
- V4URIBuilder appendRefSegment();
-
- /**
- * Appends cross join segment to the URI.
- *
- * @param segmentValues segment values.
- * @return current URIBuilder instance
- */
- V4URIBuilder appendCrossjoinSegment(String... segmentValues);
-
- /**
- * Appends all segment to the URI.
- *
- * @return current URIBuilder instance
- */
- V4URIBuilder appendAllSegment();
-
- /**
- * Adds id query option.
- *
- * @param idValue opaque token.
- * @return current URIBuilder instance
- * @see QueryOption#ID
- */
- V4URIBuilder id(String idValue);
-
- /**
- * Appends count query option.
- *
- * @param value true or false
- * @return current URIBuilder instance
- * @see QueryOption#COUNT
- */
- V4URIBuilder count(boolean value);
-
- /**
- * Appends search query option.
- *
- * @param expression search expression
- * @return current URIBuilder instance
- * @see QueryOption#SEARCH
- */
- V4URIBuilder search(String expression);
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArg.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArg.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArg.java
deleted file mode 100644
index 10ab250..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArg.java
+++ /dev/null
@@ -1,30 +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.client.api.uri.filter;
-
-/**
- * Interface for any available filter argument.
- */
-public interface FilterArg {
-
- /**
- * @return String representation of this filter argument.
- */
- String build();
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArgFactory.java
deleted file mode 100644
index f9fad74..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterArgFactory.java
+++ /dev/null
@@ -1,83 +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.client.api.uri.filter;
-
-public interface FilterArgFactory {
-
- FilterArg _null();
-
- FilterArg add(FilterArg first, FilterArg second);
-
- FilterArg ceiling(FilterArg param);
-
- FilterArg concat(FilterArg first, FilterArg second);
-
- FilterArg day(FilterArg param);
-
- FilterArg div(FilterArg first, FilterArg second);
-
- FilterArg endswith(FilterArg first, FilterArg second);
-
- FilterArg floor(FilterArg param);
-
- FilterArg hour(FilterArg param);
-
- FilterArg indexof(FilterArg first, FilterArg second);
-
- FilterArg isof(FilterArg type);
-
- FilterArg isof(FilterArg expression, FilterArg type);
-
- FilterArg length(FilterArg param);
-
- FilterArg literal(Object value);
-
- FilterArg minute(FilterArg param);
-
- FilterArg mod(FilterArg first, FilterArg second);
-
- FilterArg month(FilterArg param);
-
- FilterArg mul(FilterArg first, FilterArg second);
-
- FilterArg property(String propertyPath);
-
- FilterArg replace(FilterArg first, FilterArg second, FilterArg third);
-
- FilterArg round(FilterArg param);
-
- FilterArg second(FilterArg param);
-
- FilterArg startswith(FilterArg first, FilterArg second);
-
- FilterArg sub(FilterArg first, FilterArg second);
-
- FilterArg substring(FilterArg arg, FilterArg pos);
-
- FilterArg substring(FilterArg arg, FilterArg pos, FilterArg length);
-
- FilterArg tolower(FilterArg param);
-
- FilterArg toupper(FilterArg param);
-
- FilterArg trim(FilterArg param);
-
- FilterArg year(FilterArg param);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterFactory.java
deleted file mode 100644
index 0782daa..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/FilterFactory.java
+++ /dev/null
@@ -1,61 +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.client.api.uri.filter;
-
-import java.io.Serializable;
-
-/**
- * OData filter factory.
- */
-public interface FilterFactory extends Serializable {
-
- FilterArgFactory getArgFactory();
-
- URIFilter match(FilterArg arg);
-
- URIFilter eq(String key, Object value);
-
- URIFilter eq(FilterArg left, FilterArg right);
-
- URIFilter ne(String key, Object value);
-
- URIFilter ne(FilterArg left, FilterArg right);
-
- URIFilter gt(String key, Object value);
-
- URIFilter gt(FilterArg left, FilterArg right);
-
- URIFilter ge(String key, Object value);
-
- URIFilter ge(FilterArg left, FilterArg right);
-
- URIFilter lt(String key, Object value);
-
- URIFilter lt(FilterArg left, FilterArg right);
-
- URIFilter le(String key, Object value);
-
- URIFilter le(FilterArg left, FilterArg right);
-
- URIFilter and(URIFilter left, URIFilter right);
-
- URIFilter or(URIFilter left, URIFilter right);
-
- URIFilter not(URIFilter filter);
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/URIFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/URIFilter.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/URIFilter.java
deleted file mode 100644
index 0e0737f..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/URIFilter.java
+++ /dev/null
@@ -1,32 +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.client.api.uri.filter;
-
-/**
- * Interface for any available filter; obtain instances via <tt>FilterFactory</tt>.
- *
- * @see FilterFactory
- */
-public interface URIFilter {
-
- /**
- * @return String representation of this filter.
- */
- String build();
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterArgFactory.java
deleted file mode 100644
index 04554f5..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterArgFactory.java
+++ /dev/null
@@ -1,25 +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.client.api.uri.filter;
-
-public interface V3FilterArgFactory extends FilterArgFactory {
-
- FilterArg substringof(FilterArg first, FilterArg second);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterFactory.java
deleted file mode 100644
index 7571c98..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V3FilterFactory.java
+++ /dev/null
@@ -1,26 +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.client.api.uri.filter;
-
-public interface V3FilterFactory extends FilterFactory {
-
- @Override
- V3FilterArgFactory getArgFactory();
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterArgFactory.java
deleted file mode 100644
index b7bca85..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterArgFactory.java
+++ /dev/null
@@ -1,55 +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.client.api.uri.filter;
-
-public interface V4FilterArgFactory extends FilterArgFactory {
-
- FilterArg contains(FilterArg first, FilterArg second);
-
- FilterArg fractionalseconds(FilterArg param);
-
- FilterArg date(FilterArg param);
-
- FilterArg time(FilterArg param);
-
- FilterArg totaloffsetminutes(FilterArg param);
-
- FilterArg now();
-
- FilterArg mindatetime();
-
- FilterArg maxdatetime();
-
- FilterArg totalseconds(FilterArg param);
-
- FilterArg cast(FilterArg type);
-
- FilterArg cast(FilterArg expression, FilterArg type);
-
- FilterArg geoDistance(FilterArg first, FilterArg second);
-
- FilterArg geoIntersects(FilterArg first, FilterArg second);
-
- FilterArg geoLength(FilterArg first, FilterArg second);
-
- FilterArg any(FilterArg collection, URIFilter expression);
-
- FilterArg all(FilterArg collection, URIFilter expression);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterFactory.java
deleted file mode 100644
index 3050de2..0000000
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/filter/V4FilterFactory.java
+++ /dev/null
@@ -1,32 +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.client.api.uri.filter;
-
-import org.apache.olingo.commons.api.edm.EdmEnumType;
-
-public interface V4FilterFactory extends FilterFactory {
-
- @Override
- V4FilterArgFactory getArgFactory();
-
- URIFilter has(String key, EdmEnumType enumType, String memberName);
-
- URIFilter has(FilterArg left, EdmEnumType enumType, String memberName);
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterArgFactory.java
new file mode 100644
index 0000000..1a283f0
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterArgFactory.java
@@ -0,0 +1,28 @@
+/*
+ * 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.client.api.uri.v3;
+
+import org.apache.olingo.client.api.uri.FilterArg;
+import org.apache.olingo.client.api.uri.CommonFilterArgFactory;
+
+public interface FilterArgFactory extends CommonFilterArgFactory {
+
+ FilterArg substringof(FilterArg first, FilterArg second);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterFactory.java
new file mode 100644
index 0000000..1dcbac3
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/FilterFactory.java
@@ -0,0 +1,28 @@
+/*
+ * 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.client.api.uri.v3;
+
+import org.apache.olingo.client.api.uri.CommonFilterFactory;
+
+public interface FilterFactory extends CommonFilterFactory {
+
+ @Override
+ FilterArgFactory getArgFactory();
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/URIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/URIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/URIBuilder.java
new file mode 100644
index 0000000..72a0c03
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v3/URIBuilder.java
@@ -0,0 +1,49 @@
+/*
+ * 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.client.api.uri.v3;
+
+import org.apache.olingo.client.api.uri.CommonURIBuilder;
+
+public interface URIBuilder extends CommonURIBuilder<URIBuilder> {
+
+ public enum InlineCount {
+
+ allpages,
+ none
+
+ }
+
+ /**
+ * Appends links segment to the URI.
+ *
+ * @param segmentValue segment value
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendLinksSegment(String segmentValue);
+
+ /**
+ * Adds inlinecount query option.
+ *
+ * @param inlineCount value
+ * @return current URIBuilder instance
+ * @see QueryOption#INLINECOUNT
+ */
+ URIBuilder inlineCount(InlineCount inlineCount);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterArgFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterArgFactory.java
new file mode 100644
index 0000000..2222edd
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterArgFactory.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.client.api.uri.v4;
+
+import org.apache.olingo.client.api.uri.FilterArg;
+import org.apache.olingo.client.api.uri.CommonFilterArgFactory;
+import org.apache.olingo.client.api.uri.URIFilter;
+
+public interface FilterArgFactory extends CommonFilterArgFactory {
+
+ FilterArg contains(FilterArg first, FilterArg second);
+
+ FilterArg fractionalseconds(FilterArg param);
+
+ FilterArg date(FilterArg param);
+
+ FilterArg time(FilterArg param);
+
+ FilterArg totaloffsetminutes(FilterArg param);
+
+ FilterArg now();
+
+ FilterArg mindatetime();
+
+ FilterArg maxdatetime();
+
+ FilterArg totalseconds(FilterArg param);
+
+ FilterArg cast(FilterArg type);
+
+ FilterArg cast(FilterArg expression, FilterArg type);
+
+ FilterArg geoDistance(FilterArg first, FilterArg second);
+
+ FilterArg geoIntersects(FilterArg first, FilterArg second);
+
+ FilterArg geoLength(FilterArg first, FilterArg second);
+
+ FilterArg any(FilterArg collection, URIFilter expression);
+
+ FilterArg all(FilterArg collection, URIFilter expression);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterFactory.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterFactory.java
new file mode 100644
index 0000000..490f4bb
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/FilterFactory.java
@@ -0,0 +1,35 @@
+/*
+ * 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.client.api.uri.v4;
+
+import org.apache.olingo.client.api.uri.FilterArg;
+import org.apache.olingo.client.api.uri.CommonFilterFactory;
+import org.apache.olingo.client.api.uri.URIFilter;
+import org.apache.olingo.commons.api.edm.EdmEnumType;
+
+public interface FilterFactory extends CommonFilterFactory {
+
+ @Override
+ FilterArgFactory getArgFactory();
+
+ URIFilter has(String key, EdmEnumType enumType, String memberName);
+
+ URIFilter has(FilterArg left, EdmEnumType enumType, String memberName);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/URIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/URIBuilder.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/URIBuilder.java
new file mode 100644
index 0000000..5fc8a1d
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/uri/v4/URIBuilder.java
@@ -0,0 +1,89 @@
+/*
+ * 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.client.api.uri.v4;
+
+import org.apache.olingo.client.api.uri.CommonURIBuilder;
+
+public interface URIBuilder extends CommonURIBuilder<URIBuilder> {
+
+ /**
+ * Appends Singleton segment to the URI.
+ *
+ * @param segmentValue segment value.
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendSingletonSegment(String segmentValue);
+
+ /**
+ * Appends entity-id segment to the URI.
+ *
+ * @param segmentValue segment value
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendEntityIdSegment(String segmentValue);
+
+ /**
+ * Appends ref segment to the URI.
+ *
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendRefSegment();
+
+ /**
+ * Appends cross join segment to the URI.
+ *
+ * @param segmentValues segment values.
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendCrossjoinSegment(String... segmentValues);
+
+ /**
+ * Appends all segment to the URI.
+ *
+ * @return current URIBuilder instance
+ */
+ URIBuilder appendAllSegment();
+
+ /**
+ * Adds id query option.
+ *
+ * @param idValue opaque token.
+ * @return current URIBuilder instance
+ * @see QueryOption#ID
+ */
+ URIBuilder id(String idValue);
+
+ /**
+ * Appends count query option.
+ *
+ * @param value true or false
+ * @return current URIBuilder instance
+ * @see QueryOption#COUNT
+ */
+ URIBuilder count(boolean value);
+
+ /**
+ * Appends search query option.
+ *
+ * @param expression search expression
+ * @return current URIBuilder instance
+ * @see QueryOption#SEARCH
+ */
+ URIBuilder search(String expression);
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/utils/URIUtils.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/utils/URIUtils.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/utils/URIUtils.java
index f5c79dd..3885ead 100644
--- a/lib/client-api/src/main/java/org/apache/olingo/client/api/utils/URIUtils.java
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/utils/URIUtils.java
@@ -31,7 +31,7 @@ import org.apache.commons.codec.binary.Hex;
import org.apache.commons.io.IOUtils;
import org.apache.http.entity.InputStreamEntity;
import org.apache.olingo.client.api.Constants;
-import org.apache.olingo.client.api.ODataClient;
+import org.apache.olingo.client.api.CommonODataClient;
import org.apache.olingo.client.api.domain.ODataJClientEdmPrimitiveType;
import org.apache.olingo.client.api.domain.ODataDuration;
import org.apache.olingo.client.api.domain.ODataTimestamp;
@@ -176,7 +176,7 @@ public final class URIUtils {
return value;
}
- public static InputStreamEntity buildInputStreamEntity(final ODataClient client, final InputStream input) {
+ public static InputStreamEntity buildInputStreamEntity(final CommonODataClient client, final InputStream input) {
InputStreamEntity entity;
if (client.getConfiguration().isUseChuncked()) {
entity = new InputStreamEntity(input, -1);
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/Configuration.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/Configuration.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/Configuration.java
new file mode 100644
index 0000000..d51d334
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/Configuration.java
@@ -0,0 +1,46 @@
+/*
+ * 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.client.api.v3;
+
+import org.apache.olingo.client.api.CommonConfiguration;
+
+public interface Configuration extends CommonConfiguration {
+
+ /**
+ * Checks whether URIs contain entity key between parentheses (standard) or instead as additional segment.
+ * <br/>
+ * Example: http://services.odata.org/V4/OData/OData.svc/Products(0) or
+ * http://services.odata.org/V4/OData/OData.svc/Products/0
+ *
+ * @return whether URIs shall be built with entity key between parentheses (standard) or instead as additional
+ * segment.
+ */
+ boolean isKeyAsSegment();
+
+ /**
+ * Sets whether URIs shall be built with entity key between parentheses (standard) or instead as additional segment.
+ * <br/>
+ * Example: http://services.odata.org/V4/OData/OData.svc/Products(0) or
+ * http://services.odata.org/V4/OData/OData.svc/Products/0
+ *
+ * @param value 'TRUE' to use this feature.
+ */
+ void setKeyAsSegment(boolean value);
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/ODataClient.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/ODataClient.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/ODataClient.java
new file mode 100644
index 0000000..5959796
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/ODataClient.java
@@ -0,0 +1,67 @@
+/*
+ * 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.client.api.v3;
+
+import org.apache.olingo.client.api.CommonODataClient;
+import org.apache.olingo.client.api.communication.request.batch.v3.BatchRequestFactory;
+import org.apache.olingo.client.api.communication.request.cud.v3.CUDRequestFactory;
+import org.apache.olingo.client.api.communication.request.invoke.v3.InvokeRequestFactory;
+import org.apache.olingo.client.api.communication.request.retrieve.v3.RetrieveRequestFactory;
+import org.apache.olingo.client.api.communication.request.streamed.v3.StreamedRequestFactory;
+import org.apache.olingo.client.api.op.v3.ODataBinder;
+import org.apache.olingo.client.api.op.v3.ODataDeserializer;
+import org.apache.olingo.client.api.op.v3.ODataReader;
+import org.apache.olingo.client.api.uri.v3.URIBuilder;
+import org.apache.olingo.client.api.uri.v3.FilterFactory;
+
+public interface ODataClient extends CommonODataClient {
+
+ @Override
+ ODataDeserializer getDeserializer();
+
+ @Override
+ ODataReader getReader();
+
+ @Override
+ ODataBinder getBinder();
+
+ @Override
+ Configuration getConfiguration();
+
+ @Override
+ URIBuilder getURIBuilder(String serviceRoot);
+
+ @Override
+ FilterFactory getFilterFactory();
+
+ @Override
+ RetrieveRequestFactory getRetrieveRequestFactory();
+
+ @Override
+ CUDRequestFactory getCUDRequestFactory();
+
+ @Override
+ StreamedRequestFactory getStreamedRequestFactory();
+
+ @Override
+ InvokeRequestFactory getInvokeRequestFactory();
+
+ @Override
+ BatchRequestFactory getBatchRequestFactory();
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/UnsupportedInV3Exception.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/UnsupportedInV3Exception.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/UnsupportedInV3Exception.java
new file mode 100644
index 0000000..d30398a
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/v3/UnsupportedInV3Exception.java
@@ -0,0 +1,31 @@
+/*
+ * 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.client.api.v3;
+
+import org.apache.olingo.commons.api.edm.EdmException;
+
+public class UnsupportedInV3Exception extends EdmException {
+
+ private static final long serialVersionUID = 4773734640262424651L;
+
+ public UnsupportedInV3Exception() {
+ super("Not supported in OData 3.0");
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/Configuration.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/Configuration.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/Configuration.java
new file mode 100644
index 0000000..f7daa91
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/Configuration.java
@@ -0,0 +1,26 @@
+/*
+ * 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.client.api.v4;
+
+import org.apache.olingo.client.api.CommonConfiguration;
+
+public interface Configuration extends CommonConfiguration {
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/ODataClient.java
----------------------------------------------------------------------
diff --git a/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/ODataClient.java b/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/ODataClient.java
new file mode 100644
index 0000000..afe3c70
--- /dev/null
+++ b/lib/client-api/src/main/java/org/apache/olingo/client/api/v4/ODataClient.java
@@ -0,0 +1,67 @@
+/*
+ * 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.client.api.v4;
+
+import org.apache.olingo.client.api.CommonODataClient;
+import org.apache.olingo.client.api.communication.request.batch.v4.BatchRequestFactory;
+import org.apache.olingo.client.api.communication.request.cud.v4.CUDRequestFactory;
+import org.apache.olingo.client.api.communication.request.invoke.v4.InvokeRequestFactory;
+import org.apache.olingo.client.api.communication.request.retrieve.v4.RetrieveRequestFactory;
+import org.apache.olingo.client.api.communication.request.streamed.v4.StreamedRequestFactory;
+import org.apache.olingo.client.api.op.v4.ODataBinder;
+import org.apache.olingo.client.api.op.v4.ODataDeserializer;
+import org.apache.olingo.client.api.op.v4.ODataReader;
+import org.apache.olingo.client.api.uri.v4.URIBuilder;
+import org.apache.olingo.client.api.uri.v4.FilterFactory;
+
+public interface ODataClient extends CommonODataClient {
+
+ @Override
+ ODataDeserializer getDeserializer();
+
+ @Override
+ ODataReader getReader();
+
+ @Override
+ ODataBinder getBinder();
+
+ @Override
+ Configuration getConfiguration();
+
+ @Override
+ URIBuilder getURIBuilder(String serviceRoot);
+
+ @Override
+ FilterFactory getFilterFactory();
+
+ @Override
+ RetrieveRequestFactory getRetrieveRequestFactory();
+
+ @Override
+ CUDRequestFactory getCUDRequestFactory();
+
+ @Override
+ StreamedRequestFactory getStreamedRequestFactory();
+
+ @Override
+ InvokeRequestFactory getInvokeRequestFactory();
+
+ @Override
+ BatchRequestFactory getBatchRequestFactory();
+}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractConfiguration.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractConfiguration.java b/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractConfiguration.java
index eba44e3..5c32aec 100644
--- a/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractConfiguration.java
+++ b/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractConfiguration.java
@@ -23,7 +23,7 @@ import java.util.Map;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
-import org.apache.olingo.client.api.Configuration;
+import org.apache.olingo.client.api.CommonConfiguration;
import org.apache.olingo.client.api.format.ODataFormat;
import org.apache.olingo.client.api.format.ODataMediaFormat;
import org.apache.olingo.client.api.format.ODataPubFormat;
@@ -33,7 +33,7 @@ import org.apache.olingo.client.api.http.HttpUriRequestFactory;
import org.apache.olingo.client.core.http.DefaultHttpClientFactory;
import org.apache.olingo.client.core.http.DefaultHttpUriRequestFactory;
-public abstract class AbstractConfiguration implements Configuration {
+public abstract class AbstractConfiguration implements CommonConfiguration {
private static final String DEFAULT_PUB_FORMAT = "pubFormat";
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractODataClient.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractODataClient.java b/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractODataClient.java
index eb06136..52d5d1c 100644
--- a/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractODataClient.java
+++ b/lib/client-core/src/main/java/org/apache/olingo/client/core/AbstractODataClient.java
@@ -18,7 +18,7 @@
*/
package org.apache.olingo.client.core;
-import org.apache.olingo.client.api.ODataClient;
+import org.apache.olingo.client.api.CommonODataClient;
import org.apache.olingo.client.api.domain.ODataGeospatialValue;
import org.apache.olingo.client.api.domain.ODataObjectFactory;
import org.apache.olingo.client.api.domain.ODataPrimitiveValue;
@@ -26,7 +26,7 @@ import org.apache.olingo.client.api.op.ODataWriter;
import org.apache.olingo.client.core.op.impl.ODataObjectFactoryImpl;
import org.apache.olingo.client.core.op.impl.ODataWriterImpl;
-abstract class AbstractODataClient implements ODataClient {
+public abstract class AbstractODataClient implements CommonODataClient {
private static final long serialVersionUID = 7269096702397630265L;
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataClientFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataClientFactory.java b/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataClientFactory.java
index f45b725..e0fcd76 100644
--- a/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataClientFactory.java
+++ b/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataClientFactory.java
@@ -18,17 +18,14 @@
*/
package org.apache.olingo.client.core;
-import org.apache.olingo.client.api.ODataV3Client;
-import org.apache.olingo.client.api.ODataV4Client;
-
public final class ODataClientFactory {
- public static ODataV3Client getV3() {
- return new ODataV3ClientImpl();
+ public static org.apache.olingo.client.api.v3.ODataClient getV3() {
+ return new org.apache.olingo.client.core.v3.ODataClientImpl();
}
- public static ODataV4Client getV4() {
- return new ODataV4ClientImpl();
+ public static org.apache.olingo.client.api.v4.ODataClient getV4() {
+ return new org.apache.olingo.client.core.v4.ODataClientImpl();
}
private ODataClientFactory() {
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/bab03624/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataV3ClientImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataV3ClientImpl.java b/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataV3ClientImpl.java
deleted file mode 100644
index 1146c94..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/client/core/ODataV3ClientImpl.java
+++ /dev/null
@@ -1,149 +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.client.core;
-
-import org.apache.olingo.client.api.ODataV3Client;
-import org.apache.olingo.client.api.V3Configuration;
-import org.apache.olingo.client.api.communication.header.HeaderName;
-import org.apache.olingo.client.api.communication.header.ODataHeaders;
-import org.apache.olingo.client.api.communication.request.batch.V3BatchRequestFactory;
-import org.apache.olingo.client.api.communication.request.cud.V3CUDRequestFactory;
-import org.apache.olingo.client.api.communication.request.invoke.V3InvokeRequestFactory;
-import org.apache.olingo.client.api.communication.request.retrieve.V3RetrieveRequestFactory;
-import org.apache.olingo.client.api.communication.request.streamed.V3StreamedRequestFactory;
-import org.apache.olingo.client.api.op.ODataBinder;
-import org.apache.olingo.client.api.op.ODataReader;
-import org.apache.olingo.client.api.op.ODataSerializer;
-import org.apache.olingo.client.api.op.ODataV3Deserializer;
-import org.apache.olingo.client.api.uri.V3URIBuilder;
-import org.apache.olingo.client.api.uri.filter.V3FilterFactory;
-import org.apache.olingo.client.core.communication.header.ODataHeadersImpl;
-import org.apache.olingo.client.core.communication.request.batch.V3BatchRequestFactoryImpl;
-import org.apache.olingo.client.core.communication.request.cud.V3CUDRequestFactoryImpl;
-import org.apache.olingo.client.core.communication.request.invoke.V3InvokeRequestFactoryImpl;
-import org.apache.olingo.client.core.communication.request.retrieve.V3RetrieveRequestFactoryImpl;
-import org.apache.olingo.client.core.communication.request.streamed.V3StreamedRequestFactoryImpl;
-import org.apache.olingo.client.core.op.impl.ODataV3BinderImpl;
-import org.apache.olingo.client.core.op.impl.ODataV3DeserializerImpl;
-import org.apache.olingo.client.core.op.impl.ODataV3ReaderImpl;
-import org.apache.olingo.client.core.op.impl.ODataV3SerializerImpl;
-import org.apache.olingo.client.core.uri.V3URIBuilderImpl;
-import org.apache.olingo.client.core.uri.filter.V3FilterFactoryImpl;
-import org.apache.olingo.commons.api.edm.constants.ODataServiceVersion;
-
-public class ODataV3ClientImpl extends AbstractODataClient implements ODataV3Client {
-
- private static final long serialVersionUID = -1655712193243609209L;
-
- private final V3Configuration configuration = new V3ConfigurationImpl();
-
- private final V3FilterFactory filterFactory = new V3FilterFactoryImpl();
-
- private final ODataV3Deserializer deserializer = new ODataV3DeserializerImpl(this);
-
- private final ODataSerializer serializer = new ODataV3SerializerImpl(this);
-
- private final ODataReader reader = new ODataV3ReaderImpl(this);
-
- private final ODataBinder binder = new ODataV3BinderImpl(this);
-
- private final V3RetrieveRequestFactory retrieveReqFact = new V3RetrieveRequestFactoryImpl(this);
-
- private final V3CUDRequestFactory cudReqFact = new V3CUDRequestFactoryImpl(this);
-
- private final V3StreamedRequestFactory streamedReqFact = new V3StreamedRequestFactoryImpl(this);
-
- private final V3InvokeRequestFactory invokeReqFact = new V3InvokeRequestFactoryImpl(this);
-
- private final V3BatchRequestFactory batchReqFact = new V3BatchRequestFactoryImpl(this);
-
- @Override
- public ODataServiceVersion getServiceVersion() {
- return ODataServiceVersion.V30;
- }
-
- @Override
- public ODataHeaders getVersionHeaders() {
- final ODataHeadersImpl odataHeaders = new ODataHeadersImpl();
- odataHeaders.setHeader(HeaderName.minDataServiceVersion, ODataServiceVersion.V30.toString());
- odataHeaders.setHeader(HeaderName.maxDataServiceVersion, ODataServiceVersion.V30.toString());
- odataHeaders.setHeader(HeaderName.dataServiceVersion, ODataServiceVersion.V30.toString());
- return odataHeaders;
- }
-
- @Override
- public V3Configuration getConfiguration() {
- return configuration;
- }
-
- @Override
- public V3URIBuilder getURIBuilder(final String serviceRoot) {
- return new V3URIBuilderImpl(configuration, serviceRoot);
- }
-
- @Override
- public V3FilterFactory getFilterFactory() {
- return filterFactory;
- }
-
- @Override
- public ODataV3Deserializer getDeserializer() {
- return deserializer;
- }
-
- @Override
- public ODataSerializer getSerializer() {
- return serializer;
- }
-
- @Override
- public ODataReader getReader() {
- return reader;
- }
-
- @Override
- public ODataBinder getBinder() {
- return binder;
- }
-
- @Override
- public V3RetrieveRequestFactory getRetrieveRequestFactory() {
- return retrieveReqFact;
- }
-
- @Override
- public V3CUDRequestFactory getCUDRequestFactory() {
- return cudReqFact;
- }
-
- @Override
- public V3StreamedRequestFactory getStreamedRequestFactory() {
- return streamedReqFact;
- }
-
- @Override
- public V3InvokeRequestFactory getInvokeRequestFactory() {
- return invokeReqFact;
- }
-
- @Override
- public V3BatchRequestFactory getBatchRequestFactory() {
- return batchReqFact;
- }
-}