Zipped4

parsley.syntax.zipped.Zipped4
final implicit class Zipped4[T1, T2, T3, T4](t: (Parsley[T1], Parsley[T2], Parsley[T3], Parsley[T4])) extends AnyVal

This class enables the zipped syntax on tuples of four parsers.

Value parameters

t

the four parsers whose results should be zipped together.

Attributes

Constructor

This constructor should not be called manually, it is designed to be used via Scala's implicit resolution.

Source
zipped.scala
Graph
Supertypes
class AnyVal
trait Matchable
class Any

Members list

Value members

Concrete methods

def zipped[R](f: (T1, T2, T3, T4) => R): Parsley[R]

This combinator executes each of these parsers and combines their results with a given function.

This combinator executes each of these parsers and combines their results with a given function.

Each of these parsers is executed in turn, each yielding a result. So long as every parser succeeded, the whole combinator succeeds and each of the results is fed into the function f. The result of applying f to the results is returned by the combinator. If any of these parsers fail, the whole combinator fails.

Value parameters

f

the function to apply across the results of all the parsers.

Attributes

Returns

a parser that seqeunces each of these parsers and combines their results with the function f.

Source
zipped.scala
def zipped: Parsley[(T1, T2, T3, T4)]

This combinator executes each of these parsers and pairs all their results together.

This combinator executes each of these parsers and pairs all their results together.

Each of these parsers is executed in turn, each yielding a result. So long as every parser succeeded, the whole combinator succeeds. The pair formed from all of the results is returned by the parser. If any of these parsers fail, the whole combinator fails.

Attributes

Returns

a parser that seqeunces each of these parsers and pairs them all together.

Source
zipped.scala