[jdom-interest] Text class (Modified)
Amy Lewis
amyzing at talsever.com
Sun May 27 17:55:43 PDT 2001
On Sun, May 27, 2001 at 04:22:12PM -0700, Jason Hunter wrote:
>Brett McLaughlin wrote:
>>
>> public boolean equals(Object ob) {
>> if (ob instanceof Text) {
>> if (((Text)ob).value.equals(value)) {
>> return true;
>> }
>> }
>> return false;
>> }
>> }
>
>That needs to be == and final, the same as for other nodes.
Should that pattern be opened to review? Is object identity something
that the API should enforce? Subclasses can't change that semantic,
note.
Amy!
--
Amelia A. Lewis alicorn at mindspring.com amyzing at talsever.com
Did you exchange a walk-on part in the war for the lead role in a cage?
-- Pink Floyd
More information about the jdom-interest
mailing list