Package org.fusesource.ide.camel.model.generated

Examples of org.fusesource.ide.camel.model.generated.Bean


      if (node.getUri() != null && node.getUri().trim().length()>0) {
        // uri specified, use it
        return node.getUri();
      }
    } else if (this instanceof Bean) {
      Bean node = (Bean) this;
      return "bean " + Strings.getOrElse(node.getRef());
    } else if (this instanceof Catch) {
      Catch node = (Catch) this;
      List exceptions = node.getExceptions();
      if (exceptions != null && exceptions.size() > 0) {
        return "catch " + exceptions;
      } else {
        return "catch " + Expressions.getExpressionOrElse(node.getHandled());
      }
    } else if (this instanceof Choice) {
      return "choice";
    } else if (this instanceof ConvertBody) {
      ConvertBody node = (ConvertBody) this;
      return "convertBody " + Strings.getOrElse(node.getType());
    } else if (this instanceof Enrich) {
      Enrich node = (Enrich) this;
      return "enrich " + Strings.getOrElse(node.getResourceUri());
    } else if (this instanceof Finally) {
      return "finally";
    } else if (this instanceof InOnly) {
      InOnly node = (InOnly) this;
      return "inOnly " + Strings.getOrElse(node.getUri());
    } else if (this instanceof InOut) {
      InOut node = (InOut) this;
      return "inOut " + Strings.getOrElse(node.getUri());
    } else if (this instanceof InterceptSendToEndpoint) {
      InterceptSendToEndpoint node = (InterceptSendToEndpoint) this;
      return "intercept " + Strings.getOrElse(node.getUri());
    } else if (this instanceof Log) {
      Log node = (Log) this;
      return "log " + Strings.getOrElse(node.getLogName());
    } else if (this instanceof Marshal) {
      return "marshal";
    } else if (this instanceof OnException) {
      OnException node = (OnException) this;
      return "on exception " + Strings.getOrElse(node.getExceptions());
    } else if (this instanceof Otherwise) {
      return "otherwise";
    } else if (this instanceof PollEnrich) {
      PollEnrich node = (PollEnrich) this;
      return "poll enrich " + Strings.getOrElse(node.getResourceUri());
    } else if (this instanceof RemoveHeader) {
      RemoveHeader node = (RemoveHeader) this;
      return "remove header " + Strings.getOrElse(node.getHeaderName());
    } else if (this instanceof RemoveProperty) {
      RemoveProperty node = (RemoveProperty) this;
      return "remove property " + Strings.getOrElse(node.getPropertyName());
    } else if (this instanceof Rollback) {
      Rollback node = (Rollback) this;
      return "rollback " + Strings.getOrElse(node.getMessage());
    } else if (this instanceof SetExchangePattern) {
      SetExchangePattern node = (SetExchangePattern) this;
      ExchangePattern pattern = node.getPattern();
      if (pattern == null) {
        return "setExchangePattern";
      } else {
        return "set " + pattern;
      }
    } else if (this instanceof Sort) {
      Sort node = (Sort) this;
      return "sort " + Expressions.getExpressionOrElse(node.getExpression());
    } else if (this instanceof When) {
      When node = (When) this;
      return "when " + Expressions.getExpressionOrElse(node.getExpression());
    } else if (this instanceof Unmarshal) {
      return "unmarshal";
    } else if (this instanceof Try) {
      return "try";
    } else if (this instanceof LoadBalance) {
View Full Code Here


    Endpoint endpoint = new Endpoint();
    Filter filter = new Filter();
    Choice choice = new Choice();
    When when = new When();
    Otherwise otherwise = new Otherwise();
    Bean bean = new Bean();
   
    assertCanConnect(true, endpoint, choice);
    assertCanConnect(true, choice, when);
    assertCanConnect(true, choice, otherwise);
   
View Full Code Here

     */
    public static void addFigureIcons(ImageProvider imageProvider) {
        imageProvider.addIconsForClass(new Endpoint());
        imageProvider.addIconsForClass(new Aggregate());
        imageProvider.addIconsForClass(new AOP());
        imageProvider.addIconsForClass(new Bean());
        imageProvider.addIconsForClass(new Catch());
        imageProvider.addIconsForClass(new Choice());
        imageProvider.addIconsForClass(new ConvertBody());
        imageProvider.addIconsForClass(new Delay());
        imageProvider.addIconsForClass(new DynamicRouter());
View Full Code Here

      }

      if (processedBeans.contains(name)) continue;
      processedBeans.add(name);
     
      Bean bean = new Bean();
      bean.setName(name);
      bean.setRef(name);
      bean.setBeanType(aClass);

      String title = bean.getDisplayText();
      String description = "bean '" + name + "' of type " + aClass;

      featureList.add(new CreateBeanFigureFeature(this, title, description, bean));
    }
  }
View Full Code Here

    this.bean = endpoint;
  }

  @Override
  protected AbstractNode createNode() {
    Bean answer = new Bean();
    answer.setRef(bean.getRef());
    answer.setBeanType(bean.getBeanType());
    answer.setName(bean.getName());
    return answer;
  }
View Full Code Here

      String description = "bean '" + name + "' of type " + aClass;
      addMenuItem(menu, name, description, Bean.class, context, fp, new CreateNodeConnectionFeature(fp, Bean.class) {

        @Override
        protected AbstractNode createNode() throws Exception {
          Bean bean = new Bean();
          bean.setName(name);
          bean.setRef(name);
          bean.setBeanType(aClass);
          return bean;
        }
      });
    }
View Full Code Here

    Object bo = getBusinessObjectForPictogramElement(pe);
    if (bo instanceof Endpoint) {
      Endpoint ep = (Endpoint)getBusinessObjectForPictogramElement(pe);
      ep.setUri(value);
    } else if (bo instanceof Bean) {
      Bean bean = (Bean)getBusinessObjectForPictogramElement(pe);
      bean.setRef(value);
    }
   
    // Explicitly update the shape to display the new value in the diagram
    // Note, that this might not be necessary in future versions of Graphiti
    // (currently in discussion)
View Full Code Here

    RouteContainer c = new RouteContainer();

    RouteSupport route1 = new Route();

    Endpoint ep1 = new Endpoint();
    Bean bean1 = new Bean();
    Bean bean2 = new Bean();

    ep1.setId("fileIn1");
    ep1.setDescription("Polls files from input folder...");
    ep1.setUri("file:///home/lhein/test/input/");
    ep1.setLayout(new Rectangle(10, 10, 100, 40));

    bean1.setId("procBean1");
    bean1.setDescription("Examines the file...");
    bean1.setMethod("examineFile");
    bean1.setRef("proc1");
    bean1.setLayout(new Rectangle(150, 10, 100, 40));

    bean2.setId("procBean2");
    bean2.setDescription("Examines the file...");
    bean2.setMethod("examineFile");
    bean2.setRef("proc2");
    bean2.setLayout(new Rectangle(300, 10, 100, 40));

    ep1.addTargetNode(bean1);
    bean1.addTargetNode(bean2);

    route1.addChild(bean2);
View Full Code Here

TOP

Related Classes of org.fusesource.ide.camel.model.generated.Bean

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.