コード例 #1
0
 /**
  * Lists all transactions of the specified item, stored locally.
  *
  * @param context
  * @param itemId id of the item whose transactions will be returned.
  * @return list of transactions.
  */
 public static List<Transaction> getTransactions(Context context, String itemId) {
   final byte[] salt = getSalt();
   itemId = salt != null ? Security.obfuscate(context, salt, itemId) : itemId;
   List<Transaction> transactions = TransactionManager.getTransactions(context, itemId);
   unobfuscate(context, transactions);
   return transactions;
 }
コード例 #2
0
 static void unobfuscate(Context context, List<Transaction> transactions) {
   for (Transaction p : transactions) {
     unobfuscate(context, p);
   }
 }
コード例 #3
0
 /**
  * Lists all transactions stored locally, including cancellations and refunds.
  *
  * @param context
  * @return list of transactions.
  */
 public static List<Transaction> getTransactions(Context context) {
   List<Transaction> transactions = TransactionManager.getTransactions(context);
   unobfuscate(context, transactions);
   return transactions;
 }