1 package edu.uci.eecs.specCompiler.specExtraction;
7 * This class represents the plain context for each specification construct.
8 * Besides, it also stores some useful information such as interfaceDeclBody,
9 * which is used in @Interface construct to wrap and rename interface calls.
14 public class SpecConstruct {
15 public enum ConstructType {
16 GLOBAL, INTERFACE, POTENTIAL_CP, CP_DEFINE, CP_DEFINE_CHECK
18 public ConstructType type;
19 public final String plainText;
20 public final File file;
21 public final int beginLineNum;
22 public final int endLineNum;
23 public final String interfaceDeclBody;
25 public SpecConstruct(ConstructType type, String plainText, File file,
26 int beginLineNum, int endLineNum) {
28 this.plainText = plainText;
30 this.beginLineNum = beginLineNum;
31 this.endLineNum = endLineNum;
32 this.interfaceDeclBody = "";
35 public SpecConstruct(ConstructType type, String plainText, File file,
36 int beginLineNum, int endLineNum, String interfaceDeclBody) {
38 this.plainText = plainText;
40 this.beginLineNum = beginLineNum;
41 this.endLineNum = endLineNum;
42 this.interfaceDeclBody = interfaceDeclBody;