OracleJavaScript API Reference for Oracle ADF Faces

 

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

oracle.adfinternal.view.js.laf.dhtml.rich
Class AdfDhtmlInputFilePeer

Warning:

org.ecmascript.object.Object
   |
   +--oracle.adf.view.js.base.AdfObject
         |
         +--oracle.adf.view.js.base.AdfUIPeer
               |
               +--oracle.adf.view.js.laf.rich.AdfRichUIPeer
                     |
                     +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlValuePeer
                           |
                           +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlEditableValuePeer
                                 |
                                 +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlInputBasePeer
                                       |
                                       +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlInputTextPeer
                                             |
                                             +--oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlInputFilePeer

public class AdfDhtmlInputFilePeer
extends AdfDhtmlInputTextPeer
Renders an input file field for DHTML



Field Summary

private static Object
_clone
private static Object
_UPDATE_BUTTON_ID
private static Object
_UPDATE_DLG_CONTAINER_ID
private static Object
_UPDATE_DLG_CONTENT_ID
private static Object
_UPDATE_VALUE_ID


Fields inherited from oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlEditableValuePeer

ComponentLabelChanged


Fields inherited from oracle.adf.view.js.laf.rich.AdfRichUIPeer

addComponentPropertyChanges, addComponentPropertyGetters, BUSY_STYLECLASS, DISABLED_STYLECLASS, DRAG_SOURCE_STYLECLASS, DROP_TARGET_STYLECLASS, HOVER_TARGET_STYLECLASS, READONLY_STYLECLASS


Fields inherited from oracle.adf.view.js.base.AdfObject

constructor, superclass


Fields inherited from org.ecmascript.object.Object

prototype


Constructor Summary

public
AdfDhtmlInputFilePeer()
Renders an input file field for DHTML


Method Summary

protected Object
ComponentValueChanged(Object component, Object domElement, Object newValue, Object oldValue)
public Object
getConvertedValue(Object component, Object submittedValue)
akin to javax.faces.render.Renderer.getConvertedValue() can return undefined if converter was not successful
protected Object
GetNoteWindowAlignmentNode(Object component, Object rootNode)
Returns the node for which to align the note help window
private Object
_getUpdateButton()
protected Object
HandleComponentClick(Object componentEvent)
Handle the update button click
protected Object
HandleComponentDialog(Object componentEvent)
Handles the upload dialog This happens even before PopupClosed and is to set component value and hide custom popup and then set the focus to input field if exist.
protected Object
HandleComponentKeyPress(Object componentEvent)
Handles component-level key-press events.
protected Object
HandleDomChange(Object component, Object domEvent)
DOM change event event handler.
private Object
_handleFileChange(Object component, Object file)
protected static Object
InitSubclass()
public Object
isEmpty(Object submittedValue)
This is needed in the case where the client converter return undefined.
protected Object
LazyInitialize(Object component, Object domElement)
We need to initialize the 'value' property before the user makes any changes so that we're not going to the peer for the 'value' property in the component.setProperty method.
protected Object
PopupClosed(Object component, Object contentDom, Object popupId)
Hook for notifying a peer that a popup of its was just closed.
protected Object
VetoBlurValidation()
For input file peers, we want to use onchange for validation, instead of the focus/blur combi.
protected Object
VetoShowNoteWindow(Object component)


Methods inherited from oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlInputTextPeer

AutoTab, GetInlineEditor, HandleComponentKeyUp, IsSecret, replaceTextSelection, SetDisplayValue


Methods inherited from oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlInputBasePeer

GetSubmittedValue, HandleComponentBlur, HandleComponentFocus, RunValidation, ShouldShowHint, __simulateBlur


Methods inherited from oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlEditableValuePeer

autoSubmit, BindToComponent, ComponentChanged, __componentLabelChanged, ComponentSubmittedValueChanged, disableBrowserAutoComplete, Focus, GetComponentLabel, GetComponentSubmittedValue, GetComponentValue, GetContentNode, GetContentNodeId, GetDisplayValue, GetNoteWindowAlignmentHint, GetValidatorHints, HideNoteWindow, InitDomElement, IsInitialized, IsNoteWindowVisible, MessageNotify, MessageShow, ShowNoteWindow, ShowNoteWindowMouseOver, StashOldValue, Validate, ValidateAndStashNewValue, ValidateIfStashedOldValue, WasSubmitted


