Show / Hide Table of Contents

    Class Transaction

    Provides a scope to safely read and write to a Realm. Must use explicitly via BeginWrite().

    Inheritance
    Object
    Transaction
    Implements
    IDisposable
    Namespace: Realms
    Assembly: Realm.dll
    Syntax
    public class Transaction : IDisposable
    Remarks

    All access to a Realm occurs within a Transaction. Read transactions are created implicitly.

    Methods

    | Improve this Doc View Source

    Commit()

    Use to save the changes to the realm. If Transaction is declared in a using block, must be used before the end of that block.

    Declaration
    public void Commit()
    | Improve this Doc View Source

    Dispose()

    Will automatically Rollback() the transaction on existing scope, if not explicitly Committed.

    Declaration
    public void Dispose()
    | Improve this Doc View Source

    Rollback()

    Use explicitly to undo the changes in a Transaction, otherwise it is automatically invoked by exiting the block.

    Declaration
    public void Rollback()

    Implements

    System.IDisposable
    • Improve this Doc
    • View Source
    Back to top Copyright © 2019 Realm
    Generated by DocFX