| org.cougaar.core.util.UniqueObject
All known Subclasses: org.cougaar.servicediscovery.transaction.RelayAdapter, org.cougaar.pizza.relay.RSVPRelayTarget, org.cougaar.planning.ldm.policy.Policy, org.cougaar.glm.ldm.oplan.OplanCoupon, org.cougaar.pizza.relay.RSVPRelaySource, org.cougaar.demo.mandelbrot.v3.Job, org.cougaar.core.util.UniqueObjectBase, org.cougaar.community.requests.ListAgentParentCommunities, org.cougaar.glm.ldm.plan.CasRepImpl, org.cougaar.core.qos.frame.Frame, org.cougaar.mlm.plugin.organization.ReportChainReadyRelay, org.cougaar.core.qos.frame.Path, org.cougaar.lib.aggagent.query.QueryResultAdapter, org.cougaar.mlm.plugin.organization.ReportChainState, org.cougaar.core.plugin.deletion.SimpleDeletionPolicy, org.cougaar.logistics.plugin.inventory.ShortfallSummary, org.cougaar.planning.ldm.asset.Asset, org.cougaar.logistics.plugin.inventory.LogisticsOPlan, org.cougaar.logistics.plugin.policy.LogisticsPolicy, org.cougaar.mlm.plugin.organization.OpConInfoRelay, org.cougaar.glm.ldm.oplan.OrgRelation, org.cougaar.core.util.SimpleUniqueObject, org.cougaar.pizza.plugin.PizzaPreferences, org.cougaar.lib.web.axis.distance.DistanceQuery, org.cougaar.core.adaptivity.InterAgentOperatingMode, org.cougaar.core.adaptivity.InterAgentCondition, org.cougaar.community.requests.CommunityRequest, org.cougaar.glm.ldm.oplan.Oplan, org.cougaar.logistics.plugin.manager.RelayAdapter, org.cougaar.servicediscovery.description.Lineage,
UniqueObject | public interface UniqueObject extends Serializable(Code) | | An object with a
UID created by the
org.cougaar.core.service.UIDService .
The UID is often set by a
org.cougaar.core.domain.Domainorg.cougaar.core.domain.Factory , and/or as a final field
set in the object's constructor.
Objects that implement UniqueObject often use the UID for the
"equals(Object)" and "hashCode()" methods, e.g.
public class X implements UniqueObject .. {..
public boolean equals(Object o) {
return
(o == this ||
((o instanceof X) &&
getUID().equals(((X) o).getUID()));
}
public int hashCode() {
return getUID().hashCode();
}
}
|
Method Summary | |
UID | getUID() | void | setUID(UID uid) Set the UID of this UniqueObject, which may throw a
RuntimeException if the UID is already set. |
getUID | UID getUID()(Code) | | the UID of this UniqueObject. |
setUID | void setUID(UID uid)(Code) | | Set the UID of this UniqueObject, which may throw a
RuntimeException if the UID is already set.
|
|
|