1 package org.ozoneDB.tools.OPP.srcgen; 9 10 import org.ozoneDB.tools.OPP.srcgen.BuilderException; 11 import org.ozoneDB.tools.OPP.message.MessageWriter; 12 13 import java.lang.reflect.Modifier ; 14 15 25 public interface ClassBuilder { 26 33 public class Parameter { 34 private String type; 35 private String name; 36 private String origName; 37 private int modifier; 38 39 public String getType() { 40 return type; 41 } 42 43 public String getName() { 44 return name; 45 } 46 47 51 public int getModifier() { 52 return modifier; 53 } 54 55 59 public String getOrigTypeName() { 60 return origName; 61 } 62 63 70 public Parameter(String type, String name, String origName, int modifier) { 71 this.type = type; 72 this.name = name; 73 this.modifier = modifier; 74 this.origName = origName; 75 } 76 77 public String toString() { 78 return (Modifier.toString(modifier) + " " + type + " " + name); 79 } 80 } 81 82 88 void init(MessageWriter msgWriter); 89 90 98 void beginClass(int modifier, final String fullName, String superClass, String interfaces[]) throws BuilderException; 99 100 106 void makeConstructor(int modifier, Parameter parameters[], String exceptions[]) throws BuilderException; 107 108 117 void makeMethod(int modifier, String name, Parameter parameters[], String returnType, String exceptions[], int lockLevel) throws BuilderException; 118 119 123 void endClass() throws BuilderException; 124 } 125 | Popular Tags |