marmotta-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wik...@apache.org
Subject git commit: added 200 as default http code expected by the response at ldclient for keeping backward compatibility (related with MARMOTTA-163)
Date Mon, 22 Jul 2013 13:09:38 GMT
Updated Branches:
  refs/heads/develop 2d70611c0 -> 6ae301d3f


added 200 as default http code expected by the response at ldclient for keeping backward compatibility
(related with MARMOTTA-163)


Project: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/commit/6ae301d3
Tree: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/tree/6ae301d3
Diff: http://git-wip-us.apache.org/repos/asf/incubator-marmotta/diff/6ae301d3

Branch: refs/heads/develop
Commit: 6ae301d3f7928009ba49c0eebe114bba4451e7db
Parents: 2d70611
Author: Sergio Fernández <wikier@apache.org>
Authored: Mon Jul 22 15:09:26 2013 +0200
Committer: Sergio Fernández <wikier@apache.org>
Committed: Mon Jul 22 15:09:26 2013 +0200

----------------------------------------------------------------------
 .../org/apache/marmotta/ldclient/model/ClientResponse.java   | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-marmotta/blob/6ae301d3/libraries/ldclient/ldclient-api/src/main/java/org/apache/marmotta/ldclient/model/ClientResponse.java
----------------------------------------------------------------------
diff --git a/libraries/ldclient/ldclient-api/src/main/java/org/apache/marmotta/ldclient/model/ClientResponse.java
b/libraries/ldclient/ldclient-api/src/main/java/org/apache/marmotta/ldclient/model/ClientResponse.java
index a34d4be..70ebf48 100644
--- a/libraries/ldclient/ldclient-api/src/main/java/org/apache/marmotta/ldclient/model/ClientResponse.java
+++ b/libraries/ldclient/ldclient-api/src/main/java/org/apache/marmotta/ldclient/model/ClientResponse.java
@@ -30,6 +30,8 @@ import java.util.Date;
  */
 public class ClientResponse {
 
+	private static final int DEFAULT_HTTP_CODE = 200;
+	
     private static final int DEFAULT_EXPIRATION_IN_DAYS = 7;
 
     /**
@@ -40,11 +42,15 @@ public class ClientResponse {
     private Repository triples;
 
     private Date expires;
+    
+    public ClientResponse(Repository triples) {
+    	this(DEFAULT_HTTP_CODE, triples);
+    }
 
     public ClientResponse(int httpStatus, Repository triples) {
         this.triples = triples;
         this.expires = DateUtils.addDays(new Date(), DEFAULT_EXPIRATION_IN_DAYS);
-        this.httpStatus = this.httpStatus;
+        this.httpStatus = httpStatus;
     }
 
     public Repository getTriples() {


Mime
View raw message