Package org.python.pydev.refactoring.core.model.tree

Examples of org.python.pydev.refactoring.core.model.tree.ITreeNode


        return null;
    }

    public boolean hasChildren(Object element) {
        if (element instanceof ITreeNode) {
            ITreeNode node = (ITreeNode) element;
            return node.hasChildren();
        }
        return false;
    }
View Full Code Here


        cache = new PepticImageCache();
    }

    public Image getImage(Object element) {
        Image image = null;
        ITreeNode node = (ITreeNode) element;
        image = cache.get(node.getImageName());

        return image;
    }
View Full Code Here

        return null;
    }

    public boolean hasChildren(Object element) {
        if (element instanceof ITreeNode) {
            ITreeNode node = (ITreeNode) element;
            return node.hasChildren();
        }
        return false;
    }
View Full Code Here

    public Object getParent(Object element) {
        return ((ITreeNode) element).getParent();
    }

    public boolean hasChildren(Object element) {
        ITreeNode node = (ITreeNode) element;
        return node.hasChildren();
    }
View Full Code Here

            nodes.add((ITreeNode) o);
        }

        Iterator<ITreeNode> iter = nodes.iterator();
        while (iter.hasNext()) {
            ITreeNode node = iter.next();
            if (node instanceof TreeNodeClassField) {
                List<INodeAdapter> fields = getFields(iter);
                if (!fields.isEmpty()) {
                    ClassDefAdapter clazz = (ClassDefAdapter) node.getAdapter();
                    ConstructorFieldRequest request = new ConstructorFieldRequest(clazz, fields, offsetStrategy,
                            adapterPrefs);
                    requests.add(request);
                }
            }
View Full Code Here

        return requests;
    }

    private List<INodeAdapter> getFields(Iterator<ITreeNode> iter) {
        List<INodeAdapter> fields = new ArrayList<INodeAdapter>();
        ITreeNode field = iter.next();
        while (field instanceof TreeNodeField) {
            fields.add(field.getAdapter());
            if (iter.hasNext()) {
                field = iter.next();
            } else {
                break;
            }
View Full Code Here

TOP

Related Classes of org.python.pydev.refactoring.core.model.tree.ITreeNode

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.