当前位置: 首页>>代码示例>>Java>>正文


Java Group类代码示例

本文整理汇总了Java中com.sun.hotspot.igv.data.Group的典型用法代码示例。如果您正苦于以下问题:Java Group类的具体用法?Java Group怎么用?Java Group使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Group类属于com.sun.hotspot.igv.data包,在下文中一共展示了Group类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: resultChanged

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
@Override
public void resultChanged(LookupEvent lookupEvent) {
    final InputGraphProvider p = LookupHistory.getLast(InputGraphProvider.class);//)Utilities.actionsGlobalContext().lookup(InputGraphProvider.class);
    if (p != null) {
        SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                InputGraph graph = p.getGraph();
                if (graph != null) {
                    Group g = graph.getGroup();
                    rootNode.update(graph, g.getMethod());
                }
            }
        });
    }
}
 
开发者ID:arodchen,项目名称:MaxSim,代码行数:17,代码来源:BytecodeViewTopComponent.java

示例2: resultChanged

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
@Override
public void resultChanged(LookupEvent lookupEvent) {
    final InputGraphProvider p = null; // TODO(tw): FIXME //.getLast(InputGraphProvider.class);//)Utilities.actionsGlobalContext().lookup(InputGraphProvider.class);
    if (p != null) {
        SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                InputGraph graph = p.getGraph();
                if (graph != null) {
                    Group g = graph.getGroup();
                    rootNode.update(graph, g.getMethod());
                }
            }
        });
    }
}
 
开发者ID:arodchen,项目名称:MaxSim,代码行数:17,代码来源:BytecodeViewTopComponent.java

示例3: resultChanged

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
@Override
public void resultChanged(LookupEvent lookupEvent) {
    final InputGraphProvider p = LookupHistory.getLast(InputGraphProvider.class);//)Utilities.actionsGlobalContext().lookup(InputGraphProvider.class);
        SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
            if (p != null) {
                InputGraph graph = p.getGraph();
                if (graph != null) {
                    Group g = graph.getGroup();
                    rootNode.update(graph, g.getMethod());
                    return;
                }
            }
                    rootNode.update(null, null);
                }
        });

}
 
开发者ID:AdoptOpenJDK,项目名称:openjdk-jdk10,代码行数:20,代码来源:BytecodeViewTopComponent.java

示例4: DiagramViewModel

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
public DiagramViewModel(Group g, FilterChain filterChain, FilterChain sequenceFilterChain) {
    super(calculateStringList(g));

    this.showNodeHull = true;
    this.showBlocks = true;
    this.group = g;
    assert filterChain != null;
    this.filterChain = filterChain;
    assert sequenceFilterChain != null;
    this.sequenceFilterChain = sequenceFilterChain;
    hiddenNodes = new HashSet<Integer>();
    onScreenNodes = new HashSet<Integer>();
    selectedNodes = new HashSet<Integer>();
    super.getChangedEvent().addListener(this);
    diagramChangedEvent = new ChangedEvent<DiagramViewModel>(this);
    viewChangedEvent = new ChangedEvent<DiagramViewModel>(this);
    viewPropertiesChangedEvent = new ChangedEvent<DiagramViewModel>(this);
    groupChangedEvent = new ChangedEvent<DiagramViewModel>(this);
    groupChangedEvent.addListener(groupChangedListener);
    groupChangedEvent.fire();

    filterChain.getChangedEvent().addListener(filterChainChangedListener);
    sequenceFilterChain.getChangedEvent().addListener(filterChainChangedListener);
}
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:25,代码来源:DiagramViewModel.java

示例5: export

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
private void export(XMLWriter writer, Group g) throws IOException {
    Properties attributes = new Properties();
    attributes.setProperty("difference", Boolean.toString(true));
    writer.startTag(Parser.GROUP_ELEMENT, attributes);
    writer.writeProperties(g.getProperties());

    if (g.getMethod() != null) {
        export(writer, g.getMethod());
    }

    InputGraph previous = null;
    for (InputGraph graph : g.getGraphs()) {
        export(writer, graph, previous, true);
        previous = graph;
    }

    writer.endTag();
}
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:19,代码来源:Printer.java

