Package net.minecraft.util.org.apache.commons.lang3.tuple

Examples of net.minecraft.util.org.apache.commons.lang3.tuple.ImmutablePair


    workGraph.remove(work);
    invertedWorkGraph.remove(work);
  }

  public EdgeType getEdgeType(BaseWork a, BaseWork b) {
    return edgeProperties.get(new ImmutablePair(a,b)).getEdgeType();
  }
View Full Code Here


  /**
   * returns the edge type connecting work a and b
   */
  public TezEdgeProperty getEdgeProperty(BaseWork a, BaseWork b) {
    return edgeProperties.get(new ImmutablePair(a,b));
  }
View Full Code Here

      TezEdgeProperty edgeProp) {
    workGraph.get(a).add(b);
    invertedWorkGraph.get(b).add(a);
    roots.remove(b);
    leaves.remove(a);
    ImmutablePair workPair = new ImmutablePair(a, b);
    edgeProperties.put(workPair, edgeProp);
  }
View Full Code Here

    }

    public static ImmutablePair b(int i) {
        switch (i) {
        case 1:
            return new ImmutablePair(Blocks.COBBLESTONE, Integer.valueOf(0));

        case 2:
            return new ImmutablePair(Blocks.SMOOTH_BRICK, Integer.valueOf(0));

        case 3:
            return new ImmutablePair(Blocks.SMOOTH_BRICK, Integer.valueOf(1));

        case 4:
            return new ImmutablePair(Blocks.SMOOTH_BRICK, Integer.valueOf(2));

        case 5:
            return new ImmutablePair(Blocks.SMOOTH_BRICK, Integer.valueOf(3));

        default:
            return new ImmutablePair(Blocks.STONE, Integer.valueOf(0));
        }
    }
View Full Code Here

                        for (l = 0; !flag && l <= 10 && l >= -10; l = l <= 0 ? 1 - l : 0 - l) {
                            for (int j1 = 0; !flag && j1 <= 10 && j1 >= -10; j1 = j1 <= 0 ? 1 - j1 : 0 - j1) {
                                if (this.world.getType(i + l, j + i1, k + j1) == Blocks.MONSTER_EGGS) {
                                    if (!this.world.getGameRules().getBoolean("mobGriefing")) {
                                        int k1 = this.world.getData(i + l, j + i1, k + j1);
                                        ImmutablePair immutablepair = BlockMonsterEggs.b(k1);

                                        this.world.setTypeAndData(i + l, j + i1, k + j1, (Block) immutablepair.getLeft(), ((Integer) immutablepair.getRight()).intValue(), 3);
                                    } else {
                                        this.world.setAir(i + l, j + i1, k + j1, false);
                                    }

                                    Blocks.MONSTER_EGGS.postBreak(this.world, i + l, j + i1, k + j1, 0);
View Full Code Here

        String sql = "SELECT v.proposal_id as proposalId, avg(v.note) as moy, count(v.proposal_id) as nbVote, t.title as proposalTitle FROM vote v, proposal t where (v.proposal_id=t.id) group by v.proposal_id order by moy desc";
        List<SqlRow> rows = Ebean.createSqlQuery(sql).findList();
       
        Map<Long, Pair<Double, Integer>> moyennes = new HashMap<Long, Pair<Double, Integer>>();
        for (SqlRow row : rows) {
            Pair<Double, Integer> moyProposal = new ImmutablePair(row.getDouble("moy"), row.getInteger("nbVote"));
            moyennes.put(row.getLong("proposalId"), moyProposal);
        }
       
        return moyennes;
    }
View Full Code Here

    workGraph.remove(work);
    invertedWorkGraph.remove(work);
  }

  public EdgeType getEdgeType(BaseWork a, BaseWork b) {
    return edgeProperties.get(new ImmutablePair(a,b)).getEdgeType();
  }
View Full Code Here

  /**
   * returns the edge type connecting work a and b
   */
  public TezEdgeProperty getEdgeProperty(BaseWork a, BaseWork b) {
    return edgeProperties.get(new ImmutablePair(a,b));
  }
View Full Code Here

      TezEdgeProperty edgeProp) {
    workGraph.get(a).add(b);
    invertedWorkGraph.get(b).add(a);
    roots.remove(b);
    leaves.remove(a);
    ImmutablePair workPair = new ImmutablePair(a, b);
    edgeProperties.put(workPair, edgeProp);
  }
View Full Code Here

    workGraph.remove(work);
    invertedWorkGraph.remove(work);
  }

  public EdgeType getEdgeType(BaseWork a, BaseWork b) {
    return edgeProperties.get(new ImmutablePair(a,b)).getEdgeType();
  }
View Full Code Here

TOP

Related Classes of net.minecraft.util.org.apache.commons.lang3.tuple.ImmutablePair

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.