> -----Original Message-----
> From: David Sean Taylor [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, July 11, 2001 4:46 PM
> To: [EMAIL PROTECTED]
> Subject: RE: org.apache.turbine.om.security TurbineUser/Group/Role
> classes need to override "equals"
>
>
> I thought you were using a WeakHashMap.
> Then you just do:
>
> map.put( role.getName(), role )
>
> However its not ordered. Does it need to be?
No, it need not be ordered, so it really doesn't need Comparable interface.
How about me implementing it in BaseProfileLocator for equality?
Role gets compared on role.getName()
Group gets compared on group.getName(),
and same goes withe the user..or do I have to use "user.getUserName()"
Language/Country is simple String equality.
-Atul
>
>
>
>
> > -----Original Message-----
> > From: Atul Dambalkar [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, July 11, 2001 4:37 PM
> > To: [EMAIL PROTECTED]
> > Subject: org.apache.turbine.om.security
> TurbineUser/Group/Role classes
> > need to override "equals"
> >
> >
> > Hi David/Raphael,
> >
> > This can be a low priority..as I do have a work around.
> >
> > TurbineUser/Group/Role classes need to override "boolean
> > equals(Object obj)
> > method from java.lang.Object, so as it to be comparable in a
> > java.util.Map
> > and may also implement java.lang.Comparable interface.
> >
> > -Atul
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]