示例6: start

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
@Override
protected Group start() throws SAXException {
    Group group = new Group();
    Parser.this.difference = false;
    String differenceProperty = this.readAttribute(DIFFERENCE_PROPERTY);
    if (differenceProperty != null && (differenceProperty.equals("1") || differenceProperty.equals("true"))) {
        Parser.this.difference = true;
    }

    ParseMonitor monitor = getMonitor();
    if (monitor != null) {
        monitor.setState(group.getName());
    }

    return group;
}
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:17,代码来源:Parser.java

示例7: initReceivers

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
private void initReceivers() {

        final GroupCallback callback = new GroupCallback() {

            public void started(Group g) {
                getDocument().addGroup(g);
            }
        };

        Collection<? extends GroupReceiver> receivers = Lookup.getDefault().lookupAll(GroupReceiver.class);
        if (receivers.size() > 0) {
            JPanel panel = new JPanel();
            panel.setLayout(new BoxLayout(panel, BoxLayout.Y_AXIS));

            for (GroupReceiver r : receivers) {
                Component c = r.init(callback);
                panel.add(c);
            }

            jPanel2.add(panel, BorderLayout.PAGE_START);
        }
    }
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:23,代码来源:OutlineTopComponent.java

示例8: organize

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
public List<Pair<String, List<Group>>> organize(List<String> subFolders, List<Group> groups) {

        List<Pair<String, List<Group>>> result = new ArrayList<Pair<String, List<Group>>>();

        if (groups.size() == 1 && subFolders.size() > 0) {
            result.add(new Pair<String, List<Group>>("", groups));
        } else {
            for (Group g : groups) {
                List<Group> children = new ArrayList<Group>();
                children.add(g);
                Pair<String, List<Group>> p = new Pair<String, List<Group>>();
                p.setLeft(g.getName());
                p.setRight(children);
                result.add(p);
            }
        }

        return result;
    }
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:20,代码来源:StandardGroupOrganizer.java

示例9: FolderNode

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
private FolderNode(String name, GroupOrganizer organizer, List<String> oldSubFolders, final List<Group> groups, FolderChildren children, InstanceContent content) {
    super(children, new AbstractLookup(content));
    children.setParent(this);
    this.content = content;
    this.children = children;
    content.add(new RemoveCookie() {

        public void remove() {
            for (Group g : groups) {
                if (g.getDocument() != null) {
                    g.getDocument().removeGroup(g);
                }
            }
        }
    });
    init(name, organizer, oldSubFolders, groups);
}
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:18,代码来源:FolderNode.java

示例10: organize

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
public List<Pair<String, List<Group>>> organize(List<String> subFolders, List<Group> groups) {

        List<Pair<String, List<Group>>> result = new ArrayList<Pair<String, List<Group>>>();

        if (subFolders.size() == 0) {
            buildResult(result, groups, packageNameProvider);
        } else if (subFolders.size() == 1) {
            buildResult(result, groups, classNameProvider);
        } else if (subFolders.size() == 2) {
            for (Group g : groups) {
                List<Group> children = new ArrayList<Group>();
                children.add(g);
                Pair<String, List<Group>> p = new Pair<String, List<Group>>();
                p.setLeft(reducedNameProvider.getName(g));
                p.setRight(children);
                result.add(p);
            }
        } else {
            result.add(new Pair<String, List<Group>>("", groups));
        }

        return result;
    }
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:24,代码来源:JavaGroupOrganizer.java

示例11: buildResult

import com.sun.hotspot.igv.data.Group; //导入依赖的package包/类
private void buildResult(List<Pair<String, List<Group>>> result, List<Group> groups, NameProvider provider) {
    HashMap<String, List<Group>> map = new HashMap<String, List<Group>>();
    for (Group g : groups) {
        String s = provider.getName(g);

        if (!map.containsKey(s)) {
            List<Group> list = new ArrayList<Group>();
            Pair<String, List<Group>> pair = new Pair<String, List<Group>>(s, list);
            result.add(pair);
            map.put(s, list);
        }

        List<Group> curList = map.get(s);
        curList.add(g);
    }

    Collections.sort(result, new Comparator<Pair<String, List<Group>>>() {

        public int compare(Pair<String, List<Group>> a, Pair<String, List<Group>> b) {
            return a.getLeft().compareTo(b.getLeft());
        }
    });
}
 
开发者ID:ojdkbuild,项目名称:lookaside_java-1.8.0-openjdk,代码行数:24,代码来源:JavaGroupOrganizer.java


注:本文中的com.sun.hotspot.igv.data.Group类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。