|
WebObjects 5.2.3 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.webobjects.eointerface.EOWidgetAssociation.WidgetPlugin com.webobjects.eointerface.EOValueAssociation.ValuePlugin com.webobjects.eointerface.cocoa.EOCocoaCheckBoxPlugin
EOCocoaCheckBoxPlugin is used in Cocoa applications to connect check box
buttons and button cells to value associations. Check boxes in Cocoa are
buttons with an "on" state and an "off" state. This plugin handles
setting the state of the checkbox on behalf of its value association
and handles reporting the checkbox state to its value association as
a Boolean. When the user changes the state of the check box in the
interface, this plugin invokes its association's widgetDidChange
method.
Object Keys Taken: target, action When the user chooses an item in the display object, the EOValueSelectionAssociation updates the selected object's property with the item's title, tag, or object.
Usage:
Association classes: EOValueAssociation
Widget classes: NSButton, NSButtonCell
Nested Class Summary |
Nested classes inherited from class com.webobjects.eointerface.EOWidgetAssociation.WidgetPlugin |
EOWidgetAssociation.WidgetPlugin.Formatting |
Constructor Summary | |
EOCocoaCheckBoxPlugin(EOWidgetAssociation association,
Object widget)
Creates a new EOCocoaCheckBoxPlugin for use with association and widget. |
Method Summary | |
void |
breakConnection()
Tells the plugin to halt communication with its NSButton object. |
void |
establishConnection()
Establishes a connection between the plugin and its UI widget. |
void |
setValue(Object value,
boolean isEnabled)
Sets the state of this plugin's checkbox based on value and isEnabled . |
Object |
value()
Returns a Boolean object representing the state of this plugin's checkbox. |
String[] |
widgetKeysTaken()
Returns an array of Strings which represent outlet names in Interface Builder. |
Methods inherited from class com.webobjects.eointerface.EOValueAssociation.ValuePlugin |
endEditing, useURLAsValue |
Methods inherited from class com.webobjects.eointerface.EOWidgetAssociation.WidgetPlugin |
association, dispose, unacceptableAspects, widget |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public EOCocoaCheckBoxPlugin(EOWidgetAssociation association, Object widget)
association
- EOValueAssociation for this plugin to communicate withwidget
- the UI widget for this plugin to manageMethod Detail |
public void breakConnection()
breakConnection
in class EOWidgetAssociation.WidgetPlugin
public void establishConnection()
establishConnection
in class EOWidgetAssociation.WidgetPlugin
public void setValue(Object value, boolean isEnabled)
value
and isEnabled
.
If value
is a Boolean object whose boolean value returns true
,
or if value
is a Number object that does not represent 0,
the checkbox will be checked ("on" state), otherwise, the
check box will remain unchecked ("off" state). If value
is any other type
or null
, the checkbox will be left in the default "off" state.
setValue
in class EOValueAssociation.ValuePlugin
value
- Object to use in setting the state of this plugin's
checkbox.isEnabled
- if true
, the checkbox will be enabled in the interface
so its value can be changed; otherwise, the checkbox will be disabledpublic Object value()
value
in class EOValueAssociation.ValuePlugin
true
if the checkbox is checked, false
otherwise.public String[] widgetKeysTaken()
EOCocoaCheckBoxPlugin takes over outlets with keys "action" and "target".
widgetKeysTaken
in class EOWidgetAssociation.WidgetPlugin
|
Last updated Thu Oct 21 15:04:16 PDT 2004. | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |