Package org.apache.airavata.xbaya.component.gui

Examples of org.apache.airavata.xbaya.component.gui.ComponentTreeNode


    /**
     * @see org.apache.airavata.xbaya.component.registry.ComponentRegistry#getComponentTree()
     */
    @Override
    public ComponentTreeNode getComponentTree() throws ComponentRegistryException {
        this.tree = new ComponentTreeNode(this);
        parse();
        return this.tree;
    }
View Full Code Here


    }

    private void addComponents(String name, List<WSComponent> components) {
        this.componentsMap.put(name, components);
        WebComponentReference componentReference = new WebComponentReference(name, components);
        ComponentTreeNode treeLeaf = new ComponentTreeNode(componentReference);
        this.tree.add(treeLeaf);
    }
View Full Code Here

    /**
     * @see org.apache.airavata.xbaya.component.registry.ComponentRegistry#getComponentTree()
     */
    @Override
    public ComponentTreeNode getComponentTree() {
      ComponentTreeNode tree = new ComponentTreeNode(this);
        try {
            List<ServiceDescription> services = this.registry.searchServiceDescription("");
            for (ServiceDescription serviceDescription : services) {
                String serviceName = serviceDescription.getType().getName();
                JCRComponentReference jcr = new JCRComponentReference(serviceName, registry.getWSDL(serviceName));
                tree.add(new ComponentTreeNode(jcr));
            }
        } catch (RegistryException e) {
            log.error(e.getMessage(), e);
        } catch (Exception e) {
            log.error(e.getMessage(), e);
View Full Code Here

    /**
     * @see org.apache.airavata.xbaya.component.registry.ComponentRegistry#getComponentTree()
     */
    @Override
    public ComponentTreeNode getComponentTree() {
        ComponentTreeNode tree = new ComponentTreeNode(this);
        for (String name : this.componentMap.keySet()) {
            Component component = this.componentMap.get(name);
            SystemComponentReference componentReference = new SystemComponentReference(name, component);
            tree.add(new ComponentTreeNode(componentReference));
        }
        return tree;
    }
View Full Code Here

     * @throws ComponentRegistryException
     */
    @Override
    public ComponentTreeNode getComponentTree() throws ComponentRegistryException {
        try {
            ComponentTreeNode componentTree = getComponentTree(this.directory);
            componentTree.setComponentRegistry(this);
            return componentTree;
        } catch (RuntimeException e) {
            throw new ComponentRegistryException(e);
        }
    }
View Full Code Here

        if (!dir.isDirectory()) {
            throw new XBayaRuntimeException(dir + "is not a directory.");
        }

        boolean found = false;
        ComponentTreeNode tree = new ComponentTreeNode(dir.getName());
        for (File file : dir.listFiles()) {
            String fileName = file.getName();
            if (file.isDirectory()) {
                ComponentTreeNode subTree = getComponentTree(file);
                if (subTree != null) {
                    found = true;
                    tree.add(subTree);
                }
            } else if (fileName.endsWith(XBayaConstants.XML_SUFFIX) || fileName.endsWith(XBayaConstants.WSDL_SUFFIX)
                    || fileName.endsWith(XBayaConstants.WSDL_SUFFIX2)) {
                found = true;
                LocalComponentReference componentReference = new LocalComponentReference(file.getName(), file, this);
                ComponentTreeNode treeLeaf = new ComponentTreeNode(componentReference);
                treeLeaf.setAllowsChildren(false);
                tree.add(treeLeaf);
            }
        }
        if (!found) {
            // Doesn't show a directory that doesn't have any components.
View Full Code Here

     *
     * @param url
     */
    public URLComponentRegistry(URI url) {
        this.url = url;
        this.tree = new ComponentTreeNode(this);
    }
View Full Code Here

     * @throws ComponentRegistryException
     * @see org.apache.airavata.xbaya.component.registry.ComponentRegistry#getComponentTree()
     */
    @Override
    public ComponentTreeNode getComponentTree() throws ComponentRegistryException {
        this.tree = new ComponentTreeNode(this);
        try {
            loadComponents();
            return this.tree;
        } catch (ComponentException e) {
            throw new ComponentRegistryException(e);
View Full Code Here

        List<WSComponent> components = WSComponentFactory.createComponents(WSDLUtil
                .wsdlDefinitions3ToWsdlDefintions5(definitions));
        String urlString = this.url.toString();
        String name = urlString.substring(urlString.lastIndexOf('/') + 1);
        URLComponentReference componentReference = new URLComponentReference(name, components);
        ComponentTreeNode treeLeaf = new ComponentTreeNode(componentReference);
        this.tree.add(treeLeaf);
    }
View Full Code Here

     *
     * @return The ComponentTree
     */
    @Override
    public ComponentTreeNode getComponentTree() {
        ComponentTreeNode tree = new ComponentTreeNode(this);
        for (String name : this.componentMap.keySet()) {
            Component component = this.componentMap.get(name);
            SystemComponentReference componentReference = new SystemComponentReference(name, component);
            tree.add(new ComponentTreeNode(componentReference));
        }
        return tree;
    }
View Full Code Here

TOP

Related Classes of org.apache.airavata.xbaya.component.gui.ComponentTreeNode

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.