StepParser

org.specs2.specification.script.StepParser
See theStepParser companion object
trait StepParser[T]

A StepParser is a function to extract a value of type T from a piece of text It can also strip the text from delimiters if any

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
Self type

Members list

Value members

Abstract methods

def parse(text: String): Either[Throwable, (String, T)]

parse some text and extract some well-type value T if the original text contains delimiters to indicate the values to extract, remove them

parse some text and extract some well-type value T if the original text contains delimiters to indicate the values to extract, remove them

this is equivalent to running strip and run at the same time so it might be more efficient

Attributes

def run(text: String): Either[Throwable, T]
def strip(text: String): String

Concrete methods

def map[S](f: T => S): StepParser[S]