olingo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sklev...@apache.org
Subject [47/59] [abbrv] [partial] Removing /ODataJClient: merge complete
Date Fri, 23 May 2014 10:58:42 GMT
http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/ODataValueUpdateRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/ODataValueUpdateRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/ODataValueUpdateRequest.java
deleted file mode 100644
index 32745f2..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/ODataValueUpdateRequest.java
+++ /dev/null
@@ -1,138 +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 com.msopentech.odatajclient.engine.communication.request.cud;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpClientException;
-import com.msopentech.odatajclient.engine.client.http.HttpMethod;
-import com.msopentech.odatajclient.engine.communication.response.ODataResponseImpl;
-import com.msopentech.odatajclient.engine.communication.request.AbstractODataBasicRequestImpl;
-import com.msopentech.odatajclient.engine.communication.request.batch.ODataBatchableRequest;
-import com.msopentech.odatajclient.engine.communication.response.ODataValueUpdateResponse;
-import com.msopentech.odatajclient.engine.data.ODataPrimitiveValue;
-import com.msopentech.odatajclient.engine.data.ODataValue;
-import com.msopentech.odatajclient.engine.metadata.edm.EdmSimpleType;
-import com.msopentech.odatajclient.engine.format.ODataValueFormat;
-import com.msopentech.odatajclient.engine.utils.URIUtils;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URI;
-import org.apache.commons.io.IOUtils;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-import org.apache.http.client.methods.HttpEntityEnclosingRequestBase;
-
-/**
- * This class implements an OData update entity property value request.
- */
-public class ODataValueUpdateRequest extends AbstractODataBasicRequestImpl<ODataValueUpdateResponse, ODataValueFormat>
-        implements ODataBatchableRequest {
-
-    /**
-     * Value to be created.
-     */
-    private final ODataValue value;
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param method request method.
-     * @param targetURI entity set or entity or entity property URI.
-     * @param value value to be created.
-     */
-    ODataValueUpdateRequest(final ODataClient odataClient,
-            final HttpMethod method, final URI targetURI, final ODataValue value) {
-
-        super(odataClient, ODataValueFormat.class, method, targetURI);
-        // set request body
-        this.value = value;
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataValueUpdateResponseImpl execute() {
-        final InputStream input = getPayload();
-        ((HttpEntityEnclosingRequestBase) request).setEntity(URIUtils.buildInputStreamEntity(odataClient, input));
-
-        try {
-            return new ODataValueUpdateResponseImpl(httpClient, doExecute());
-        } finally {
-            IOUtils.closeQuietly(input);
-        }
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    protected InputStream getPayload() {
-        return IOUtils.toInputStream(value.toString());
-    }
-
-    /**
-     * Response class about an ODataValueUpdateRequest.
-     */
-    private class ODataValueUpdateResponseImpl extends ODataResponseImpl implements ODataValueUpdateResponse {
-
-        private ODataValue value = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataValueUpdateResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataValueUpdateResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public ODataValue getBody() {
-            if (value == null) {
-                final ODataValueFormat format = ODataValueFormat.fromString(getAccept());
-
-                try {
-                    value = new ODataPrimitiveValue.Builder(odataClient).
-                            setType(format == ODataValueFormat.TEXT ? EdmSimpleType.String : EdmSimpleType.Stream).
-                            setText(IOUtils.toString(getRawResponse())).
-                            build();
-                } catch (IOException e) {
-                    throw new HttpClientException(e);
-                } finally {
-                    this.close();
-                }
-            }
-            return value;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V3CUDRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V3CUDRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V3CUDRequestFactory.java
deleted file mode 100644
index 06602a8..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V3CUDRequestFactory.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 com.msopentech.odatajclient.engine.communication.request.cud;
-
-import com.msopentech.odatajclient.engine.client.ODataV3Client;
-
-public class V3CUDRequestFactory extends AbstractCUDRequestFactory {
-
-    private static final long serialVersionUID = 109196636064983035L;
-
-    public V3CUDRequestFactory(final ODataV3Client client) {
-        super(client);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V4CUDRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V4CUDRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V4CUDRequestFactory.java
deleted file mode 100644
index 7fd36fe..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/cud/V4CUDRequestFactory.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 com.msopentech.odatajclient.engine.communication.request.cud;
-
-import com.msopentech.odatajclient.engine.client.ODataV4Client;
-
-public class V4CUDRequestFactory extends AbstractCUDRequestFactory {
-
-    private static final long serialVersionUID = 3080623853913380425L;
-
-    public V4CUDRequestFactory(final ODataV4Client client) {
-        super(client);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/AbstractInvokeRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/AbstractInvokeRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/AbstractInvokeRequestFactory.java
deleted file mode 100644
index 4397450..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/AbstractInvokeRequestFactory.java
+++ /dev/null
@@ -1,58 +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 com.msopentech.odatajclient.engine.communication.request.invoke;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.data.ODataInvokeResult;
-import com.msopentech.odatajclient.engine.data.ODataValue;
-import com.msopentech.odatajclient.engine.metadata.AbstractEdmMetadata;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractDataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEdmx;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractFunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractSchema;
-import java.net.URI;
-import java.util.Map;
-
-abstract class AbstractInvokeRequestFactory<META extends AbstractEdmMetadata<
-        EDMX, DS, S, EC, E, C, FI>, EDMX extends AbstractEdmx<DS, S, EC, E, C, FI>, DS extends AbstractDataServices<
-        S, EC, E, C, FI>, S extends AbstractSchema<EC, E, C, FI>, EC extends AbstractEntityContainer<
-        FI>, E extends AbstractEntityType, C extends AbstractComplexType, FI extends AbstractFunctionImport>
-        implements InvokeRequestFactory<META, EDMX, DS, S, EC, E, C, FI> {
-
-    private static final long serialVersionUID = -906760270085197249L;
-
-    protected final ODataClient client;
-
-    protected AbstractInvokeRequestFactory(final ODataClient client) {
-        this.client = client;
-    }
-
-    @Override
-    public <RES extends ODataInvokeResult> ODataInvokeRequest<RES> getInvokeRequest(
-            final URI uri, final META metadata, final FI functionImport, final Map<String, ODataValue> parameters) {
-
-        final ODataInvokeRequest<RES> result = getInvokeRequest(uri, metadata, functionImport);
-        result.setParameters(parameters);
-        return result;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/InvokeRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/InvokeRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/InvokeRequestFactory.java
deleted file mode 100644
index 9d06070..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/InvokeRequestFactory.java
+++ /dev/null
@@ -1,68 +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 com.msopentech.odatajclient.engine.communication.request.invoke;
-
-import com.msopentech.odatajclient.engine.data.ODataInvokeResult;
-import com.msopentech.odatajclient.engine.data.ODataValue;
-import com.msopentech.odatajclient.engine.metadata.AbstractEdmMetadata;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractDataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEdmx;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractFunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractSchema;
-import java.io.Serializable;
-import java.net.URI;
-import java.util.Map;
-
-/**
- * OData request factory class.
- */
-public interface InvokeRequestFactory<META extends AbstractEdmMetadata<
-        EDMX, DS, S, EC, E, C, FI>, EDMX extends AbstractEdmx<DS, S, EC, E, C, FI>, DS extends AbstractDataServices<
-        S, EC, E, C, FI>, S extends AbstractSchema<EC, E, C, FI>, EC extends AbstractEntityContainer<
-        FI>, E extends AbstractEntityType, C extends AbstractComplexType, FI extends AbstractFunctionImport>
-        extends Serializable {
-
-    /**
-     * Gets an invoke request instance.
-     *
-     * @param <RES> OData domain object result, derived from return type defined in the function import
-     * @param uri URI that identifies the function import
-     * @param metadata Edm metadata
-     * @param functionImport function import to be invoked
-     * @return new ODataInvokeRequest instance.
-     */
-    <RES extends ODataInvokeResult> ODataInvokeRequest<RES> getInvokeRequest(
-            URI uri, META metadata, FI functionImport);
-
-    /**
-     * Gets an invoke request instance.
-     *
-     * @param <RES> OData domain object result, derived from return type defined in the function import
-     * @param uri URI that identifies the function import
-     * @param metadata Edm metadata
-     * @param functionImport function import to be invoked
-     * @param parameters parameters to pass to function import invocation
-     * @return new ODataInvokeRequest instance.
-     */
-    <RES extends ODataInvokeResult> ODataInvokeRequest<RES> getInvokeRequest(
-            URI uri, META metadata, FI functionImport, Map<String, ODataValue> parameters);
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/ODataInvokeRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/ODataInvokeRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/ODataInvokeRequest.java
deleted file mode 100644
index 49fa245..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/ODataInvokeRequest.java
+++ /dev/null
@@ -1,235 +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 com.msopentech.odatajclient.engine.communication.request.invoke;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpClientException;
-import com.msopentech.odatajclient.engine.client.http.HttpMethod;
-import com.msopentech.odatajclient.engine.communication.request.AbstractODataBasicRequestImpl;
-import com.msopentech.odatajclient.engine.communication.request.batch.ODataBatchableRequest;
-import com.msopentech.odatajclient.engine.communication.response.ODataInvokeResponse;
-import com.msopentech.odatajclient.engine.communication.response.ODataResponseImpl;
-import com.msopentech.odatajclient.engine.data.ODataEntity;
-import com.msopentech.odatajclient.engine.data.ODataEntitySet;
-import com.msopentech.odatajclient.engine.data.ODataInvokeResult;
-import com.msopentech.odatajclient.engine.data.ODataNoContent;
-import com.msopentech.odatajclient.engine.data.ODataProperty;
-import com.msopentech.odatajclient.engine.data.ODataValue;
-import com.msopentech.odatajclient.engine.format.ODataFormat;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import com.msopentech.odatajclient.engine.utils.URIUtils;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.util.LinkedHashMap;
-import java.util.Map;
-import org.apache.commons.io.IOUtils;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-import org.apache.http.client.methods.HttpPost;
-import org.apache.http.client.methods.HttpRequestBase;
-import org.apache.http.client.utils.URIBuilder;
-
-/**
- * This class implements an OData invoke operation request.
- */
-public class ODataInvokeRequest<T extends ODataInvokeResult>
-        extends AbstractODataBasicRequestImpl<ODataInvokeResponse<T>, ODataPubFormat>
-        implements ODataBatchableRequest {
-
-    private final Class<T> reference;
-
-    /**
-     * Function parameters.
-     */
-    private Map<String, ODataValue> parameters;
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param reference reference class for invoke result
-     * @param method HTTP method of the request.
-     * @param uri URI that identifies the operation.
-     */
-    ODataInvokeRequest(
-            final ODataClient odataClient,
-            final Class<T> reference,
-            final HttpMethod method,
-            final URI uri) {
-
-        super(odataClient, ODataPubFormat.class, method, uri);
-
-        this.reference = reference;
-        this.parameters = new LinkedHashMap<String, ODataValue>();
-    }
-
-    /**
-     * Sets operation parameters.
-     *
-     * @param parameters operation parameters.
-     */
-    public void setParameters(final Map<String, ODataValue> parameters) {
-        this.parameters.clear();
-        if (parameters != null && !parameters.isEmpty()) {
-            this.parameters.putAll(parameters);
-        }
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public void setFormat(final ODataPubFormat format) {
-        final String _format = (reference.isAssignableFrom(ODataProperty.class) && format == ODataPubFormat.ATOM)
-                ? ODataFormat.XML.toString()
-                : format.toString();
-        setAccept(_format);
-        setContentType(_format);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    protected InputStream getPayload() {
-        if (!this.parameters.isEmpty() && this.method == HttpMethod.POST) {
-            // Additional, non-binding parameters MUST be sent as JSON
-            final ODataEntity tmp = odataClient.getObjectFactory().newEntity("");
-            for (Map.Entry<String, ODataValue> param : parameters.entrySet()) {
-                ODataProperty property = null;
-
-                if (param.getValue().isPrimitive()) {
-                    property = odataClient.getObjectFactory().
-                            newPrimitiveProperty(param.getKey(), param.getValue().asPrimitive());
-                } else if (param.getValue().isComplex()) {
-                    property = odataClient.getObjectFactory().
-                            newComplexProperty(param.getKey(), param.getValue().asComplex());
-                } else if (param.getValue().isCollection()) {
-                    property = odataClient.getObjectFactory().
-                            newCollectionProperty(param.getKey(), param.getValue().asCollection());
-                }
-
-                if (property != null) {
-                    tmp.addProperty(property);
-                }
-            }
-
-            return odataClient.getWriter().writeEntity(tmp, ODataPubFormat.JSON, false);
-        }
-
-        return null;
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataInvokeResponse<T> execute() {
-        final InputStream input = getPayload();
-
-        if (!this.parameters.isEmpty()) {
-            if (this.method == HttpMethod.GET) {
-                final URIBuilder uriBuilder = new URIBuilder(this.uri);
-                for (Map.Entry<String, ODataValue> param : parameters.entrySet()) {
-                    if (!param.getValue().isPrimitive()) {
-                        throw new IllegalArgumentException("Only primitive values can be passed via GET");
-                    }
-
-                    uriBuilder.addParameter(param.getKey(), param.getValue().toString());
-                }
-                try {
-                    ((HttpRequestBase) this.request).setURI(uriBuilder.build());
-                } catch (URISyntaxException e) {
-                    throw new IllegalArgumentException("While adding GET parameters", e);
-                }
-            } else if (this.method == HttpMethod.POST) {
-                ((HttpPost) request).setEntity(URIUtils.buildInputStreamEntity(odataClient, input));
-
-                setContentType(ODataPubFormat.JSON.toString());
-            }
-        }
-
-        try {
-            return new ODataInvokeResponseImpl(httpClient, doExecute());
-        } finally {
-            IOUtils.closeQuietly(input);
-        }
-    }
-
-    /**
-     * Response class about an ODataInvokeRequest.
-     */
-    protected class ODataInvokeResponseImpl extends ODataResponseImpl implements ODataInvokeResponse<T> {
-
-        private T invokeResult = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataInvokeResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataInvokeResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        @SuppressWarnings("unchecked")
-        public T getBody() {
-            if (invokeResult == null) {
-                if (reference.isAssignableFrom(ODataNoContent.class)) {
-                    invokeResult = (T) new ODataNoContent();
-                }
-
-                try {
-                    if (reference.isAssignableFrom(ODataEntitySet.class)) {
-                        invokeResult = (T) odataClient.getReader().readEntitySet(res.getEntity().getContent(),
-                                ODataPubFormat.fromString(getContentType()));
-                    }
-                    if (reference.isAssignableFrom(ODataEntity.class)) {
-                        invokeResult = (T) odataClient.getReader().readEntity(res.getEntity().getContent(),
-                                ODataPubFormat.fromString(getContentType()));
-                    }
-                    if (reference.isAssignableFrom(ODataProperty.class)) {
-                        invokeResult = (T) odataClient.getReader().readProperty(res.getEntity().getContent(),
-                                ODataFormat.fromString(getContentType()));
-                    }
-                } catch (IOException e) {
-                    throw new HttpClientException(e);
-                } finally {
-                    this.close();
-                }
-            }
-            return invokeResult;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V3InvokeRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V3InvokeRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V3InvokeRequestFactory.java
deleted file mode 100644
index 79cef99..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V3InvokeRequestFactory.java
+++ /dev/null
@@ -1,88 +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 com.msopentech.odatajclient.engine.communication.request.invoke;
-
-import com.msopentech.odatajclient.engine.client.ODataV3Client;
-import com.msopentech.odatajclient.engine.client.http.HttpMethod;
-import com.msopentech.odatajclient.engine.data.ODataEntity;
-import com.msopentech.odatajclient.engine.data.ODataEntitySet;
-import com.msopentech.odatajclient.engine.data.ODataInvokeResult;
-import com.msopentech.odatajclient.engine.data.ODataNoContent;
-import com.msopentech.odatajclient.engine.data.ODataProperty;
-import com.msopentech.odatajclient.engine.metadata.EdmV3Metadata;
-import com.msopentech.odatajclient.engine.metadata.EdmV3Type;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.ComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.DataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.Edmx;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.EntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.EntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.FunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.Schema;
-import java.net.URI;
-import org.apache.commons.lang3.StringUtils;
-
-public class V3InvokeRequestFactory extends AbstractInvokeRequestFactory<
-        EdmV3Metadata, Edmx, DataServices, Schema, EntityContainer, EntityType, ComplexType, FunctionImport> {
-
-    private static final long serialVersionUID = -659256862901915496L;
-
-    public V3InvokeRequestFactory(final ODataV3Client client) {
-        super(client);
-    }
-
-    @Override
-    @SuppressWarnings("unchecked")
-    public <RES extends ODataInvokeResult> ODataInvokeRequest<RES> getInvokeRequest(
-            final URI uri, final EdmV3Metadata metadata, final FunctionImport functionImport) {
-
-        HttpMethod method = null;
-        if (HttpMethod.GET.name().equals(functionImport.getHttpMethod())) {
-            method = HttpMethod.GET;
-        } else if (HttpMethod.POST.name().equals(functionImport.getHttpMethod())) {
-            method = HttpMethod.POST;
-        } else if (functionImport.getHttpMethod() == null) {
-            if (functionImport.isSideEffecting()) {
-                method = HttpMethod.POST;
-            } else {
-                method = HttpMethod.GET;
-            }
-        }
-
-        ODataInvokeRequest<RES> result;
-        if (StringUtils.isBlank(functionImport.getReturnType())) {
-            result = (ODataInvokeRequest<RES>) new ODataInvokeRequest<ODataNoContent>(
-                    client, ODataNoContent.class, method, uri);
-        } else {
-            final EdmV3Type returnType = new EdmV3Type(metadata, functionImport.getReturnType());
-
-            if (returnType.isCollection() && returnType.isEntityType()) {
-                result = (ODataInvokeRequest<RES>) new ODataInvokeRequest<ODataEntitySet>(
-                        client, ODataEntitySet.class, method, uri);
-            } else if (!returnType.isCollection() && returnType.isEntityType()) {
-                result = (ODataInvokeRequest<RES>) new ODataInvokeRequest<ODataEntity>(
-                        client, ODataEntity.class, method, uri);
-            } else {
-                result = (ODataInvokeRequest<RES>) new ODataInvokeRequest<ODataProperty>(
-                        client, ODataProperty.class, method, uri);
-            }
-        }
-
-        return result;
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V4InvokeRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V4InvokeRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V4InvokeRequestFactory.java
deleted file mode 100644
index 33ff14d..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/invoke/V4InvokeRequestFactory.java
+++ /dev/null
@@ -1,49 +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 com.msopentech.odatajclient.engine.communication.request.invoke;
-
-import com.msopentech.odatajclient.engine.client.ODataV4Client;
-import com.msopentech.odatajclient.engine.data.ODataInvokeResult;
-import com.msopentech.odatajclient.engine.metadata.EdmV4Metadata;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.ComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.EntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.EntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.DataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.Edmx;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.FunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.Schema;
-import java.net.URI;
-
-public class V4InvokeRequestFactory extends AbstractInvokeRequestFactory<
-        EdmV4Metadata, Edmx, DataServices, Schema, EntityContainer, EntityType, ComplexType, FunctionImport> {
-
-    private static final long serialVersionUID = 8452737360003104372L;
-
-    public V4InvokeRequestFactory(final ODataV4Client client) {
-        super(client);
-    }
-
-    @Override
-    public <RES extends ODataInvokeResult> ODataInvokeRequest<RES> getInvokeRequest(
-            final URI uri, final EdmV4Metadata metadata, final FunctionImport functionImport) {
-
-        throw new UnsupportedOperationException("Not supported yet.");
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractODataRetrieveRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractODataRetrieveRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractODataRetrieveRequest.java
deleted file mode 100644
index 4ce0f94..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractODataRetrieveRequest.java
+++ /dev/null
@@ -1,97 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpMethod;
-import com.msopentech.odatajclient.engine.communication.response.ODataResponseImpl;
-import com.msopentech.odatajclient.engine.communication.request.AbstractODataBasicRequestImpl;
-import com.msopentech.odatajclient.engine.communication.request.batch.ODataBatchableRequest;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import java.io.InputStream;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This is an abstract representation of an OData retrieve query request returning one or more result item.
- * Get instance by using ODataRetrieveRequestFactory.
- */
-abstract class AbstractODataRetrieveRequest<V, T extends Enum<T>>
-        extends AbstractODataBasicRequestImpl<ODataRetrieveResponse<V>, T>
-        implements ODataBatchableRequest {
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param formatRef reference class for the format being used
-     * @param query query to be executed.
-     */
-    AbstractODataRetrieveRequest(final ODataClient odataClient, final Class<T> formatRef, final URI query) {
-        super(odataClient, formatRef, HttpMethod.GET, query);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public abstract ODataRetrieveResponse<V> execute();
-
-    /**
-     * {@inheritDoc }
-     * <p>
-     * This kind of request doesn't have any payload: null will be returned.
-     */
-    @Override
-    protected InputStream getPayload() {
-        return null;
-    }
-
-    /**
-     * Response abstract class about an ODataRetrieveRequest.
-     */
-    protected abstract class ODataRetrieveResponseImpl extends ODataResponseImpl implements ODataRetrieveResponse<V> {
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        protected ODataRetrieveResponseImpl() {
-            super();
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        protected ODataRetrieveResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public abstract V getBody();
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractRetrieveRequestFactory.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractRetrieveRequestFactory.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractRetrieveRequestFactory.java
deleted file mode 100644
index 633c1e8..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/AbstractRetrieveRequestFactory.java
+++ /dev/null
@@ -1,78 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import java.net.URI;
-
-public abstract class AbstractRetrieveRequestFactory implements RetrieveRequestFactory {
-
-    private static final long serialVersionUID = -111683263158803362L;
-
-    protected final ODataClient client;
-
-    protected AbstractRetrieveRequestFactory(final ODataClient client) {
-        this.client = client;
-    }
-
-    @Override
-    public ODataEntitySetRequest getEntitySetRequest(final URI query) {
-        return new ODataEntitySetRequest(client, query);
-    }
-
-    @Override
-    public ODataEntitySetIteratorRequest getEntitySetIteratorRequest(final URI query) {
-        return new ODataEntitySetIteratorRequest(client, query);
-    }
-
-    @Override
-    public ODataEntityRequest getEntityRequest(final URI query) {
-        return new ODataEntityRequest(client, query);
-    }
-
-    @Override
-    public ODataPropertyRequest getPropertyRequest(final URI query) {
-        return new ODataPropertyRequest(client, query);
-    }
-
-    @Override
-    public ODataValueRequest getValueRequest(final URI query) {
-        return new ODataValueRequest(client, query);
-    }
-
-    @Override
-    public ODataLinkCollectionRequest getLinkCollectionRequest(final URI targetURI, final String linkName) {
-        return new ODataLinkCollectionRequest(client, targetURI, linkName);
-    }
-
-    @Override
-    public ODataMediaRequest getMediaRequest(final URI query) {
-        return new ODataMediaRequest(client, query);
-    }
-
-    @Override
-    public ODataRawRequest getRawRequest(final URI uri) {
-        return new ODataRawRequest(client, uri);
-    }
-
-    @Override
-    public ODataGenericRetrieveRequest getGenericRetrieveRequest(final URI uri) {
-        return new ODataGenericRetrieveRequest(client, uri);
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntityRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntityRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntityRequest.java
deleted file mode 100644
index 4ac6b3c..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntityRequest.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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataEntity;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData retrieve query request returning a single entity.
- */
-public class ODataEntityRequest extends AbstractODataRetrieveRequest<ODataEntity, ODataPubFormat> {
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param query query to be executed.
-     */
-    ODataEntityRequest(final ODataClient odataClient, final URI query) {
-        super(odataClient, ODataPubFormat.class, query);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataEntity> execute() {
-        return new ODataEntityResponseImpl(httpClient, doExecute());
-    }
-
-    /**
-     * Response class about an ODataEntityRequest.
-     */
-    public class ODataEntityResponseImpl extends ODataRetrieveResponseImpl {
-
-        private ODataEntity entity = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataEntityResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataEntityResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public ODataEntity getBody() {
-            if (entity == null) {
-                try {
-                    entity = odataClient.getReader().
-                            readEntity(getRawResponse(), ODataPubFormat.fromString(getContentType()));
-                } finally {
-                    this.close();
-                }
-            }
-            return entity;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetIteratorRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetIteratorRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetIteratorRequest.java
deleted file mode 100644
index 60529a3..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetIteratorRequest.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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataEntitySetIterator;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData EntitySet query request.
- */
-public class ODataEntitySetIteratorRequest extends AbstractODataRetrieveRequest<ODataEntitySetIterator, ODataPubFormat> {
-
-    private ODataEntitySetIterator feedIterator = null;
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param query query to be executed.
-     */
-    ODataEntitySetIteratorRequest(final ODataClient odataClient, final URI query) {
-        super(odataClient, ODataPubFormat.class, query);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataEntitySetIterator> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataEntitySetIteratorResponseImpl(httpClient, res);
-    }
-
-    /**
-     * Response class about an ODataEntitySetIteratorRequest.
-     */
-    protected class ODataEntitySetIteratorResponseImpl extends ODataRetrieveResponseImpl {
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataEntitySetIteratorResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        @SuppressWarnings("unchecked")
-        public ODataEntitySetIterator getBody() {
-            if (feedIterator == null) {
-                feedIterator = new ODataEntitySetIterator(
-                        odataClient, getRawResponse(), ODataPubFormat.fromString(getContentType()));
-            }
-            return feedIterator;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetRequest.java
deleted file mode 100644
index 54e3f54..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataEntitySetRequest.java
+++ /dev/null
@@ -1,95 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataEntitySet;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData EntitySet query request.
- */
-public class ODataEntitySetRequest extends AbstractODataRetrieveRequest<ODataEntitySet, ODataPubFormat> {
-
-    private ODataEntitySet feed = null;
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param query query to be executed.
-     */
-    ODataEntitySetRequest(final ODataClient odataClient, final URI query) {
-        super(odataClient, ODataPubFormat.class, query);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataEntitySet> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataEntitySetResponseImpl(httpClient, res);
-    }
-
-    /**
-     * Response class about an ODataEntitySetRequest.
-     */
-    protected class ODataEntitySetResponseImpl extends ODataRetrieveResponseImpl {
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataEntitySetResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataEntitySetResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        @SuppressWarnings("unchecked")
-        public ODataEntitySet getBody() {
-            if (feed == null) {
-                try {
-                    feed = odataClient.getReader().
-                            readEntitySet(getRawResponse(), ODataPubFormat.fromString(getContentType()));
-                } finally {
-                    this.close();
-                }
-            }
-            return feed;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataGenericRetrieveRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataGenericRetrieveRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataGenericRetrieveRequest.java
deleted file mode 100644
index a428c43..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataGenericRetrieveRequest.java
+++ /dev/null
@@ -1,107 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.response.ODataResponseImpl;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataObjectWrapper;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements a generic OData retrieve query request.
- */
-public class ODataGenericRetrieveRequest extends ODataRawRequest {
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param uri query request.
-     */
-    public ODataGenericRetrieveRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, uri);
-    }
-
-    /**
-     * Sets accepted format.
-     *
-     * @param format format.
-     */
-    public void setFormat(final String format) {
-        setAccept(format);
-        setContentType(format);
-    }
-
-    /**
-     * Executes the query.
-     *
-     * @return query response.
-     */
-    public ODataRetrieveResponse<ODataObjectWrapper> execute() {
-        return new ODataGenericResponseImpl(httpClient, doExecute());
-    }
-
-    /**
-     * Query response implementation about a generic query request.
-     */
-    protected class ODataGenericResponseImpl extends ODataResponseImpl
-            implements ODataRetrieveResponse<ODataObjectWrapper> {
-
-        /**
-         * Retrieved object wrapper.
-         */
-        private ODataObjectWrapper obj = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataGenericResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataGenericResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public ODataObjectWrapper getBody() {
-            if (obj == null) {
-                try {
-                    obj = new ODataObjectWrapper(odataClient.getReader(), getRawResponse(), getContentType());
-                } finally {
-                    this.close();
-                }
-            }
-            return obj;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataLinkCollectionRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataLinkCollectionRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataLinkCollectionRequest.java
deleted file mode 100644
index 4007777..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataLinkCollectionRequest.java
+++ /dev/null
@@ -1,96 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpClientException;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataLinkCollection;
-import com.msopentech.odatajclient.engine.format.ODataFormat;
-import java.io.IOException;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData link query request.
- */
-public class ODataLinkCollectionRequest extends AbstractODataRetrieveRequest<ODataLinkCollection, ODataFormat> {
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param targetURI target URI.
-     * @param linkName link name.
-     */
-    ODataLinkCollectionRequest(final ODataClient odataClient, final URI targetURI, final String linkName) {
-        super(odataClient, ODataFormat.class,
-                odataClient.getURIBuilder(targetURI.toASCIIString()).appendLinksSegment(linkName).build());
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataLinkCollection> execute() {
-        return new ODataLinkCollectionResponseImpl(httpClient, doExecute());
-    }
-
-    protected class ODataLinkCollectionResponseImpl extends ODataRetrieveResponseImpl {
-
-        private ODataLinkCollection links = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataLinkCollectionResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataLinkCollectionResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public ODataLinkCollection getBody() {
-            if (links == null) {
-                try {
-                    links = odataClient.getReader().readLinks(
-                            res.getEntity().getContent(), ODataFormat.fromString(getContentType()));
-                } catch (IOException e) {
-                    throw new HttpClientException(e);
-                } finally {
-                    this.close();
-                }
-            }
-            return links;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMediaRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMediaRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMediaRequest.java
deleted file mode 100644
index 01a4644..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMediaRequest.java
+++ /dev/null
@@ -1,107 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpClientException;
-import com.msopentech.odatajclient.engine.communication.header.ODataHeaders;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.format.ODataMediaFormat;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData media query request.
- */
-public class ODataMediaRequest extends AbstractODataRetrieveRequest<InputStream, ODataMediaFormat> {
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param query query to be executed.
-     */
-    ODataMediaRequest(final ODataClient odataClient, final URI query) {
-        super(odataClient, ODataMediaFormat.class, query);
-
-        setAccept(ODataMediaFormat.APPLICATION_OCTET_STREAM.toString());
-        setContentType(ODataMediaFormat.APPLICATION_OCTET_STREAM.toString());
-
-        this.odataHeaders.removeHeader(ODataHeaders.HeaderName.minDataServiceVersion);
-        this.odataHeaders.removeHeader(ODataHeaders.HeaderName.maxDataServiceVersion);
-        this.odataHeaders.removeHeader(ODataHeaders.HeaderName.dataServiceVersion);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<InputStream> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataMediaResponseImpl(httpClient, res);
-    }
-
-    /**
-     * Response class about an ODataMediaRequest.
-     */
-    protected class ODataMediaResponseImpl extends ODataRetrieveResponseImpl {
-
-        private InputStream input = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataMediaResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataMediaResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * Gets query result objects.
-         * <br/>
-         * <b>WARNING</b>: Closing this <tt>ODataResponse</tt> instance is left to the caller.
-         *
-         * @return query result objects as <tt>InputStream</tt>.
-         */
-        @Override
-        public InputStream getBody() {
-            if (input == null) {
-                try {
-                    input = res.getEntity().getContent();
-                } catch (IOException e) {
-                    throw new HttpClientException(e);
-                }
-            }
-            return input;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMetadataRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMetadataRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMetadataRequest.java
deleted file mode 100644
index 06e497b..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataMetadataRequest.java
+++ /dev/null
@@ -1,118 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.request.ODataRequest;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.metadata.AbstractEdmMetadata;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractDataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEdmx;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractEntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractFunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.AbstractSchema;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-import org.apache.http.entity.ContentType;
-
-/**
- * This class implements a metadata query request.
- */
-class ODataMetadataRequest<META extends AbstractEdmMetadata<
-        EDMX, DS, S, EC, E, C, FI>, EDMX extends AbstractEdmx<DS, S, EC, E, C, FI>, DS extends AbstractDataServices<
-        S, EC, E, C, FI>, S extends AbstractSchema<EC, E, C, FI>, EC extends AbstractEntityContainer<
-        FI>, E extends AbstractEntityType, C extends AbstractComplexType, FI extends AbstractFunctionImport>
-        extends AbstractODataRetrieveRequest<META, ODataPubFormat> {
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param uri metadata URI.
-     */
-    ODataMetadataRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, ODataPubFormat.class, uri);
-        super.setAccept(ContentType.APPLICATION_XML.getMimeType());
-        super.setContentType(ContentType.APPLICATION_XML.getMimeType());
-    }
-
-    @Override
-    public ODataRequest setAccept(final String value) {
-        // do nothing: Accept is application/XML
-        return this;
-    }
-
-    @Override
-    public ODataRequest setContentType(final String value) {
-        // do nothing: Accept is application/XML
-        return this;
-    }
-
-    @Override
-    public ODataRetrieveResponse<META> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataMetadataResponseImpl(httpClient, res);
-    }
-
-    /**
-     * Response class about an ODataMetadataRequest.
-     */
-    protected class ODataMetadataResponseImpl extends ODataRetrieveResponseImpl {
-
-        private META metadata = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        public ODataMetadataResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataMetadataResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        @SuppressWarnings("unchecked")
-        public META getBody() {
-            if (metadata == null) {
-                try {
-                    metadata = (META) odataClient.getReader().readMetadata(getRawResponse());
-                } finally {
-                    this.close();
-                }
-            }
-            return metadata;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataPropertyRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataPropertyRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataPropertyRequest.java
deleted file mode 100644
index cc3429d..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataPropertyRequest.java
+++ /dev/null
@@ -1,95 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpClientException;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataProperty;
-import com.msopentech.odatajclient.engine.format.ODataFormat;
-import java.io.IOException;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData entity property query request.
- */
-public class ODataPropertyRequest extends AbstractODataRetrieveRequest<ODataProperty, ODataFormat> {
-
-    /**
-     * Private constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param query query to be executed.
-     */
-    ODataPropertyRequest(final ODataClient odataClient, final URI query) {
-        super(odataClient, ODataFormat.class, query);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataProperty> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataPropertyResponseImpl(httpClient, res);
-    }
-
-    protected class ODataPropertyResponseImpl extends ODataRetrieveResponseImpl {
-
-        private ODataProperty property = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataPropertyResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataPropertyResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        /**
-         * {@inheritDoc }
-         */
-        @Override
-        public ODataProperty getBody() {
-            if (property == null) {
-                try {
-                    property = odataClient.getReader().readProperty(
-                            res.getEntity().getContent(), ODataFormat.fromString(getContentType()));
-                } catch (IOException e) {
-                    throw new HttpClientException(e);
-                } finally {
-                    this.close();
-                }
-            }
-            return property;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataRawRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataRawRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataRawRequest.java
deleted file mode 100644
index 31bb6ac..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataRawRequest.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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.client.http.HttpMethod;
-import com.msopentech.odatajclient.engine.communication.request.ODataRequestImpl;
-import com.msopentech.odatajclient.engine.format.ODataPubFormat;
-import java.net.URI;
-
-/**
- * This class implements a generic OData request.
- */
-public class ODataRawRequest extends ODataRequestImpl<ODataPubFormat> {
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param uri request URI.
-     */
-    ODataRawRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, ODataPubFormat.class, HttpMethod.GET, uri);
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataServiceDocumentRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataServiceDocumentRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataServiceDocumentRequest.java
deleted file mode 100644
index c7ab454..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataServiceDocumentRequest.java
+++ /dev/null
@@ -1,91 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.communication.response.ODataRetrieveResponse;
-import com.msopentech.odatajclient.engine.data.ODataServiceDocument;
-import com.msopentech.odatajclient.engine.format.ODataFormat;
-import java.net.URI;
-import org.apache.http.HttpResponse;
-import org.apache.http.client.HttpClient;
-
-/**
- * This class implements an OData service document request.
- */
-public class ODataServiceDocumentRequest extends AbstractODataRetrieveRequest<ODataServiceDocument, ODataFormat> {
-
-    /**
-     * Constructor.
-     *
-     * @param odataClient client instance getting this request
-     * @param uri request URI.
-     */
-    ODataServiceDocumentRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, ODataFormat.class, uri);
-    }
-
-    /**
-     * {@inheritDoc }
-     */
-    @Override
-    public ODataRetrieveResponse<ODataServiceDocument> execute() {
-        final HttpResponse res = doExecute();
-        return new ODataServiceResponseImpl(httpClient, res);
-    }
-
-    /**
-     * Response class about an ODataServiceDocumentRequest.
-     */
-    protected class ODataServiceResponseImpl extends ODataRetrieveResponseImpl {
-
-        private ODataServiceDocument serviceDocument = null;
-
-        /**
-         * Constructor.
-         * <p>
-         * Just to create response templates to be initialized from batch.
-         */
-        private ODataServiceResponseImpl() {
-        }
-
-        /**
-         * Constructor.
-         *
-         * @param client HTTP client.
-         * @param res HTTP response.
-         */
-        private ODataServiceResponseImpl(final HttpClient client, final HttpResponse res) {
-            super(client, res);
-        }
-
-        @Override
-        public ODataServiceDocument getBody() {
-            if (serviceDocument == null) {
-                try {
-                    serviceDocument = odataClient.getReader().readServiceDocument(
-                            getRawResponse(), ODataFormat.fromString(getContentType()));
-                } finally {
-                    this.close();
-                }
-            }
-            return serviceDocument;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV3MetadataRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV3MetadataRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV3MetadataRequest.java
deleted file mode 100644
index c50b949..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV3MetadataRequest.java
+++ /dev/null
@@ -1,39 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.metadata.EdmV3Metadata;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.ComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.DataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.Edmx;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.EntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.EntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.FunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.v3.Schema;
-import java.net.URI;
-
-public class ODataV3MetadataRequest extends ODataMetadataRequest<
-        EdmV3Metadata, Edmx, DataServices, Schema, EntityContainer, EntityType, ComplexType, FunctionImport> {
-
-    public ODataV3MetadataRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, uri);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/olingo-odata4/blob/19f3792f/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV4MetadataRequest.java
----------------------------------------------------------------------
diff --git a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV4MetadataRequest.java b/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV4MetadataRequest.java
deleted file mode 100644
index 20a383f..0000000
--- a/ODataJClient/engine/src/main/java/com/msopentech/odatajclient/engine/communication/request/retrieve/ODataV4MetadataRequest.java
+++ /dev/null
@@ -1,39 +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 com.msopentech.odatajclient.engine.communication.request.retrieve;
-
-import com.msopentech.odatajclient.engine.client.ODataClient;
-import com.msopentech.odatajclient.engine.metadata.EdmV4Metadata;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.ComplexType;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.DataServices;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.Edmx;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.EntityContainer;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.EntityType;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.FunctionImport;
-import com.msopentech.odatajclient.engine.metadata.edm.v4.Schema;
-import java.net.URI;
-
-public class ODataV4MetadataRequest extends ODataMetadataRequest<
-        EdmV4Metadata, Edmx, DataServices, Schema, EntityContainer, EntityType, ComplexType, FunctionImport> {
-
-    public ODataV4MetadataRequest(final ODataClient odataClient, final URI uri) {
-        super(odataClient, uri);
-    }
-
-}


Mime
View raw message