User: ko5tik  
  Date: 02/04/16 04:58:34

  Modified:    src/java/xdocletgui/swing TreeFactoryScratch.java
  Log:
  tag creation works
  
  Revision  Changes    Path
  1.12      +27 -0     xdocletgui/src/java/xdocletgui/swing/TreeFactoryScratch.java
  
  Index: TreeFactoryScratch.java
  ===================================================================
  RCS file: 
/cvsroot/xdoclet/xdocletgui/src/java/xdocletgui/swing/TreeFactoryScratch.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -w -r1.11 -r1.12
  --- TreeFactoryScratch.java   9 Apr 2002 16:35:38 -0000       1.11
  +++ TreeFactoryScratch.java   16 Apr 2002 11:58:34 -0000      1.12
  @@ -62,6 +62,33 @@
   
   
        /**
  +      * create tag node from tag description (also create mandatory subnodes)
  +      *
  +      * @param tag tag description
  +      * @param xdoc xdoc to weawe into
  +      * @return fresh and clean tag
  +      */
  +     public static TagTreeNode createTagNode(Tag tag, XDoc xdoc) {
  +
  +             XTag xtag = xdoc.addTag(tag.getName(), "");
  +             TagTreeNode ttn = new TagTreeNode(tag, xtag);
  +             Iterator params = tag.getParameters().iterator();
  +             for (int i = 0; i < tag.size(); i++) {
  +                     TagParameter tp = tag.getTagParameter(i);
  +
  +                     if (tp.isMandatory()) {
  +                             //create node for this
  +                             TagParameterTreeNode tpn = new 
TagParameterTreeNode(tp, "");
  +                             ttn.add(tpn);
  +                             xtag.setAttribute(tp.getName(), "");
  +                     }
  +             }
  +
  +             return ttn;
  +     }
  +
  +
  +     /**
         * Describe what the method does
         *
         * @param classes Describe what the parameter does
  
  
  

_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel

Reply via email to