コード例 #1
0
ファイル: Dependency.java プロジェクト: 9smart/redline
  /**
   * Returns an array of Integer with the flags of every dependency from a list of dependencies.
   *
   * @param dependencyList List of dependencies
   * @return Integer[] with all flags of the dependencies
   */
  public static Integer[] getArrayOfFlags(List<Dependency> dependencyList) {
    List<Integer> flagsList = new LinkedList<Integer>();

    for (Dependency dependency : dependencyList) {
      flagsList.add(dependency.getFlags());
    }

    return flagsList.toArray(new Integer[flagsList.size()]);
  }
コード例 #2
0
ファイル: Dependency.java プロジェクト: 9smart/redline
  /**
   * Returns an array of Integer with the flags of every dependency from a list of dependencies.
   *
   * @param dependencies List of dependencies
   * @return Integer[] with all flags of the dependencies
   */
  public static Integer[] getArrayOfFlags(Map<String, Dependency> dependencies) {
    List<Integer> flagsList = new LinkedList<Integer>();

    for (Dependency dependency : dependencies.values()) {
      flagsList.add(dependency.getFlags());
    }

    return flagsList.toArray(new Integer[flagsList.size()]);
  }