public abstract class InsertingComponentFragmentLocator extends Object
getFramentUrlForInsertedComponent
for each registered
InsertedComponentFragmentLocator
on each UIComponent starting from the target
component and upto the UIViewRoot and each registered InsertingComponentFragmentLocator on each
component from the parent of the target component to the UIViewRoot. If a non-null URL string
is returned, the walk of the ancestor chain halts and the returned value is considered the
URL string for the document for the target component. If the registered listeners return
null
for every component in the ancestor chain, the containing URL is assumed to be
the URL of the enclosing page.
Implementations of InsertingComponentFragmentLocator are registered using the normal
Service Provider Interface pattern. A text file named
"org.apache.myfaces.trinidad.change.InsertingComponentFragmentLocator" is placed in the
META-INF/services directory. This file contains the fully qualified class names of all the
InsertingComponentFragmentLocator strategy to register.InsertedComponentFragmentLocator
Constructor and Description |
---|
InsertingComponentFragmentLocator() |
Modifier and Type | Method and Description |
---|---|
abstract String |
getInsertedFragmentUrl(javax.faces.context.FacesContext context,
javax.faces.component.UIComponent componentToTest,
javax.faces.component.UIComponent targetComponent)
Returns the URL string of the fragment inserted by
componentToTest , or
null if this InsertingComponentFragmentLocator could not determine the URL. |
public abstract String getInsertedFragmentUrl(javax.faces.context.FacesContext context, javax.faces.component.UIComponent componentToTest, javax.faces.component.UIComponent targetComponent)
componentToTest
, or
null
if this InsertingComponentFragmentLocator could not determine the URL.context
- The FacesContext instance for current requestcomponentToTest
- The component that possibly inserted the targetComponent. This component
will be used to determine the fragment URL for targetComponent.
componentToTest
will be an ancestor of the
targetComponent
. EL context will NOT be setup for
componentToTest
when this method is called.targetComponent
- The component to determine the fragment URL forCopyright © 2001-2017 The Apache Software Foundation. All Rights Reserved.