Class

io.scalajs.npm.mysql

ConnectionOptions

Related Doc: package mysql

Permalink

class ConnectionOptions extends Object

MySQL Connection Options

Annotations
@RawJSType() @ScalaJSDefined()
Linear Supertypes
Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ConnectionOptions
  2. Object
  3. Any
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ConnectionOptions(host: UndefOr[String] = js.undefined, port: UndefOr[Int] = js.undefined, localAddress: UndefOr[String] = js.undefined, socketPath: UndefOr[String] = js.undefined, user: UndefOr[String] = js.undefined, password: UndefOr[String] = js.undefined, database: UndefOr[String] = js.undefined, charset: UndefOr[String] = js.undefined, timezone: UndefOr[String] = js.undefined, connectTimeout: UndefOr[Boolean] = js.undefined, stringifyObjects: UndefOr[Boolean] = js.undefined, insecureAuth: UndefOr[Boolean] = js.undefined, typeCast: UndefOr[Boolean] = js.undefined, queryFormat: UndefOr[String] = js.undefined, supportBigNumbers: UndefOr[Boolean] = js.undefined, bigNumberStrings: UndefOr[Boolean] = js.undefined, dateStrings: UndefOr[String] = js.undefined, debug: UndefOr[Boolean] = js.undefined, trace: UndefOr[Boolean] = js.undefined, multipleStatements: UndefOr[Boolean] = js.undefined, flags: UndefOr[String] = js.undefined, ssl: UndefOr[SSLOptions] = js.undefined)

    Permalink

    host

    The hostname of the database you are connecting to. (Default: localhost)

    port

    The port number to connect to. (Default: 3306)

    localAddress

    The source IP address to use for TCP connection. (Optional)

    socketPath

    The path to a unix domain socket to connect to. When used host and port are ignored.

    user

    The MySQL user to authenticate as.

    password

    The password of that MySQL user.

    database

    Name of the database to use for this connection (Optional).

    charset

    The charset for the connection. This is called "collation" in the SQL-level of MySQL (like utf8_general_ci). If a SQL-level charset is specified (like utf8mb4) then the default collation for that charset is used. (Default: 'UTF8_GENERAL_CI')

    timezone

    The timezone used to store local dates. (Default: 'local')

    connectTimeout

    The milliseconds before a timeout occurs during the initial connection to the MySQL server. (Default: 10000)

    stringifyObjects

    Stringify objects instead of converting to values. See issue #501. (Default: 'false')

    insecureAuth

    Allow connecting to MySQL instances that ask for the old (insecure) authentication method. (Default: false)

    typeCast

    Determines if column values should be converted to native JavaScript types. (Default: true)

    queryFormat

    A custom query format function. See Custom format.

    supportBigNumbers

    When dealing with big numbers (BIGINT and DECIMAL columns) in the database, you should enable this option (Default: false).

    bigNumberStrings

    Enabling both supportBigNumbers and bigNumberStrings forces big numbers (BIGINT and DECIMAL columns) to be always returned as JavaScript String objects (Default: false). Enabling supportBigNumbers but leaving bigNumberStrings disabled will return big numbers as String objects only when they cannot be accurately represented with [JavaScript Number objects] (http://ecma262-5.com/ELS5_HTML.htm#Section_8.5) (which happens when they exceed the [-253, +253] range), otherwise they will be returned as Number objects. This option is ignored if supportBigNumbers is disabled.

    dateStrings

    Force date types (TIMESTAMP, DATETIME, DATE) to be returned as strings rather then inflated into JavaScript Date objects. (Default: false)

    debug

    Prints protocol details to stdout. (Default: false)

    trace

    Generates stack traces on Error to include call site of library entrance ("long stack traces"). Slight performance penalty for most calls. (Default: true)

    multipleStatements

    Allow multiple mysql statements per query. Be careful with this, it could increase the scope of SQL injection attacks. (Default: false)

    flags

    List of connection flags to use other than the default ones. It is also possible to blacklist default ones. For more information, check Connection Flags.

    ssl

    object with ssl parameters or a string containing name of ssl profile. See SSL options.

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. var bigNumberStrings: UndefOr[Boolean]

    Permalink

    Enabling both supportBigNumbers and bigNumberStrings forces big numbers (BIGINT and DECIMAL columns) to be always returned as JavaScript String objects (Default: false).

    Enabling both supportBigNumbers and bigNumberStrings forces big numbers (BIGINT and DECIMAL columns) to be always returned as JavaScript String objects (Default: false). Enabling supportBigNumbers but leaving bigNumberStrings disabled will return big numbers as String objects only when they cannot be accurately represented with [JavaScript Number objects] (http://ecma262-5.com/ELS5_HTML.htm#Section_8.5) (which happens when they exceed the [-253, +253] range), otherwise they will be returned as Number objects. This option is ignored if supportBigNumbers is disabled.

  6. var charset: UndefOr[String]

    Permalink

    The charset for the connection.

    The charset for the connection. This is called "collation" in the SQL-level of MySQL (like utf8_general_ci). If a SQL-level charset is specified (like utf8mb4) then the default collation for that charset is used. (Default: 'UTF8_GENERAL_CI')

  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. var connectTimeout: UndefOr[Boolean]

    Permalink

    The milliseconds before a timeout occurs during the initial connection to the MySQL server.

    The milliseconds before a timeout occurs during the initial connection to the MySQL server. (Default: 10000)

  9. var database: UndefOr[String]

    Permalink

    Name of the database to use for this connection (Optional).

  10. var dateStrings: UndefOr[String]

    Permalink

    Force date types (TIMESTAMP, DATETIME, DATE) to be returned as strings rather then inflated into JavaScript Date objects.

    Force date types (TIMESTAMP, DATETIME, DATE) to be returned as strings rather then inflated into JavaScript Date objects. (Default: false)

  11. var debug: UndefOr[Boolean]

    Permalink

    Prints protocol details to stdout.

    Prints protocol details to stdout. (Default: false)

  12. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. var flags: UndefOr[String]

    Permalink

    List of connection flags to use other than the default ones.

    List of connection flags to use other than the default ones. It is also possible to blacklist default ones. For more information, check Connection Flags.

  16. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  17. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  18. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  19. var host: UndefOr[String]

    Permalink

    The hostname of the database you are connecting to.

    The hostname of the database you are connecting to. (Default: localhost)

  20. var insecureAuth: UndefOr[Boolean]

    Permalink

    Allow connecting to MySQL instances that ask for the old (insecure) authentication method.

    Allow connecting to MySQL instances that ask for the old (insecure) authentication method. (Default: false)

  21. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  22. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  23. var localAddress: UndefOr[String]

    Permalink

    The source IP address to use for TCP connection.

    The source IP address to use for TCP connection. (Optional)

  24. var multipleStatements: UndefOr[Boolean]

    Permalink

    Allow multiple mysql statements per query.

    Allow multiple mysql statements per query. Be careful with this, it could increase the scope of SQL injection attacks. (Default: false)

  25. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  26. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  27. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  28. var password: UndefOr[String]

    Permalink

    The password of that MySQL user.

  29. var port: UndefOr[Int]

    Permalink

    The port number to connect to.

    The port number to connect to. (Default: 3306)

  30. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  31. var queryFormat: UndefOr[String]

    Permalink

    A custom query format function.

    A custom query format function. See Custom format.

  32. var socketPath: UndefOr[String]

    Permalink

    The path to a unix domain socket to connect to.

    The path to a unix domain socket to connect to. When used host and port are ignored.

  33. var ssl: UndefOr[SSLOptions]

    Permalink

    object with ssl parameters or a string containing name of ssl profile.

    object with ssl parameters or a string containing name of ssl profile. See SSL options.

  34. var stringifyObjects: UndefOr[Boolean]

    Permalink

    Stringify objects instead of converting to values.

    Stringify objects instead of converting to values. See issue #501. (Default: 'false')

  35. var supportBigNumbers: UndefOr[Boolean]

    Permalink

    When dealing with big numbers (BIGINT and DECIMAL columns) in the database, you should enable this option (Default: false).

  36. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  37. var timezone: UndefOr[String]

    Permalink

    The timezone used to store local dates.

    The timezone used to store local dates. (Default: 'local')

  38. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  39. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  40. var trace: UndefOr[Boolean]

    Permalink

    Generates stack traces on Error to include call site of library entrance ("long stack traces").

    Generates stack traces on Error to include call site of library entrance ("long stack traces"). Slight performance penalty for most calls. (Default: true)

  41. var typeCast: UndefOr[Boolean]

    Permalink

    Determines if column values should be converted to native JavaScript types.

    Determines if column values should be converted to native JavaScript types. (Default: true)

  42. var user: UndefOr[String]

    Permalink

    The MySQL user to authenticate as.

  43. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  44. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  45. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  46. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped