1 16 package org.outerj.daisy.emailnotifier; 17 18 import org.outerj.daisy.repository.VariantKey; 19 20 24 public class CollectionSubscriptionKey implements Comparable { 27 private VariantKey delegate; 28 29 public CollectionSubscriptionKey(long collectionId, long branchId, long languageId) { 30 this.delegate = new VariantKey(collectionId, branchId, languageId); 31 } 32 33 public long getCollectionId() { 34 return delegate.getDocumentId(); 35 } 36 37 public long getBranchId() { 38 return delegate.getBranchId(); 39 } 40 41 public long getLanguageId() { 42 return delegate.getLanguageId(); 43 } 44 45 public int hashCode() { 46 return delegate.hashCode(); 47 } 48 49 public boolean equals(Object obj) { 50 return delegate.equals(obj); 51 } 52 53 public int compareTo(Object o) { 54 CollectionSubscriptionKey otherKey = (CollectionSubscriptionKey)o; 55 return delegate.compareTo(otherKey.delegate); 56 } 57 } 58 | Popular Tags |