You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@olingo.apache.org by sk...@apache.org on 2014/03/10 10:02:41 UTC
[25/51] [abbrv] [partial] [OLINGO-192] rename java packages
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4DeserializerImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4DeserializerImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4DeserializerImpl.java
deleted file mode 100644
index 4bd6ff2..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4DeserializerImpl.java
+++ /dev/null
@@ -1,70 +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.odata4.client.core.op.impl;
-
-import java.io.IOException;
-import java.io.InputStream;
-import org.apache.olingo.odata4.client.api.ODataClient;
-import org.apache.olingo.odata4.client.api.data.ServiceDocument;
-import org.apache.olingo.odata4.client.api.edm.xml.v4.XMLMetadata;
-import org.apache.olingo.odata4.client.api.format.ODataFormat;
-import org.apache.olingo.odata4.client.api.op.ODataV4Deserializer;
-import org.apache.olingo.odata4.client.core.data.v4.JSONServiceDocumentImpl;
-import org.apache.olingo.odata4.client.core.data.v4.XMLServiceDocumentImpl;
-import org.apache.olingo.odata4.client.core.op.impl.AbstractODataDeserializer;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.EdmxImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.XMLMetadataImpl;
-
-public class ODataV4DeserializerImpl extends AbstractODataDeserializer implements ODataV4Deserializer {
-
- private static final long serialVersionUID = 8593081342440470415L;
-
- public ODataV4DeserializerImpl(final ODataClient client) {
- super(client);
- }
-
- @Override
- public XMLMetadata toMetadata(final InputStream input) {
- try {
- return new XMLMetadataImpl(getXmlMapper().readValue(input, EdmxImpl.class));
- } catch (Exception e) {
- throw new IllegalArgumentException("Could not parse as Edmx document", e);
- }
- }
-
- @Override
- public ServiceDocument toServiceDocument(final InputStream input, final ODataFormat format) {
- try {
- return format == ODataFormat.XML
- ? getXmlMapper().readValue(input, XMLServiceDocumentImpl.class)
- : getObjectMapper().readValue(input, JSONServiceDocumentImpl.class);
- } catch (IOException e) {
- throw new IllegalArgumentException("Could not parse Service Document", e);
- }
- }
-
-// @Override
-// protected JSONEntry toJSONEntry(final InputStream input) {
-// try {
-// return getObjectMapper().readValue(input, JSONEntry.class);
-// } catch (IOException e) {
-// throw new IllegalArgumentException("While deserializing JSON entry", e);
-// }
-// }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4ReaderImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4ReaderImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4ReaderImpl.java
deleted file mode 100644
index 5aa76a7..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4ReaderImpl.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.odata4.client.core.op.impl;
-
-import java.io.InputStream;
-import org.apache.olingo.odata4.client.api.domain.ODataServiceDocument;
-import org.apache.olingo.odata4.client.api.format.ODataFormat;
-import org.apache.olingo.odata4.client.core.ODataV4ClientImpl;
-import org.apache.olingo.odata4.client.core.edm.EdmClientImpl;
-import org.apache.olingo.odata4.client.core.op.impl.AbstractODataReader;
-import org.apache.olingo.odata4.commons.api.edm.Edm;
-
-public class ODataV4ReaderImpl extends AbstractODataReader {
-
- private static final long serialVersionUID = -2481293269536406956L;
-
- public ODataV4ReaderImpl(final ODataV4ClientImpl client) {
- super(client);
- }
-
- @Override
- public Edm readMetadata(final InputStream input) {
- return new EdmClientImpl(client.getDeserializer().toMetadata(input));
- }
-
- @Override
- public ODataServiceDocument readServiceDocument(final InputStream input, final ODataFormat format) {
- return ((ODataV4ClientImpl) client).getBinder().getODataServiceDocument(
- ((ODataV4ClientImpl) client).getDeserializer().toServiceDocument(input, format));
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4SerializerImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4SerializerImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4SerializerImpl.java
deleted file mode 100644
index 774da59..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/ODataV4SerializerImpl.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.odata4.client.core.op.impl;
-
-import org.apache.olingo.odata4.client.api.ODataClient;
-import org.apache.olingo.odata4.client.core.op.impl.AbstractODataSerializer;
-
-public class ODataV4SerializerImpl extends AbstractODataSerializer {
-
- private static final long serialVersionUID = 7587265188399685309L;
-
- public ODataV4SerializerImpl(final ODataClient client) {
- super(client);
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/SchemaDeserializer.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/SchemaDeserializer.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/SchemaDeserializer.java
deleted file mode 100644
index c17c4cd..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/op/impl/SchemaDeserializer.java
+++ /dev/null
@@ -1,147 +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.odata4.client.core.op.impl;
-
-import com.fasterxml.jackson.core.JsonParser;
-import com.fasterxml.jackson.core.JsonProcessingException;
-import com.fasterxml.jackson.core.JsonToken;
-import com.fasterxml.jackson.databind.DeserializationContext;
-import java.io.IOException;
-import org.apache.olingo.odata4.client.core.edm.xml.AbstractSchema;
-import org.apache.olingo.odata4.client.core.edm.xml.v3.AssociationImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v3.UsingImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v3.ValueTermImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.ActionImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.AnnotationImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.FunctionImpl;
-import org.apache.olingo.odata4.client.core.edm.xml.v4.TypeDefinitionImpl;
-import org.apache.olingo.odata4.commons.api.edm.constants.ODataServiceVersion;
-
-@SuppressWarnings("rawtypes")
-public class SchemaDeserializer extends AbstractEdmDeserializer<AbstractSchema> {
-
- @Override
- protected AbstractSchema doDeserialize(final JsonParser jp, final DeserializationContext ctxt)
- throws IOException, JsonProcessingException {
-
- final AbstractSchema schema = ODataServiceVersion.V30 == client.getServiceVersion()
- ? new org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl()
- : new org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl();
-
- for (; jp.getCurrentToken() != JsonToken.END_OBJECT; jp.nextToken()) {
- final JsonToken token = jp.getCurrentToken();
- if (token == JsonToken.FIELD_NAME) {
- if ("Namespace".equals(jp.getCurrentName())) {
- schema.setNamespace(jp.nextTextValue());
- } else if ("Alias".equals(jp.getCurrentName())) {
- schema.setAlias(jp.nextTextValue());
- } else if ("Using".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getUsings().add(jp.readValueAs( UsingImpl.class));
- } else if ("Association".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getAssociations().add(jp.readValueAs( AssociationImpl.class));
- } else if ("ComplexType".equals(jp.getCurrentName())) {
- jp.nextToken();
- if (schema instanceof org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) {
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getComplexTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v3.ComplexTypeImpl.class));
- } else {
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).
- getComplexTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v4.ComplexTypeImpl.class));
- }
- } else if ("EntityType".equals(jp.getCurrentName())) {
- jp.nextToken();
- if (schema instanceof org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) {
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getEntityTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v3.EntityTypeImpl.class));
- } else {
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).
- getEntityTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v4.EntityTypeImpl.class));
- }
- } else if ("EnumType".equals(jp.getCurrentName())) {
- jp.nextToken();
- if (schema instanceof org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) {
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getEnumTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v3.EnumTypeImpl.class));
- } else {
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).
- getEnumTypes().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v4.EnumTypeImpl.class));
- }
- } else if ("ValueTerm".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getValueTerms().add(jp.readValueAs( ValueTermImpl.class));
- } else if ("EntityContainer".equals(jp.getCurrentName())) {
- jp.nextToken();
-
- if (schema instanceof org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) {
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).
- getEntityContainers().add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v3.EntityContainerImpl.class));
- } else {
- org.apache.olingo.odata4.client.core.edm.xml.v4.EntityContainerImpl entityContainer
- = jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v4.EntityContainerImpl.class);
- entityContainer.setDefaultEntityContainer(true);
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).
- setEntityContainer(entityContainer);
- }
- } else if ("Annotations".equals(jp.getCurrentName())) {
- jp.nextToken();
- if (schema instanceof org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) {
- ((org.apache.olingo.odata4.client.core.edm.xml.v3.SchemaImpl) schema).getAnnotationsList().
- add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v3.AnnotationsImpl.class));
- } else {
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).getAnnotationsList().
- add(jp.readValueAs(
- org.apache.olingo.odata4.client.core.edm.xml.v4.AnnotationsImpl.class));
- }
- } else if ("Action".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).getActions().
- add(jp.readValueAs( ActionImpl.class));
- } else if ("Annotation".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).getAnnotations().
- add(jp.readValueAs( AnnotationImpl.class));
- } else if ("Function".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).getFunctions().
- add(jp.readValueAs( FunctionImpl.class));
- } else if ("TypeDefinition".equals(jp.getCurrentName())) {
- jp.nextToken();
- ((org.apache.olingo.odata4.client.core.edm.xml.v4.SchemaImpl) schema).
- getTypeDefinitions().add(jp.readValueAs( TypeDefinitionImpl.class));
- }
- }
- }
-
- return schema;
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/AbstractURIBuilder.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/AbstractURIBuilder.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/AbstractURIBuilder.java
deleted file mode 100644
index a92ee5c..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/AbstractURIBuilder.java
+++ /dev/null
@@ -1,273 +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.odata4.client.core.uri;
-
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.util.ArrayList;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.olingo.odata4.client.api.uri.QueryOption;
-import org.apache.olingo.odata4.client.api.uri.SegmentType;
-import org.apache.olingo.odata4.client.api.uri.URIBuilder;
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class AbstractURIBuilder<UB extends URIBuilder<?>> implements URIBuilder<UB> {
-
- private static final long serialVersionUID = -3267515371720408124L;
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(URIBuilder.class);
-
- protected static class Segment {
-
- private final SegmentType type;
-
- private final String value;
-
- public Segment(final SegmentType type, final String value) {
- this.type = type;
- this.value = value;
- }
-
- public SegmentType getType() {
- return type;
- }
-
- public String getValue() {
- return value;
- }
-
- }
-
- protected final List<Segment> segments = new ArrayList<Segment>();
-
- /**
- * Insertion-order map of query options.
- */
- protected final Map<String, String> queryOptions = new LinkedHashMap<String, String>();
-
- /**
- * Constructor.
- *
- * @param serviceRoot absolute URL (schema, host and port included) representing the location of the root of the data
- * service.
- */
- protected AbstractURIBuilder(final String serviceRoot) {
- segments.add(new Segment(SegmentType.SERVICEROOT, serviceRoot));
- }
-
- protected abstract UB getThis();
-
- @Override
- public UB addQueryOption(final QueryOption option, final String value) {
- return addQueryOption(option.toString(), value);
- }
-
- @Override
- public UB addQueryOption(final String option, final String value) {
- queryOptions.put(option, value);
- return getThis();
- }
-
- @Override
- public UB appendEntitySetSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.ENTITYSET, segmentValue));
- return getThis();
- }
-
- @Override
- public UB appendKeySegment(final Object val) {
- final String segValue = URIUtils.escape(val);
-
- segments.add(new Segment(SegmentType.KEY, "(" + segValue + ")"));
- return getThis();
- }
-
- protected abstract String noKeysWrapper();
-
- @Override
- public UB appendKeySegment(final Map<String, Object> segmentValues) {
- if (segmentValues == null || segmentValues.isEmpty()) {
- segments.add(new Segment(SegmentType.KEY, noKeysWrapper()));
- } else {
- final StringBuilder keyBuilder = new StringBuilder().append('(');
- for (Map.Entry<String, Object> entry : segmentValues.entrySet()) {
- keyBuilder.append(entry.getKey()).append('=').append(URIUtils.escape(entry.getValue()));
- keyBuilder.append(',');
- }
- keyBuilder.deleteCharAt(keyBuilder.length() - 1).append(')');
-
- segments.add(new Segment(SegmentType.KEY, keyBuilder.toString()));
- }
-
- return getThis();
- }
-
- @Override
- public UB appendPropertySegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.PROPERTY, segmentValue));
- return getThis();
-
- }
-
- @Override
- public UB appendNavigationSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.NAVIGATION, segmentValue));
- return getThis();
- }
-
- @Override
- public UB appendDerivedEntityTypeSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.DERIVED_ENTITY_TYPE, segmentValue));
- return getThis();
- }
-
- @Override
- public UB appendValueSegment() {
- segments.add(new Segment(SegmentType.VALUE, SegmentType.VALUE.getValue()));
- return getThis();
- }
-
- @Override
- public UB appendOperationCallSegment(final String operation, final Map<String, Object> arguments) {
- segments.add(new Segment(
- segments.size() == 1 ? SegmentType.UNBOUND_OPERATION : SegmentType.BOUND_OPERATION, operation));
- return appendKeySegment(arguments);
- }
-
- @Override
- public UB appendMetadataSegment() {
- segments.add(new Segment(SegmentType.METADATA, SegmentType.METADATA.getValue()));
- return getThis();
- }
-
- @Override
- public UB appendBatchSegment() {
- segments.add(new Segment(SegmentType.BATCH, SegmentType.BATCH.getValue()));
- return getThis();
- }
-
- @Override
- public UB count() {
- segments.add(new Segment(SegmentType.ROOT_QUERY_OPTION, "$" + QueryOption.COUNT.toString()));
- return getThis();
- }
-
- @Override
- public UB expand(final String... expandItems) {
- return addQueryOption(QueryOption.EXPAND, StringUtils.join(expandItems, ","));
- }
-
- @Override
- public UB format(final String format) {
- return addQueryOption(QueryOption.FORMAT, format);
- }
-
- @Override
- public UB filter(final URIFilter filter) {
- return addQueryOption(QueryOption.FILTER, filter.build());
- }
-
- @Override
- public UB filter(final String filter) {
- return addQueryOption(QueryOption.FILTER, filter);
- }
-
- @Override
- public UB select(final String... selectItems) {
- return addQueryOption(QueryOption.SELECT, StringUtils.join(selectItems, ","));
- }
-
- @Override
- public UB orderBy(final String order) {
- return addQueryOption(QueryOption.ORDERBY, order);
- }
-
- @Override
- public UB top(final int top) {
- return addQueryOption(QueryOption.TOP, String.valueOf(top));
- }
-
- @Override
- public UB skip(final int skip) {
- return addQueryOption(QueryOption.SKIP, String.valueOf(skip));
- }
-
- @Override
- public UB skipToken(final String skipToken) {
- return addQueryOption(QueryOption.SKIPTOKEN, skipToken);
- }
-
- protected abstract char getBoundOperationSeparator();
-
- protected abstract char getDerivedEntityTypeSeparator();
-
- @Override
- public URI build() {
- final StringBuilder segmentsBuilder = new StringBuilder();
- for (Segment seg : segments) {
- if (segmentsBuilder.length() > 0 && seg.getType() != SegmentType.KEY) {
- switch (seg.getType()) {
- case BOUND_OPERATION:
- segmentsBuilder.append(getBoundOperationSeparator());
- break;
-
- case DERIVED_ENTITY_TYPE:
- segmentsBuilder.append(getDerivedEntityTypeSeparator());
- break;
-
- default:
- segmentsBuilder.append('/');
- }
- }
-
- if (seg.getType() == SegmentType.ENTITY) {
- segmentsBuilder.append(seg.getType().getValue());
- } else {
- segmentsBuilder.append(seg.getValue());
- }
- }
-
- try {
- final org.apache.http.client.utils.URIBuilder builder =
- new org.apache.http.client.utils.URIBuilder(segmentsBuilder.toString());
-
- for (Map.Entry<String, String> option : queryOptions.entrySet()) {
- builder.addParameter("$" + option.getKey(), option.getValue());
- }
-
- return builder.build().normalize();
- } catch (URISyntaxException e) {
- throw new IllegalArgumentException("Could not build valid URI", e);
- }
- }
-
- @Override
- public String toString() {
- return build().toASCIIString();
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/URIUtils.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/URIUtils.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/URIUtils.java
deleted file mode 100644
index 70812ea..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/URIUtils.java
+++ /dev/null
@@ -1,195 +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.odata4.client.core.uri;
-
-import java.io.ByteArrayInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.math.BigDecimal;
-import java.net.URI;
-import java.net.URLEncoder;
-import java.text.DecimalFormat;
-import java.util.UUID;
-import org.apache.commons.codec.binary.Hex;
-import org.apache.commons.io.IOUtils;
-import org.apache.http.entity.InputStreamEntity;
-import org.apache.olingo.odata4.client.api.ODataClient;
-import org.apache.olingo.odata4.client.api.ODataConstants;
-import org.apache.olingo.odata4.client.api.domain.EdmSimpleType;
-import org.apache.olingo.odata4.client.api.domain.ODataDuration;
-import org.apache.olingo.odata4.client.api.domain.ODataTimestamp;
-import org.apache.olingo.odata4.client.api.edm.xml.CommonFunctionImport;
-import org.apache.olingo.odata4.client.api.edm.xml.EntityContainer;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * URI utilities.
- */
-public final class URIUtils {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(URIUtils.class);
-
- private URIUtils() {
- // Empty private constructor for static utility classes
- }
-
- /**
- * Build URI starting from the given base and href.
- * <br/>
- * If href is absolute or base is null then base will be ignored.
- *
- * @param base URI prefix.
- * @param href URI suffix.
- * @return built URI.
- */
- public static URI getURI(final String base, final String href) {
- if (href == null) {
- throw new IllegalArgumentException("Null link provided");
- }
-
- URI uri = URI.create(href);
-
- if (!uri.isAbsolute() && base != null) {
- uri = URI.create(base + "/" + href);
- }
-
- return uri.normalize();
- }
-
- /**
- * Build URI starting from the given base and href.
- * <br/>
- * If href is absolute or base is null then base will be ignored.
- *
- * @param base URI prefix.
- * @param href URI suffix.
- * @return built URI.
- */
- public static URI getURI(final URI base, final URI href) {
- if (href == null) {
- throw new IllegalArgumentException("Null link provided");
- }
- return getURI(base, href.toASCIIString());
- }
-
- /**
- * Build URI starting from the given base and href.
- * <br/>
- * If href is absolute or base is null then base will be ignored.
- *
- * @param base URI prefix.
- * @param href URI suffix.
- * @return built URI.
- */
- public static URI getURI(final URI base, final String href) {
- if (href == null) {
- throw new IllegalArgumentException("Null link provided");
- }
-
- URI uri = URI.create(href);
-
- if (!uri.isAbsolute() && base != null) {
- uri = URI.create(base.toASCIIString() + "/" + href);
- }
-
- return uri.normalize();
- }
-
- /**
- * Gets function import URI segment.
- *
- * @param entityContainer entity container.
- * @param functionImport function import.
- * @return URI segment.
- */
- public static String rootFunctionImportURISegment(
- final EntityContainer entityContainer, final CommonFunctionImport functionImport) {
-
- final StringBuilder result = new StringBuilder();
- if (!entityContainer.isDefaultEntityContainer()) {
- result.append(entityContainer.getName()).append('.');
- }
- result.append(functionImport.getName());
-
- return result.toString();
- }
-
- /**
- * Turns primitive values into their respective URI representation.
- *
- * @param obj primitive value
- * @return URI representation
- */
- public static String escape(final Object obj) {
- String value;
-
- try {
- value = (obj instanceof UUID)
- ? "guid'" + obj.toString() + "'"
- : (obj instanceof byte[])
- ? "X'" + Hex.encodeHexString((byte[]) obj) + "'"
- : ((obj instanceof ODataTimestamp) && ((ODataTimestamp) obj).getTimezone() == null)
- ? "datetime'" + URLEncoder.encode(((ODataTimestamp) obj).toString(), ODataConstants.UTF8) + "'"
- : ((obj instanceof ODataTimestamp) && ((ODataTimestamp) obj).getTimezone() != null)
- ? "datetimeoffset'" + URLEncoder.encode(((ODataTimestamp) obj).toString(), ODataConstants.UTF8)
- + "'"
- : (obj instanceof ODataDuration)
- ? "time'" + ((ODataDuration) obj).toString() + "'"
- : (obj instanceof BigDecimal)
- ? new DecimalFormat(EdmSimpleType.Decimal.pattern()).format((BigDecimal) obj) + "M"
- : (obj instanceof Double)
- ? new DecimalFormat(EdmSimpleType.Double.pattern()).format((Double) obj) + "D"
- : (obj instanceof Float)
- ? new DecimalFormat(EdmSimpleType.Single.pattern()).format((Float) obj) + "f"
- : (obj instanceof Long)
- ? ((Long) obj).toString() + "L"
- : (obj instanceof String)
- ? "'" + URLEncoder.encode((String) obj, ODataConstants.UTF8) + "'"
- : obj.toString();
- } catch (Exception e) {
- LOG.warn("While escaping '{}', using toString()", obj, e);
- value = obj.toString();
- }
-
- return value;
- }
-
- public static InputStreamEntity buildInputStreamEntity(final ODataClient client, final InputStream input) {
- InputStreamEntity entity;
- if (client.getConfiguration().isUseChuncked()) {
- entity = new InputStreamEntity(input, -1);
- } else {
- byte[] bytes = new byte[0];
- try {
- bytes = IOUtils.toByteArray(input);
- } catch (IOException e) {
- LOG.error("While reading input for not chunked encoding", e);
- }
-
- entity = new InputStreamEntity(new ByteArrayInputStream(bytes), bytes.length);
- }
- entity.setChunked(client.getConfiguration().isUseChuncked());
-
- return entity;
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V3URIBuilderImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V3URIBuilderImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V3URIBuilderImpl.java
deleted file mode 100644
index c721000..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V3URIBuilderImpl.java
+++ /dev/null
@@ -1,93 +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.odata4.client.core.uri;
-
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.olingo.odata4.client.api.V3Configuration;
-import org.apache.olingo.odata4.client.api.uri.QueryOption;
-import org.apache.olingo.odata4.client.api.uri.SegmentType;
-import org.apache.olingo.odata4.client.api.uri.V3URIBuilder;
-
-public class V3URIBuilderImpl extends AbstractURIBuilder<V3URIBuilder> implements V3URIBuilder {
-
- private static final long serialVersionUID = -3506851722447870532L;
-
- private final V3Configuration configuration;
-
- public V3URIBuilderImpl(final V3Configuration configuration, final String serviceRoot) {
- super(serviceRoot);
- this.configuration = configuration;
- }
-
- @Override
- protected V3URIBuilder getThis() {
- return this;
- }
-
- @Override
- protected char getBoundOperationSeparator() {
- return '/';
- }
-
- @Override
- protected char getDerivedEntityTypeSeparator() {
- return '/';
- }
-
- @Override
- public V3URIBuilder appendLinksSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.LINKS, SegmentType.LINKS.getValue()));
- segments.add(new Segment(SegmentType.ENTITYSET, segmentValue));
-
- return getThis();
- }
-
- @Override
- protected String noKeysWrapper() {
- return StringUtils.EMPTY;
- }
-
- @Override
- public V3URIBuilder appendKeySegment(final Object val) {
- if (configuration.isKeyAsSegment()) {
- final String segValue = URIUtils.escape(val);
- segments.add(new Segment(SegmentType.KEY_AS_SEGMENT, segValue));
- } else {
- super.appendKeySegment(val);
- }
-
- return getThis();
- }
-
- @Override
- public V3URIBuilder appendKeySegment(final Map<String, Object> segmentValues) {
- if (!configuration.isKeyAsSegment()) {
- super.appendKeySegment(segmentValues);
- }
-
- return getThis();
- }
-
- @Override
- public V3URIBuilder inlineCount(final InlineCount inlineCount) {
- return addQueryOption(QueryOption.INLINECOUNT, inlineCount.name());
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V4URIBuilderImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V4URIBuilderImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V4URIBuilderImpl.java
deleted file mode 100644
index dcdaf62..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/V4URIBuilderImpl.java
+++ /dev/null
@@ -1,101 +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.odata4.client.core.uri;
-
-import org.apache.commons.lang3.StringUtils;
-import org.apache.olingo.odata4.client.api.uri.QueryOption;
-import org.apache.olingo.odata4.client.api.uri.SegmentType;
-import org.apache.olingo.odata4.client.api.uri.V4URIBuilder;
-
-public class V4URIBuilderImpl extends AbstractURIBuilder<V4URIBuilder> implements V4URIBuilder {
-
- private static final long serialVersionUID = -3506851722447870532L;
-
- public V4URIBuilderImpl(final String serviceRoot) {
- super(serviceRoot);
- }
-
- @Override
- protected V4URIBuilder getThis() {
- return this;
- }
-
- @Override
- protected String noKeysWrapper() {
- return "()";
- }
-
- @Override
- protected char getBoundOperationSeparator() {
- return '.';
- }
-
- @Override
- protected char getDerivedEntityTypeSeparator() {
- return '.';
- }
-
- @Override
- public V4URIBuilder appendSingletonSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.SINGLETON, segmentValue));
- return getThis();
- }
-
- @Override
- public V4URIBuilder appendEntityIdSegment(final String segmentValue) {
- segments.add(new Segment(SegmentType.ENTITY, null));
- return addQueryOption(QueryOption.ID, segmentValue);
- }
-
- @Override
- public V4URIBuilder appendRefSegment() {
- segments.add(new Segment(SegmentType.REF, SegmentType.REF.getValue()));
- return getThis();
- }
-
- @Override
- public V4URIBuilder appendCrossjoinSegment(final String... segmentValues) {
- StringBuilder segValue = new StringBuilder(SegmentType.CROSS_JOIN.getValue()).
- append('(').append(StringUtils.join(segmentValues, ",")).append(')');
- segments.add(new Segment(SegmentType.CROSS_JOIN, segValue.toString()));
- return getThis();
- }
-
- @Override
- public V4URIBuilder count(final boolean value) {
- return addQueryOption(QueryOption.COUNT, Boolean.toString(value));
- }
-
- @Override
- public V4URIBuilder appendAllSegment() {
- segments.add(new Segment(SegmentType.ALL, SegmentType.ALL.getValue()));
- return getThis();
- }
-
- @Override
- public V4URIBuilder id(final String idValue) {
- return addQueryOption(QueryOption.ID, idValue);
- }
-
- @Override
- public V4URIBuilder search(final String expression) {
- return addQueryOption(QueryOption.SEARCH, expression);
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractComparingFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractComparingFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractComparingFilter.java
deleted file mode 100644
index c76de47..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractComparingFilter.java
+++ /dev/null
@@ -1,45 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-abstract class AbstractComparingFilter implements URIFilter {
-
- private final FilterArg left;
-
- private final FilterArg right;
-
- AbstractComparingFilter(final FilterArg left, final FilterArg right) {
- this.left = left;
- this.right = right;
- }
-
- protected abstract String getOp();
-
- @Override
- public String build() {
- return new StringBuilder().
- append('(').append(left.build()).
- append(' ').append(getOp()).append(' ').
- append(right.build()).append(')').
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterArgFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterArgFactory.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterArgFactory.java
deleted file mode 100644
index b7c68aa..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterArgFactory.java
+++ /dev/null
@@ -1,178 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArgFactory;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-/**
- * OData filter arguments factory.
- */
-abstract class AbstractFilterArgFactory implements FilterArgFactory {
-
- @Override
- public FilterArg _null() {
- return new FilterConst("null");
- }
-
- @Override
- public FilterArg property(final String propertyPath) {
- return new FilterProperty(propertyPath);
- }
-
- @Override
- public FilterArg literal(final Object value) {
- return new FilterLiteral(value);
- }
-
- @Override
- public FilterArg add(final FilterArg first, final FilterArg second) {
- return new FilterOp("add", first, second);
- }
-
- @Override
- public FilterArg sub(final FilterArg first, final FilterArg second) {
- return new FilterOp("add", first, second);
- }
-
- @Override
- public FilterArg mul(final FilterArg first, final FilterArg second) {
- return new FilterOp("mul", first, second);
- }
-
- @Override
- public FilterArg div(final FilterArg first, final FilterArg second) {
- return new FilterOp("div", first, second);
- }
-
- @Override
- public FilterArg mod(final FilterArg first, final FilterArg second) {
- return new FilterOp("mod", first, second);
- }
-
- @Override
- public FilterArg endswith(final FilterArg first, final FilterArg second) {
- return new FilterFunction("endswith", first, second);
- }
-
- @Override
- public FilterArg startswith(final FilterArg first, final FilterArg second) {
- return new FilterFunction("startswith", first, second);
- }
-
- @Override
- public FilterArg length(final FilterArg param) {
- return new FilterFunction("length", param);
- }
-
- @Override
- public FilterArg indexof(final FilterArg first, final FilterArg second) {
- return new FilterFunction("indexof", first, second);
- }
-
- @Override
- public FilterArg replace(final FilterArg first, final FilterArg second, final FilterArg third) {
- return new FilterFunction("replace", first, second, third);
- }
-
- @Override
- public FilterArg substring(final FilterArg arg, final FilterArg pos) {
- return new FilterFunction("substring", arg, pos);
- }
-
- @Override
- public FilterArg substring(final FilterArg arg, final FilterArg pos, final FilterArg length) {
- return new FilterFunction("substring", arg, pos, length);
- }
-
- @Override
- public FilterArg tolower(final FilterArg param) {
- return new FilterFunction("tolower", param);
- }
-
- @Override
- public FilterArg toupper(final FilterArg param) {
- return new FilterFunction("toupper", param);
- }
-
- @Override
- public FilterArg trim(final FilterArg param) {
- return new FilterFunction("trim", param);
- }
-
- @Override
- public FilterArg concat(final FilterArg first, final FilterArg second) {
- return new FilterFunction("concat", first, second);
- }
-
- @Override
- public FilterArg day(final FilterArg param) {
- return new FilterFunction("day", param);
- }
-
- @Override
- public FilterArg hour(final FilterArg param) {
- return new FilterFunction("hour", param);
- }
-
- @Override
- public FilterArg minute(final FilterArg param) {
- return new FilterFunction("minute", param);
- }
-
- @Override
- public FilterArg month(final FilterArg param) {
- return new FilterFunction("month", param);
- }
-
- @Override
- public FilterArg second(final FilterArg param) {
- return new FilterFunction("second", param);
- }
-
- @Override
- public FilterArg year(final FilterArg param) {
- return new FilterFunction("year", param);
- }
-
- @Override
- public FilterArg round(final FilterArg param) {
- return new FilterFunction("round", param);
- }
-
- @Override
- public FilterArg floor(final FilterArg param) {
- return new FilterFunction("floor", param);
- }
-
- @Override
- public FilterArg ceiling(final FilterArg param) {
- return new FilterFunction("ceiling", param);
- }
-
- @Override
- public FilterArg isof(final FilterArg type) {
- return new FilterFunction("isof", type);
- }
-
- @Override
- public FilterArg isof(final FilterArg expression, final FilterArg type) {
- return new FilterFunction("isof", expression, type);
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterFactory.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterFactory.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterFactory.java
deleted file mode 100644
index 288f547..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AbstractFilterFactory.java
+++ /dev/null
@@ -1,108 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterFactory;
-
-abstract class AbstractFilterFactory implements FilterFactory {
-
- private static final long serialVersionUID = -6141317149802621836L;
-
- @Override
- public URIFilter match(final FilterArg arg) {
- return new MatchFilter(arg);
- }
-
- @Override
- public URIFilter eq(final String key, final Object value) {
- return new EqFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter eq(final FilterArg left, final FilterArg right) {
- return new EqFilter(left, right);
- }
-
- @Override
- public URIFilter ne(final String key, final Object value) {
- return new NeFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter ne(final FilterArg left, final FilterArg right) {
- return new NeFilter(left, right);
- }
-
- @Override
- public URIFilter gt(final String key, final Object value) {
- return new GtFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter gt(final FilterArg left, final FilterArg right) {
- return new GtFilter(left, right);
- }
-
- @Override
- public URIFilter ge(final String key, final Object value) {
- return new GeFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter ge(final FilterArg left, final FilterArg right) {
- return new GeFilter(left, right);
- }
-
- @Override
- public URIFilter lt(final String key, final Object value) {
- return new LtFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter lt(final FilterArg left, final FilterArg right) {
- return new LtFilter(left, right);
- }
-
- @Override
- public URIFilter le(final String key, final Object value) {
- return new LeFilter(getArgFactory().property(key), getArgFactory().literal(value));
- }
-
- @Override
- public URIFilter le(final FilterArg left, final FilterArg right) {
- return new LeFilter(left, right);
- }
-
- @Override
- public URIFilter and(final URIFilter left, final URIFilter right) {
- return new AndFilter(left, right);
- }
-
- @Override
- public URIFilter or(final URIFilter left, final URIFilter right) {
- return new OrFilter(left, right);
- }
-
- @Override
- public URIFilter not(final URIFilter filter) {
- return new NotFilter(filter);
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AndFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AndFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AndFilter.java
deleted file mode 100644
index c9068a3..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/AndFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-
-public class AndFilter implements URIFilter {
-
- private final URIFilter left;
-
- private final URIFilter right;
-
- public AndFilter(final URIFilter left, final URIFilter right) {
- this.left = left;
- this.right = right;
- }
-
- @Override
- public String build() {
- return new StringBuilder().
- append('(').append(left.build()).
- append(" and ").
- append(right.build()).append(')').
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/EqFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/EqFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/EqFilter.java
deleted file mode 100644
index 01bfd03..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/EqFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class EqFilter extends AbstractComparingFilter {
-
- EqFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "eq";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterConst.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterConst.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterConst.java
deleted file mode 100644
index 22987b6..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterConst.java
+++ /dev/null
@@ -1,41 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArgFactory;
-
-/**
- * Filter property path; obtain instances via <tt>FilterArgFactory</tt>.
- *
- * @see FilterArgFactory
- */
-public class FilterConst implements FilterArg {
-
- private final String value;
-
- FilterConst(final String value) {
- this.value = value;
- }
-
- @Override
- public String build() {
- return value;
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterFunction.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterFunction.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterFunction.java
deleted file mode 100644
index 1f32837..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterFunction.java
+++ /dev/null
@@ -1,48 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.commons.lang3.StringUtils;
-
-public class FilterFunction implements FilterArg {
-
- private final String function;
-
- private final FilterArg[] params;
-
- FilterFunction(final String function, final FilterArg... params) {
- this.function = function;
- this.params = params;
- }
-
- @Override
- public String build() {
- final String[] strParams = params == null || params.length == 0 ? new String[0] : new String[params.length];
- for (int i = 0; i < strParams.length; i++) {
- strParams[i] = params[i].build();
- }
-
- return new StringBuilder(function).
- append('(').
- append(strParams.length == 0 ? StringUtils.EMPTY : StringUtils.join(strParams, ',')).
- append(')').
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLambda.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLambda.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLambda.java
deleted file mode 100644
index dbb1e2a..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLambda.java
+++ /dev/null
@@ -1,46 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-
-public class FilterLambda implements FilterArg {
-
- private final FilterArg collection;
-
- private final String operator;
-
- private final URIFilter expression;
-
- FilterLambda(final FilterArg collection, final String operator, final URIFilter expression) {
- this.collection = collection;
- this.operator = operator;
- this.expression = expression;
- }
-
- @Override
- public String build() {
- return new StringBuilder(collection.build()).
- append('/').
- append(operator).
- append(expression.build()).
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLiteral.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLiteral.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLiteral.java
deleted file mode 100644
index 578c3e3..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterLiteral.java
+++ /dev/null
@@ -1,41 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.olingo.odata4.client.core.uri.URIUtils;
-
-/**
- * Filter value literals; obtain instances via <tt>FilterArgFactory</tt>.
- *
- * @see FilterArgFactory
- */
-public class FilterLiteral implements FilterArg {
-
- private final Object value;
-
- FilterLiteral(final Object value) {
- this.value = value;
- }
-
- @Override
- public String build() {
- return URIUtils.escape(value);
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterOp.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterOp.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterOp.java
deleted file mode 100644
index a59fd7b..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterOp.java
+++ /dev/null
@@ -1,45 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class FilterOp implements FilterArg {
-
- private final String op;
-
- private final FilterArg first;
-
- private final FilterArg second;
-
- FilterOp(final String op, final FilterArg first, final FilterArg second) {
- this.op = op;
- this.first = first;
- this.second = second;
- }
-
- @Override
- public String build() {
- return new StringBuilder().
- append('(').append(first.build()).
- append(' ').append(op).append(' ').
- append(second.build()).append(')').
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterProperty.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterProperty.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterProperty.java
deleted file mode 100644
index e467a44..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/FilterProperty.java
+++ /dev/null
@@ -1,40 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-/**
- * Filter property path; obtain instances via <tt>FilterArgFactory</tt>.
- *
- * @see FilterArgFactory
- */
-public class FilterProperty implements FilterArg {
-
- private final String propertyPath;
-
- FilterProperty(final String value) {
- this.propertyPath = value;
- }
-
- @Override
- public String build() {
- return propertyPath;
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GeFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GeFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GeFilter.java
deleted file mode 100644
index 77024d9..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GeFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class GeFilter extends AbstractComparingFilter {
-
- GeFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "ge";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GtFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GtFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GtFilter.java
deleted file mode 100644
index 9f1d188..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/GtFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class GtFilter extends AbstractComparingFilter {
-
- GtFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "gt";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/HasFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/HasFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/HasFilter.java
deleted file mode 100644
index 22f4d94..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/HasFilter.java
+++ /dev/null
@@ -1,34 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class HasFilter extends AbstractComparingFilter {
-
- HasFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "has";
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LeFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LeFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LeFilter.java
deleted file mode 100644
index 122ef1b..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LeFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class LeFilter extends AbstractComparingFilter {
-
- LeFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "le";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LtFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LtFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LtFilter.java
deleted file mode 100644
index 5cbde0d..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/LtFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class LtFilter extends AbstractComparingFilter {
-
- LtFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "lt";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/MatchFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/MatchFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/MatchFilter.java
deleted file mode 100644
index ae352ad..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/MatchFilter.java
+++ /dev/null
@@ -1,36 +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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class MatchFilter implements URIFilter {
-
- private final FilterArg arg;
-
- MatchFilter(final FilterArg arg) {
- this.arg = arg;
- }
-
- @Override
- public String build() {
- return arg.build();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NeFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NeFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NeFilter.java
deleted file mode 100644
index cba18ec..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NeFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-
-public class NeFilter extends AbstractComparingFilter {
-
- NeFilter(final FilterArg left, final FilterArg right) {
- super(left, right);
- }
-
- @Override
- protected String getOp() {
- return "ne";
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NotFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NotFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NotFilter.java
deleted file mode 100644
index 8aed7bb..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/NotFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-
-public class NotFilter implements URIFilter {
-
- private final URIFilter filter;
-
- public NotFilter(final URIFilter left) {
- this.filter = left;
- }
-
- @Override
- public String build() {
- return new StringBuilder("not (").append(filter.build()).append(')').toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/OrFilter.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/OrFilter.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/OrFilter.java
deleted file mode 100644
index 648fa27..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/OrFilter.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.URIFilter;
-
-public class OrFilter implements URIFilter {
-
- private final URIFilter left;
-
- private final URIFilter right;
-
- public OrFilter(final URIFilter left, final URIFilter right) {
- this.left = left;
- this.right = right;
- }
-
- @Override
- public String build() {
- return new StringBuilder().
- append('(').append(left.build()).
- append(" or ").
- append(right.build()).append(')').
- toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterArgFactoryImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterArgFactoryImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterArgFactoryImpl.java
deleted file mode 100644
index ace149d..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterArgFactoryImpl.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.FilterArg;
-import org.apache.olingo.odata4.client.api.uri.filter.V3FilterArgFactory;
-
-public class V3FilterArgFactoryImpl extends AbstractFilterArgFactory implements V3FilterArgFactory {
-
- @Override
- public FilterArg substringof(final FilterArg first, final FilterArg second) {
- return new FilterFunction("substringof", first, second);
- }
-
-}
http://git-wip-us.apache.org/repos/asf/incubator-olingo-odata4/blob/897db8ef/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterFactoryImpl.java
----------------------------------------------------------------------
diff --git a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterFactoryImpl.java b/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterFactoryImpl.java
deleted file mode 100644
index e966c9c..0000000
--- a/lib/client-core/src/main/java/org/apache/olingo/odata4/client/core/uri/filter/V3FilterFactoryImpl.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.odata4.client.core.uri.filter;
-
-import org.apache.olingo.odata4.client.api.uri.filter.V3FilterArgFactory;
-import org.apache.olingo.odata4.client.api.uri.filter.V3FilterFactory;
-
-public class V3FilterFactoryImpl extends AbstractFilterFactory implements V3FilterFactory {
-
- private static final long serialVersionUID = 1092594961118334631L;
-
- @Override
- public V3FilterArgFactory getArgFactory() {
- return new V3FilterArgFactoryImpl();
- }
-
-}