diff options
author | Seshu Kumar M <seshu.kumar.m@huawei.com> | 2019-04-17 14:46:48 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2019-04-17 14:46:48 +0000 |
commit | f31f8ce722efcb2465d290cc3755c258ef2857af (patch) | |
tree | 82d1716be29aca2614051f8acb4e965a05f19ae8 | |
parent | 48d3624fdf93d88f299e8b116ec7ee9c254450d7 (diff) | |
parent | 77bcf35cbb626ef78329862549329fd809125017 (diff) |
-rw-r--r-- | openstack-client/src/main/java/com/woorea/openstack/base/client/OpenStackRequest.java | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/openstack-client/src/main/java/com/woorea/openstack/base/client/OpenStackRequest.java b/openstack-client/src/main/java/com/woorea/openstack/base/client/OpenStackRequest.java index 3a082a2..3374a10 100644 --- a/openstack-client/src/main/java/com/woorea/openstack/base/client/OpenStackRequest.java +++ b/openstack-client/src/main/java/com/woorea/openstack/base/client/OpenStackRequest.java @@ -26,6 +26,18 @@ import java.util.Map; public class OpenStackRequest<R> { private OpenStackClient client; + + private String endpoint; + + private HttpMethod method; + + private StringBuilder path = new StringBuilder(); + + private Map<String, List<Object>> headers = new HashMap<>(); + + private Entity<?> entity; + + private Class<R> returnType; public OpenStackRequest() { @@ -39,18 +51,7 @@ public class OpenStackRequest<R> { this.returnType = returnType; header("Accept", "application/json"); } - - private String endpoint; - - private HttpMethod method; - - private StringBuilder path = new StringBuilder(); - - private Map<String, List<Object>> headers = new HashMap<>(); - - private Entity<?> entity; - - private Class<R> returnType; + public OpenStackRequest<R> endpoint(String endpoint) { this.endpoint = endpoint; |