コード例 #1
0
    public override TransactionBase BeginTransaction(TransactionParameterBuffer tpb)
    {
        var transaction = new GdsTransaction(this);

        transaction.BeginTransaction(tpb);

        return(transaction);
    }
コード例 #2
0
    public override async ValueTask <TransactionBase> BeginTransactionAsync(TransactionParameterBuffer tpb, CancellationToken cancellationToken = default)
    {
        var transaction = new GdsTransaction(this);

        await transaction.BeginTransactionAsync(tpb, cancellationToken).ConfigureAwait(false);

        return(transaction);
    }
コード例 #3
0
    public GdsArray(DatabaseBase db, TransactionBase transaction, long handle, string tableName, string fieldName)
        : base(tableName, fieldName)
    {
        if (!(db is GdsDatabase))
        {
            throw new ArgumentException($"Specified argument is not of {nameof(GdsDatabase)} type.");
        }

        if (!(transaction is GdsTransaction))
        {
            throw new ArgumentException($"Specified argument is not of {nameof(GdsTransaction)} type.");
        }

        _database    = (GdsDatabase)db;
        _transaction = (GdsTransaction)transaction;
        _handle      = handle;
    }