|
SAP NetWeaver 2004S SPS 10 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sapportals.htmlb.Component
com.sapportals.htmlb.Container
com.sapportals.htmlb.Form
The Form element which encapsulates all entry or event-firing controls.
Copyright 2004 SAP AG
| Nested Class Summary | |
class |
Form.FormElement
internal class for encapsulating form meta-data |
| Field Summary | |
static String |
UI_ID
|
static int |
VAR_BEGIN
constant for render call. render the begin of the form |
static int |
VAR_END
constant for render call. render the end of the form |
| Fields inherited from class com.sapportals.htmlb.Container |
elements |
| Constructor Summary | |
Form()
Application developers should |
|
Form(String formId)
Application developers should |
|
| Method Summary | |
void |
addForcedEnabledElement(String generatedId,
Component component)
internal use only |
void |
addForceJavascriptInterface(IJavascriptComponent c,
String generatedId)
|
void |
addFormEndJavascript(JavascriptFragment javascript)
|
void |
addFullIdFormElement(String componentId,
String fullId)
|
void |
addStandAloneHoverMenusAsString(StringBuffer hoverMenusAsString)
|
void |
clearForceJavascriptInterface()
|
void |
clearFormEndJavascripts()
|
void |
decodeFormElements(String encodedString)
decode Form meta-data from a String representation. |
String |
encodeFormElements()
encode all form elements in a String. |
String |
getAction()
get the action for this form, i.e. the URL that will receive the request for this form when submitted |
Class |
getClassForId(int index)
INTERNAL USE ONLY. |
String |
getClassIdForComponent(String name)
INTERNAL USE ONLY. |
String |
getClassIdForComponent(String tableName,
String name)
INTERNAL USE ONLY. |
ClassLoader |
getClassLoader()
|
Component |
getComponentById(String id)
INTERNAL USE ONLY. |
String |
getComponentIdForLabel(String id)
INTERNAL USE ONLY. |
IEventModifier |
getCurrentEventModifier()
|
Button |
getDefaultButton()
get the current default button for this page. |
String |
getEncodingType()
get the encoding type for this form, e.g. |
ArrayList |
getEventModifier()
|
String |
getEventNameForId(int index)
INTERNAL USE ONLY. |
Component |
getFocusedControl()
get the control which will get the focus after loading the page |
HashMap |
getForcedEnabledElement()
internal use only |
TreeMap |
getForceJavascriptInterface()
|
ArrayList |
getFormEndJavascripts()
|
String |
getFormId()
get the Id of this form |
String |
getFullIdForComponent(Component component)
INTERNAL USE ONLY. |
String |
getFullIdForComponent(String name)
INTERNAL USE ONLY. |
String |
getFullIdForComponent(String modifierName,
String name,
int row)
INTERNAL USE ONLY. |
HashMap |
getFullIdFormElements()
|
HashSet |
getHoverMenus()
returns the hover menus for rendering |
int |
getIdForClass(Class aClass)
INTERNAL USE ONLY. |
int |
getIdForEvent(String eventName)
INTERNAL USE ONLY. |
int |
getIndexOfElement(Component component)
internal use. |
int |
getIndexOfLabel(String id)
|
String |
getLanguage()
gets the language identification for this component. |
MessageBar |
getMessageBar()
|
String |
getMethod()
get the method associated with this form, either 'GET' or 'POST' |
Iterator |
getRegisteredElementNames()
get a HashMap containing all registered elements for this form. |
HashMap |
getRegisteredElements()
get a HashMap containing all registered elements for this form. |
HashSet |
getScrollContainerSet()
|
StringBuffer |
getStandAloneHoverMenusAsString()
|
String |
getTarget()
get the target frame for this form |
String |
getUI()
get a identification String for the renderer that is unique across all supported components. |
String |
getUserIdForIndex(int index)
INTERNAL USE ONLY. |
HashSet |
getValueHelpMappingFields()
returns the value help mapping fields |
boolean |
isDiscardFocusFirstElement()
|
boolean |
isHeightInHundredPercent()
returns if the height should be in hundert percent |
boolean |
isLabeled(String id)
|
boolean |
isLoadingMessage()
|
boolean |
isMessageBarAtFormEnd()
|
boolean |
isMessageBarRequired()
returns if a message bar is required for this form or not |
boolean |
isScrollingToLastPosition()
|
boolean |
isUserDefinedMessageBar()
|
boolean |
isWidthInHundredPercent()
returns if the width of the form is hundert percent |
IEventModifier |
popEventModifier()
|
void |
pushEventModifier(IEventModifier eventModifier)
|
protected int |
registerFormElement(Component component)
INTERNAL USE ONLY. |
int |
registerFormElement(Component component,
String id)
INTERNAL USE ONLY. |
void |
registerHoverMenu(HoverMenu hoverMenu)
register the hover menu hover menus within one page should be collected before they'll be rendered, for saving performance |
void |
registerScrollContainer(String id)
|
void |
registerValueHelpMappingField(InputField field)
register the value help mapping fields |
void |
setAction(String theAction)
set the action for this form, i.e. the URL that will receive the request for this form when submitted |
void |
setClassLoader(ClassLoader classLoader)
|
void |
setDefaultButton(Button defaultButton)
sets the current default button for this page. |
void |
setDiscardFocusFirstElement(boolean discardFocus)
If false (default) the focus in 508 mode should go to the first possible element. |
void |
setEncodingType(String theEncodingType)
set the encoding type for this form, e.g. |
void |
setFocusedControl(Button focusedButton)
set the control which will get the focus after loading the page |
void |
setFocusedControl(Component focusedComponent)
set the control which will get the focus after loading the page |
void |
setFocusedControl(DropdownListBox focusedDropdownListBox)
set the control which will get the focus after loading the page |
void |
setFocusedControl(InputField focusedInputField)
set the control which will get the focus after loading the page |
void |
setFocusedControl(TextEdit focusedTextEdit)
set the control which will get the focus after loading the page |
void |
setFormId(String theFormId)
set the Id of this form. |
void |
setHeightInHundredPercent(boolean heightInHundredPercent)
sets the height of the form to 100% |
void |
setLanguage(String language)
sets the language identification for this component. |
void |
setLoadingMessage(boolean show)
|
void |
setMessageBar(MessageBar messageBar)
sets the message bar for validation |
void |
setMessageBarAtFormEnd(boolean messageBarAtBodyEnd)
|
void |
setMessageBarRequired(boolean messageBarRequired)
determines if a message bar is required for this form or not |
void |
setMethod(String theMethod)
set the method associated with this form, either 'GET' or 'POST' |
void |
setScrollingToLastPosition(boolean scrollingToLastPosition)
|
void |
setTarget(String target)
set the target frame for this form. |
void |
setUserDefinedMessageBar(boolean userDefinedMessageBar)
|
void |
setWidthInHundredPercent(boolean widthInHundredPercent)
sets the width of the form to hundert percent |
| Methods inherited from class com.sapportals.htmlb.Container |
addComponent, addRawText, addText, getChildCount, iterator, preRender, removeComponent, render |
| Methods inherited from class com.sapportals.htmlb.Component |
getEncodedIdForForm, getId, getParent, initFromPageContext, initFromShortId, initializeFromId, isJsObjectNeeded, render, renderAsString, requiresForm, setId, setJsObjectNeeded, setParent |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final String UI_ID
public static final int VAR_BEGIN
public static final int VAR_END
| Constructor Detail |
public Form()
convenience constructor for a new form. An ID will automatically be supplied.
IPageContext.createForm(),
IPageContext.createFormDocument(String)public Form(String formId)
creates a Form with a given ID.
formId - the Id to be used for this form. Must be
'clean' for HTML usage!IPageContext.createForm(),
IPageContext.createFormDocument(String)| Method Detail |
public void pushEventModifier(IEventModifier eventModifier)
public IEventModifier popEventModifier()
public IEventModifier getCurrentEventModifier()
public ArrayList getEventModifier()
public String getUI()
getUI in class Componentpublic String getMethod()
public void setMethod(String theMethod)
theMethod - the method to be usedpublic String getAction()
public void setAction(String theAction)
theAction - the Action, i.e. URL for this formpublic String getFormId()
public void setFormId(String theFormId)
theFormId - the idpublic String getEncodingType()
public void setEncodingType(String theEncodingType)
theEncodingType - the encoding type for this form.public String getTarget()
public void setTarget(String target)
target - the target for this formpublic Button getDefaultButton()
public void setDefaultButton(Button defaultButton)
defaultButton - the default Button for this formpublic Component getFocusedControl()
public void setFocusedControl(InputField focusedInputField)
focusedInputField - input field which should get the focuspublic void setFocusedControl(DropdownListBox focusedDropdownListBox)
public void setFocusedControl(TextEdit focusedTextEdit)
public void setFocusedControl(Button focusedButton)
focusedButton - button which should get the focuspublic void setFocusedControl(Component focusedComponent)
public String getLanguage()
public void setLanguage(String language)
language - a String representing the language for this componentprotected int registerFormElement(Component component)
component - the component to include
public int registerFormElement(Component component,
String id)
component - the component to include
public int getIndexOfElement(Component component)
component - the component
public HashMap getRegisteredElements()
public Iterator getRegisteredElementNames()
public int getIdForEvent(String eventName)
eventName - the name of the event
public String getEventNameForId(int index)
index - the int id of the event
public int getIdForClass(Class aClass)
aClass - the class
public Class getClassForId(int index)
index - the int id of the event
public String encodeFormElements()
public void decodeFormElements(String encodedString)
encodedString - the String containing the encoded informationpublic String getFullIdForComponent(Component component)
gets a unique ID for a component for encoding in the generated output.
component - the component for which a unique ID is requestedIPageContext.getParamIdForComponent(Component)public void registerHoverMenu(HoverMenu hoverMenu)
public HashSet getHoverMenus()
public String getComponentIdForLabel(String id)
public int getIndexOfLabel(String id)
public boolean isLabeled(String id)
public String getFullIdForComponent(String name)
for retrieving the old ID after submission
name - the id of the original component as specified by the
application developer
IPageContext.getParamIdForComponent(String)public Component getComponentById(String id)
for retrieving the a component by ID during rendering warning: this does not work for reference to controls contained in some modifier from outside of the scope of that modifier. from within the same modifier it may work but is highly at risk someone should write a test that uses eventing within a table row to check.
id - the id of the component as specified by the
application developer
public String getUserIdForIndex(int index)
get the component name for the component at the index position within this form
index - the index of the component within this form
public String getFullIdForComponent(String modifierName,
String name,
int row)
for retrieving the old ID after submission
modifierName - the id of the outer component, e.g. a TableViewname - the id of the original component as specified by the
application developer
IPageContext.getTableComponentForId(String,String,int)public String getClassIdForComponent(String name)
gets an ID for the class of the component with the specified id
name - the id of the component
public String getClassIdForComponent(String tableName,
String name)
gets an ID for the class of the component with the specified id
tableName - the id of the outer component, e.g. a TableViewname - the id of the component
public void addFormEndJavascript(JavascriptFragment javascript)
public ArrayList getFormEndJavascripts()
public void clearFormEndJavascripts()
public void addForceJavascriptInterface(IJavascriptComponent c,
String generatedId)
public TreeMap getForceJavascriptInterface()
public void clearForceJavascriptInterface()
public boolean isScrollingToLastPosition()
public void setScrollingToLastPosition(boolean scrollingToLastPosition)
public void addFullIdFormElement(String componentId,
String fullId)
public HashMap getFullIdFormElements()
public MessageBar getMessageBar()
public void setMessageBar(MessageBar messageBar)
public boolean isUserDefinedMessageBar()
public void setUserDefinedMessageBar(boolean userDefinedMessageBar)
public boolean isMessageBarAtFormEnd()
public void setMessageBarAtFormEnd(boolean messageBarAtBodyEnd)
public void addStandAloneHoverMenusAsString(StringBuffer hoverMenusAsString)
public StringBuffer getStandAloneHoverMenusAsString()
public ClassLoader getClassLoader()
public void setClassLoader(ClassLoader classLoader)
public void registerScrollContainer(String id)
public HashSet getScrollContainerSet()
public boolean isMessageBarRequired()
public void setMessageBarRequired(boolean messageBarRequired)
public void addForcedEnabledElement(String generatedId,
Component component)
public HashMap getForcedEnabledElement()
public boolean isWidthInHundredPercent()
public void setWidthInHundredPercent(boolean widthInHundredPercent)
public boolean isHeightInHundredPercent()
public void setHeightInHundredPercent(boolean heightInHundredPercent)
public HashSet getValueHelpMappingFields()
public void registerValueHelpMappingField(InputField field)
public void setLoadingMessage(boolean show)
public boolean isLoadingMessage()
public boolean isDiscardFocusFirstElement()
public void setDiscardFocusFirstElement(boolean discardFocus)
|
SAP NetWeaver 2004S SPS 10 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||