Class RDFChangesExternalTxn

java.lang.Object
org.apache.jena.rdfpatch.changes.RDFChangesWrapper
org.apache.jena.rdfpatch.changes.RDFChangesExternalTxn
All Implemented Interfaces:
RDFChanges

public class RDFChangesExternalTxn extends RDFChangesWrapper
Wrapper for RDFChanges that ignores transaction begin/commit in the patch assuming the caller is handling that, for example, executing a batch of patches in a single transaction.

On abort, throws PatchTxnAbortException which is a PatchException. If used with batched transactions, the caller does not know whether some patches committed and then one had a TA record.

  • Constructor Details

    • RDFChangesExternalTxn

      public RDFChangesExternalTxn(RDFChanges other)
  • Method Details

    • txnDepth

      public int txnDepth()
    • txnCountBegin

      public int txnCountBegin()
    • txnCountCommit

      public int txnCountCommit()
    • txnBegin

      public void txnBegin()
      Description copied from interface: RDFChanges
      Indicator that a transaction begins, or becomes a write transaction.
      Specified by:
      txnBegin in interface RDFChanges
      Overrides:
      txnBegin in class RDFChangesWrapper
    • txnCommit

      public void txnCommit()
      Description copied from interface: RDFChanges
      Indicator that a transaction commits. If this throws an exception, the transaction will be aborted locally and not commit after all.
      Specified by:
      txnCommit in interface RDFChanges
      Overrides:
      txnCommit in class RDFChangesWrapper
    • txnAbort

      public void txnAbort()
      Description copied from interface: RDFChanges
      Indicator that a transaction aborts
      Specified by:
      txnAbort in interface RDFChanges
      Overrides:
      txnAbort in class RDFChangesWrapper
    • segment

      public void segment()
      Description copied from interface: RDFChanges
      Segment marker.

      A segment is a number of transactions; the grouping rationale is not defined by RDF Patch.

      It might be used to indicate a logical collection of change transactions in a long stream of transactions.

      There is no guarantee it will be used.

      Segments must contain complete transactions.
      Segments must not span start-finish pairs.

      Specified by:
      segment in interface RDFChanges
      Overrides:
      segment in class RDFChangesWrapper