1 17 18 19 package org.apache.naming; 20 21 22 28 29 public class NamingEntry { 30 31 32 34 35 public static final int ENTRY = 0; 36 public static final int LINK_REF = 1; 37 public static final int REFERENCE = 2; 38 39 public static final int CONTEXT = 10; 40 41 42 44 45 public NamingEntry(String name, Object value, int type) { 46 this.name = name; 47 this.value = value; 48 this.type = type; 49 } 50 51 52 54 55 59 public int type; 60 public String name; 61 public Object value; 62 63 64 66 67 public boolean equals(Object obj) { 68 if ((obj != null) && (obj instanceof NamingEntry)) { 69 return name.equals(((NamingEntry) obj).name); 70 } else { 71 return false; 72 } 73 } 74 75 76 public int hashCode() { 77 return name.hashCode(); 78 } 79 80 81 } 82 | Popular Tags |