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


Java FeatureDescriptor.setValue方法代碼示例

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


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

示例1: __addFeatureValues

import java.beans.FeatureDescriptor; //導入方法依賴的package包/類
/**
 * Add all of the attributes of one FeatureDescriptor to thos
 * of another, replacing any attributes that conflict.
 */
static void __addFeatureValues(
  FeatureDescriptor addingDescriptor,
  FeatureDescriptor destinationDescriptor
  )
{
  Enumeration<String> keys = addingDescriptor.attributeNames();

  if (keys != null)
  {
    while (keys.hasMoreElements())
    {
      String key = keys.nextElement();
      Object value = addingDescriptor.getValue(key);
      destinationDescriptor.setValue(key, value);
    }
  }
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:22,代碼來源:JavaIntrospector.java

示例2: _createFeatureDescriptorList

import java.beans.FeatureDescriptor; //導入方法依賴的package包/類
/**
 * Creates the list of FeatureDescriptors.
 */
private List<FeatureDescriptor> _createFeatureDescriptorList()
{
  ArrayList<FeatureDescriptor> list = new ArrayList<FeatureDescriptor>();
  // FeatureDescriptor for "requestContext"
  FeatureDescriptor requestContext = new FeatureDescriptor();
  requestContext.setName(RequestContext.VARIABLE_NAME);
  // TODO translate this
  requestContext.setShortDescription("Trinidad RequestContext");
  requestContext.setValue(ELResolver.RESOLVABLE_AT_DESIGN_TIME, false);
  requestContext.setValue(ELResolver.TYPE, RequestContext.class);
  list.add(requestContext);
  
  // FeatureDescriptor for "pageFlowScope"
  FeatureDescriptor pageFlowScope = new FeatureDescriptor();
  pageFlowScope.setName(PAGE_FLOW_SCOPE_VARIABLE_NAME);
  // TODO translate this
  pageFlowScope.setShortDescription("Trinidad Page Flow Scope");
  pageFlowScope.setValue(ELResolver.RESOLVABLE_AT_DESIGN_TIME, false);
  pageFlowScope.setValue(ELResolver.TYPE, Map.class);
  list.add(pageFlowScope);
  
  // FeatureDescriptor for "processScope"
  FeatureDescriptor processScope = new FeatureDescriptor();
  processScope.setName(PAGE_FLOW_SCOPE_VARIABLE_NAME);
  // TODO translate this
  pageFlowScope.setShortDescription(
    "Backwards compatibility alias for Trinidad Page Flow Scope");
  processScope.setExpert(true);
  processScope.setValue(ELResolver.RESOLVABLE_AT_DESIGN_TIME, false);
  processScope.setValue(ELResolver.TYPE, Map.class);
  list.add(pageFlowScope);

  return Collections.unmodifiableList(list);
}
 
開發者ID:apache,項目名稱:myfaces-trinidad,代碼行數:38,代碼來源:TrinidadELResolver.java

示例3: createObjectCircle

import java.beans.FeatureDescriptor; //導入方法依賴的package包/類
private static EventObject createObjectCircle() {
    FeatureDescriptor fd = new FeatureDescriptor();
    EventObject eo = new EventObject(fd);
    fd.setValue("event", eo);
    return eo;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:7,代碼來源:MirrorValuesApp.java


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