Permalink
Browse files

added a nice doclet to support excluding classes and methods, begun w…

…ork on cleaning up the javadoc
  • Loading branch information...
1 parent 315747e commit cd420ee8c4895e119a05732de45f731d7ee032dd Kristofer Karlsson committed Jun 13, 2010
View
@@ -6,6 +6,7 @@
<module fileurl="file://$PROJECT_DIR$/core/core.iml" filepath="$PROJECT_DIR$/core/core.iml" />
<module fileurl="file://$PROJECT_DIR$/core-dep/core-dep.iml" filepath="$PROJECT_DIR$/core-dep/core-dep.iml" />
<module fileurl="file://$PROJECT_DIR$/j2se/j2se.iml" filepath="$PROJECT_DIR$/j2se/j2se.iml" />
+ <module fileurl="file://$PROJECT_DIR$/javadoc/javadoc.iml" filepath="$PROJECT_DIR$/javadoc/javadoc.iml" />
<module fileurl="file://$PROJECT_DIR$/contrib/midlet/midlet.iml" filepath="$PROJECT_DIR$/contrib/midlet/midlet.iml" />
<module fileurl="file://$PROJECT_DIR$/testsuite/testsuite.iml" filepath="$PROJECT_DIR$/testsuite/testsuite.iml" />
</modules>
View
@@ -279,9 +279,22 @@
</emmajava>
</target>
- <target name="javadoc" description="Generate javadoc">
+ <target name="compile-doclet">
+ <mkdir dir="${build.dir}/doclet"/>
+ <javac
+ destdir="${build.dir}/doclet"
+ debug="true"
+ >
+ <src path="javadoc/src"/>
+ </javac>
+ </target>
+
+ <target name="javadoc" description="Generate javadoc" depends="compile-doclet">
<javadoc
- destdir="${build.dir}/javadoc">
+ doclet="ExcludeDoclet"
+ docletpath="${build.dir}/doclet"
+ destdir="${build.dir}/javadoc"
+ >
<fileset dir="${core.src.dir}" />
<fileset dir="${cldc11.src.dir}" />
<fileset dir="${j2se.src.dir}" />
@@ -1,5 +1,8 @@
package org.luaj.kahluafork.compiler;
+/**
+ * @exclude
+ */
public class BlockCnt {
BlockCnt previous; /* chain */
int breaklist; /* list of jumps out of this loop */
@@ -1,5 +1,8 @@
package org.luaj.kahluafork.compiler;
+/**
+ * @exclude
+ */
public class ConsControl {
ExpDesc v = new ExpDesc(); /* last list item read */
ExpDesc t; /* table descriptor */
@@ -1,5 +1,8 @@
package org.luaj.kahluafork.compiler;
+/**
+ * @exclude
+ */
public class ExpDesc {
int k; // expkind, from enumerated list, above
@@ -27,6 +27,9 @@
import java.util.Hashtable;
+/**
+ * @exclude
+ */
public class FuncState {
private static final Object NULL_OBJECT = new Object();
@@ -21,6 +21,9 @@
******************************************************************************/
package org.luaj.kahluafork.compiler;
+/**
+ * @exclude
+ */
class InstructionPtr {
final int[] code;
final int idx;
@@ -4,6 +4,9 @@
** structure to chain all variables in the left-hand side of an
** assignment
*/
+/**
+ * @exclude
+ */
public class LHS_assign {
LHS_assign prev;
/* variable (global, local, upvalue, or indexed) */
@@ -30,6 +30,9 @@
import se.krka.kahlua.vm.Prototype;
+/**
+ * @exclude
+ */
public class LexState {
public int nCcalls;
@@ -1,5 +1,8 @@
package org.luaj.kahluafork.compiler;
+/**
+ * @exclude
+ */
public class Token {
int token;
@@ -113,20 +113,20 @@ public static LuaClosure loadis(InputStream inputStream, String name, KahluaTabl
return loadis(inputStream, name, null, environment);
}
- public static LuaClosure loadis(InputStream inputStream, String name, String source, KahluaTable environment) throws IOException {
- return loadis(new InputStreamReader(inputStream), name, source, environment);
- }
-
public static LuaClosure loadis(Reader reader, String name, KahluaTable environment) throws IOException {
return loadis(reader, name, null, environment);
}
- public static LuaClosure loadis(Reader reader, String name, String source, KahluaTable environment) throws IOException {
- return new LuaClosure(LexState.compile(reader.read(), reader, name, source), environment);
- }
-
public static LuaClosure loadstring(String source, String name, KahluaTable environment) throws IOException {
return loadis(new ByteArrayInputStream(source.getBytes("UTF-8")), name, source, environment);
}
+
+ private static LuaClosure loadis(Reader reader, String name, String source, KahluaTable environment) throws IOException {
+ return new LuaClosure(LexState.compile(reader.read(), reader, name, source), environment);
+ }
+
+ private static LuaClosure loadis(InputStream inputStream, String name, String source, KahluaTable environment) throws IOException {
+ return loadis(new InputStreamReader(inputStream), name, source, environment);
+ }
}
@@ -24,47 +24,88 @@ of this software and associated documentation files (the "Software"), to deal
import java.io.PrintStream;
public class KahluaThread {
+ /** @exclude */
public static final int FIELDS_PER_FLUSH = 50;
+ /** @exclude */
public static final int OP_MOVE = 0;
+ /** @exclude */
public static final int OP_LOADK = 1;
+ /** @exclude */
public static final int OP_LOADBOOL = 2;
+ /** @exclude */
public static final int OP_LOADNIL = 3;
+ /** @exclude */
public static final int OP_GETUPVAL = 4;
+ /** @exclude */
public static final int OP_GETGLOBAL = 5;
+ /** @exclude */
public static final int OP_GETTABLE = 6;
+ /** @exclude */
public static final int OP_SETGLOBAL = 7;
+ /** @exclude */
public static final int OP_SETUPVAL = 8;
+ /** @exclude */
public static final int OP_SETTABLE = 9;
+ /** @exclude */
public static final int OP_NEWTABLE = 10;
+ /** @exclude */
public static final int OP_SELF = 11;
+ /** @exclude */
public static final int OP_ADD = 12;
+ /** @exclude */
public static final int OP_SUB = 13;
+ /** @exclude */
public static final int OP_MUL = 14;
+ /** @exclude */
public static final int OP_DIV = 15;
+ /** @exclude */
public static final int OP_MOD = 16;
+ /** @exclude */
public static final int OP_POW = 17;
+ /** @exclude */
public static final int OP_UNM = 18;
+ /** @exclude */
public static final int OP_NOT = 19;
+ /** @exclude */
public static final int OP_LEN = 20;
+ /** @exclude */
public static final int OP_CONCAT = 21;
+ /** @exclude */
public static final int OP_JMP = 22;
+ /** @exclude */
public static final int OP_EQ = 23;
+ /** @exclude */
public static final int OP_LT = 24;
+ /** @exclude */
public static final int OP_LE = 25;
+ /** @exclude */
public static final int OP_TEST = 26;
+ /** @exclude */
public static final int OP_TESTSET = 27;
+ /** @exclude */
public static final int OP_CALL = 28;
+ /** @exclude */
public static final int OP_TAILCALL = 29;
+ /** @exclude */
public static final int OP_RETURN = 30;
+ /** @exclude */
public static final int OP_FORLOOP = 31;
+ /** @exclude */
public static final int OP_FORPREP = 32;
+ /** @exclude */
public static final int OP_TFORLOOP = 33;
+ /** @exclude */
public static final int OP_SETLIST = 34;
+ /** @exclude */
public static final int OP_CLOSE = 35;
+ /** @exclude */
public static final int OP_CLOSURE = 36;
+ /** @exclude */
public static final int OP_VARARG = 37;
+ /** @exclude */
private static final int MAX_INDEX_RECURSION = 100;
+ /** @exclude */
private static final String meta_ops[];
static {
meta_ops = new String[38];
@@ -80,8 +121,11 @@ of this software and associated documentation files (the "Software"), to deal
meta_ops[OP_LE] = "__le";
}
+ /** @exclude */
public Coroutine currentCoroutine;
+ /** @exclude */
private final PrintStream out;
+ /** @exclude */
private final Platform platform;
public KahluaThread(Platform platform, KahluaTable environment) {
@@ -936,7 +980,7 @@ private final void luaMainloop() {
}
}
- public Object getMetaOp(Object o, String meta_op) {
+ protected Object getMetaOp(Object o, String meta_op) {
KahluaTable meta = (KahluaTable) getmetatable(o, true);
if (meta == null) {
return null;
@@ -1237,6 +1281,9 @@ public Platform getPlatform() {
return platform;
}
+ /**
+ * @exclude
+ */
public static void yieldHelper(LuaCallFrame callFrame, LuaCallFrame argsCallFrame, int nArguments) {
KahluaUtil.luaAssert(callFrame.canYield, "Can not yield outside of a coroutine");
@@ -29,6 +29,9 @@ of this software and associated documentation files (the "Software"), to deal
import java.io.InputStream;
import java.io.OutputStream;
+/**
+ * @exclude
+ */
public final class Prototype {
public int[] code;
@@ -22,6 +22,9 @@ of this software and associated documentation files (the "Software"), to deal
package se.krka.kahlua.vm;
+/**
+ * @exclude
+ */
public final class UpValue {
// For open upvalues
private Coroutine coroutine;
@@ -33,6 +33,9 @@ of this software and associated documentation files (the "Software"), to deal
import java.awt.event.FocusListener;
import java.util.Properties;
+/**
+ * @exclude
+ */
public class JSyntaxUtil {
private static boolean initialized;
@@ -24,8 +24,10 @@ of this software and associated documentation files (the "Software"), to deal
import jsyntaxpane.DefaultSyntaxKit;
import jsyntaxpane.Lexer;
-import jsyntaxpane.lexers.LuaLexer;
+/**
+ * @exclude
+ */
public class KahluaKit extends DefaultSyntaxKit {
public KahluaKit(Lexer lexer) {
View
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="JAVA_MODULE" version="4">
+ <component name="NewModuleRootManager" inherit-compiler-output="true">
+ <exclude-output />
+ <content url="file://$MODULE_DIR$">
+ <sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
+ </content>
+ <orderEntry type="inheritedJdk" />
+ <orderEntry type="sourceFolder" forTests="false" />
+ </component>
+</module>
+
Oops, something went wrong.

0 comments on commit cd420ee

Please sign in to comment.