public final class CompositeComponentELUtils extends Object
| Modifier and Type | Field and Description | 
|---|---|
| static Pattern | CC_ATTRS_METHOD_EXPRESSION_REGEXA regular expression used to determine if cc.attrs is used as a method expression
 in an expression String. | 
| static Pattern | CC_EXPRESSION_REGEXA regular expression used to determine if cc is used in an expression String. | 
| static String | CC_FIND_COMPONENT_EXPRESSION | 
| static String | CURRENT_COMPOSITE_COMPONENT_KEYThe key under which the current composite component is stored in the attribute
 map of the FacesContext. | 
| static String | LEVEL_KEYIndicates the nesting level where the composite component was created, working as reference
 point to all EL expressions created in that point from Facelets engine. | 
| static String | LOCATION_KEYThe key under which the Location of the composite componente is stored
 in the attributes map of the component by InterfaceHandler. | 
| Modifier and Type | Method and Description | 
|---|---|
| static UIComponent | getCompositeComponentBasedOnLocation(FacesContext facesContext,
                                    Location location)Try to find a composite component on the composite component stack
 and using UIComponent.getCurrentCompositeComponent() based on the 
 location of the facelet page that generated the composite component. | 
| static UIComponent | getCompositeComponentBasedOnLocation(FacesContext facesContext,
                                    Location location,
                                    int ccLevel)Same as getCompositeComponentBasedOnLocation(final FacesContext facesContext, final Location location),
 but takes into account the ccLevel to resolve the composite component. | 
| static UIComponent | getCompositeComponentBasedOnLocation(FacesContext facesContext,
                                    UIComponent baseComponent,
                                    Location location) | 
| static boolean | isCompositeComponentAttrsMethodExpression(String expression)Tests if cc.attrs is used as a method expression in an expression String. | 
| static boolean | isCompositeComponentExpression(String expression)Tests if the expression refers to the current composite component: #{cc} | 
| static void | removeCompositeComponentForResolver(FacesContext facesContext)Removes the composite component from the attribute map of the FacesContext. | 
| static void | saveCompositeComponentForResolver(FacesContext facesContext,
                                 Location location,
                                 int ccLevel)Trys to get the composite component using getCompositeComponentBasedOnLocation()
 and saves it in an attribute on the FacesContext, which is then used by 
 CompositeComponentImplicitObject. | 
public static final String CURRENT_COMPOSITE_COMPONENT_KEY
public static final String LOCATION_KEY
public static final String LEVEL_KEY
public static final Pattern CC_EXPRESSION_REGEX
public static final Pattern CC_ATTRS_METHOD_EXPRESSION_REGEX
public static final String CC_FIND_COMPONENT_EXPRESSION
public static UIComponent getCompositeComponentBasedOnLocation(FacesContext facesContext, Location location)
facesContext - location - public static UIComponent getCompositeComponentBasedOnLocation(FacesContext facesContext, UIComponent baseComponent, Location location)
public static UIComponent getCompositeComponentBasedOnLocation(FacesContext facesContext, Location location, int ccLevel)
facesContext - location - ccLevel - public static void saveCompositeComponentForResolver(FacesContext facesContext, Location location, int ccLevel)
facesContext - location - public static void removeCompositeComponentForResolver(FacesContext facesContext)
facesContext - public static boolean isCompositeComponentExpression(String expression)
public static boolean isCompositeComponentAttrsMethodExpression(String expression)
expression - Copyright © 2021 The Apache Software Foundation. All rights reserved.