object Interpolator extends VersionSpecificInterpolatorModule
- Source
- Interpolator.scala
- Grouped
- Alphabetic
- By Inheritance
- Interpolator
- VersionSpecificInterpolatorModule
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- trait Interpolators[Ctx, Expr[+_], ToExpr[_], Type[_]] extends AnyRef
A trait that provides Interpolator factory methods that conform to a particular input Expr type parameter.
A trait that provides Interpolator factory methods that conform to a particular input Expr type parameter.
In scala 3, the Interpolator companion object contains methods similar to these for quoted.Expr, and as such this would generally by calling methods directly on Interpolator. However, since in scala 2 the Expr depends on a particular instance of
blackbox.Context
, instead an Interpolators must be constructed from the Interpolator companion object'smacroInterpolators
method that takes a Context. - trait LiftedInterpolator[C <: Context with Singleton] extends AnyRef
- Annotations
- @ifdef("scalaEpochVersion:2")
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- def contextInterpolators(c: Context): Interpolators[c.type, scala.reflect.macros.blackbox.Context.Expr, scala.reflect.macros.Universe.Liftable, scala.reflect.macros.blackbox.Context.TypeTag] with LiftedInterpolator[c.type]
Create a Interpolators that can parse Exprs belonging to the specified Context
Create a Interpolators that can parse Exprs belonging to the specified Context
- Annotations
- @ifdef("scalaEpochVersion:2")
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- val idInterpolators: Interpolators[IdCtx, Id, IdToExpr, ClassTag]
Returns an Interpolators that can parse raw values
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def lazy[Ctx, Expr, A](fn: () => Interpolator[Ctx, Expr, A]): Interpolator[Ctx, Expr, A]
Indirectly refers to a parser, to allow for mutual-recursion
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
A library for writing custom string interpolation implementations via parser combinators
Entry Points
If the string context should create an object: Create leaf parsers using the methods in the Interpolator companion object, combine and manipulate them with the methods in Interpolator, then interpolate using the final
Interpolator
'sinterpolate
method.If the string context should create an extractor: Create leaf parsers using the methods in the Extractor companion object, combine and manipulate them with the methods in Extractor, then interpolate using the final
Extractor
'sextractor
method.If the string context should do both: Create leaf parsers using the methods in the Parser companion object, combine and manipulate them with the methods in Parser, then interpolate using the final
Parser
'sinterpolate
andextractor
methods.