|
Oracle Fusion Middleware JavaScript API Reference for Oracle ADF Faces 11g Release 2 (11.1.2.0.0) E17489-01 |
||||||||
PREV NEXT | FRAMES NO FRAMES Warning: private items are visible |
org.ecmascript.object.Object | +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDomUtils
public class AdfDomUtils extends Object
Field Summary |
|
---|---|
private static Object |
|
private static Object |
|
private static Object |
Fields inherited from org.ecmascript.object.Object |
constructor, prototype |
Constructor Summary |
|
---|---|
public |
Method Summary |
|
---|---|
public static Boolean |
|
public static Object |
|
public static Boolean |
|
public static Object |
|
private static Object |
|
public static Object |
|
static Object |
|
public static Boolean |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static HTMLElement |
|
public static Object |
|
public static HTMLElement |
|
private static Number |
|
public static HTMLElement |
|
public static Object |
|
public static Number |
|
public static HTMLElement |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static HTMLElement |
|
public static HTMLElement |
|
public static HTMLElement |
|
public static Object |
|
public static Object |
|
private static Object |
|
public static Object |
|
public static HTMLElement |
|
public static Object |
|
public static HTMLElement |
|
public static HTMLElement |
|
public static Number |
|
public static Object |
|
public static Number |
|
public static HTMLElement |
|
public static HTMLElement |
|
public static HTMLElement |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
private static Object |
|
public static Object |
|
public static Boolean |
|
private static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
private static Object |
|
public static Object |
|
public static Object |
|
private static Object |
|
private static Object |
|
public static Object |
|
public static Object |
|
public static Object |
|
public static Object |
Field Detail |
---|
private static Object _HELP_WINDOW_NAME_COOKIE
private static Object _LEGAL_ATTRIBUTES
private static Object _LEGAL_ELEMENTS
Constructor Detail |
---|
public AdfDomUtils()
Method Detail |
---|
public static Boolean addCSSClassName(HTMLElement domElement,
String className)
true
if the class name was added.domElement |
- | DOM Element to add style class name to |
className |
- | Name of style class to add
Default value = null
|
Boolean
- null true
if the style class was addedpublic static Object addInlineStyle(Object element,
Object newStyle,
Object takesPrecedence)
element |
||
newStyle |
||
takesPrecedence |
Object
public static Boolean addOrRemoveCSSClassName(Boolean add,
HTMLElement domElement,
String className)
add |
- | boolean value if we should do an add of a CSS className |
domElement |
- | DOM Element to remove style class name from |
className |
- | the CSS className which should be added or removed |
Boolean
- null true
if the element's style class list changedpublic static Object canScroll(Object domNode,
Object viewPortWidth,
Object viewPortHeight)
domNode |
||
viewPortWidth |
||
viewPortHeight |
Object
private static Object _cleanElementHtml(Object node)
node |
Object
public static Object cleanHtml(Object domDocument,
Object value)
domDocument |
||
value |
Object
static Object __componentTextChanged(Object component,
Object domElement,
Object newValue,
Object oldValue)
component |
||
domElement |
||
newValue |
||
oldValue |
Object
public static Boolean containsCSSClassName(HTMLElement domElement,
String className)
domElement |
- | DOM Element to check for the style className |
className |
- | the CSS className to check for |
Boolean
- null true
if the className is in the element's list of classespublic static Object fillEmptyCell(Object cell)
cell |
Object
public static Object findAccessKeyDom(Object domElement,
Object accessKeyValue)
domElement |
||
accessKeyValue |
Object
public static Object getAutoScrollDeltas(Object target,
Object clientX,
Object clientY)
target |
||
clientX |
||
clientY |
Object
public static HTMLElement getChildElementByPosition(Object parentElement,
Object type,
Object position)
parentElement |
- | the parent node |
type |
||
position |
- | the node position uder its parent element |
HTMLElement
- the position if currentElement is not nullpublic static Object getChildElements(Object parentElement)
parentElement |
Object
public static HTMLElement getCommonAncestor(HTMLElement nodeA,
HTMLElement nodeB)
nodeA |
- | One of the DOM nodes to count nodes between |
nodeB |
- | One of the DOM nodes to count nodes between |
HTMLElement
- null or the common ancestor of the two nodes.private static Number _getCSSClassNameIndex(String currentClassName,
String className)
className
appears within currentClassName
with either a space or the beginning or end of currentClassName
on either side. This function optimizes the runtime speed by not creating objects in most cases and assuming 1) It is OK to only check for spaces as whitespace characters 2) It is rare for the searched className to be a substring of another className, therefore if we get a hit on indexOf, we have almost certainly found our className 3) It is even rarer for the searched className to be a substring of more than one className, therefore, repeating the search from the end of the string should almost always either return our className or the original search hit from indexOfcurrentClassName |
- | Space-separated class name string to search |
className |
- | String to search for within currentClassName |
Number
- index of className in currentClassName, or -1 if it doesn't existpublic static HTMLElement getDescendentElement(HTMLElement parentElement,
String elementName,
Number index)
parentElement |
- | The parent DOM element under which to search for the descendent. |
elementName |
- | The name of the descendent element to find (eg. "SPAN"). |
index |
- | The numeric position of the descendent element, starting with "0". For clarification, 0 is the first position, 1 is the second position, etc. |
HTMLElement
- The descendent element if one is found, otherwise null.public static Object getElementAtPoint(Object element,
Object pageX,
Object pageY,
Object closestMatch)
element |
||
pageX |
||
pageY |
||
closestMatch |
Object
public static Number getElementDepth(HTMLElement element)
element |
- | the element whose depth is returned |
Number
- the number of nodes deep in the DOM treepublic static HTMLElement getElementPosition(Object currentElement)
currentElement |
- | the current node |
HTMLElement
- the position if currentElement is not nullpublic static Object getElementsByClassName(Object domNode,
Object className)
domNode |
||
className |
Object
public static Object getFirstChildElement(Object parentElement)
parentElement |
Object
public static Object getFirstChildNodeByType(Object parentElement,
Object type)
parentElement |
||
type |
Object
public static HTMLElement getFirstDescendentElement(HTMLElement parentElement,
String elementName)
parentElement |
- | The parent DOM element under which to search for the descendent. |
elementName |
- | The name of the descendent element to find (eg. "SPAN"). |
HTMLElement
- The descendent element if one is found, otherwise null.public static HTMLElement getFirstElementByTagName(Object domElement,
Object tagName)
domElement |
||
tagName |
HTMLElement
- the DOM within the component related to scopedIdpublic static HTMLElement getFirstElementMatch(HTMLElement element,
Boolean isExclusive,
Function matchFunc,
Object context)
element |
- | element to begin searching from |
isExclusive |
- | Whether to include provided element in the search |
matchFunc |
- | A function which is used to test whether a particular element is a match. The function takes a single argument - the element to test - and returns a boolean indicating whether the element is a match. |
context |
- | optional context for the match function |
HTMLElement
- The first matching element if one is found, null otherwise.public static Object getFormElement(Object node)
node |
Object
public static Object getFormElementValue(HTMLElement formElement,
String formElementName)
formElement |
- | the FORM element |
formElementName |
- | The name of the form element to get the value of. |
Object
private static Object _getHelpWindowName()
Object
public static Object getLastChildElement(Object parentElement)
parentElement |
Object
public static HTMLElement getLastElementMatch(HTMLElement element,
Boolean isExclusive,
Function matchFunc,
Object context)
element |
- | element to begin searching from |
isExclusive |
- | Whether to include provided element in the search |
matchFunc |
- | A function which is used to test whether a particular element is a match. The function takes a single argument - the element to test - and returns a boolean indicating whether the element is a match. |
context |
- | optional context for the match function |
HTMLElement
- The last matching element if one is found, null otherwise.public static Object getMultiPartForm(Object actionForm)
actionForm |
Object
public static HTMLElement getNextElement(Object currentElement)
currentElement |
- | the current node |
HTMLElement
- the nex sibiling element if found or null if notpublic static HTMLElement getNextElementMatch(HTMLElement element,
HTMLElement contextElement,
Boolean isExclusive,
Function matchFunc,
Object context)
element |
- | element to begin searching from |
contextElement |
- | The search is constrained to the subtree within the this element. If no context element is specified, the root document element is treated as the context element. |
isExclusive |
- | Whether to include the children of the provided element in the search.
Default value = false
|
matchFunc |
- | A function which is used to test whether a particular element is a match. The function takes a single argument - the element to test - and returns a boolean indicating whether the element is a match. |
context |
- | optional context for the match function |
HTMLElement
- The next matching element if one is found, null otherwise.public static Number getNodeDistance(HTMLElement nodeA,
HTMLElement nodeB)
nodeA |
- | One of the DOM nodes to count nodes between |
nodeB |
- | One of the DOM nodes to count nodes between |
Number
- zero if equal, the number of nodes between them, or Number.POSITIVE_INFINITY if the nodes are not connected.public static Object getNodeInfo(Object domNode)
domNode |
Object
public static Number getNonWhitespaceChildCount(HTMLElement parentElement)
parentElement |
- | the node whose children we want to count |
Number
- the number of child elements and non-whitespace text nodespublic static HTMLElement getOnlyChildElement(HTMLElement parentElement)
parentElement |
- | the node whose children we want to retrieve the sole child from |
HTMLElement
- the only child element or null if 0 or more than 1 displayed child is foundpublic static HTMLElement getPreviousElement(Object currentElement)
currentElement |
- | the current node |
HTMLElement
- the previous sibling element if found or null if notpublic static HTMLElement getPreviousElementMatch(HTMLElement element,
HTMLElement contextElement,
Function matchFunc,
Object context)
element |
- | element to begin searching from |
contextElement |
- | The search is constrained to the subtree within the this element. If no context element is specified, the root document element is treated as the context element. |
matchFunc |
- | A function which is used to test whether a particular element is a match. The function takes a single argument - the element to test - and returns a boolean indicating whether the element is a match. |
context |
- | optional context for the match function |
HTMLElement
- The previous matching element if one is found, null otherwise.public static Object getTabIndex(Object element)
element |
- | the element to get the property for |
Object
- the tab index, if specified otherwise undefinedpublic static Object handleTextChangeWithAccessKey(Object component,
Object domElement,
Object newValue)
component |
- | The component that the text changed for |
domElement |
- | The element that renders the text value for this component (not necessarily the root element for the component) |
newValue |
- | The new text value for the component |
Object
- true if the value was able to be setpublic static Object isAncestor(Object ancestorNode,
Object node)
ancestorNode |
||
node |
Object
public static Object isAncestorOrSelf(Object ancestorNode,
Object node)
ancestorNode |
||
node |
Object
public static Object isInVisibleSubtree(Object node)
node |
Object
public static Object isNodeInDocumentHierarchy(Object domDocument,
Object node)
node
is in the domDocument
's hierarchydomDocument |
||
node |
Object
public static Object isVisible(Object domElement)
domElement |
Object
public static Object launchHelpWindow(Object url)
url |
- | The url that should be displayed in the help window. |
Object
private static Object _removeAccessKeyElement(Object domElement,
Object accessKeyElement)
domElement |
||
accessKeyElement |
Object
public static Object removeAllNodes(HTMLElement element)
element |
- | the DOM element whose children will be removed |
Object
public static Boolean removeCSSClassName(HTMLElement domElement,
String className)
true
if the class name was removed.domElement |
- | DOM Element to remove style class name from |
className |
- | Name of style class to remove
Default value = null
|
Boolean
- null true
if the style class was removedprivate static Object _removeSiblings(Object domElement)
domElement |
Object
public static Object scrollChildIntoViewY(Object childElement)
childElement |
Object
public static Object scrollDownBy(Object domElement,
Object deltaY)
domElement |
||
deltaY |
Object
public static Object scrollRightBy(Object domElement,
Object deltaX)
domElement |
||
deltaX |
Object
public static Object setAccessibleState(Object component,
Object state)
component |
||
state |
Object
private static Object _setHelpWindowName(Object windowName)
windowName |
Object
public static Object setScrollLeft(Object domElement,
Object newScrollLeft)
domElement |
||
newScrollLeft |
Object
public static Object setScrollTop(Object domElement,
Object newScrollTop)
domElement |
||
newScrollTop |
Object
private static Object _setTextAndAccessKeySpan(Object component,
Object domElement,
Object accessKeyValue,
Object accessKeySpan,
Object newValue)
component |
||
domElement |
||
accessKeyValue |
||
accessKeySpan |
||
newValue |
Object
private static Object _setTextContent(Object domElement,
Object value)
domElement |
||
value |
Object
public static Object setVisible(Object domElement,
Object visible)
domElement |
||
visible |
Object
public static Object stripScripts(Object domElement)
domElement |
Object
public static Object suppressActionLinkBrowserContextMenu(AdfUIInputEvent componentContextMenuEvent)
componentContextMenuEvent |
- | The component context menu event |
Object
public static Object swapIcon(HTMLElement originalIcon,
String iconKey)
originalIcon |
- | the original icon dom element that you want swapped out. The originalIcon must have a parent node in order to be replaced. |
iconKey |
- | Key used to identify this icon |
Object
|
Oracle Fusion Middleware JavaScript API Reference for Oracle ADF Faces 11g Release 2 (11.1.2.0.0) E17489-01 |
||||||||
PREV NEXT | FRAMES NO FRAMES Warning: private items are visible |