Revision: 4021
          http://vexi.svn.sourceforge.net/vexi/?rev=4021&view=rev
Author:   clrg
Date:     2011-02-05 14:53:12 +0000 (Sat, 05 Feb 2011)

Log Message:
-----------
Add docs for 'Running Vexi'

Modified Paths:
--------------
    trunk/org.vexi-build.jsdoc/src/poke/java/vexi/jsdoc/RunOnVexi.java
    trunk/org.vexi-core.main/src/main/java/org/vexi/core/Main.java
    trunk/org.vexi-core.main/src/main/jpp/org/vexi/core/Vexi.jpp

Modified: trunk/org.vexi-build.jsdoc/src/poke/java/vexi/jsdoc/RunOnVexi.java
===================================================================
--- trunk/org.vexi-build.jsdoc/src/poke/java/vexi/jsdoc/RunOnVexi.java  
2011-02-04 19:51:42 UTC (rev 4020)
+++ trunk/org.vexi-build.jsdoc/src/poke/java/vexi/jsdoc/RunOnVexi.java  
2011-02-05 14:53:12 UTC (rev 4021)
@@ -49,7 +49,7 @@
                        addConcept("Biscuits", "org.vexi.core.Vexi");
                        addConcept("Box Model", "org.vexi.core.Box");
                        addConcept("Cloning", "org.ibex.js.JS");
-                       addConcept("Running Vexi", "org.vexi.core.Vexi");
+                       addConcept("Running Vexi", "org.vexi.core.Main");
                        addConcept("Special Variables", 
"org.ibex.js.Interpreter");
                        addConcept("Streams", "org.vexi.core.Vexi");
                        addConcept("Surfaces", "org.vexi.core.Surface");

Modified: trunk/org.vexi-core.main/src/main/java/org/vexi/core/Main.java
===================================================================
--- trunk/org.vexi-core.main/src/main/java/org/vexi/core/Main.java      
2011-02-04 19:51:42 UTC (rev 4020)
+++ trunk/org.vexi-core.main/src/main/java/org/vexi/core/Main.java      
2011-02-05 14:53:12 UTC (rev 4021)
@@ -21,6 +21,39 @@
 import org.vexi.plat.Platform;
 import org.vexi.util.Log;
 
