Package net.sf.joafip.meminspector.entity.show

Examples of net.sf.joafip.meminspector.entity.show.NodeForClass


  }

  /* TreeModel interface implementation */

  public Object getChild(final Object parent, final int index) {
    final NodeForClass parentNode = (NodeForClass) parent;
    return parentNode.getChildAt(index);
  }
View Full Code Here


    final NodeForClass parentNode = (NodeForClass) parent;
    return parentNode.getChildAt(index);
  }

  public int getChildCount(final Object parent) {
    final NodeForClass parentNode = (NodeForClass) parent;
    return parentNode.getChildCount();
  }
View Full Code Here

    final NodeForClass parentNode = (NodeForClass) parent;
    return parentNode.getChildCount();
  }

  public int getIndexOfChild(final Object parent, final Object child) {
    final NodeForClass parentNode = (NodeForClass) parent;
    return parentNode.getIndexOfChild((NodeForClass) child);
  }
View Full Code Here

  public Object getRoot() {
    return rootNode;
  }

  public boolean isLeaf(final Object object) {
    final NodeForClass node = (NodeForClass) object;
    return node.getChildCount() == 0;
  }
View Full Code Here

  }

  public Component getTreeCellRendererComponent(final JTree tree,
      final Object value, final boolean selected, final boolean expanded,
      final boolean leaf, final int row, final boolean hasFocus) {
    final NodeForClass nodeForClass = (NodeForClass) value;
    // final TreePath path = tree.getPathForRow(row);
    // String field;
    // final boolean fieldIsStatic=false;
    // if (path == null) {
    // field = "-no path for row-";
    // fieldIsStatic = false;
    // } else {
    // final TreePath parentPath = path.getParentPath();
    // if (/* nodeForObject.isLeafNode() || */parentPath == null) {
    // field = "";
    // fieldIsStatic = false;
    // } else {
    // final INodeForObject parentNode = (INodeForObject) parentPath
    // .getLastPathComponent();
    // final String field2 = parentNode.getField(nodeForObject);
    // if (field2 == null) {
    // field = " -" + parentNode.getId() + " have not child #"
    // + nodeForObject.getId() + "-";
    // fieldIsStatic = false;
    // } else {
    // field = " " + field2;
    // final Boolean fieldIsStatic2 = parentNode
    // .fieldIsStatic(nodeForObject);
    // if (fieldIsStatic2 == null) {
    // fieldIsStatic = false;
    // } else {
    // fieldIsStatic = fieldIsStatic2;
    // }
    // }
    // }
    // }

    final Font font = tree.getFont();
    setFont(font);

    try {
      final StringBuilder stringBuilder = new StringBuilder();
      stringBuilder.append(nodeForClass.getClassName());
      stringBuilder.append(' ');
      stringBuilder.append(nodeForClass.getNewSize());
      setText(stringBuilder.toString());

      // if (nodeForObject == null) {
      // setText("null");
      // } else {
      // final String string = nodeForObject.identificationString();
      // if (string == null) {
      // setText("<null string>");
      // } else {
      // setText(string + field);
      // }
      // }

      Icon icon;
      /*
       * if (nodeForObject.isLeafNode()) { if
       * (nodeForObject.isMarkedNew()) { icon = objectLeafNewIcon; } else
       * if (nodeForObject.isMarkedNewSon()) { icon =
       * objectLeafNewSonIcon; } else { icon = objectLeafIcon; } } else {
       */
      if (nodeForClass.isMarkedNew()) {
        icon = objectNewIcon;
        // } else if (nodeForObject.isMarkedNewSon()) {
        // icon = objectNewSonIcon;
      } else {
        icon = objectIcon;
View Full Code Here

TOP

Related Classes of net.sf.joafip.meminspector.entity.show.NodeForClass

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.