Packages

package v0

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

Type Members

  1. implicit class XtensionOptionPatch extends AnyRef
    Definition Classes
    Api
  2. implicit class XtensionScalaFixListInspect[A] extends AnyRef
    Definition Classes
    Api
  3. implicit class XtensionScalafixProductInspect extends AnyRef
    Definition Classes
    Api
  4. implicit class XtensionSeqPatch extends AnyRef
    Definition Classes
    Api
  5. type CustomMessage[T] = config.CustomMessage[T]
    Definition Classes
    Api
  6. final case class Database(documents: Seq[Document]) extends Product with Serializable
  7. final case class Denotation(flags: Long, name: String, signature: String, names: List[ResolvedName]) extends HasFlags with Product with Serializable
  8. type Diagnostic = lint.Diagnostic
    Definition Classes
    Api
  9. final case class Document(input: Input, language: String, names: List[ResolvedName], messages: List[Message], symbols: List[ResolvedSymbol], synthetics: List[Synthetic]) extends Product with Serializable
  10. trait Flags extends AnyRef
  11. trait HasFlags extends AnyRef
  12. final case class LintCategory(id: String, explanation: String, severity: LintSeverity) extends Product with Serializable

    A unique identifier for one kind of a linter message.

    A unique identifier for one kind of a linter message.

    id

    a string ID for this message, typically the name of the assigned variable. If id is empty, then the name of the rewrite reporting this LintCategory is used as id.

    explanation

    An optional explanation for this kind of message.

    severity

    The default category this message should get reported to. Note that users can configure/override the default category.

  13. final case class LintMessage(message: String, position: scala.meta.Position, category: LintCategory) extends Diagnostic with Product with Serializable

    An observation of a LintCategory at a particular position

    An observation of a LintCategory at a particular position

    message

    The message to display to the user. If empty, LintID.explanation is used instead.

    position

    Optionally place a caret under a location in a source file. For an empty position use Position.None.

    category

    the LintCategory associated with this message.

  14. final case class Message(position: Position, severity: Severity, text: String) extends Product with Serializable
  15. type Patch = patch.Patch
    Definition Classes
    Api
  16. final case class ResolvedName(position: Position, symbol: Symbol, isDefinition: Boolean) extends Product with Serializable
  17. final case class ResolvedSymbol(symbol: Symbol, denotation: Denotation) extends Product with Serializable
  18. 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[Diagnostic] = ctx.tree.collect {
        case nil @ q"null" => error.at(nil.pos)
      }
    }
  19. trait RuleCtx extends PatchOps
  20. type RuleName = rule.RuleName
    Definition Classes
    Api
  21. abstract class SemanticRule extends Rule
  22. trait SemanticdbIndex extends SemanticContext

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

  23. sealed trait Severity extends Product
  24. sealed trait Signature extends AnyRef
  25. sealed trait Symbol extends Product
  26. 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)
  27. 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
    Api
  2. val Diagnostic: lint.Diagnostic.type
    Definition Classes
    Api
  3. val Patch: patch.Patch.type
    Definition Classes
    Api
  4. val RuleName: rule.RuleName.type
    Definition Classes
    Api
  5. object Flags extends Flags
  6. object LintCategory extends Serializable
  7. object ResolvedName extends Serializable
  8. object Rule
  9. object RuleCtx
  10. object SemanticdbIndex
  11. object Severity
  12. object Signature
  13. object Symbol
  14. object SymbolMatcher

Inherited from Api

Inherited from AnyRef

Inherited from Any

Ungrouped