|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.mit.csail.sdg.alloy4compiler.parser.CompUtil
public final class CompUtil
This class provides convenience methods for calling the parser and the compiler.
| Method Summary | |
|---|---|
static CompModule |
parseEverything_fromFile(A4Reporter rep,
java.util.Map<java.lang.String,java.lang.String> loaded,
java.lang.String filename)
Read everything from "file" and parse it; if it mentions submodules, open them and parse them too. |
static CompModule |
parseEverything_fromFile(A4Reporter rep,
java.util.Map<java.lang.String,java.lang.String> loaded,
java.lang.String filename,
int initialResolutionMode)
Read everything from "file" and parse it; if it mentions submodules, open them and parse them too. |
static Expr |
parseOneExpression_fromString(Module world,
java.lang.String input)
Parses then typecheck the given input String as an Alloy expression from that world |
static ConstList<Command> |
parseOneModule_fromFile(java.lang.String filename)
Parses 1 module from the file (without loading any subfiles) |
static ConstList<Command> |
parseOneModule_fromString(java.lang.String content)
Parses 1 module from the input string (without loading any subfiles) |
static CompModule |
parseOneModule(java.lang.String content)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static ConstList<Command> parseOneModule_fromString(java.lang.String content)
throws Err
Err
public static CompModule parseOneModule(java.lang.String content)
throws Err
Err
public static ConstList<Command> parseOneModule_fromFile(java.lang.String filename)
throws Err
Err
public static Expr parseOneExpression_fromString(Module world,
java.lang.String input)
throws Err
Err - if world==null or if any other error occurred
public static CompModule parseEverything_fromFile(A4Reporter rep,
java.util.Map<java.lang.String,java.lang.String> loaded,
java.lang.String filename)
throws Err
rep - - if nonnull, we will report compilation progress messages to itloaded - - a cache of files that have been pre-fetched (can be null if there were no prefetching)filename - - the main module we are parsing
Err - if an error occurred
And if loaded!=null, it will contain all the files needed for this parse, and furthermore, other entries will be deleted.
public static CompModule parseEverything_fromFile(A4Reporter rep,
java.util.Map<java.lang.String,java.lang.String> loaded,
java.lang.String filename,
int initialResolutionMode)
throws Err
rep - - if nonnull, we will report compilation progress messages to itloaded - - a cache of files that have been pre-fetched (can be null if there were no prefetching)filename - - the main module we are parsinginitialResolutionMode - - use 1 for the historical behavior, and 2 for Alloy 4.2's new "universal implicit this" name resolution behavior
Err - if an error occurred
And if loaded!=null, it will contain all the files needed for this parse, and furthermore, other entries will be deleted.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||