コード例 #1
0
ファイル: PairSet.java プロジェクト: N3TWORK/extendedset
 /**
  * Add the pairs obtained from the Cartesian product of transactions and items
  *
  * @param trans collection of transactions
  * @param item the given item
  * @return <code>true</code> if the set set has been changed
  */
 public boolean addAll(Collection<T> trans, I item) {
   if (trans == null || trans.isEmpty() || item == null) return false;
   return matrix.addAll(allTransactions.convert(trans).indices(), itemToIndex(item));
 }
コード例 #2
0
ファイル: PairSet.java プロジェクト: N3TWORK/extendedset
 /**
  * Add the pairs obtained from the Cartesian product of transactions and items
  *
  * @param trans collection of transactions
  * @param items collection of items
  * @return <code>true</code> if the set set has been changed
  */
 public boolean addAll(Collection<T> trans, Collection<I> items) {
   if (trans == null || trans.isEmpty() || items == null || items.isEmpty()) return false;
   return matrix.addAll(
       allTransactions.convert(trans).indices(), allItems.convert(items).indices());
 }
コード例 #3
0
ファイル: PairSet.java プロジェクト: N3TWORK/extendedset
 /**
  * Add the pairs obtained from the Cartesian product of transactions and items
  *
  * @param trans the given transaction
  * @param items collection of items
  * @return <code>true</code> if the set set has been changed
  */
 public boolean addAll(T trans, Collection<I> items) {
   if (trans == null || items == null || items.isEmpty()) return false;
   return matrix.addAll(transactionToIndex(trans), allItems.convert(items).indices());
 }
コード例 #4
0
ファイル: PairSet.java プロジェクト: N3TWORK/extendedset
 /** {@inheritDoc} */
 @Override
 public boolean addAll(Collection<? extends Pair<T, I>> c) {
   return matrix.addAll(convert(c).matrix);
 }