|
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.appserver.WOElement com.webobjects.appserver.WOComponent com.webobjects.directtoweb.D2WComponent com.webobjects.directtoweb.D2WPage com.webobjects.directtoweb.D2WListPage
The D2WListPage class provides the behavior for the list page and select page Direct to Web templates, specifically BASListPage, NEUListPage, and WOLListPage. The classes for these components inherit directly from D2WListPage and define no additional methods or variables.
D2WPlainListPage also inherits from this class.
Most of the methods in this class are accessed, via the EOKeyValueCoding interface defined in the EOControl framework, from the bindings (.wod) file of the Direct to Web template. If you create a Direct to Web template from a list page or select page, you can invoke the methods in this class in the same way.
Nested Class Summary |
Nested classes inherited from class com.webobjects.appserver.WOComponent |
WOComponent.Event |
Nested classes inherited from class com.webobjects.foundation.NSKeyValueCoding |
NSKeyValueCoding.DefaultImplementation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.Null, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.Utility, NSKeyValueCoding.ValueAccessor |
Nested classes inherited from class com.webobjects.foundation.NSKeyValueCodingAdditions |
NSKeyValueCodingAdditions.DefaultImplementation, NSKeyValueCodingAdditions.Utility |
Nested classes inherited from class com.webobjects.foundation.NSValidation |
NSValidation.DefaultImplementation, NSValidation.Utility, NSValidation.ValidationException |
Field Summary |
Fields inherited from class com.webobjects.directtoweb.D2WComponent |
currentObjectKey |
Fields inherited from interface com.webobjects.foundation.NSKeyValueCoding |
NullValue |
Fields inherited from interface com.webobjects.foundation.NSKeyValueCodingAdditions |
KeyPathSeparator |
Constructor Summary | |
D2WListPage(WOContext aContext)
Creates an instance of D2WListPage with the specified context. |
Method Summary | |
String |
alternatingColorForRow()
Gets the alternating row background color. |
void |
appendToResponse(WOResponse r,
WOContext c)
Fetches on the display group if the editing context did save changes recently. |
WOComponent |
backAction()
Is invoked when the user clicks 'Return' in the list page. |
String |
backgroundColorForRow()
Gets the row background color. |
String |
backgroundColorForRowMethod()
Contributes to the template method that corresponds to the method backgroundColorForRow . |
String |
defaultSortKey()
Gets the default sort key. |
WOComponent |
deleteObjectAction()
Is invoked when the user clicks the delete button next to an object on the list page. |
WODisplayGroup |
displayGroup()
Gets the display group that contains the objects listed on the page. |
void |
editingContextDidSaveChanges(NSNotification notif)
Handles notifications when the editing context did save changes. |
WOComponent |
editObjectAction()
Is invoked when the user clicks the edit button next to an object on the list page. |
void |
finalize()
|
WOComponent |
inspectObjectAction()
Is invoked when the user clicks the inspect button next to an object on the list page. |
boolean |
isEntityReadOnly()
Indicates whether the entity displayed on this page can be modified. |
boolean |
isListEmpty()
Indicates whether the list displayed contains no objects. |
boolean |
isSelecting()
Indicates whether the page is a select page. |
int |
listSize()
Gets the total number of objects in the display group. |
int |
numberOfObjectsPerBatch()
Gets the batch size of the display group. |
WOAssociation |
replacementAssociationForAssociation(WOAssociation oldAssociation,
String oldBinding,
com.webobjects.directtoweb.generation.DTWTemplate aTemplate,
WOContext aContext)
Replaces the following bindings: isListEmpty ,
d2wContext.propertyKey ,
d2wContext.justification ,
d2wContext.displayNameForProperty , object ,
displayedObjects . |
EOEnterpriseObject |
selectedObject()
Gets the selected object of the display group. |
WOComponent |
selectObjectAction()
Is invoked when the user clicks 'Select' next to one of the objects on the select page. |
void |
setBackgroundColorForRow(String newValue)
Sets the row background color to the specified value. |
void |
setDataSource(EODataSource dataSource)
Sets the data source to the specified data source. |
void |
setLocalContext(D2WContext newValue)
Sets the local context to the specified D2WContext. |
void |
setSelectedObject(EOEnterpriseObject selectedObject)
Selects the object in the display group if the specified object is not null; clears the selection of the display group otherwise. |
Methods inherited from class com.webobjects.directtoweb.D2WPage |
alternateRowColor, dataSource, descriptionForResponse, extraBindings, nextPage, nextPageDelegate, pageWrapperName, setExtraBindings, setNextPage, setNextPageDelegate, showCancel |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.webobjects.directtoweb.ListPageInterface |
setNextPage, setNextPageDelegate |
Methods inherited from interface com.webobjects.directtoweb.SelectPageInterface |
nextPageDelegate, setNextPageDelegate |
Constructor Detail |
public D2WListPage(WOContext aContext)
aContext
- instance of WOContexteditingContextDidSaveChanges(NSNotification)
,
D2WPage.D2WPage(WOContext)
,
NSNotificationCenter
Method Detail |
public String alternatingColorForRow()
The current implementation returns "#FFFF00" if the task is
"select" and the object is selected in the display group; the value
of the method alternatingColorForRow
otherwise.
The implementation is subject to change in future releases.
D2WPage.alternateRowColor()
,
D2WComponent.backgroundColorForTable()
,
D2WComponent.backgroundColorForTableDark()
public void appendToResponse(WOResponse r, WOContext c)
appendToResponse
in class WOComponent
r
- instance of WOResponsec
- instance of WOContexteditingContextDidSaveChanges(com.webobjects.foundation.NSNotification)
,
WOComponent.WOComponent(WOContext)
public WOComponent backAction()
nextPage
. You can also specify custom behavior for this
action by overriding the method nextPageDelegate
;
in this case, the method nextPage
is ignored.
D2WPage.nextPage()
,
D2WPage.nextPageDelegate()
public String backgroundColorForRow()
The current implementation return "#FFFF00" if the task is
"select" and the object is selected in the display group; the value
of the method alternatingColorForRow
otherwise.
The implementation is subject to change in future releases.
displayGroup()
,
alternatingColorForRow()
,
D2WComponent.task()
,
D2WComponent.object()
public String backgroundColorForRowMethod()
backgroundColorForRow
.
The implementation is subject to change in future releases.
backgroundColorForRow
backgroundColorForRow()
,
replacementAssociationForAssociation(WOAssociation, String, DTWTemplate, WOContext)
public String defaultSortKey()
The current implementation takes the first attribute in the display property keys.
The implementation is subject to change in future releases.
D2WComponent.displayPropertyKeys()
public WOComponent deleteObjectAction()
public WODisplayGroup displayGroup()
public WOComponent editObjectAction()
public void editingContextDidSaveChanges(NSNotification notif)
notif
- instance of NSNotificationD2WListPage(WOContext)
,
appendToResponse(WOResponse, WOContext)
public void finalize() throws Throwable
finalize
in class D2WPage
Throwable
public WOComponent inspectObjectAction()
public boolean isEntityReadOnly()
The current implementation returns true if the value for the key "readOnly" in the D2WContext is D2WModel.One; false otherwise.
The implementation is subject to change in future releases.
isEntityReadOnly
in class D2WComponent
D2WComponent.d2wContext()
,
D2WModel.One
public boolean isListEmpty()
listSize()
public boolean isSelecting()
The current implementation returns true if the task in the D2WContext equals "select"; false otherwise.
The implementation is subject to change in future releases.
public int listSize()
public int numberOfObjectsPerBatch()
The current implementation parses the value for the key "batchSize" in the D2WContext and returns the int if parsing succeeds; 10 otherwise.
The implementation is subject to change in future releases.
displayGroup()
,
D2WComponent.d2wContext()
public WOAssociation replacementAssociationForAssociation(WOAssociation oldAssociation, String oldBinding, com.webobjects.directtoweb.generation.DTWTemplate aTemplate, WOContext aContext)
isListEmpty
,
d2wContext.propertyKey
,
d2wContext.justification
,
d2wContext.displayNameForProperty
, object
,
displayedObjects
.
May also replace the bindings showCancel
and
selectObjectAction
.
The implementation is subject to change in future releases.
replacementAssociationForAssociation
in interface com.webobjects.directtoweb.generation.DTWGeneration
replacementAssociationForAssociation
in class D2WPage
oldAssociation
- instance of WOAssociationoldBinding
- instance of StringaTemplate
- instance of DTWTemplateaContext
- instance of WOContext
isListEmpty()
,
setDataSource(EODataSource)
,
selectObjectAction()
,
D2WPage.showCancel()
,
D2WPage.replacementAssociationForAssociation(WOAssociation, String, DTWTemplate, WOContext)
,
D2WComponent.object()
,
D2WContext.propertyKey()
,
D2WContext.displayNameForProperty()
public WOComponent selectObjectAction()
nextPageDelegate
.
D2WPage.nextPageDelegate()
public EOEnterpriseObject selectedObject()
selectedObject
in interface SelectPageInterface
displayGroup()
,
setSelectedObject(EOEnterpriseObject)
public void setBackgroundColorForRow(String newValue)
The current implementation does nothing.
The implementation is subject to change in future releases.
newValue
- instance of String - ignoredbackgroundColorForRow()
public void setDataSource(EODataSource dataSource)
setDataSource
in interface ListPageInterface
setDataSource
in class D2WPage
dataSource
- instance of EODataSourceD2WPage.setDataSource(com.webobjects.eocontrol.EODataSource)
,
displayGroup()
public void setLocalContext(D2WContext newValue)
The current implementation also supports sorting the first column of the List Page and affects the display of sort icons.
The implementation is subject to change in future releases.
setLocalContext
in class D2WComponent
newValue
- instance of D2WContextdisplayGroup()
,
numberOfObjectsPerBatch()
,
defaultSortKey()
public void setSelectedObject(EOEnterpriseObject selectedObject)
setSelectedObject
in interface SelectPageInterface
selectedObject
- instance of EOEnterpriseObjectselectedObject()
|
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 |