abstract class DBX::Adapter::Base

Overview

Base adapter.

Direct Known Subclasses

Defined in:

adapter/adapter.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(db : DB::Database) #

[View source]

Class Method Detail

def self.builder_class : QueryBuilder.class #

Returns query builder class.


[View source]
def self.new_builder : QueryBuilder #

Returns a new query builder instance.


[View source]

Instance Method Detail

abstract def create!(query : DBX::Query, data : Hash | NamedTuple, as types, returning : DBX::QueryBuilder::OneOrMoreFieldsType = "*", pk_name : DBX::QueryBuilder::FieldType = :id, pk_type = ::Union(Int64, ::Nil)) #

Creates a new record and returns. See DBX::Query#create! for more details.


[View source]
def db : DB::Database #

[View source]
def new_builder : QueryBuilder #

Returns a new query builder instance.


[View source]