Package org.jwall.web.policy

Examples of org.jwall.web.policy.Method


        super.getListCellRendererComponent(arg0, arg1, arg2, arg3, arg4);
        setFont(new Font("Monospaced", Font.PLAIN, 13));

       
        if( arg1.getType() == TreeNode.METHOD_NODE ){
          Method m = (Method) arg1;
            setText( "Method "+m.getValue() );
            setIcon( WebPolicyEditor.getIcon(m) );
            return this;
        }
       
        if( arg1.getType() == TreeNode.META_INF_NODE ){
View Full Code Here


        }



        if( arg1.getType() == TreeNode.METHOD_NODE ){
            Method m = (Method) arg1;

            StringBuffer s = new StringBuffer( "<html>" );
            if( m.isInherited() ){
                setInheritanceColors();
                s.append( "<i>" );

            }

            s.append( "Method " + m.getValue() );

            if( m.isInherited() )
                s.append( "</>" );

            s.append( "</html>" );

            setText( s.toString() );
View Full Code Here

            i++;
            newName = "GET-" + i;
          }
        }

        Method method = new Method(newName);
        node.add(method);
        rmodel.notify(node);

        jtree.startEditingAtPath(new TreePath(PolicyTreeModel
            .getPath(method)));
View Full Code Here

    for (TreeNode node : nodes) {

      if (node.getType() == TreeNode.METHOD_NODE) {

        Method m = (Method) node;
        if (m.getValue().equals(name))
          return true;
      }
    }

    return false;
View Full Code Here

      ctx.setBase(name.getText());
      return ctx;
    }

    if (nodeType == TreeNode.METHOD_NODE) {
      Method m = (Method) node;
      m.setValue(name.getText());
      return m;
    }

    if (nodeType == TreeNode.RESOURCE_NODE) {
      Resource res = (Resource) node;
View Full Code Here

    return o;
  }

  public void createUIComponents(TreeNode node) {
    if (node.getType() == TreeNode.METHOD_NODE) {
      Method m = (Method) node;
      JLabel l1 = new JLabel("Method(s): ");
      l1.setFont(f);
      l1.setAlignmentY(Component.CENTER_ALIGNMENT);
      p.add(l1);

      String v = m.getValue();
      name = new JTextField(v, v.length() + 2);
      name.addKeyListener(this);
      name.setFont(f);
      p.add(name);
    }
View Full Code Here

      }

      if (AbstractTreeAction.TREE_INSERT_METHOD == e.getActionCommand()) {
        log.finest("Inserting method...");

        Method method = new Method("GET");
        for (TreeNode ch : node.children()) {

          if (ch instanceof Method) {

            Method other = (Method) ch;
            if (other.getValue() == "GET")
              method = new Method("POST");

          }

        }
View Full Code Here

TOP

Related Classes of org.jwall.web.policy.Method

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.