From 9b7d99bc8fcd8ee2f5d2d36ba75f2aade851b07c Mon Sep 17 00:00:00 2001 From: Kenneth Russel Date: Mon, 4 Jun 2007 01:41:03 +0000 Subject: Added GlueGenRuntimePackage to allow people to rename and incorporate those helper classes into their apps git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/../svn-server-sync/gluegen/trunk@62 a78bb65f-1512-4460-ba86-f6dc96a7bf27 --- src/java/com/sun/gluegen/JavaConfiguration.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/java/com/sun/gluegen/JavaConfiguration.java') diff --git a/src/java/com/sun/gluegen/JavaConfiguration.java b/src/java/com/sun/gluegen/JavaConfiguration.java index 7488a30..7f6efa9 100644 --- a/src/java/com/sun/gluegen/JavaConfiguration.java +++ b/src/java/com/sun/gluegen/JavaConfiguration.java @@ -88,6 +88,13 @@ public class JavaConfiguration { * List of imports to emit at the head of the output files. */ private List/**/ imports = new ArrayList(); + /** + * The package in which the generated glue code expects to find its + * run-time helper classes (BufferFactory, CPU, + * StructAccessor). Defaults to "com.sun.gluegen.runtime". + */ + private String gluegenRuntimePackage = "com.sun.gluegen.runtime"; + /** * The kind of exception raised by the generated code if run-time * checks fail. Defaults to RuntimeException. @@ -248,6 +255,10 @@ public class JavaConfiguration { return JavaEmitter.ACC_PUBLIC; } + /** Returns the package in which the generated glue code expects to + find its run-time helper classes (BufferFactory, CPU, + StructAccessor). Defaults to "com.sun.gluegen.runtime". */ + public String gluegenRuntimePackage() { return gluegenRuntimePackage; } /** Returns the kind of exception to raise if run-time checks fail in the generated code. */ public String runtimeExceptionType() { return runtimeExceptionType; } /** Returns the list of imports that should be emitted at the top of each .java file. */ @@ -681,6 +692,8 @@ public class JavaConfiguration { //System.err.println("read cmd = [" + cmd + "]"); if (cmd.equalsIgnoreCase("Package")) { packageName = readString("package", tok, filename, lineNo); + } else if (cmd.equalsIgnoreCase("GlueGenRuntimePackage")) { + gluegenRuntimePackage = readString("GlueGenRuntimePackage", tok, filename, lineNo); } else if (cmd.equalsIgnoreCase("ImplPackage")) { implPackageName = readString("ImplPackage", tok, filename, lineNo); } else if (cmd.equalsIgnoreCase("JavaClass")) { -- cgit v1.2.3