Packages

object Slick

Source
Slick.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Slick
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. def flow[T](session: SlickSession, parallelism: Int, toStatement: Function2[T, Connection, PreparedStatement]): Flow[T, Integer, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  2. def flow[T](session: SlickSession, parallelism: Int, toStatement: Function[T, String]): Flow[T, Integer, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  3. def flow[T](session: SlickSession, toStatement: Function2[T, Connection, PreparedStatement]): Flow[T, Integer, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  4. def flow[T](session: SlickSession, toStatement: Function[T, String]): Flow[T, Integer, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  5. def flowWithPassThrough[T, R](session: SlickSession, executionContext: ExecutionContext, parallelism: Int, toStatement: Function2[T, Connection, PreparedStatement], mapper: Function2[T, Integer, R]): Flow[T, R, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    session

    The database session to use.

    executionContext

    ExecutionContext used to run mapper function in. E.g. the dispatcher of the ActorSystem.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

    mapper

    A function to create a result from the incoming element T and the database statement result.

  6. def flowWithPassThrough[T, R](session: SlickSession, executionContext: ExecutionContext, parallelism: Int, toStatement: Function[T, String], mapper: BiFunction[T, Integer, R]): Flow[T, R, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    session

    The database session to use.

    executionContext

    ExecutionContext used to run mapper function in. E.g. the dispatcher of the ActorSystem.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

    mapper

    A function to create a result from the incoming element T and the database statement result.

  7. def flowWithPassThrough[T, R](session: SlickSession, executionContext: ExecutionContext, toStatement: Function2[T, Connection, PreparedStatement], mapper: Function2[T, Integer, R]): Flow[T, R, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    session

    The database session to use.

    executionContext

    ExecutionContext used to run mapper function in. E.g. the dispatcher of the ActorSystem.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

    mapper

    A function to create a result from the incoming element T and the database statement result.

  8. def flowWithPassThrough[T, R](session: SlickSession, executionContext: ExecutionContext, toStatement: Function[T, String], mapper: BiFunction[T, Integer, R]): Flow[T, R, NotUsed]

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    Java API: creates a Flow that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, then executes those statements against the specified Slick database and allows to combine the statement result and element into a result type R.

    session

    The database session to use.

    executionContext

    ExecutionContext used to run mapper function in. E.g. the dispatcher of the ActorSystem.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

    mapper

    A function to create a result from the incoming element T and the database statement result.

  9. def sink(session: SlickSession, parallelism: Int): Sink[String, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of complete SQL statements (e.g.

    Java API: creates a Sink that takes a stream of complete SQL statements (e.g. a stream of Strings) to execute against the specified Slick database.

    session

    The database session to use.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

  10. def sink(session: SlickSession): Sink[String, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of complete SQL statements (e.g.

    Java API: creates a Sink that takes a stream of complete SQL statements (e.g. a stream of Strings) to execute against the specified Slick database.

    session

    The database session to use.

  11. def sink[T](session: SlickSession, parallelism: Int, toStatement: Function2[T, Connection, PreparedStatement]): Sink[T, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  12. def sink[T](session: SlickSession, parallelism: Int, toStatement: Function[T, String]): Sink[T, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    parallelism

    How many parallel asynchronous streams should be used to send statements to the database. Use a value of 1 for sequential execution.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  13. def sink[T](session: SlickSession, toStatement: Function2[T, Connection, PreparedStatement]): Sink[T, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  14. def sink[T](session: SlickSession, toStatement: Function[T, String]): Sink[T, CompletionStage[Done]]

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    Java API: creates a Sink that takes a stream of elements of type T, transforms each element to a SQL statement using the specified function, and then executes those statements against the specified Slick database.

    session

    The database session to use.

    toStatement

    A function that creates the SQL statement to execute from the current element. Any DML or DDL statement is acceptable.

  15. def source[T](session: SlickSession, query: String, mapper: Function[SlickRow, T]): Source[T, NotUsed]

    Java API: creates a Source that performs the specified query against the specified Slick database and streams the results through the specified mapper function to turn database each row element into an instance of T.

    Java API: creates a Source that performs the specified query against the specified Slick database and streams the results through the specified mapper function to turn database each row element into an instance of T.

    session

    The database session to use.

    query

    The query string to execute. There is currently no Java DSL support for parameter substitution so you will have to build the full query statement before passing it in.

    mapper

    A function that takes an individual result row and transforms it to an instance of T.