001: //GEN-BEGIN:BeanInfo
002: /*
003: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
004: *
005: * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
006: *
007: * The contents of this file are subject to the terms of either the GNU
008: * General Public License Version 2 only ("GPL") or the Common
009: * Development and Distribution License("CDDL") (collectively, the
010: * "License"). You may not use this file except in compliance with the
011: * License. You can obtain a copy of the License at
012: * http://www.netbeans.org/cddl-gplv2.html
013: * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
014: * specific language governing permissions and limitations under the
015: * License. When distributing the software, include this License Header
016: * Notice in each file and include the License file at
017: * nbbuild/licenses/CDDL-GPL-2-CP. Sun designates this
018: * particular file as subject to the "Classpath" exception as provided
019: * by Sun in the GPL Version 2 section of the License file that
020: * accompanied this code. If applicable, add the following below the
021: * License Header, with the fields enclosed by brackets [] replaced by
022: * your own identifying information:
023: * "Portions Copyrighted [year] [name of copyright owner]"
024: *
025: * Contributor(s):
026: *
027: * The Original Software is NetBeans. The Initial Developer of the Original
028: * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
029: * Microsystems, Inc. All Rights Reserved.
030: *
031: * If you wish your version of this file to be governed by only the CDDL
032: * or only the GPL Version 2, indicate your decision by adding
033: * "[Contributor] elects to include this software in this distribution
034: * under the [CDDL or GPL Version 2] license." If you do not indicate a
035: * single choice of license, a recipient has the option to distribute
036: * your version of this file under either the CDDL, the GPL Version 2 or
037: * to extend the choice of license to its licensees as provided above.
038: * However, if you add GPL Version 2 code and therefore, elected the GPL
039: * Version 2 license, then the option applies only if the new code is
040: * made subject to such option by the copyright holder.
041: */
042: package org.netbeans.modules.visualweb.web.ui.dt.component;
043:
044: import java.awt.Image;
045: import java.beans.BeanDescriptor;
046: import java.beans.BeanInfo;
047: import java.beans.IntrospectionException;
048: import java.beans.PropertyDescriptor;
049: import java.util.Locale;
050: import java.util.ResourceBundle;
051:
052: import com.sun.rave.designtime.CategoryDescriptor;
053: import com.sun.rave.designtime.Constants;
054: import com.sun.rave.designtime.faces.FacetDescriptor;
055: import com.sun.rave.designtime.markup.AttributeDescriptor;
056:
057: import java.beans.SimpleBeanInfo;
058:
059: /**
060: * <p>Auto-generated design time metadata class.
061: * Do <strong>NOT</strong> modify; all changes
062: * <strong>will</strong> be lost!</p>
063: */
064:
065: abstract class TreeBeanInfoBase extends SimpleBeanInfo {
066:
067: protected static ResourceBundle resources = ResourceBundle
068: .getBundle(
069: "org.netbeans.modules.visualweb.web.ui.dt.component.Bundle-JSF",
070: Locale.getDefault(), TreeBeanInfoBase.class
071: .getClassLoader());
072:
073: /**
074: * <p>Construct a new <code>TreeBeanInfoBase</code>.</p>
075: */
076: public TreeBeanInfoBase() {
077:
078: beanClass = com.sun.rave.web.ui.component.Tree.class;
079: defaultPropertyName = "text";
080: iconFileName_C16 = "/org/netbeans/modules/visualweb/web/ui/dt/component/Tree_C16";
081: iconFileName_C32 = "/org/netbeans/modules/visualweb/web/ui/dt/component/Tree_C32";
082: iconFileName_M16 = "/org/netbeans/modules/visualweb/web/ui/dt/component/Tree_M16";
083: iconFileName_M32 = "/org/netbeans/modules/visualweb/web/ui/dt/component/Tree_M32";
084:
085: }
086:
087: /**
088: * <p>The bean class that this BeanInfo represents.
089: */
090: protected Class beanClass;
091:
092: /**
093: * <p>The cached BeanDescriptor.</p>
094: */
095: protected BeanDescriptor beanDescriptor;
096:
097: /**
098: * <p>The index of the default property.</p>
099: */
100: protected int defaultPropertyIndex = -2;
101:
102: /**
103: * <p>The name of the default property.</p>
104: */
105: protected String defaultPropertyName;
106:
107: /**
108: * <p>The 16x16 color icon.</p>
109: */
110: protected String iconFileName_C16;
111:
112: /**
113: * <p>The 32x32 color icon.</p>
114: */
115: protected String iconFileName_C32;
116:
117: /**
118: * <p>The 16x16 monochrome icon.</p>
119: */
120: protected String iconFileName_M16;
121:
122: /**
123: * <p>The 32x32 monochrome icon.</p>
124: */
125: protected String iconFileName_M32;
126:
127: /**
128: * <p>The cached property descriptors.</p>
129: */
130: protected PropertyDescriptor[] propDescriptors;
131:
132: /**
133: * <p>Return the <code>BeanDescriptor</code> for this bean.</p>
134: */
135: public BeanDescriptor getBeanDescriptor() {
136:
137: if (beanDescriptor != null) {
138: return beanDescriptor;
139: }
140:
141: beanDescriptor = new BeanDescriptor(beanClass);
142: beanDescriptor.setDisplayName(resources
143: .getString("Tree_DisplayName"));
144: beanDescriptor.setShortDescription(resources
145: .getString("Tree_Description"));
146: beanDescriptor.setExpert(false);
147: beanDescriptor.setHidden(false);
148: beanDescriptor.setPreferred(false);
149: beanDescriptor.setValue(
150: Constants.BeanDescriptor.FACET_DESCRIPTORS,
151: getFacetDescriptors());
152: beanDescriptor.setValue(Constants.BeanDescriptor.HELP_KEY,
153: "projrave_ui_elements_palette_bh_tree");
154: beanDescriptor.setValue(Constants.BeanDescriptor.INSTANCE_NAME,
155: "tree");
156: beanDescriptor.setValue(Constants.BeanDescriptor.IS_CONTAINER,
157: Boolean.TRUE);
158: beanDescriptor
159: .setValue(Constants.BeanDescriptor.PROPERTIES_HELP_KEY,
160: "projrave_ui_elements_palette_bh_propsheets_bh_tree_props");
161: beanDescriptor.setValue(
162: Constants.BeanDescriptor.PROPERTY_CATEGORIES,
163: getCategoryDescriptors());
164: beanDescriptor.setValue(Constants.BeanDescriptor.TAG_NAME,
165: "tree");
166: beanDescriptor.setValue(Constants.BeanDescriptor.TAGLIB_PREFIX,
167: "ui");
168: beanDescriptor.setValue(Constants.BeanDescriptor.TAGLIB_URI,
169: "http://www.sun.com/web/ui");
170:
171: return beanDescriptor;
172:
173: }
174:
175: /**
176: * <p>Return the <code>CategoryDescriptor</code> array for the property categories of this component.</p>
177: */
178: private CategoryDescriptor[] getCategoryDescriptors() {
179:
180: return com.sun.rave.designtime.base.CategoryDescriptors
181: .getDefaultCategoryDescriptors();
182:
183: }
184:
185: /**
186: * <p>Return the index of the default property, or
187: * -1 if there is no default property.</p>
188: */
189: public int getDefaultPropertyIndex() {
190:
191: if (defaultPropertyIndex > -2) {
192: return defaultPropertyIndex;
193: } else {
194: if (defaultPropertyName == null) {
195: defaultPropertyIndex = -1;
196: } else {
197: PropertyDescriptor pd[] = getPropertyDescriptors();
198: for (int i = 0; i < pd.length; i++) {
199: if (defaultPropertyName.equals(pd[i].getName())) {
200: defaultPropertyIndex = i;
201: break;
202: }
203: }
204: }
205: }
206: return defaultPropertyIndex;
207: }
208:
209: /**
210: * <p>The cached facet descriptors.</p>
211: */
212: protected FacetDescriptor[] facetDescriptors;
213:
214: /**
215: * <p>Return the <code>FacetDescriptor</code>s for this bean.</p>
216: */
217: public FacetDescriptor[] getFacetDescriptors() {
218:
219: if (facetDescriptors != null) {
220: return facetDescriptors;
221: }
222: facetDescriptors = new FacetDescriptor[] {};
223: return facetDescriptors;
224:
225: }
226:
227: /**
228: * <p>Return the specified image (if any)
229: * for this component class.</p>
230: */
231: public Image getIcon(int kind) {
232:
233: String name;
234: switch (kind) {
235: case ICON_COLOR_16x16:
236: name = iconFileName_C16;
237: break;
238: case ICON_COLOR_32x32:
239: name = iconFileName_C32;
240: break;
241: case ICON_MONO_16x16:
242: name = iconFileName_M16;
243: break;
244: case ICON_MONO_32x32:
245: name = iconFileName_M32;
246: break;
247: default:
248: name = null;
249: break;
250: }
251: if (name == null) {
252: return null;
253: }
254:
255: Image image = loadImage(name + ".png");
256: if (image == null) {
257: image = loadImage(name + ".gif");
258: }
259: return image;
260:
261: }
262:
263: /**
264: * <p>Return a class loaded by name via the class loader that loaded this class.</p>
265: */
266: private java.lang.Class loadClass(java.lang.String name) {
267:
268: try {
269: return Class.forName(name);
270: } catch (ClassNotFoundException e) {
271: throw new RuntimeException(e);
272: }
273:
274: }
275:
276: /**
277: * <p>Return the <code>PropertyDescriptor</code>s for this bean.</p>
278: */
279: public PropertyDescriptor[] getPropertyDescriptors() {
280:
281: if (propDescriptors != null) {
282: return propDescriptors;
283: }
284: AttributeDescriptor attrib = null;
285:
286: try {
287:
288: PropertyDescriptor prop_clientSide = new PropertyDescriptor(
289: "clientSide", beanClass, "isClientSide",
290: "setClientSide");
291: prop_clientSide.setDisplayName(resources
292: .getString("Tree_clientSide_DisplayName"));
293: prop_clientSide.setShortDescription(resources
294: .getString("Tree_clientSide_Description"));
295: prop_clientSide.setExpert(false);
296: prop_clientSide.setHidden(false);
297: prop_clientSide.setPreferred(false);
298: attrib = new AttributeDescriptor("clientSide", false,
299: "false", true);
300: prop_clientSide.setValue(
301: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
302: attrib);
303: prop_clientSide
304: .setValue(
305: Constants.PropertyDescriptor.CATEGORY,
306: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
307:
308: PropertyDescriptor prop_expandOnSelect = new PropertyDescriptor(
309: "expandOnSelect", beanClass, "isExpandOnSelect",
310: "setExpandOnSelect");
311: prop_expandOnSelect.setDisplayName(resources
312: .getString("Tree_expandOnSelect_DisplayName"));
313: prop_expandOnSelect.setShortDescription(resources
314: .getString("Tree_expandOnSelect_Description"));
315: prop_expandOnSelect.setExpert(false);
316: prop_expandOnSelect.setHidden(false);
317: prop_expandOnSelect.setPreferred(false);
318: attrib = new AttributeDescriptor("expandOnSelect", false,
319: "true", true);
320: prop_expandOnSelect.setValue(
321: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
322: attrib);
323: prop_expandOnSelect
324: .setValue(
325: Constants.PropertyDescriptor.CATEGORY,
326: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
327:
328: PropertyDescriptor prop_immediate = new PropertyDescriptor(
329: "immediate", beanClass, "isImmediate",
330: "setImmediate");
331: prop_immediate.setDisplayName(resources
332: .getString("Tree_immediate_DisplayName"));
333: prop_immediate.setShortDescription(resources
334: .getString("Tree_immediate_Description"));
335: prop_immediate.setExpert(false);
336: prop_immediate.setHidden(false);
337: prop_immediate.setPreferred(false);
338: attrib = new AttributeDescriptor("immediate", false,
339: "false", true);
340: prop_immediate.setValue(
341: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
342: attrib);
343: prop_immediate
344: .setValue(
345: Constants.PropertyDescriptor.CATEGORY,
346: com.sun.rave.designtime.base.CategoryDescriptors.ADVANCED);
347:
348: PropertyDescriptor prop_required = new PropertyDescriptor(
349: "required", beanClass, "isRequired", "setRequired");
350: prop_required.setDisplayName(resources
351: .getString("Tree_required_DisplayName"));
352: prop_required.setShortDescription(resources
353: .getString("Tree_required_Description"));
354: prop_required.setExpert(false);
355: prop_required.setHidden(false);
356: prop_required.setPreferred(false);
357: attrib = new AttributeDescriptor("required", false,
358: "false", true);
359: prop_required.setValue(
360: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
361: attrib);
362: prop_required
363: .setValue(
364: Constants.PropertyDescriptor.CATEGORY,
365: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
366:
367: PropertyDescriptor prop_selected = new PropertyDescriptor(
368: "selected", beanClass, "getSelected", "setSelected");
369: prop_selected.setDisplayName(resources
370: .getString("Tree_selected_DisplayName"));
371: prop_selected.setShortDescription(resources
372: .getString("Tree_selected_Description"));
373: prop_selected.setExpert(false);
374: prop_selected.setHidden(false);
375: prop_selected.setPreferred(false);
376: attrib = new AttributeDescriptor("selected", false, null,
377: true);
378: prop_selected.setValue(
379: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
380: attrib);
381: prop_selected
382: .setValue(
383: Constants.PropertyDescriptor.CATEGORY,
384: com.sun.rave.designtime.base.CategoryDescriptors.DATA);
385:
386: PropertyDescriptor prop_style = new PropertyDescriptor(
387: "style", beanClass, "getStyle", "setStyle");
388: prop_style.setDisplayName(resources
389: .getString("Tree_style_DisplayName"));
390: prop_style.setShortDescription(resources
391: .getString("Tree_style_Description"));
392: prop_style
393: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.css.CssStylePropertyEditor"));
394: prop_style.setExpert(false);
395: prop_style.setHidden(false);
396: prop_style.setPreferred(false);
397: attrib = new AttributeDescriptor("style", false, null, true);
398: prop_style.setValue(
399: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
400: attrib);
401: prop_style
402: .setValue(
403: Constants.PropertyDescriptor.CATEGORY,
404: com.sun.rave.designtime.base.CategoryDescriptors.APPEARANCE);
405:
406: PropertyDescriptor prop_styleClass = new PropertyDescriptor(
407: "styleClass", beanClass, "getStyleClass",
408: "setStyleClass");
409: prop_styleClass.setDisplayName(resources
410: .getString("Tree_styleClass_DisplayName"));
411: prop_styleClass.setShortDescription(resources
412: .getString("Tree_styleClass_Description"));
413: prop_styleClass
414: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.StyleClassPropertyEditor"));
415: prop_styleClass.setExpert(false);
416: prop_styleClass.setHidden(false);
417: prop_styleClass.setPreferred(false);
418: attrib = new AttributeDescriptor("styleClass", false, null,
419: true);
420: prop_styleClass.setValue(
421: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
422: attrib);
423: prop_styleClass
424: .setValue(
425: Constants.PropertyDescriptor.CATEGORY,
426: com.sun.rave.designtime.base.CategoryDescriptors.APPEARANCE);
427:
428: PropertyDescriptor prop_text = new PropertyDescriptor(
429: "text", beanClass, "getText", "setText");
430: prop_text.setDisplayName(resources
431: .getString("Tree_text_DisplayName"));
432: prop_text.setShortDescription(resources
433: .getString("Tree_text_Description"));
434: prop_text.setExpert(false);
435: prop_text.setHidden(false);
436: prop_text.setPreferred(false);
437: attrib = new AttributeDescriptor("text", false, null, true);
438: prop_text.setValue(
439: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
440: attrib);
441: prop_text
442: .setValue(
443: Constants.PropertyDescriptor.CATEGORY,
444: com.sun.rave.designtime.base.CategoryDescriptors.APPEARANCE);
445:
446: PropertyDescriptor prop_visible = new PropertyDescriptor(
447: "visible", beanClass, "isVisible", "setVisible");
448: prop_visible.setDisplayName(resources
449: .getString("Tree_visible_DisplayName"));
450: prop_visible.setShortDescription(resources
451: .getString("Tree_visible_Description"));
452: prop_visible.setExpert(false);
453: prop_visible.setHidden(false);
454: prop_visible.setPreferred(false);
455: attrib = new AttributeDescriptor("visible", false, "true",
456: true);
457: prop_visible.setValue(
458: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
459: attrib);
460: prop_visible
461: .setValue(
462: Constants.PropertyDescriptor.CATEGORY,
463: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
464:
465: PropertyDescriptor prop_action = new PropertyDescriptor(
466: "action", beanClass, "getAction", "setAction");
467: prop_action.setDisplayName(resources
468: .getString("Tree_action_DisplayName"));
469: prop_action.setShortDescription(resources
470: .getString("Tree_action_Description"));
471: prop_action.setExpert(false);
472: prop_action.setHidden(true);
473: prop_action.setPreferred(false);
474: attrib = new AttributeDescriptor("action", false, null,
475: true);
476: prop_action.setValue(
477: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
478: attrib);
479: prop_action
480: .setValue(
481: Constants.PropertyDescriptor.CATEGORY,
482: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
483:
484: PropertyDescriptor prop_actionListener = new PropertyDescriptor(
485: "actionListener", beanClass, "getActionListener",
486: "setActionListener");
487: prop_actionListener.setDisplayName(resources
488: .getString("Tree_actionListener_DisplayName"));
489: prop_actionListener.setShortDescription(resources
490: .getString("Tree_actionListener_Description"));
491: prop_actionListener
492: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.MethodBindingPropertyEditor"));
493: prop_actionListener.setExpert(false);
494: prop_actionListener.setHidden(true);
495: prop_actionListener.setPreferred(false);
496: attrib = new AttributeDescriptor("actionListener", false,
497: null, true);
498: prop_actionListener.setValue(
499: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
500: attrib);
501: prop_actionListener
502: .setValue(
503: Constants.PropertyDescriptor.CATEGORY,
504: com.sun.rave.designtime.base.CategoryDescriptors.ADVANCED);
505:
506: PropertyDescriptor prop_expanded = new PropertyDescriptor(
507: "expanded", beanClass, "isExpanded", "setExpanded");
508: prop_expanded.setDisplayName(resources
509: .getString("Tree_expanded_DisplayName"));
510: prop_expanded.setShortDescription(resources
511: .getString("Tree_expanded_Description"));
512: prop_expanded.setExpert(false);
513: prop_expanded.setHidden(true);
514: prop_expanded.setPreferred(false);
515: prop_expanded
516: .setValue(
517: Constants.PropertyDescriptor.CATEGORY,
518: com.sun.rave.designtime.base.CategoryDescriptors.APPEARANCE);
519:
520: PropertyDescriptor prop_imageURL = new PropertyDescriptor(
521: "imageURL", beanClass, "getImageURL", "setImageURL");
522: prop_imageURL.setDisplayName(resources
523: .getString("Tree_imageURL_DisplayName"));
524: prop_imageURL.setShortDescription(resources
525: .getString("Tree_imageURL_Description"));
526: prop_imageURL
527: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.ImageUrlPropertyEditor"));
528: prop_imageURL.setExpert(false);
529: prop_imageURL.setHidden(true);
530: prop_imageURL.setPreferred(false);
531: attrib = new AttributeDescriptor("imageURL", false, null,
532: true);
533: prop_imageURL.setValue(
534: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
535: attrib);
536: prop_imageURL
537: .setValue(
538: Constants.PropertyDescriptor.CATEGORY,
539: com.sun.rave.designtime.base.CategoryDescriptors.APPEARANCE);
540:
541: PropertyDescriptor prop_target = new PropertyDescriptor(
542: "target", beanClass, "getTarget", "setTarget");
543: prop_target.setDisplayName(resources
544: .getString("Tree_target_DisplayName"));
545: prop_target.setShortDescription(resources
546: .getString("Tree_target_Description"));
547: prop_target
548: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.SelectOneDomainEditor"));
549: prop_target.setExpert(false);
550: prop_target.setHidden(true);
551: prop_target.setPreferred(false);
552: attrib = new AttributeDescriptor("target", false, null,
553: true);
554: prop_target.setValue(
555: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
556: attrib);
557: prop_target
558: .setValue(
559: Constants.PropertyDescriptor.CATEGORY,
560: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
561: prop_target
562: .setValue(
563: "com.sun.rave.propertyeditors.DOMAIN_CLASS",
564: com.sun.rave.propertyeditors.domains.HtmlFrameTargetsDomain.class);
565:
566: PropertyDescriptor prop_toolTip = new PropertyDescriptor(
567: "toolTip", beanClass, "getToolTip", "setToolTip");
568: prop_toolTip.setDisplayName(resources
569: .getString("Tree_toolTip_DisplayName"));
570: prop_toolTip.setShortDescription(resources
571: .getString("Tree_toolTip_Description"));
572: prop_toolTip
573: .setPropertyEditorClass(loadClass("com.sun.rave.propertyeditors.StringPropertyEditor"));
574: prop_toolTip.setExpert(false);
575: prop_toolTip.setHidden(false);
576: prop_toolTip.setPreferred(false);
577: attrib = new AttributeDescriptor("toolTip", false, null,
578: true);
579: prop_toolTip.setValue(
580: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
581: attrib);
582: prop_toolTip
583: .setValue(
584: Constants.PropertyDescriptor.CATEGORY,
585: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
586:
587: PropertyDescriptor prop_url = new PropertyDescriptor("url",
588: beanClass, "getUrl", "setUrl");
589: prop_url.setDisplayName(resources
590: .getString("Tree_url_DisplayName"));
591: prop_url.setShortDescription(resources
592: .getString("Tree_url_Description"));
593: prop_url
594: .setPropertyEditorClass(loadClass("org.netbeans.modules.visualweb.web.ui.dt.component.propertyeditors.SunWebUrlPropertyEditor"));
595: prop_url.setExpert(false);
596: prop_url.setHidden(true);
597: prop_url.setPreferred(false);
598: attrib = new AttributeDescriptor("url", false, null, true);
599: prop_url.setValue(
600: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
601: attrib);
602: prop_url
603: .setValue(
604: Constants.PropertyDescriptor.CATEGORY,
605: com.sun.rave.designtime.base.CategoryDescriptors.BEHAVIOR);
606:
607: PropertyDescriptor prop_attributes = new PropertyDescriptor(
608: "attributes", beanClass, "getAttributes", null);
609: prop_attributes.setDisplayName(resources
610: .getString("Tree_attributes_DisplayName"));
611: prop_attributes.setShortDescription(resources
612: .getString("Tree_attributes_Description"));
613: prop_attributes.setExpert(false);
614: prop_attributes.setHidden(true);
615: prop_attributes.setPreferred(false);
616: prop_attributes
617: .setValue(
618: Constants.PropertyDescriptor.CATEGORY,
619: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
620:
621: PropertyDescriptor prop_childCount = new PropertyDescriptor(
622: "childCount", beanClass, "getChildCount", null);
623: prop_childCount.setDisplayName(resources
624: .getString("Tree_childCount_DisplayName"));
625: prop_childCount.setShortDescription(resources
626: .getString("Tree_childCount_Description"));
627: prop_childCount.setExpert(false);
628: prop_childCount.setHidden(true);
629: prop_childCount.setPreferred(false);
630: prop_childCount
631: .setValue(
632: Constants.PropertyDescriptor.CATEGORY,
633: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
634:
635: PropertyDescriptor prop_children = new PropertyDescriptor(
636: "children", beanClass, "getChildren", null);
637: prop_children.setDisplayName(resources
638: .getString("Tree_children_DisplayName"));
639: prop_children.setShortDescription(resources
640: .getString("Tree_children_Description"));
641: prop_children.setExpert(false);
642: prop_children.setHidden(true);
643: prop_children.setPreferred(false);
644: prop_children
645: .setValue(
646: Constants.PropertyDescriptor.CATEGORY,
647: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
648:
649: PropertyDescriptor prop_facets = new PropertyDescriptor(
650: "facets", beanClass, "getFacets", null);
651: prop_facets.setDisplayName(resources
652: .getString("Tree_facets_DisplayName"));
653: prop_facets.setShortDescription(resources
654: .getString("Tree_facets_Description"));
655: prop_facets.setExpert(false);
656: prop_facets.setHidden(true);
657: prop_facets.setPreferred(false);
658: prop_facets
659: .setValue(
660: Constants.PropertyDescriptor.CATEGORY,
661: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
662:
663: PropertyDescriptor prop_family = new PropertyDescriptor(
664: "family", beanClass, "getFamily", null);
665: prop_family.setDisplayName(resources
666: .getString("Tree_family_DisplayName"));
667: prop_family.setShortDescription(resources
668: .getString("Tree_family_Description"));
669: prop_family.setExpert(false);
670: prop_family.setHidden(true);
671: prop_family.setPreferred(false);
672: prop_family
673: .setValue(
674: Constants.PropertyDescriptor.CATEGORY,
675: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
676:
677: PropertyDescriptor prop_id = new PropertyDescriptor("id",
678: beanClass, "getId", "setId");
679: prop_id.setDisplayName(resources
680: .getString("Tree_id_DisplayName"));
681: prop_id.setShortDescription(resources
682: .getString("Tree_id_Description"));
683: prop_id.setExpert(false);
684: prop_id.setHidden(true);
685: prop_id.setPreferred(false);
686: attrib = new AttributeDescriptor("id", false, null, false);
687: prop_id.setValue(
688: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
689: attrib);
690: prop_id
691: .setValue(
692: Constants.PropertyDescriptor.CATEGORY,
693: com.sun.rave.designtime.base.CategoryDescriptors.GENERAL);
694:
695: PropertyDescriptor prop_parent = new PropertyDescriptor(
696: "parent", beanClass, "getParent", "setParent");
697: prop_parent.setDisplayName(resources
698: .getString("Tree_parent_DisplayName"));
699: prop_parent.setShortDescription(resources
700: .getString("Tree_parent_Description"));
701: prop_parent.setExpert(false);
702: prop_parent.setHidden(true);
703: prop_parent.setPreferred(false);
704: prop_parent
705: .setValue(
706: Constants.PropertyDescriptor.CATEGORY,
707: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
708:
709: PropertyDescriptor prop_rendered = new PropertyDescriptor(
710: "rendered", beanClass, "isRendered", "setRendered");
711: prop_rendered.setDisplayName(resources
712: .getString("Tree_rendered_DisplayName"));
713: prop_rendered.setShortDescription(resources
714: .getString("Tree_rendered_Description"));
715: prop_rendered.setExpert(false);
716: prop_rendered.setHidden(false);
717: prop_rendered.setPreferred(false);
718: attrib = new AttributeDescriptor("rendered", false, null,
719: true);
720: prop_rendered.setValue(
721: Constants.PropertyDescriptor.ATTRIBUTE_DESCRIPTOR,
722: attrib);
723: prop_rendered
724: .setValue(
725: Constants.PropertyDescriptor.CATEGORY,
726: com.sun.rave.designtime.base.CategoryDescriptors.ADVANCED);
727:
728: PropertyDescriptor prop_rendererType = new PropertyDescriptor(
729: "rendererType", beanClass, "getRendererType",
730: "setRendererType");
731: prop_rendererType.setDisplayName(resources
732: .getString("Tree_rendererType_DisplayName"));
733: prop_rendererType.setShortDescription(resources
734: .getString("Tree_rendererType_Description"));
735: prop_rendererType.setExpert(false);
736: prop_rendererType.setHidden(true);
737: prop_rendererType.setPreferred(false);
738: prop_rendererType
739: .setValue(
740: Constants.PropertyDescriptor.CATEGORY,
741: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
742:
743: PropertyDescriptor prop_rendersChildren = new PropertyDescriptor(
744: "rendersChildren", beanClass, "getRendersChildren",
745: null);
746: prop_rendersChildren.setDisplayName(resources
747: .getString("Tree_rendersChildren_DisplayName"));
748: prop_rendersChildren.setShortDescription(resources
749: .getString("Tree_rendersChildren_Description"));
750: prop_rendersChildren.setExpert(false);
751: prop_rendersChildren.setHidden(true);
752: prop_rendersChildren.setPreferred(false);
753: prop_rendersChildren
754: .setValue(
755: Constants.PropertyDescriptor.CATEGORY,
756: com.sun.rave.designtime.base.CategoryDescriptors.INTERNAL);
757:
758: propDescriptors = new PropertyDescriptor[] { prop_action,
759: prop_actionListener, prop_attributes,
760: prop_childCount, prop_children, prop_clientSide,
761: prop_expandOnSelect, prop_expanded, prop_facets,
762: prop_family, prop_id, prop_imageURL,
763: prop_immediate, prop_parent, prop_rendered,
764: prop_rendererType, prop_rendersChildren,
765: prop_required, prop_selected, prop_style,
766: prop_styleClass, prop_target, prop_text,
767: prop_toolTip, prop_url, prop_visible, };
768: return propDescriptors;
769:
770: } catch (IntrospectionException e) {
771: e.printStackTrace();
772: return null;
773: }
774:
775: }
776:
777: }
778: //GEN-END:BeanInfo
|