Package vg.userInterface.attributePanel.components.data

Examples of vg.userInterface.attributePanel.components.data.AttributeRow


    boolean checkAll = true;
    // Finding of attributes and their values
    if(this.vertexAttributes != null) {
      for(StorableAttribute bufAttr : this.vertexAttributes.keySet()) {
        if(bufAttr.getName() != null && bufAttr.getValue() != null) {
          AttributeRow value = null;
          value = data.get(bufAttr.getName());
          boolean visible = this.vertexAttributes.get(bufAttr);
          if(value == null) {
            value = new AttributeRow(bufAttr.getName(), visible, "V", new AttributeValue());
            data.put(bufAttr.getName(), value);
          }
          switch(value.getShow()) {
            case AttributeShower.DEF_UNSHOW_GREEN:
            {
              checkAll = false;
              if(visible) {
                value.getShower().setYellowShow();
              }
              break;
            }
            case AttributeShower.DEF_SHOW_GREEN:
            {
              if(!visible) {
                value.getShower().setYellowShow();
              }
              break;
            }
          }
          value.addValue(bufAttr.getValue());
        } else {
          VisualGraph.log.printError("[" + this.getClass().getName() + ".buildPanel]" + " Error in attribute panel. Attribute name or attribute value = null(Vertex)");
        }
      }
    }
    //-----------------------------------
    if(this.edgeAttributes != null) {
      for(StorableAttribute bufAttr : this.edgeAttributes.keySet()) {
        if(bufAttr.getName() != null && bufAttr.getValue() != null) {
          AttributeRow value = null;
          value = data.get(bufAttr.getName());
          boolean visible = this.edgeAttributes.get(bufAttr);
          if(value == null) {
            value = new AttributeRow(bufAttr.getName(), visible, "E", new AttributeValue());
            data.put(bufAttr.getName(), value);
          }
          switch(value.getShow()) {
            case AttributeShower.DEF_UNSHOW_GREEN:
            {
              checkAll = false;
              if(visible) {
                value.getShower().setYellowShow();
              }
              break;
            }
            case AttributeShower.DEF_SHOW_GREEN:
            {
              if(!visible) {
                value.getShower().setYellowShow();
              }
              break;
            }
          }
          value.addValue(bufAttr.getValue());
        } else {
          VisualGraph.log.printError("[" + this.getClass().getName() + ".buildPanel]" + " Error in attribute panel. Attribute name or attribute value = null(Edge)");
        }
      }
    }
View Full Code Here

TOP

Related Classes of vg.userInterface.attributePanel.components.data.AttributeRow

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.