directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject [2/2] directory-kerby git commit: Added some Javadoc
Date Wed, 30 Dec 2015 12:19:49 GMT
Added some Javadoc

Project: http://git-wip-us.apache.org/repos/asf/directory-kerby/repo
Commit: http://git-wip-us.apache.org/repos/asf/directory-kerby/commit/047258b6
Tree: http://git-wip-us.apache.org/repos/asf/directory-kerby/tree/047258b6
Diff: http://git-wip-us.apache.org/repos/asf/directory-kerby/diff/047258b6

Branch: refs/heads/trunk
Commit: 047258b62285ecf17aa8e75c94eab8c8cf363924
Parents: 5c9c007
Author: Emmanuel L├ęcharny <elecharny@symas.com>
Authored: Wed Dec 30 13:19:25 2015 +0100
Committer: Emmanuel L├ęcharny <elecharny@symas.com>
Committed: Wed Dec 30 13:19:25 2015 +0100

----------------------------------------------------------------------
 .../kerberos/kerb/type/base/HostAddress.java    |  2 ++
 .../kerberos/kerb/type/base/HostAddresses.java  | 26 ++++++++++++++------
 2 files changed, 20 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/directory-kerby/blob/047258b6/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddress.java
----------------------------------------------------------------------
diff --git a/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddress.java
b/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddress.java
index 7b5cc3d..8bea901 100644
--- a/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddress.java
+++ b/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddress.java
@@ -37,6 +37,8 @@ import org.apache.kerby.kerberos.kerb.type.KrbSequenceType;
  *         address         [1] OCTET STRING
  * }
  * </pre>
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class HostAddress extends KrbSequenceType {
     /**

http://git-wip-us.apache.org/repos/asf/directory-kerby/blob/047258b6/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddresses.java
----------------------------------------------------------------------
diff --git a/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddresses.java
b/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddresses.java
index 21edb15..17bfd84 100644
--- a/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddresses.java
+++ b/kerby-kerb/kerb-core/src/main/java/org/apache/kerby/kerberos/kerb/type/base/HostAddresses.java
@@ -19,25 +19,35 @@
  */
 package org.apache.kerby.kerberos.kerb.type.base;
 
-import org.apache.kerby.kerberos.kerb.type.KrbSequenceOfType;
-
 import java.net.InetAddress;
 
+import org.apache.kerby.kerberos.kerb.type.KrbSequenceOfType;
+
 /**
- -- NOTE: HostAddresses is always used as an OPTIONAL field and
- -- should not be empty.
- HostAddresses   -- NOTE: subtly different from rfc1510,
- -- but has a value mapping and encodes the same
- ::= SEQUENCE OF HostAddress
+ * The HostAddress as defined in RFC 4120 :
+ * <pre>
+ * -- NOTE: HostAddresses is always used as an OPTIONAL field and
+ * -- should not be empty.
+ * HostAddresses   -- NOTE: subtly different from rfc1510,
+ *                 -- but has a value mapping and encodes the same
+ *         ::= SEQUENCE OF HostAddress
+ * </pre>
+ * 
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class HostAddresses extends KrbSequenceOfType<HostAddress> {
-
+    /**
+     * Tells if the list of HostAddresses contain a given HostAddress
+     * @param address The {@link InetAddress} we are looking for
+     * @return <tt>true</tt> if it's present
+     */
     public boolean contains(InetAddress address) {
         for (HostAddress hostAddress : getElements()) {
             if (hostAddress.equalsWith(address)) {
                 return true;
             }
         }
+        
         return false;
     }
 }


Mime
View raw message