ScriptPreprocessor

scala.build.preprocessing.ScriptPreprocessor
case object ScriptPreprocessor extends Preprocessor

Attributes

Graph
Supertypes
trait Singleton
trait Product
trait Mirror
trait Serializable
trait Product
trait Equals
trait Preprocessor
class Object
trait Matchable
class Any
Show all
Self type

Members list

Type members

Inherited types

type MirroredElemLabels = EmptyTuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Singleton
type MirroredElemTypes = EmptyTuple

Attributes

Inherited from:
Singleton
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror
type MirroredMonoType = Singleton.this.type

The mirrored *-type

The mirrored *-type

Attributes

Inherited from:
Singleton
type MirroredType = Singleton.this.type

Attributes

Inherited from:
Singleton

Value members

Concrete methods

def getScriptWrapper(buildOptions: BuildOptions): CodeWrapper

Get correct script wrapper depending on the platform and version of Scala. For Scala 2 or Platform JS use ObjectCodeWrapper. Otherwise - for Scala 3 on JVM or Native use ClassCodeWrapper.

Get correct script wrapper depending on the platform and version of Scala. For Scala 2 or Platform JS use ObjectCodeWrapper. Otherwise - for Scala 3 on JVM or Native use ClassCodeWrapper.

Value parameters

buildOptions

final version of options, build may fail if incompatible wrapper is chosen

Attributes

Returns

code wrapper compatible with provided BuildOptions

def getScriptWrappingFunction(logger: Logger, containsMainAnnot: Boolean, packageStrings: Seq[Name], wrapperName: Name, scriptCode: String, scriptPath: String): CodeWrapper => (String, WrapperParams)
def preprocess(input: SingleElement, logger: Logger, maybeRecoverOnError: BuildException => Option[BuildException], allowRestrictedFeatures: Boolean, suppressWarningOptions: SuppressWarningOptions)(using ScalaCliInvokeData): Option[Either[BuildException, Seq[PreprocessedSource]]]

Inherited methods

def fromProduct(p: Product): MirroredMonoType

Create a new instance of type T with elements taken from product p.

Create a new instance of type T with elements taken from product p.

Attributes

Inherited from:
Singleton
def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product