PostgresJAsyncContext

class PostgresJAsyncContext[N <: NamingStrategy](naming: N, pool: ConnectionPool[PostgreSQLConnection]) extends JAsyncContext[PostgresDialect, N, PostgreSQLConnection] with PostgresJAsyncContextBase[N]
trait UUIDObjectEncoding
trait ArrayEncoding
class JAsyncContext[PostgresDialect, N, PostgreSQLConnection]
trait JAsyncContextBase[PostgresDialect, N]
trait Encoders
trait Decoders
trait SqlContext[PostgresDialect, N]
trait ContextVerbTranslate[PostgresDialect, N]
trait ContextTranslateMacro[PostgresDialect, N]
trait ContextTranslateProto[PostgresDialect, N]
trait Context[PostgresDialect, N]
trait Closeable
trait AutoCloseable
trait EncodingDsl
trait LowPriorityImplicits
trait ProtoContextSecundus[PostgresDialect, N]
trait RowContext
class Object
trait Matchable
class Any

Type members

Inherited classlikes

case class AsyncDecoder[T](sqlType: DecoderSqlType)(implicit decoder: BaseDecoder[T]) extends BaseDecoder[T]
Inherited from:
Decoders
case class AsyncEncoder[T](sqlType: DecoderSqlType)(implicit encoder: BaseEncoder[T]) extends BaseEncoder[T]
Inherited from:
Encoders
case class BatchGroup(string: String, prepare: List[Prepare])
Inherited from:
RowContext
case class BatchGroupReturning(string: String, returningBehavior: ReturnAction, prepare: List[Prepare])
Inherited from:
RowContext
Inherited from:
Context
class JasyncNullChecker extends BaseNullChecker
Inherited from:
JAsyncContext
trait NumericDecoder[T] extends BaseDecoder[T]
Inherited from:
Decoders

Inherited types

type BaseDecoder[T] = GenericDecoder[ResultRow, Session, T, Specific]
Inherited from:
EncodingDsl
type BaseEncoder[T] = GenericEncoder[T, PrepareRow, Session]
Inherited from:
EncodingDsl
type BaseNullChecker = GenericNullChecker[ResultRow, Session]
Inherited from:
EncodingDsl
type CBF[T, Col] = Factory[T, Col]
Inherited from:
ArrayEncoding
type ColumnResolver = GenericColumnResolver[ResultRow]
Inherited from:
EncodingDsl
type Decoder[T] = AsyncDecoder[T]
Inherited from:
Decoders
type DecoderMethod[T] = (Int, ResultRow, Session) => T
Inherited from:
EncodingDsl
type DecoderSqlType = SqlTypes
Inherited from:
Decoders
type Encoder[T] = AsyncEncoder[T]
Inherited from:
Encoders
type EncoderMethod[T] = (Int, T, PrepareRow, Session) => PrepareRow
Inherited from:
EncodingDsl
type EncoderSqlType = SqlTypes
Inherited from:
Encoders
type Extractor[T] = (ResultRow, Session) => T
Inherited from:
RowContext
type Index = Int
Inherited from:
Decoders
Inherited from:
JAsyncContext
type Prepare = (PrepareRow, Session) => (List[Any], PrepareRow)
Inherited from:
RowContext
override type PrepareRow = Seq[Any]
Inherited from:
JAsyncContextBase
override type Result[T] = Future[T]
Inherited from:
JAsyncContext
override type ResultRow = RowData
Inherited from:
JAsyncContextBase
type RowTyper[T] = GenericRowTyper[ResultRow, T]
Inherited from:
EncodingDsl
override type RunActionResult = Long
Inherited from:
JAsyncContext
override type RunActionReturningResult[T] = T
Inherited from:
JAsyncContext
override type RunBatchActionResult = Seq[Long]
Inherited from:
JAsyncContext
override type RunBatchActionReturningResult[T] = Seq[T]
Inherited from:
JAsyncContext
override type RunQueryResult[T] = Seq[T]
Inherited from:
JAsyncContext
override type RunQuerySingleResult[T] = T
Inherited from:
JAsyncContext
override type Runner = ExecutionContext
Inherited from:
JAsyncContextBase
override type RunnerBehavior = Implicit
Inherited from:
JAsyncContextBase
override type Session = Unit
Inherited from:
JAsyncContextBase
override type TranslateResult[T] = T
Inherited from:
ContextVerbTranslate
Inherited from:
ContextTranslateMacro