Methods inherited from oracle.adfinternal.view.js.laf.dhtml.rich.AdfDhtmlValuePeer

getConvertedObject, getFormatHint, GetNullDefault


Methods inherited from oracle.adf.view.js.laf.rich.AdfRichUIPeer

addComponentEventHandlers, addComponentPropertyChanges, addComponentPropertyGetters, addDomEventHandlers, addEventHandlerToDomInstance, addSuppressedPPRAttributes, bind, cancelAllPopups, cancelPopup, ChildVisibilityChanged, ComponentInlineStyleChanged, ComponentPropertyChanged, componentRemoved, ComponentRemoved, ComponentStyleClassChanged, ComponentVisibleChanged, ConvertClientIdToLocator, convertLocatorToClientId, CreateDraggableNode, createPeerClass, createSubId, CreateSubId, DefaultInitClass, DispatchComponentEvent, domReplaceNotify, DomReplaceNotify, focus, getAbsoluteId, getAbsoluteLocator, getAccessibleName, GetAccessibleName, getAllPopups, getComponent, GetComponent, GetComponentId, getComponentParent, getComponentProperty, GetComponentVisible, getDescendantComponents, getDomContentElement, getDomContentElementForComponent, GetDomContentElementForNode, getDomDocument, getDomElement, getDomElementForComponent, getDomNode, GetDomNodeForCommentComponent, getDomNodeForComponent, getDragOverFeedback, GetDragOverFeedback, getDragTransferable, GetDragTransferable, getFirstAncestorComponent, getInlineEditor, getInlineStyleProperty, getLocatorByDomElement, getPagePosition, getPopupWindow, GetRichResourceURL, getSubIdDomElement, GetSubIdDomElement, hideAllPopups, hidePopup, Init, InitClass, initialize, isActive, isInActiveHeirarchy, isPopupVisible, messageNotify, messageShow, needsChildVisibilityChanges, processPushData, ProcessPushData, registerKeyStroke, replaceDomElement, ReplaceDomElement, resizeNotify, ResizeNotify, scrollIntoView, ScrollIntoView, setBusy, SetBusy, setInlineStyleProperty, showContextMenu, showPopup, TruncateClientId, TruncateClientIdOnceImpl, UnbindFromComponent, unregisterKeyStroke, visitChildren


Methods inherited from oracle.adf.view.js.base.AdfUIPeer

getDefaultDragRecognizer, getParentPeer, initiateDrag, isVisible, needsResizeNotify


Methods inherited from oracle.adf.view.js.base.AdfObject

adopt, clone, createCallback, createInitializedObject, createSubclass, ensureClassInitialization, equals, getClass, GetLazyArrayProperty, GetLazyMapProperty, getTypeName, toDebugString, toString


Field Detail


_clone

private static Object _clone

_UPDATE_BUTTON_ID

private static Object _UPDATE_BUTTON_ID

_UPDATE_DLG_CONTAINER_ID

private static Object _UPDATE_DLG_CONTAINER_ID

_UPDATE_DLG_CONTENT_ID

private static Object _UPDATE_DLG_CONTENT_ID

_UPDATE_VALUE_ID

private static Object _UPDATE_VALUE_ID

Constructor Detail


AdfDhtmlInputFilePeer

public AdfDhtmlInputFilePeer()

Renders an input file field for DHTML

Method Detail


ComponentValueChanged

protected Object ComponentValueChanged(Object component,
                                       Object domElement,
                                       Object newValue,
                                       Object oldValue)

Parameters:
component    
domElement    
newValue    
oldValue    
Return:
Object
Overrides:
AdfDhtmlValuePeer.ComponentValueChanged(Object, Object, Object, Object)

getConvertedValue

public Object getConvertedValue(Object component,
                                Object submittedValue)

akin to javax.faces.render.Renderer.getConvertedValue() can return undefined if converter was not successful

Parameters:
component    
submittedValue    
Return:
Object
Overrides:
AdfDhtmlValuePeer.getConvertedValue(Object, Object)

GetNoteWindowAlignmentNode

protected Object GetNoteWindowAlignmentNode(Object component,
                                            Object rootNode)

