1 18 package org.objectweb.speedo.pobjects.userid; 19 20 import java.io.Serializable ; 21 22 26 public class InnerUserId { 27 private String f1; 28 private int f2; 29 private long oid1; 30 private long oid2; 31 32 public InnerUserId() { 33 } 34 35 public InnerUserId(String f1, int f2, long oid1, long oid2) { 36 this.f1 = f1; 37 this.f2 = f2; 38 this.oid1 = oid1; 39 this.oid2 = oid2; 40 } 41 42 public InnerUserId(String f1, int f2, Oid oid) { 43 this.f1 = f1; 44 this.f2 = f2; 45 oid1 = oid.oid1; 46 oid2 = oid.oid2; 47 } 48 49 public String getF1() { 50 return f1; 51 } 52 53 public int getF2() { 54 return f2; 55 } 56 57 public long getOid1() { 58 return oid1; 59 } 60 61 public long getOid2() { 62 return oid2; 63 } 64 65 69 public static class Oid implements Serializable { 70 public long oid1; 71 public long oid2; 72 73 76 public Oid() { 77 oid1 = 0; 78 oid2 = 0; 79 } 80 81 84 public Oid(long o1, long o2) { 85 oid1 = o1; 86 oid2 = o2; 87 } 88 89 public boolean equals(java.lang.Object obj) { 90 if (obj == null || !this.getClass().equals(obj.getClass())) 91 return (false); 92 return oid1 == ((Oid) obj).oid1 && oid2 == ((Oid) obj).oid2; 93 } 94 95 public int hashCode() { 96 return ((int) oid1); 97 } 98 } 99 100 } 101 | Popular Tags |