Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Subclass final class (Boolean) ?



Erik,

To define a custom type for webobjects, you have to give it the class, the method for construction from your primitive type, and the method to extract your primitive type from that object.  Therefore, no way to get helper classes involved...

Ken

On Aug 27, 2006, at 11:56 AM, Erik Mattheis wrote:

Ultimately, the code behind the scenes is going to be nicer with a primitive boolean value to evaluate, so why not just create some method (sorry, I'm not familiar with WebObjects) that will evaluate the input string and give you a primitive boolean? Seems like you just want something like return myInputString.equalsIgnoreCase("Y").


Also, why have an interface where a boolean value is represented by a String at all? Can't you use a checkbox or radio button that was designed to have exactly two discrete states?


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden

This email sent to email@hidden

References: 
 >Subclass final class (Boolean) ? (From: Ken Anderson <email@hidden>)
 >Re: Subclass final class (Boolean) ? (From: Andrei Tchijov <email@hidden>)
 >Re: Subclass final class (Boolean) ? (From: Ken Anderson <email@hidden>)
 >Re: Subclass final class (Boolean) ? (From: Erik Mattheis <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.