blob: e0364b5c6ec2bd7b2f25bf8a7ef2240196ebba95 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
/* NSC -- new Scala compiler
* Copyright 2005-2011 LAMP/EPFL
* @author Paul Phillips
*/
package scala.tools.nsc
package interpreter
/** An implementation-agnostic history interface which makes no
* reference to the jline classes.
*/
trait History {
def asStrings: List[String]
def index: Int
def size: Int
def grep(s: String): List[String]
def flush(): Unit
}
object History {
object Empty extends History {
def asStrings = Nil
def grep(s: String) = Nil
def index = 0
def size = 0
def flush() = ()
}
}
|