scala.tools.nsc

interpreter

package interpreter

Linear Supertypes
ReplStrings, ReplConfig, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. interpreter
  2. ReplStrings
  3. ReplConfig
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. type InputStream = java.io.InputStream

  2. type JClass = Class[_]

  3. type JCollection[T] = Collection[T]

  4. type JFile = File

  5. type JList[T] = java.util.List[T]

  6. type JPrintWriter = PrintWriter

  7. type OutputStream = java.io.OutputStream

  8. trait SparkExprTyper extends AnyRef

  9. class SparkILoop extends LoopCommands

    The Scala interactive shell.

    The Scala interactive shell. It provides a read-eval-print loop around the Interpreter class. After instantiation, clients should call the main() method.

    If no in0 is specified, then input will come from the console, and the class will attempt to provide input editing feature such as input history.

    Version

    1.2

  10. class SparkIMain extends AbstractScriptEngine with Compilable with SparkImports

    An interpreter for Scala code.

    An interpreter for Scala code.

    The main public entry points are compile(), interpret(), and bind(). The compile() method loads a complete Scala file. The interpret() method executes one line of Scala code at the request of the user. The bind() method binds an object to a variable that can then be used by later interpreted code.

    The overall approach is based on compiling the requested code and then using a Java classloader and Java reflection to run the code and access its results.

    In more detail, a single compiler instance is used to accumulate all successfully compiled or interpreted Scala code. To "interpret" a line of code, the compiler generates a fresh object that includes the line of code and which has public member(s) to export all variables defined by that code. To extract the result of an interpreted line to show the user, a second "result object" is created which imports the variables exported by the above object and then exports members called "$eval" and "$print". To accomodate user expressions that read from variables or methods defined in previous statements, "import" statements are used.

    This interpreter shares the strengths and weaknesses of using the full compiler-to-Java. The main strength is that interpreted code behaves exactly as does compiled code, including running at full speed. The main weakness is that redefining classes and methods is not handled properly, because rebinding at the Java level is technically difficult.

  11. class SparkISettings extends AnyRef

    Settings for the interpreter

    Settings for the interpreter

    Version

    1.0

  12. trait SparkImports extends AnyRef

  13. class SparkJLineCompletion extends Completion with CompletionOutput

  14. trait SparkMemberHandlers extends AnyRef

  15. class SparkReplReporter extends ConsoleReporter

    Like ReplGlobal, a layer for ensuring extra functionality.

  16. class TapMaker[T] extends AnyRef

    Definition Classes
    ReplConfig

Value Members

  1. val IR: Results.type

  2. object SparkILoop

  3. object SparkIMain

    Utility methods for the Interpreter.

  4. def any2stringOf(x: Any, maxlen: Int): String

    Definition Classes
    ReplStrings
  5. def isAcross: Boolean

    Definition Classes
    ReplConfig
  6. def isPaged: Boolean

    Definition Classes
    ReplConfig
  7. def isReplDebug: Boolean

    Definition Classes
    ReplConfig
  8. def isReplInfo: Boolean

    Definition Classes
    ReplConfig
  9. def isReplPower: Boolean

    Definition Classes
    ReplConfig
  10. def isReplTrace: Boolean

    Definition Classes
    ReplConfig
  11. implicit def postfixOps: postfixOps

  12. lazy val replProps: ReplProps

    Definition Classes
    ReplConfig
  13. def staticTypeTag[T](implicit arg0: ClassTag[T]): reflect.api.JavaUniverse.TypeTag[T]

  14. def string2code(str: String): String

    Definition Classes
    ReplStrings
  15. def string2codeQuoted(str: String): String

    Definition Classes
    ReplStrings
  16. def unquoted(s: String): String

    Definition Classes
    ReplStrings
  17. def words(s: String): List[String]

    Definition Classes
    ReplStrings

Inherited from ReplStrings

Inherited from ReplConfig

Inherited from AnyRef

Inherited from Any

Ungrouped