Package org.fusesource.ide.fabric8.core.dto

Examples of org.fusesource.ide.fabric8.core.dto.ContainerDTO


        }
        ContainersNode containersNode = fabric.getContainersNode();
        if (containersNode != null) {
          List<ContainerDTO> selectedContainers = getSelectedContainers();
          if (!selectedContainers.isEmpty()) {
            ContainerDTO container = selectedContainers.get(0);
            ContainerNode containerNode = containersNode
                .getContainerNode(container.getId());
            if (containerNode != null) {
              Selections.setSingleSelection(
                  fabric.getRefreshableUI(), containerNode);
            }
          }
View Full Code Here


    IStructuredSelection selection = getSelection();
    if (selection != null) {
      boolean changed = false;
      Iterator iterator = selection.iterator();
      while (iterator.hasNext()) {
        ContainerDTO container = ContainerNode
            .toContainer(iterator.next());
        if (container != null) {
          containers.add(container);
        }
      }
View Full Code Here

            return container != null && container.isRoot();
          }
        }));

    if (rootContainers.size() == 1 && fabric != null) {
      ContainerDTO rootContainer = rootContainers.get(0);
      ContainersNode containersNode = fabric.getContainersNode();
      if (containersNode != null) {
        return containersNode.getContainerNode(rootContainer.getId());
      }
    }
    return null;
  }
View Full Code Here

            Viewers.async(new Runnable() {

              @Override
              public void run() {
                for (CreateContainerMetadataDTO metadata : newAgents) {
                  ContainerDTO newContainer = metadata.getContainer();
                  if (newContainer != null) {
                    setContainerProfiles(newContainer, profiles);
                    refreshCreatedAgent(args.getName());
                  }
                }
View Full Code Here

            Viewers.async(new Runnable() {

              @Override
              public void run() {
                for (CreateContainerMetadataDTO metadata : newAgents) {
                  ContainerDTO newContainer = metadata.getContainer();
                  if (newContainer != null) {
                    setContainerProfiles(newContainer, profiles);
                    refreshCreatedAgent(args.getName());
                  }
                }
View Full Code Here

  public void okPressed() {
    if (isValid()) {
      String agentName = getNewAgentName();
      ProfileDTO[] profiles = getSelectedProfileArray();

      ContainerDTO agent = null;
      if (selectedAgent != null) {
        agent = selectedAgent.getContainer();
      }
      args.setName(agentName);
      getFabric().createContainer(agent, profiles, args.delegate());
View Full Code Here

    // addChild(connectionWrapper);
    // }
  }

  protected boolean hasJmxConnector() {
    ContainerDTO a = getContainer();
    String jmxUrl = a.getJMXUrl();
    boolean provisioned = a.isAlive() && a.isProvisioningComplete();
    return jmxUrl != null && jmxUrl.trim().length() > 0
        && (provisioned || a.isRoot());
  }
View Full Code Here

  public boolean supportsJmxDomain(String domain) {
    return container.getJmxDomains().contains(domain);
  }

  public boolean matches(ProfileDTO profile) {
    ContainerDTO ag = getContainer();
    List<String> profileIds = ag.getProfileIDs();
    for (String pId : profileIds) {
      if (Objects.equal(pId, profile.getId())) {
        if (Objects.equal(ag.getVersionId(), profile.getVersionId())) {
          return true;
        }
      }
    }
    return false;
View Full Code Here

  @Override
  public Object[] getElements(Object element) {
    if (element instanceof ContainerNode) {
      ContainerNode node = (ContainerNode) element;
      ContainerDTO agent = node.getContainer();
      return agent.getProfiles().toArray();
    }
    if (element instanceof VersionNode) {
      VersionNode version = (VersionNode) element;
      return getProfileChildren(version);
    }
View Full Code Here

        }

      }
    }

    ContainerDTO agent = null;
    if (selectedAgent != null) {
      agent = selectedAgent.getContainer();
    }
    ProfileDTO[] profiles = form.getSelectedProfileArray();
    versionNode.getFabric().createContainer(agent, profiles, args.build());
View Full Code Here

TOP

Related Classes of org.fusesource.ide.fabric8.core.dto.ContainerDTO

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.