Packages

package v0

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. v0
  2. ScalafixSyntax
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. implicit class XtensionOptionPatch extends AnyRef
    Definition Classes
    ScalafixSyntax
  2. implicit class XtensionSeqPatch extends AnyRef
    Definition Classes
    ScalafixSyntax
  3. type CustomMessage[T] = config.CustomMessage[T]
    Definition Classes
    ScalafixSyntax
  4. final case class Database(documents: Seq[Document]) extends Product with Serializable
  5. final case class Denotation(flags: Long, name: String, signature: String, names: List[ResolvedName], tpe: scala.meta.internal.semanticdb.Signature) extends HasFlags with Product with Serializable
  6. final case class Document(input: Input, language: String, names: List[ResolvedName], messages: List[Message], symbols: List[ResolvedSymbol], synthetics: List[Synthetic]) extends Product with Serializable
  7. trait Flags extends AnyRef
  8. trait HasFlags extends AnyRef
  9. type LintCategory = lint.LintCategory
    Definition Classes
    ScalafixSyntax
  10. type LintMessage = lint.LintMessage
    Definition Classes
    ScalafixSyntax
  11. final case class Message(position: Position, severity: Severity, text: String) extends Product with Serializable
  12. type Patch = patch.Patch
    Definition Classes
    ScalafixSyntax
  13. final case class ResolvedName(position: Position, symbol: Symbol, isDefinition: Boolean) extends Product with Serializable
  14. final case class ResolvedSymbol(symbol: Symbol, denotation: Denotation) extends Product with Serializable
  15. abstract class Rule extends AnyRef

    A Scalafix Rule.

    A Scalafix Rule.

    To provide automatic fixes for this rule, override the fix method. Example:

    object ReverseNames extends Rule("ReverseNames") {
      override def fix(ctx: RuleCtx) =
        ctx.tree.collect {
          case name @ Name(value) => ctx.replaceTree(name, value.reverse)
        }.asPatch
    }

    To report violations of this rule (without automatic fix), override the check method. Example:

    // example syntactic linter
    object NoNulls extends Rule("NoNulls") {
      val error = LintCategory.error("Nulls are not allowed.")
      override def check(ctx: RuleCtx): List[LintMessage] = ctx.tree.collect {
        case nil @ q"null" => error.at(nil.pos)
      }
    }
  16. trait RuleCtx extends PatchOps
  17. type RuleName = rule.RuleName
    Definition Classes
    ScalafixSyntax
  18. abstract class SemanticRule extends Rule
  19. trait SemanticdbIndex extends SemanticContext

    An index for looking up data in a scala.meta.Database.

  20. sealed trait Severity extends Product
  21. sealed trait Signature extends AnyRef
  22. sealed trait Symbol extends Product
  23. final class SymbolMatcher extends AnyRef

    Utility to match against a particular symbol.

    Utility to match against a particular symbol.

    Can be used both in pattern matching and regular condition testing.

    val myMethod = SymbolMatcher(Symbol("_root_.myMethod"))
    myMethod.matches(Tree)
    Tree match {
      case myMethod(_) => // act on tree
    }
    myMethod.matches(Tree)
  24. final case class Synthetic(position: Position, text: String, names: List[ResolvedName]) extends Product with Serializable

Value Members

  1. val CustomMessage: config.CustomMessage.type
    Definition Classes
    ScalafixSyntax
  2. val LintCategory: lint.LintCategory.type
    Definition Classes
    ScalafixSyntax
  3. val Patch: patch.Patch.type
    Definition Classes
    ScalafixSyntax
  4. val RuleName: rule.RuleName.type
    Definition Classes
    ScalafixSyntax
  5. object Flags extends Flags
  6. object ResolvedName extends Serializable
  7. object Rule
  8. object RuleCtx
  9. object SemanticdbIndex
  10. object Severity
  11. object Signature
  12. object Symbol
  13. object SymbolMatcher

Inherited from ScalafixSyntax

Inherited from AnyRef

Inherited from Any

Ungrouped