Package org.apache.jmeter.control

Examples of org.apache.jmeter.control.GenericController


     * @throws InvocationTargetException
     * @throws InterruptedException
     */
    private void addSimpleController(final JMeterTreeModel model, final JMeterTreeNode node, String name)
            throws InterruptedException, InvocationTargetException {
        final GenericController sc = new GenericController();
        sc.setProperty(TestElement.GUI_CLASS, LOGIC_CONTROLLER_GUI);
        sc.setName(name);
        JMeterUtils.runSafe(new Runnable() {
            @Override
            public void run() {
                try {
                    model.addComponent(sc, node);
View Full Code Here


      super(name);
    }

    public void testConfigGathering() throws Exception {
      ListedHashTree testing = new ListedHashTree();
      GenericController controller = new GenericController();
      ConfigTestElement config1 = new ConfigTestElement();
      config1.setName("config1");
      config1.setProperty("test.property", "A test value");
      TestSampler sampler = new TestSampler();
      sampler.setName("sampler");
View Full Code Here

    init();
  }

  /* Implements JMeterGUIComponent.createTestElement() */
  public TestElement createTestElement() {
    GenericController lc = new GenericController();
    configureTestElement(lc);
    return lc;
  }
View Full Code Here

  /*
   * Helper method to add a Divider
   */
  private void addDivider(JMeterTreeModel model, JMeterTreeNode node) throws IllegalUserActionException {
    GenericController sc = new GenericController();
    sc.setProperty(TestElement.GUI_CLASS, "org.apache.jmeter.control.gui.LogicControllerGui");
    sc.setName("-------------------");
    model.addComponent(sc, node);
  }
View Full Code Here

   * @param name
   *            A name for the Controller
   */
  private void addSimpleController(JMeterTreeModel model, JMeterTreeNode node, String name)
      throws IllegalUserActionException {
    GenericController sc = new GenericController();
    sc.setProperty(TestElement.GUI_CLASS, "org.apache.jmeter.control.gui.LogicControllerGui");
    sc.setName(name);
    model.addComponent(sc, node);
  }
View Full Code Here

      super(name);
    }

    public void testCloning() throws Exception {
      ListedHashTree original = new ListedHashTree();
      GenericController controller = new GenericController();
      controller.setName("controller");
      Arguments args = new Arguments();
      args.setName("args");
      TestPlan plan = new TestPlan();
      plan.addParameter("server", "jakarta");
      original.add(controller, args);
View Full Code Here

  public void setAtts(Attributes atts) throws java.lang.Exception
  {
    String className = atts.getValue("type");
    if(className.equals("org.apache.jmeter.control.LogicController"))
    {
      controller = new GenericController();
    }
    else
    {
      controller = (GenericController)Class.forName(atts.getValue("type")).newInstance();
    }
    if(controller instanceof ModifyController)
    {
      controller = new GenericController();
    }
    controller.setName(atts.getValue("name"));
    controller.setProperty(TestElement.GUI_CLASS,JMeterHandler.getGuiClass(atts.getValue("type")));

  }
View Full Code Here

   *@param  out                      Description of Parameter
   *@exception  java.io.IOException  Description of Exception
   ***********************************************************/
  public void save(Saveable cont, Writer out) throws java.io.IOException
  {
    GenericController controller = (GenericController)cont;
    writeMainTag(out, controller);
    writeSubElements(controller, out);
    out.write("</Controller>");
  }
View Full Code Here

          if (replaced) {
            ((TestElement)item).setProperty(TestElement.GUI_CLASS,
                "org.apache.jmeter.protocol.http.config.gui.UrlConfigGui");
            ((TestElement)item).setProperty(TestElement.NAME,"HTTP Request Defaults");
            GenericController newControl = new GenericController();
            newControl.setProperty(TestElement.GUI_CLASS,
                "org.apache.jmeter.control.gui.LogicControllerGui");
            newControl.setName("Simple Controller");
            tree.replace(item, newControl);
            tree.add(newControl, item);
          }
        } else {
          updateTree(tree.getTree(item));
View Full Code Here

     *@exception Exception  !ToDo (Exception description)
     ***************************************/
    public void testConfigGathering() throws Exception
    {
      ListedHashTree testing = new ListedHashTree();
      GenericController controller = new GenericController();
      ConfigTestElement config1 = new ConfigTestElement();
      config1.setName("config1");
      config1.setProperty(HTTPSampler.DOMAIN, "www.jarkarta.org");
      HTTPSampler sampler = new HTTPSampler();
      sampler.setName("sampler");
View Full Code Here

TOP

Related Classes of org.apache.jmeter.control.GenericController

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.