Value members

Constructors

def this(naming: N, config: PostgresJAsyncContextConfig)
def this(naming: N, config: Config)
def this(naming: N, configPrefix: String)

Concrete methods

override protected def expandAction(sql: String, returningAction: ReturnAction): String
Definition Classes
JAsyncContext
override protected def extractActionResult[O](returningAction: ReturnAction, returningExtractor: () => O)(result: QueryResult): List[O]
Definition Classes
JAsyncContext
@targetName("runQueryDefault")
inline def run[T](inline quoted: Quoted[Query[T]]): Future[Seq[T]]
@targetName("runQuery")
inline def run[T](inline quoted: Quoted[Query[T]], inline wrap: OuterSelectWrap): Future[Seq[T]]
@targetName("runQuerySingle")
inline def run[T](inline quoted: Quoted[T]): Future[T]
@targetName("runAction")
inline def run[E](inline quoted: Quoted[Action[E]]): Future[Long]
@targetName("runActionReturning")
inline def run[E, T](inline quoted: Quoted[ActionReturning[E, T]]): Future[T]
@targetName("runActionReturningMany")
inline def run[E, T](inline quoted: Quoted[ActionReturning[E, List[T]]]): Future[List[T]]
@targetName("runBatchAction")
inline def run[I, A <: Action[I] & QAC[I, Nothing]](inline quoted: Quoted[BatchAction[A]]): Future[Seq[Long]]
@targetName("runBatchActionReturning")
inline def run[I, T, A <: Action[I] & QAC[I, T]](inline quoted: Quoted[BatchAction[A]]): Future[Seq[T]]

Inherited methods

inline def _summonTranslateRunner(): TranslateRunner

Internal API that cannot be made private due to how inline functions

Internal API that cannot be made private due to how inline functions

