Package org.spf4j.zel.vm
Class NullParsingContext
- java.lang.Object
-
- org.spf4j.zel.vm.NullParsingContext
-
- All Implemented Interfaces:
ParsingContext
public final class NullParsingContext extends Object implements ParsingContext
- Author:
- zoly
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.spf4j.zel.vm.ParsingContext
ParsingContext.Location
-
-
Field Summary
Fields Modifier and Type Field Description static NullParsingContextINSTANCE
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NullParsingContextcreateSubContext()clone this contextvoidgenerateCode(ParsingContext.Location[] loc, Instruction... args)generate instruction code with argumentvoidgenerateCode(ParsingContext.Location loc, Instruction instr)voidgenerateCodeAll(ParsingContext parsingContext)Add code to this contextintgetAddress()return the current code addressInstructiongetLast()org.spf4j.zel.vm.ProgramBuildergetProgramBuilder()get the code generated in this contextvoidstaticSymbol(String name)voidstaticSymbol(String name, Object object)
-
-
-
Field Detail
-
INSTANCE
public static final NullParsingContext INSTANCE
-
-
Method Detail
-
getAddress
public int getAddress()
return the current code address- Specified by:
getAddressin interfaceParsingContext- Returns:
-
getProgramBuilder
@Nullable public org.spf4j.zel.vm.ProgramBuilder getProgramBuilder()
Description copied from interface:ParsingContextget the code generated in this context- Specified by:
getProgramBuilderin interfaceParsingContext- Returns:
- Object[]
-
generateCodeAll
public void generateCodeAll(ParsingContext parsingContext)
Description copied from interface:ParsingContextAdd code to this context- Specified by:
generateCodeAllin interfaceParsingContext
-
createSubContext
public NullParsingContext createSubContext()
Description copied from interface:ParsingContextclone this context- Specified by:
createSubContextin interfaceParsingContext- Returns:
-
staticSymbol
public void staticSymbol(String name, Object object)
- Specified by:
staticSymbolin interfaceParsingContext
-
staticSymbol
public void staticSymbol(String name)
- Specified by:
staticSymbolin interfaceParsingContext
-
getLast
public Instruction getLast()
- Specified by:
getLastin interfaceParsingContext
-
generateCode
public void generateCode(ParsingContext.Location[] loc, Instruction... args)
Description copied from interface:ParsingContextgenerate instruction code with argument- Specified by:
generateCodein interfaceParsingContext
-
generateCode
public void generateCode(ParsingContext.Location loc, Instruction instr)
- Specified by:
generateCodein interfaceParsingContext
-
-