oltu-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r1524413 - /oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java
Date Wed, 18 Sep 2013 13:52:06 GMT
Author: simonetripodi
Date: Wed Sep 18 13:52:06 2013
New Revision: 1524413

URL: http://svn.apache.org/r1524413
Log:
OLTU-118 - Implement JWS of the JOSE working group

dropped unused Header#Builder inner class

Modified:
    oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java

Modified: oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java
URL: http://svn.apache.org/viewvc/oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java?rev=1524413&r1=1524412&r2=1524413&view=diff
==============================================================================
--- oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java (original)
+++ oltu/trunk/jose/jws/src/main/java/org/apache/oltu/jose/jws/Header.java Wed Sep 18 13:52:06
2013
@@ -178,136 +178,4 @@ public final class Header {
         return customFields.entrySet();
     }
 
-    public static final class Builder {
-
-        /**
-         * The {@code alg} JWS Header parameter.
-         */
-        private String algorithm;
-
-        /**
-         * The {@code jku} JWS Header parameter.
-         */
-        private String jwkSetUrl;
-
-        /**
-         * The {@code jwk} JWS Header parameter.
-         */
-        private String jsonWebKey;
-
-        /**
-         * The {@code x5u} JWS Header parameter.
-         */
-        private String x509url;
-
-        /**
-         * The {@code x5t} JWS Header parameter.
-         */
-        private String x509CertificateThumbprint;
-
-        /**
-         * The {@code x5c} JWS Header parameter.
-         */
-        private String x509CertificateChain;
-
-        /**
-         * The {@code kid} JWS Header parameter.
-         */
-        private String keyId;
-
-        /**
-         * The {@code typ} JWS Header parameter.
-         */
-        private String type;
-
-        /**
-         * The {@code cty} JWS Header parameter.
-         */
-        private String contentType;
-
-        /**
-         * The {@code crit} JWS Header parameter.
-         */
-        private String[] critical;
-
-        /**
-         * The registry that keeps the custom fields.
-         */
-        private final Map<String, Object> customFields = new LinkedHashMap<String,
Object>();
-
-        public Builder setAlgorithm(String algorithm) {
-            this.algorithm = algorithm;
-            return this;
-        }
-
-        public Builder setJwkSetUrl(String jwkSetUrl) {
-            this.jwkSetUrl = jwkSetUrl;
-            return this;
-        }
-
-        public Builder setJsonWebKey(String jsonWebKey) {
-            this.jsonWebKey = jsonWebKey;
-            return this;
-        }
-
-        public Builder setX509url(String x509url) {
-            this.x509url = x509url;
-            return this;
-        }
-
-        public Builder setX509CertificateThumbprint(String x509CertificateThumbprint) {
-            this.x509CertificateThumbprint = x509CertificateThumbprint;
-            return this;
-        }
-
-        public Builder setX509CertificateChain(String x509CertificateChain) {
-            this.x509CertificateChain = x509CertificateChain;
-            return this;
-        }
-
-        public Builder setKeyId(String keyId) {
-            this.keyId = keyId;
-            return this;
-        }
-
-        public Builder setType(String type) {
-            this.type = type;
-            return this;
-        }
-
-        public Builder setContentType(String contentType) {
-            this.contentType = contentType;
-            return this;
-        }
-
-        public Builder setCritical(String[] critical) {
-            this.critical = critical;
-            return this;
-        }
-
-        public Builder setCustomField(String key, String value) {
-            if (key == null) {
-                throw new IllegalArgumentException("Null key not allowed.");
-            }
-            if (value != null) {
-                customFields.put(key, value);
-            }
-            return this;
-        }
-
-        public Header build() {
-            return new Header(algorithm,
-                              jwkSetUrl,
-                              jsonWebKey,
-                              x509url,
-                              x509CertificateThumbprint,
-                              x509CertificateChain,
-                              keyId, type,
-                              contentType,
-                              critical,
-                              customFields);
-        }
-
-    }
-
 }



Mime
View raw message