+/*@PAGE(concept=Running Vexi)
+ * 
+ * <p>This page covers running Vexi from the command line.</p>
+ * 
+ * <p>The basic structure of the command is:</p>
+ * 
+ * <pre>java -jar vexi.jar [options] [sources]</pre>
+ * 
+ * <p>The sources are a list of a combination of directories, 
&lsquo;.vexi&rsquo; archives, or URLs in
+ * which Vexi can find vexicode templates (files with a &lsquo;.t&rsquo; 
extension) and other resources
+ * (e.g. image files).</p>
+ * 
+ * <p>Options are prefixed by a '-' (dash) and must be specified <i>before</i> 
sources.</p>
+ * 
+ * <table cellpadding="5" style="margin-left:20px">
+ *    <tr><td><code>-t &lt;template></code></td>
+ *    <td><p>Set the template to execute using VML-style resource syntax 
&mdash; default is 'main'</p></td></tr>
+ *    <tr><td><code>-l &lt;level></code></td>
+ *    <td><p>Set core logging level to { debug, info (default), warn, error, 
silent }</td></tr>
+ *    <tr><td><code>-l rpc</code></td>
+ *    <td><p>Log all XML-RPC and SOAP conversations</td></tr>
+ *    <tr><td><code>-l host:port</code></td>
+ *    <td><p>Emit log to TCP socket</td></tr>
+ *    <tr><td><code>-l &lt;file></code></td>
+ *    <td><p>Write log to a file on disk</td></tr>
+ *    <tr><td><code>-hr</code></td>
+ *    <td><p>&ldquo;Hot replace&ldquo; updated templates during the 
application lifecycle</td></tr>
+ *    <tr><td><code>-debug</code></td>
+ *    <td><p>Start with vexiscript property &lsquo;vexi.debug&rsquo; set to 
&lsquo;true&rsquo; (otherwise &lsquo;false&rsquo;</td></tr>
+ * </table>
+ * 
+ * */
+
 /** 
  *  Entry point for the Vexi Engine; handles splash screen,
  *  argument processing, and initial Vexi application loading
@@ -83,10 +116,11 @@
             "    -l rpc          log all XML-RPC and SOAP conversations\n"+
             "    -l host:port    emit log to TCP socket\n"+
             "    -l <file>       write log to a file on disk\n"+
-            "    -a              check assertions [not yet supported]\n"+
-            "    -w <window-id>  reserved for libvexi\n"+
-            "    -p              dump profiling information [not yet 
supported]"+
-            "    -debug          start with vexi.debug set to true";    
+            //"    -a              check assertions [not yet supported]\n"+
+            //"    -w <window-id>  reserved for libvexi\n"+
+            //"    -p              dump profiling information [not yet 
supported]"+
+            "    -hr             'hot replace' updated templates whilst 
running"+
+            "    -debug          start with vexi.debug set to true";
     }
     
     public void start(String[] args) throws Exception{
@@ -101,10 +135,12 @@
         while (true) {
             if (startargs > args.length - 1) {
                 printUsage();
-            } else if (args[startargs].equals("-a")) {
+            //} else if (args[startargs].equals("-a")) {
                 //DISABLED JS.checkAssertions = true;
             } else if (args[startargs].equals("-hr")) {
                 hotreplace = true;
+            } else if (args[startargs].equals("-debug")) {
+                debug = true;
             } else if (args[startargs].equals("-t")) {
                 startargs++;
                 startupTemplate = args[startargs];
@@ -133,11 +169,9 @@
                        Log.user.file(opt);
                     }
                 }
-            } else if (args[startargs].equals("-debug")) {
-                debug = true;
             } else if (!args[startargs].startsWith("-")) {
                 break;
-            }else{
+            } else {
                // Ignore unknown options 
                //  - we may be an old version and not supporting options, but 
the launcher doesn't realise
                //  - also allows org.vexi.debug.Main to pass in its (super set 
of org.vexi.core.Main's) options.
@@ -202,8 +236,8 @@
     
     
     protected void printUsage() {
-        System.err.println("Usage: vexi [-lawp] [ url | file | directory ]");
-        System.err.println("");
+        System.err.println("Usage: vexi [option] [ url | file | directory ]");
+        System.err.println("Options:");
         System.err.println(CORE_OPTIONS());
         Runtime.getRuntime().exit(-1);
     }

Modified: trunk/org.vexi-core.main/src/main/jpp/org/vexi/core/Vexi.jpp
===================================================================
--- trunk/org.vexi-core.main/src/main/jpp/org/vexi/core/Vexi.jpp        
2011-02-04 19:51:42 UTC (rev 4020)
+++ trunk/org.vexi-core.main/src/main/jpp/org/vexi/core/Vexi.jpp        
2011-02-05 14:53:12 UTC (rev 4021)
@@ -141,13 +141,6 @@
  * */
 
 
-/*@PAGE(concept=Running Vexi)
- * 
- * <p><i>TODO</i></p>
- * 
- * */
-
-
 /*@PAGE(concept=Biscuits)
  * 
  * <p>Biscuits are analgous to the browser concept of cookies, but only exist 
on the client side of
@@ -442,8 +435,8 @@
          * strings so they are human readable
          * @method
          * @param(js1)
-         * @param(js2)
-         * @param(... jsn)
+         * @param(name=js2,optional=true)
+         * @param(name=... jsn,optional=true)
          * @return(null) */
         case "trace": return VexiJS.script().get(name);
         


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
The modern datacenter depends on network connectivity to access resources
and provide services. The best practices for maximizing a physical server's
connectivity to a physical network are well understood - see how these
rules translate into the virtual world? 
http://p.sf.net/sfu/oracle-sfdevnlfb
_______________________________________________
Vexi-svn mailing list
Vexi-svn@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vexi-svn

Reply via email to