Returns the node for which to align the note help window

Parameters:
component    
rootNode    
Return:
Object
Overrides:
AdfDhtmlEditableValuePeer.GetNoteWindowAlignmentNode(Object, Object)

_getUpdateButton

private Object _getUpdateButton()

Return:
Object

HandleComponentClick

protected Object HandleComponentClick(Object componentEvent)

Handle the update button click

Parameters:
componentEvent    
Return:
Object
Overrides:
AdfDhtmlEditableValuePeer.HandleComponentClick(Object)

HandleComponentDialog

protected Object HandleComponentDialog(Object componentEvent)

Handles the upload dialog This happens even before PopupClosed and is to set component value and hide custom popup and then set the focus to input field if exist.

Parameters:
componentEvent  -  the component event invoked as users close upload popup.
Return:
Object

HandleComponentKeyPress

protected Object HandleComponentKeyPress(Object componentEvent)

Handles component-level key-press events. We check for this when inputText's rows > 1 and we need to check the maximumLength. Also used for doing autoTab.

Parameters:
componentEvent    
Return:
Object
Overrides:
AdfDhtmlInputTextPeer.HandleComponentKeyPress(Object)

HandleDomChange

protected Object HandleDomChange(Object component,
                                 Object domEvent)

DOM change event event handler. This gets called when the file is changed. and it will validate the value.

Parameters:
component  -  Component that this peer will be associated with
domEvent  -  event on the dom
Return:
Object

_handleFileChange

private Object _handleFileChange(Object component,
                                 Object file)

Parameters:
component    
file    
Return:
Object

InitSubclass

protected static Object InitSubclass()

Return:
Object
Overrides:
AdfDhtmlValuePeer.InitSubclass()

isEmpty

public Object isEmpty(Object submittedValue)

This is needed in the case where the client converter return undefined. Required validation works on the converted value. When the converter can't convert this will be called to determine if the field is empty. If this isn't doing the correct thing then a client converter is required.

Parameters:
submittedValue    
Return:
Object
Overrides:
AdfDhtmlValuePeer.isEmpty(Object)

LazyInitialize

protected Object LazyInitialize(Object component,
                                Object domElement)

We need to initialize the 'value' property before the user makes any changes so that we're not going to the peer for the 'value' property in the component.setProperty method. See explanation below. Background: 1. In component.setProperty if the old and new value of a property are equal the setProperty method returns without setting anything. This is to avoid unnecessary propertyChangeEvents. 2. We do not send down the 'value' property from the server, so the 'value' property starts out undefined. If a property is undefined then calls to get the current value will go to the peer. So initally calls to getValue() go to the peer's GetComponentValue() Issue: - Mostly component.setProperty will only be called after the user makes a change, and if the property is currently undefined the peer's property getter will be called for the 'old' value. The peer will then return the current value, which is the new changed value. - That means the 'old' value is the same as the new value, and so the property is not set (see point 1 above). - Therefore we need to initialize the 'value' property before the user makes any changes so that we're not going to the peer for the 'value' property in the component.setProperty method.

Parameters:
component    
domElement    
Return:
Object
Overrides:
AdfDhtmlEditableValuePeer.LazyInitialize(Object, Object)

PopupClosed

protected Object PopupClosed(Object component,
                             Object contentDom,
                             Object popupId)

Hook for notifying a peer that a popup of its was just closed.

Parameters:
component    
contentDom    
popupId    
Return:
Object
Overrides:
AdfRichUIPeer.PopupClosed(AdfUIComponent, HTMLElement, String)

VetoBlurValidation

protected Object VetoBlurValidation()

For input file peers, we want to use onchange for validation, instead of the focus/blur combi. There are two main reasons for this: - There is no browser built-in autocomplete for input file elements. - Safari does not trigger focus/blur on input file elements.

Return:
Object
Overrides:
AdfDhtmlInputBasePeer.VetoBlurValidation()

VetoShowNoteWindow

protected Object VetoShowNoteWindow(Object component)

Parameters:
component    
Return:
Object
Overrides:
AdfDhtmlEditableValuePeer.VetoShowNoteWindow(Object)

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

 

Generated on 2009.09.25 03:44 UTC
Copyright (c) 1998, 2009, Oracle and/or its affiliates. All rights reserved.