org.sonar.sslr.internal.vm
Class Instruction

java.lang.Object
  extended by org.sonar.sslr.internal.vm.Instruction
Direct Known Subclasses:
Instruction.BackCommitInstruction, Instruction.BacktrackInstruction, Instruction.CallInstruction, Instruction.ChoiceInstruction, Instruction.CommitInstruction, Instruction.CommitVerifyInstruction, Instruction.EndInstruction, Instruction.FailTwiceInstruction, Instruction.IgnoreErrorsInstruction, Instruction.JumpInstruction, Instruction.PredicateChoiceInstruction, Instruction.RetInstruction, NativeExpression

public abstract class Instruction
extends Object


Nested Class Summary
static class Instruction.BackCommitInstruction
           
static class Instruction.BacktrackInstruction
           
static class Instruction.CallInstruction
           
static class Instruction.ChoiceInstruction
           
static class Instruction.CommitInstruction
           
static class Instruction.CommitVerifyInstruction
           
static class Instruction.EndInstruction
           
static class Instruction.FailTwiceInstruction
           
static class Instruction.IgnoreErrorsInstruction
           
static class Instruction.JumpInstruction
           
static class Instruction.PredicateChoiceInstruction
          Instruction dedicated for predicates.
static class Instruction.RetInstruction
           
 
Constructor Summary
Instruction()
           
 
Method Summary
static void addAll(List<Instruction> list, Instruction[] array)
           
static Instruction backCommit(int offset)
           
static Instruction backtrack()
           
static Instruction call(int offset, Matcher matcher)
           
static Instruction choice(int offset)
           
static Instruction commit(int offset)
           
static Instruction commitVerify(int offset)
           
static Instruction end()
           
abstract  void execute(Machine machine)
          Executes this instruction.
static Instruction failTwice()
           
static Instruction ignoreErrors()
           
static Instruction jump(int offset)
           
static Instruction predicateChoice(int offset)
           
static Instruction ret()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Instruction

public Instruction()
Method Detail

addAll

public static void addAll(List<Instruction> list,
                          Instruction[] array)

jump

public static Instruction jump(int offset)

call

public static Instruction call(int offset,
                               Matcher matcher)

ret

public static Instruction ret()

backtrack

public static Instruction backtrack()

end

public static Instruction end()

choice

public static Instruction choice(int offset)

predicateChoice

public static Instruction predicateChoice(int offset)

commit

public static Instruction commit(int offset)

commitVerify

public static Instruction commitVerify(int offset)

failTwice

public static Instruction failTwice()

backCommit

public static Instruction backCommit(int offset)

ignoreErrors

public static Instruction ignoreErrors()

execute

public abstract void execute(Machine machine)
Executes this instruction.



Copyright © 2009-2014 SonarSource. All Rights Reserved.