case class OptIn(configStyleArguments: Boolean = true, breaksInsideChains: Boolean = false, breakChainOnFirstMethodDot: Boolean = true, selfAnnotationNewline: Boolean = true, annotationNewlines: Boolean = true, blankLineBeforeDocstring: Boolean = false) extends Product with Serializable

configStyleArguments

Call-sites where there is a newline after opening ( and newline before closing ). If true, preserves the newlines and keeps one line per argument.

breaksInsideChains

If true, then the user can opt out of line breaks inside select chains.

// original
foo
  .map(_ + 1).map(_ + 1)
  .filter(_ > 2)
// if true
foo
  .map(_ + 1).map(_ + 1)
  .filter(_ > 2)
// if false
foo
  .map(_ + 1)
  .map(_ + 1)
  .filter(_ > 2)
breakChainOnFirstMethodDot

If true, keeps the line break before a dot if it already exists.

// original
foo
  .map(_ + 1)
  .filter( > 2)
// if true
foo
  .map(_ + 1)
  .filter( > 2)
// if false
foo.map(_ + 1).filter( > 2)
selfAnnotationNewline

See https://github.com/scalameta/scalafmt/issues/938 If true, will force a line break before a self annotation if there was a line break there before.

blankLineBeforeDocstring

If false, always insert a blank line before docstrings, If true, preserves blank line only if one exists before. Example:

// before
object Foo {
  /** Docstring */
  def foo = 2
}
// after, if blankLineBeforeDocstring=true
object Foo {
  /** Docstring */
  def foo = 2
}
// after, if blankLineBeforeDocstring=false
object Foo {

  /** Docstring */
  def foo = 2
}
Linear Supertypes
Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. OptIn
  2. Serializable
  3. Product
  4. Equals
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new OptIn(configStyleArguments: Boolean = true, breaksInsideChains: Boolean = false, breakChainOnFirstMethodDot: Boolean = true, selfAnnotationNewline: Boolean = true, annotationNewlines: Boolean = true, blankLineBeforeDocstring: Boolean = false)

    configStyleArguments

    Call-sites where there is a newline after opening ( and newline before closing ). If true, preserves the newlines and keeps one line per argument.

    breaksInsideChains

    If true, then the user can opt out of line breaks inside select chains.

    // original
    foo
      .map(_ + 1).map(_ + 1)
      .filter(_ > 2)
    // if true
    foo
      .map(_ + 1).map(_ + 1)
      .filter(_ > 2)
    // if false
    foo
      .map(_ + 1)
      .map(_ + 1)
      .filter(_ > 2)
    breakChainOnFirstMethodDot

    If true, keeps the line break before a dot if it already exists.

    // original
    foo
      .map(_ + 1)
      .filter( > 2)
    // if true
    foo
      .map(_ + 1)
      .filter( > 2)
    // if false
    foo.map(_ + 1).filter( > 2)
    selfAnnotationNewline

    See https://github.com/scalameta/scalafmt/issues/938 If true, will force a line break before a self annotation if there was a line break there before.

    blankLineBeforeDocstring

    If false, always insert a blank line before docstrings, If true, preserves blank line only if one exists before. Example:

    // before
    object Foo {
      /** Docstring */
      def foo = 2
    }
    // after, if blankLineBeforeDocstring=true
    object Foo {
      /** Docstring */
      def foo = 2
    }
    // after, if blankLineBeforeDocstring=false
    object Foo {
    
      /** Docstring */
      def foo = 2
    }

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. val annotationNewlines: Boolean
  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. val blankLineBeforeDocstring: Boolean
  7. val breakChainOnFirstMethodDot: Boolean
  8. val breaksInsideChains: Boolean
  9. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  10. val configStyleArguments: Boolean
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  13. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  14. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  15. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  17. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  18. def productElementNames: Iterator[String]
    Definition Classes
    Product
  19. implicit val reader: ConfDecoder[OptIn]
  20. val selfAnnotationNewline: Boolean
  21. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  22. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  23. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  24. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped