當前位置: 首頁>>代碼示例>>Java>>正文


Java UIComponent.getFacetsAndChildren方法代碼示例

本文整理匯總了Java中javax.faces.component.UIComponent.getFacetsAndChildren方法的典型用法代碼示例。如果您正苦於以下問題:Java UIComponent.getFacetsAndChildren方法的具體用法?Java UIComponent.getFacetsAndChildren怎麽用?Java UIComponent.getFacetsAndChildren使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在javax.faces.component.UIComponent的用法示例。


在下文中一共展示了UIComponent.getFacetsAndChildren方法的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: _gatherTransientComponents

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
@SuppressWarnings("unchecked")
static private void _gatherTransientComponents(
  UIComponent component, List<UIComponent> componentsToRemove)
{
  Iterator<UIComponent> kids = component.getFacetsAndChildren();
  while (kids.hasNext())
  {
    UIComponent kid = kids.next();
    // UIXComponentBase doesn't mind transient components
    // in its saved state, so don't bother with this.
    if (!(component instanceof UIXComponentBase) &&
        kid.isTransient())
    {
      componentsToRemove.add(kid);
    }
    else
    {
      _gatherTransientComponents(kid, componentsToRemove);
    }
  }
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:22,代碼來源:StateManagerImpl.java

示例2: _findInsideOf

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
static private UIComponent _findInsideOf(
  UIComponent from,
  String id)
{
  Iterator<UIComponent> kids = from.getFacetsAndChildren();
  while (kids.hasNext())
  {
    UIComponent kid = kids.next();
    if (id.equals(kid.getId()))
      return kid;

    if (!(kid instanceof NamingContainer))
    {
      UIComponent returned = _findInsideOf(kid, id);
      if (returned != null)
        return returned;
    }
  }

  return null;
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:22,代碼來源:UIXComponentBase.java

示例3: _resetChildren

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
@SuppressWarnings("unchecked")
private void _resetChildren(UIComponent comp)
{
  Iterator<UIComponent> kids = comp.getFacetsAndChildren();

  while (kids.hasNext())
  {
    UIComponent kid = kids.next();
    
    if (kid instanceof UIXEditableValue)
    {
      ((UIXEditableValue) kid).resetValue();
      RequestContext.getCurrentInstance().addPartialTarget(kid);
    }
    else if (kid instanceof EditableValueHolder)
    {
      _resetEditableValueHolder((EditableValueHolder) kid);
      RequestContext.getCurrentInstance().addPartialTarget(kid);
    }
    else if (kid instanceof UIXCollection)
    {
      ((UIXCollection) kid).resetStampState();
      RequestContext.getCurrentInstance().addPartialTarget(kid);
    }

    _resetChildren(kid);
  }
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:29,代碼來源:ResetActionListener.java

示例4: _executeBindings

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
/**
 * Execute any "binding" attributes so that a popped view
 * is properly set up
 */
@SuppressWarnings("unchecked")
private void _executeBindings(FacesContext context, UIComponent component)
{
  ValueExpression expression = component.getValueExpression("binding");
  if (expression != null)
    expression.setValue(context.getELContext(), component);

  Iterator<UIComponent> kids = component.getFacetsAndChildren();
  while (kids.hasNext())
    _executeBindings(context, kids.next());
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:16,代碼來源:DialogServiceImpl.java

示例5: _renderChildren

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
private static void _renderChildren(FacesContext context, UIComponent root) throws IOException
{
  Iterator<UIComponent> iterator = root.getFacetsAndChildren();
  while (iterator.hasNext())
  {
    UIComponent child = iterator.next();
    if (child.isRendered())
      child.encodeAll(context);
  }
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:11,代碼來源:PartialViewContextImpl.java

示例6: _clearCachedClientIds

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
/**
 * Default implementation of clearing the cached client ids
 */
private static void _clearCachedClientIds(UIComponent component)
{
  // clear this component
  String id = component.getId();
  component.setId(id);

  // clear the children
  Iterator<UIComponent> allChildren = component.getFacetsAndChildren();

  while (allChildren.hasNext())
  {
    clearCachedClientIds(allChildren.next());
  }
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:18,代碼來源:UIXComponent.java

示例7: findComponentById

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
public static UIComponent findComponentById(UIComponent parent, String id) {
	if (id.equals(parent.getId())) {
		return parent;
	}
	Iterator<UIComponent> kids = parent.getFacetsAndChildren();
	while (kids.hasNext()) {
		UIComponent kid = kids.next();
		UIComponent found = findComponentById(kid, id);
		if (found != null) {
			return found;
		}
	}
	return null;
}
 
開發者ID:phoenixctms,項目名稱:ctsms,代碼行數:15,代碼來源:WebUtil.java

示例8: getRenderedFacetsAndChildren

import javax.faces.component.UIComponent; //導入方法依賴的package包/類
/**
 * Allows the rendered to specify what components should be involved with rendered children
 * life-cycle operations and methods.
 *
 * @param facesContext the faces context
 * @param component the component from which to get the rendered facets and children
 * @see UIXComponentBase#getRenderedFacetsAndChildren(FacesContext)
 * @return A list of components to process as rendered components. Defaults to all facets and
 * children of a component
 */
public Iterator<UIComponent> getRenderedFacetsAndChildren(
  FacesContext facesContext,
  UIComponent  component)
{
  return component.getFacetsAndChildren();
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:17,代碼來源:CoreRenderer.java


注:本文中的javax.faces.component.UIComponent.getFacetsAndChildren方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。