@Override @Atomic(readOnly = true) public boolean containsAll(Collection<?> c) { return super.containsAll(c); }
public Advice newAdvice(Atomic atomic) { if (atomic.readOnly()) return DefaultAtomicContext.FLATTEN_READONLY; if (!atomic.canFail()) return DefaultAtomicContext.FLATTEN_READWRITE; if (atomic.speculativeReadOnly()) return DefaultAtomicContext.READ_ONLY; return DefaultAtomicContext.READ_WRITE; }
@Override @Atomic(readOnly = true) /** Note that this operation is only transactional if both lists are transactional. **/ public boolean equals(Object o) { return super.equals(o); }
@Atomic public void editPaymentMethod(PaymentMethod paymentMethod, String code, LocalizedString description, String paymentReferenceFormat) { paymentMethod.edit(code, description, paymentReferenceFormat == null ? "" : paymentReferenceFormat); }
@Override @Atomic(readOnly = true) public int hashCode() { int value = 0; for (E o : entries.get()) { if (o != null) { value += o.hashCode(); } } return value; }
@Override @Atomic(readOnly = true) public int hashCode() { return super.hashCode(); }
@Override @Atomic(readOnly = true) public int indexOf(Object o) { return super.indexOf(o); }
@Override @Atomic(readOnly = true) public int lastIndexOf(Object o) { return super.lastIndexOf(o); }
@Atomic public void setDefaultPaymentMethods(PaymentMethod defaultCashPaymentMethod, PaymentMethod defaultSibsPaymentMethod, PaymentMethod defaultRefundPaymentMethod) { PaymentMethod.setDefaultPaymentMethods(defaultCashPaymentMethod, defaultSibsPaymentMethod, defaultRefundPaymentMethod); }
@Override @Atomic public boolean removeAll(Collection<?> c) { return super.removeAll(c); }
@Override @Atomic(speculativeReadOnly = false) protected void removeRange(int fromIndex, int toIndex) { super.removeRange(fromIndex, toIndex); }
@Override @Atomic public boolean retainAll(Collection<?> c) { return super.retainAll(c); }
@Override @Atomic(readOnly = true) public String toString() { return super.toString(); }
@Atomic public void deletePaymentMethod(PaymentMethod paymentMethod) { paymentMethod.delete(); }
@Atomic public PaymentMethod createPaymentMethod(String code, LocalizedString description, String paymentReferenceFormat) { return PaymentMethod.create(code, description, paymentReferenceFormat == null ? "" : paymentReferenceFormat); }
@Override @Atomic(readOnly = true) public E getLast() { if (isEmpty()) { throw new NoSuchElementException(); } return peekLast(); }
@Override @Atomic(readOnly = true) public E getFirst() { if (isEmpty()) { throw new NoSuchElementException(); } return peekFirst(); }
@Override @Atomic(speculativeReadOnly = false) public E removeLast() { try { return remove(size() - 1); } catch (IndexOutOfBoundsException e) { throw new NoSuchElementException(); } }
@Override @Atomic(speculativeReadOnly = false) public boolean addAll(int index, Collection<? extends E> c) { int size = size(); if (index > size) { throw new IndexOutOfBoundsException(); } ensureCapacity(size + c.size()); return super.addAll(index, c); }
@Override @Atomic(readOnly = true) public Object[] toArray() { return toArray(new Object[size()]); }