Package com.jgraph.layout.hierarchical.model

Examples of com.jgraph.layout.hierarchical.model.JGraphHierarchyRank.toArray()


    Map map = new Hashtable();
    Object[][] rank = new Object[model.maxRank + 1][];
    for (int i = 0; i <= model.maxRank; i++) {
      JGraphHierarchyRank rankSet = (JGraphHierarchyRank) model.ranks
          .get(new Integer(i));
      rank[i] = rankSet.toArray();
      for (int j = 0; j < rank[i].length; j++) {
        // Use the weight to store the rank and visited to store whether
        // or not the cell is in the list
        JGraphAbstractHierarchyCell cell = (JGraphAbstractHierarchyCell) rank[i][j];
        WeightedCellSorter cellWrapper = new WeightedCellSorter(cell, i);
View Full Code Here


   */
  protected void rankMedianPosition(int rankValue,
      JGraphHierarchyModel model, int nextRankValue) {
    JGraphHierarchyRank rankSet = (JGraphHierarchyRank) model.ranks
        .get(new Integer(rankValue));
    Object[] rank = rankSet.toArray();
    // Form an array of the order in which the cell are to be processed
    // , the order is given by the weighted sum of the in or out edges,
    // depending on whether we're travelling up or down the hierarchy.
    WeightedCellSorter[] weightedValues = new WeightedCellSorter[rank.length];
    Map cellMap = new Hashtable(rank.length);
View Full Code Here

    // Stores initial ordering as being the best one found so far
    nestedBestRanks = new Object[model.ranks.size()][];
    for (int i = 0; i < nestedBestRanks.length; i++) {
      JGraphHierarchyRank rank = (JGraphHierarchyRank) model.ranks
          .get(new Integer(i));
      nestedBestRanks[i] = rank.toArray();
    }

    progress.reset(maxIterations);
    iterationsWithoutImprovement = 0;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.