LiteralAgentParser

org.nlogo.agent.LiteralAgentParser
class LiteralAgentParser(_world: World, readLiteralPrefix: (Token, Iterator[Token]) => AnyRef) extends Iterator[Token] => AnyRef

Attributes

Source
LiteralAgentParser.scala
Graph
Supertypes
trait Iterator[Token] => AnyRef
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def apply(tokens: Iterator[Token]): AnyRef

parses a literal agent or agentset. It recognizes a number of forms: {turtle 4} {patch 0 1} {breed-singular 2} {all-turtles} {all-patches} {observer} {breed some-breed} {turtles 1 2 3 4 5} {patches [1 2] [3 4] [5 6]} {links [0 1] [1 2]} To parse the turtle and patch forms, it uses parseLiteralAgent().

parses a literal agent or agentset. It recognizes a number of forms: {turtle 4} {patch 0 1} {breed-singular 2} {all-turtles} {all-patches} {observer} {breed some-breed} {turtles 1 2 3 4 5} {patches [1 2] [3 4] [5 6]} {links [0 1] [1 2]} To parse the turtle and patch forms, it uses parseLiteralAgent().

Attributes

Source
LiteralAgentParser.scala
def world: World

Attributes

Source
LiteralAgentParser.scala

Inherited methods

def andThen[A](g: AnyRef => A): Iterator[Token] => A

Attributes

Inherited from:
Function1
def compose[A](g: A => Iterator[Token]): A => AnyRef

Attributes

Inherited from:
Function1
override def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Function1 -> Any
Inherited from:
Function1