Inherited from:
ContextTranslateMacro
def arrayDecoder[I, O, Col <: Seq[O]](mapper: I => O)(implicit bf: Factory[O, Col], iTag: ClassTag[I], oTag: ClassTag[O]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
def arrayEncoder[T, Col <: Seq[T]](mapper: T => Any): AsyncEncoder[Col]
Inherited from:
ArrayEncoders
def arrayRawDecoder[T : ClassTag, Col <: Seq[T]](implicit evidence$1: ClassTag[T], bf: Factory[T, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
def arrayRawEncoder[T, Col <: Seq[T]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
override def close: Unit
Definition Classes
JAsyncContext -> Context -> Closeable -> AutoCloseable
Inherited from:
JAsyncContext
override def context: Runner
Definition Classes
JAsyncContext -> Context
Inherited from:
JAsyncContext
def decoder[T : ClassTag](f: PartialFunction[Any, T], sqlType: DecoderSqlType): AsyncDecoder[T]
Inherited from:
Decoders
def encoder[T](f: T => Any, sqlType: DecoderSqlType): AsyncEncoder[T]
Inherited from:
Encoders
def encoder[T](sqlType: DecoderSqlType): AsyncEncoder[T]
Inherited from:
Encoders
def executeAction(sql: String, prepare: Prepare)(executionInfo: ExecutionInfo, dc: ExecutionContext): Future[Long]
Inherited from:
JAsyncContext
def executeActionReturning[T](sql: String, prepare: Prepare, extractor: () => T, returningAction: ReturnAction)(info: ExecutionInfo, dc: Runner): Future[T]
Inherited from:
JAsyncContext
def executeActionReturningMany[T](sql: String, prepare: Prepare, extractor: () => T, returningAction: ReturnAction)(info: ExecutionInfo, dc: Runner): Future[List[T]]
Inherited from:
JAsyncContext
def executeBatchAction(groups: List[BatchGroup])(executionInfo: ExecutionInfo, dc: ExecutionContext): Future[List[Long]]
Inherited from:
JAsyncContext
def executeBatchActionReturning[T](groups: List[BatchGroupReturning], extractor: () => T)(executionInfo: ExecutionInfo, dc: ExecutionContext): Future[List[T]]
Inherited from:
JAsyncContext
def executeQuery[T](sql: String, prepare: Prepare, extractor: () => T)(executionInfo: ExecutionInfo, dc: ExecutionContext): Future[List[T]]
Inherited from:
JAsyncContext
def executeQuerySingle[T](sql: String, prepare: Prepare, extractor: () => T)(executionInfo: ExecutionInfo, dc: ExecutionContext): Future[T]
Inherited from:
JAsyncContext
protected def handleSingleResult[T](sql: String, list: List[T]): T
Inherited from:
Context
inline def lift[T](inline runtimeValue: T): T
Inherited from:
Context
inline def liftQuery[U <: (Iterable), T](inline runtimeValue: U[T]): Query[T]
Inherited from:
Context
protected def mappedBaseDecoder[Base, Mapped](mapped: MappedEncoding[Base, Mapped], decoder: () => Base): () => Mapped
Inherited from:
EncodingDsl
protected def mappedBaseEncoder[Mapped, Base](mapped: MappedEncoding[Mapped, Base], encoder: () => Base): () => Mapped
Inherited from:
EncodingDsl
@tailrec
final protected def prepareParam(param: Any): String
Inherited from:
ContextTranslateProto
def probe(sql: String): Try[QueryResult]
Inherited from:
JAsyncContext
override def push[A, B](result: A)(f: A => B): B
Definition Classes
ContextVerbTranslate -> ContextTranslateProto
Inherited from:
ContextVerbTranslate
override def seq[A](list: List[A]): List[A]
Definition Classes
ContextVerbTranslate -> ContextTranslateProto
Inherited from:
ContextVerbTranslate
def transaction[T](f: TransactionalExecutionContext => Future[T])(implicit ec: ExecutionContext): CompletableFuture[T]
Inherited from:
JAsyncContext
@targetName("translateBatchActionReturning")
inline def translate[I, T, A <: Action[I] & QAC[I, T]](inline quoted: Quoted[BatchAction[A]], inline prettyPrint: Boolean): TranslateResult[List[String]]
Inherited from:
ContextTranslateMacro
@targetName("translateBatchActionReturning")
inline def translate[I, T, A <: Action[I] & QAC[I, T]](inline quoted: Quoted[BatchAction[A]]): TranslateResult[List[String]]
Inherited from:
ContextTranslateMacro
@targetName("translateBatchAction")
inline def translate[I, A <: Action[I] & QAC[I, Nothing]](inline quoted: Quoted[BatchAction[A]], inline prettyPrint: Boolean): TranslateResult[List[String]]
Inherited from:
ContextTranslateMacro
@targetName("translateBatchAction")
inline def translate[I, A <: Action[I] & QAC[I, Nothing]](inline quoted: Quoted[BatchAction[A]]): TranslateResult[List[String]]
Inherited from:
ContextTranslateMacro
@targetName("translateActionReturning")
inline def translate[E, T](inline quoted: Quoted[ActionReturning[E, T]], inline prettyPrint: Boolean): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateActionReturning")
inline def translate[E, T](inline quoted: Quoted[ActionReturning[E, T]]): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateAction")
inline def translate[E](inline quoted: Quoted[Action[E]], inline prettyPrint: Boolean): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateAction")
inline def translate[E](inline quoted: Quoted[Action[E]]): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateQuerySingle")
inline def translate[T](inline quoted: Quoted[T], inline prettyPrint: Boolean): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateQuerySingle")
inline def translate[T](inline quoted: Quoted[T]): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateQuery")
inline def translate[T](inline quoted: Quoted[Query[T]], inline prettyPrint: Boolean): TranslateResult[String]
Inherited from:
ContextTranslateMacro
@targetName("translateQuery")
inline def translate[T](inline quoted: Quoted[Query[T]]): TranslateResult[String]
Inherited from:
ContextTranslateMacro
def translateBatchQueryEndpoint(groups: List[BatchGroup], prettyPrint: Boolean)(executionInfo: ExecutionInfo, dc: TranslateRunner): TranslateResult[List[String]]
Inherited from:
ContextTranslateProto
def translateBatchQueryReturningEndpoint(groups: List[BatchGroupReturning], prettyPrint: Boolean)(executionInfo: ExecutionInfo, dc: TranslateRunner): TranslateResult[List[String]]
Inherited from:
ContextTranslateProto
override def translateContext: TranslateRunner
Definition Classes
JAsyncContext -> ContextTranslateMacro
Inherited from:
JAsyncContext
def translateQueryEndpoint[T](statement: String, prepare: Prepare, extractor: () => T, prettyPrint: Boolean)(executionInfo: ExecutionInfo, dc: TranslateRunner): TranslateResult[String]
Inherited from:
ContextTranslateProto
protected def withConnection[T](f: Connection => Future[T])(implicit ec: ExecutionContext): Future[T]
Inherited from:
JAsyncContext
override def wrap[T](t: => T): T
Definition Classes
ContextVerbTranslate -> ContextTranslateProto
Inherited from:
ContextVerbTranslate

Inherited fields

val dateTimeZone: ZoneId
Inherited from:
JAsyncContextBase
protected val identityExtractor: (ResultRow, Session) => ResultRow
Inherited from:
RowContext
protected val identityPrepare: Prepare
Inherited from:
RowContext
val idiom: PostgresDialect
Inherited from:
JAsyncContext

Extensions

Inherited extensions

extension [T](q: Query[T])
inline def filterByKeys(inline map: Map[String, String]): Query[T]

When using this with FilterColumns make sure it comes FIRST. Otherwise the columns are you filtering may have been nullified in the SQL before the filteration has actually happened.

When using this with FilterColumns make sure it comes FIRST. Otherwise the columns are you filtering may have been nullified in the SQL before the filteration has actually happened.

Inherited from:
Context
inline def filterColumns(inline columns: List[String]): Query[T]
Inherited from:
Context

Implicits

Inherited implicits

implicit inline def anyValDecoder[Cls <: AnyVal]: AsyncDecoder[Cls]
Inherited from:
LowPriorityImplicits
implicit inline def anyValEncoder[Cls <: AnyVal]: AsyncEncoder[Cls]
Inherited from:
LowPriorityImplicits
implicit def arrayBigDecimalDecoder[Col <: Seq[BigDecimal]](implicit bf: Factory[BigDecimal, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayBigDecimalEncoder[Col <: Seq[BigDecimal]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayBooleanDecoder[Col <: Seq[Boolean]](implicit bf: Factory[Boolean, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayBooleanEncoder[Col <: Seq[Boolean]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayByteDecoder[Col <: Seq[Byte]](implicit bf: Factory[Byte, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayByteEncoder[Col <: Seq[Byte]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayDateDecoder[Col <: Seq[Date]](implicit bf: Factory[Date, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayDateEncoder[Col <: Seq[Date]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayDoubleDecoder[Col <: Seq[Double]](implicit bf: Factory[Double, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayDoubleEncoder[Col <: Seq[Double]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayFloatDecoder[Col <: Seq[Float]](implicit bf: Factory[Float, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayFloatEncoder[Col <: Seq[Float]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayIntDecoder[Col <: Seq[Index]](implicit bf: Factory[Index, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayIntEncoder[Col <: Seq[Index]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayLocalDateDecoder[Col <: Seq[LocalDate]](implicit bf: Factory[LocalDate, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayLocalDateEncoder[Col <: Seq[LocalDate]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayLocalDateTimeDecoder[Col <: Seq[LocalDateTime]](implicit bf: Factory[LocalDateTime, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayLocalDateTimeEncoder[Col <: Seq[LocalDateTime]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayLongDecoder[Col <: Seq[Long]](implicit bf: Factory[Long, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayLongEncoder[Col <: Seq[Long]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayMappedDecoder[I, O, Col <: (Seq)](implicit mapped: MappedEncoding[I, O], d: AsyncDecoder[Seq[I]], bf: Factory[O, Col[O]]): AsyncDecoder[Col[O]]
Inherited from:
ArrayEncoding
implicit def arrayMappedEncoder[I, O, Col <: (Seq)](implicit mapped: MappedEncoding[I, O], e: AsyncEncoder[Seq[O]]): AsyncEncoder[Col[I]]
Inherited from:
ArrayEncoding
implicit def arrayShortDecoder[Col <: Seq[Short]](implicit bf: Factory[Short, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayShortEncoder[Col <: Seq[Short]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit def arrayStringDecoder[Col <: Seq[String]](implicit bf: Factory[String, Col]): AsyncDecoder[Col]
Inherited from:
ArrayDecoders
implicit def arrayStringEncoder[Col <: Seq[String]]: AsyncEncoder[Col]
Inherited from:
ArrayEncoders
implicit val bigDecimalDecoder: AsyncDecoder[BigDecimal]
Inherited from:
Decoders
implicit val bigDecimalEncoder: AsyncEncoder[BigDecimal]
Inherited from:
Encoders
implicit val booleanDecoder: AsyncDecoder[Boolean]
Inherited from:
Decoders
implicit val booleanEncoder: AsyncEncoder[Boolean]
Inherited from:
Encoders
implicit val byteArrayDecoder: AsyncDecoder[Array[Byte]]
Inherited from:
Decoders
implicit val byteArrayEncoder: AsyncEncoder[Array[Byte]]
Inherited from:
Encoders
implicit val byteDecoder: AsyncDecoder[Byte]
Inherited from:
Decoders
implicit val byteEncoder: AsyncEncoder[Byte]
Inherited from:
Encoders
implicit val dateDecoder: AsyncDecoder[Date]
Inherited from:
Decoders
implicit val dateEncoder: AsyncEncoder[Date]
Inherited from:
Encoders
implicit inline def dec[T]: GenericDecoder[ResultRow, Session, T, Generic]
Inherited from:
Context
implicit val doubleDecoder: AsyncDecoder[Double]
Inherited from:
Decoders
implicit val doubleEncoder: AsyncEncoder[Double]
Inherited from:
Encoders
implicit val floatDecoder: AsyncDecoder[Float]
Inherited from:
Decoders
implicit val floatEncoder: AsyncEncoder[Float]
Inherited from:
Encoders
implicit val intDecoder: AsyncDecoder[Int]
Inherited from:
Decoders
implicit val intEncoder: AsyncEncoder[Int]
Inherited from:
Encoders
implicit val localDateDecoder: AsyncDecoder[LocalDate]
Inherited from:
Decoders
implicit val localDateEncoder: AsyncEncoder[LocalDate]
Inherited from:
Encoders
implicit val localDateTimeDecoder: AsyncDecoder[LocalDateTime]
Inherited from:
Decoders
implicit val localDateTimeEncoder: AsyncEncoder[LocalDateTime]
Inherited from:
Encoders
implicit val longDecoder: AsyncDecoder[Long]
Inherited from:
Decoders
implicit val longEncoder: AsyncEncoder[Long]
Inherited from:
Encoders
implicit def mappedDecoder[I, O](implicit mapped: MappedEncoding[I, O], decoder: AsyncDecoder[I]): AsyncDecoder[O]
Inherited from:
Decoders
implicit def mappedEncoder[I, O](implicit mapped: MappedEncoding[I, O], e: AsyncEncoder[O]): AsyncEncoder[I]
Inherited from:
Encoders
implicit val nullChecker: NullChecker
Inherited from:
JAsyncContext
implicit def optionDecoder[T](implicit d: AsyncDecoder[T]): AsyncDecoder[Option[T]]
Inherited from:
Decoders
implicit def optionEncoder[T](implicit d: AsyncEncoder[T]): AsyncEncoder[Option[T]]
Inherited from:
Encoders
implicit val shortDecoder: AsyncDecoder[Short]
Inherited from:
Decoders
implicit val shortEncoder: AsyncEncoder[Short]
Inherited from:
Encoders
implicit val stringDecoder: AsyncDecoder[String]
Inherited from:
Decoders
implicit val stringEncoder: AsyncEncoder[String]
Inherited from:
Encoders
implicit def toCompletableFuture[T](f: Future[T]): CompletableFuture[T]
Inherited from:
JAsyncContext
implicit def toFuture[T](cf: CompletableFuture[T]): Future[T]
Inherited from:
JAsyncContext
implicit def toKotlinFunction[T, R](f: T => R): Function1[T, R]
Inherited from:
JAsyncContext
implicit val uuidDecoder: AsyncDecoder[UUID]
Inherited from:
UUIDObjectEncoding
implicit val uuidEncoder: AsyncEncoder[UUID]
Inherited from:
UUIDObjectEncoding
implicit val zonedDateTimeDecoder: AsyncDecoder[ZonedDateTime]
Inherited from:
Decoders
implicit val zonedDateTimeEncoder: AsyncEncoder[ZonedDateTime]
Inherited from:
Encoders