Login | Register
My pages Projects Community openCollabNet

Discussions > commits > svn commit: r157 - trunk/src: ise/antelope/common ise/antelope/plugin ise/antelope/tasks test

antelope
Discussion topic

Hide all messages in topic

All messages in topic

svn commit: r157 - trunk/src: ise/antelope/common ise/antelope/plugin ise/antelope/tasks test

Author danson
Full name Dale Anson
Date 2008-07-19 00:30:08 PDT
Message Author: danson
Date: 2008-07-19 00:30:07-0700
New Revision: 157

Modified:
   trunk/src/ise/antelo​pe/common/AntLogger.​java
   trunk/src/ise/antelo​pe/common/AntProgres​sListener.java
   trunk/src/ise/antelo​pe/common/AntelopePa​nel.java
   trunk/src/ise/antelo​pe/common/AntelopePr​ojectHelper2.java
   trunk/src/ise/antelo​pe/common/SAXNodeHan​dler.java
   trunk/src/ise/antelo​pe/common/version.tx​t
   trunk/src/ise/antelo​pe/plugin/AntelopePl​uginPanel.java
   trunk/src/ise/antelo​pe/plugin/ConsolePlu​ginHandler.java
   trunk/src/ise/antelo​pe/tasks/SplitTask.j​ava
   trunk/src/ise/antelo​pe/tasks/antelope.ta​skdefs
   trunk/src/ise/antelo​pe/tasks/antlib.xml
   trunk/src/test/antel​ope_task_test.xml
   trunk/src/test/fileu​til_test.xml

Log:
misc updates

Modified: trunk/src/ise/antelo​pe/common/AntLogger.​java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​AntLogger.java?view=​diff&rev=157​&p1=trunk/src/ise/an​telope/common/AntLog​ger.java&p2=trun​k/src/ise/antelope/c​ommon/AntLogger.java​&r1=156&r2=1​57
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/AntLogger.​java (original)
+++ trunk/src/ise/antelo​pe/common/AntLogger.​java 2008-07-19 00:30:07-0700
@@ -203,7 +203,7 @@
    private AntFileHandler fileHandler = null;
 
    /**
- * LogRecords can have parameters, the namespace is added as the only parameter.
+ * LogRecords can have parameters, the namespace is added as the only parameter.
     */
    private Object[] parameters = new String[]{NAMESPACE};
 
@@ -323,7 +323,7 @@
       open();
       log( " " );
       // note: ConsolePluginHandler uses this message to show the Console plugin,
- // so if you change this message, be sure to update the ConsolePluginHandler
+ // so if you change this message, be sure to update the ConsolePluginHandler
       log( Level.CONFIG, "===== BUILD STARTED =====" + lSep );
       startTime = System.currentTimeMillis();
    }
@@ -367,13 +367,13 @@
          log( Level.SEVERE, message.toString() );
       }
       message = new StringBuffer();
- message.append( "Total time: " );
- message.append( formatTime( System.currentTimeMillis() - startTime ) );
+ //message.append( "Total time: " );
+ //message.append( formatTime( System.currentTimeMillis() - startTime ) );
       message.append( lSep );
       // note: ConsolePluginHandler uses this message to set focus back to the buffer,
- // so if you change this message, be sure to update the ConsolePluginHandler
+ // so if you change this message, be sure to update the ConsolePluginHandler
       message.append( "===== BUILD FINISHED =====" ).append( lSep );
- message.append( new java.util.Date().toS​tring()).append(lSep​);
+ //message.append( new java.util.Date().toS​tring()).append(lSep​);
 
       String msg = message.toString();
       log( Level.CONFIG, msg );
@@ -489,7 +489,7 @@
       if ( message == null ) {
          message = "" ;
       }
-
+
       Log.log(this, message);
 
       // log the message
@@ -535,7 +535,7 @@
       return echo;
    }
 
-
+
    /**
     * Initializes the logger. This will install a ConsoleHandler by default.
     */
@@ -653,7 +653,7 @@
                         line = new StringBuffer();
                       }
                       else {
- line.append((byte)b);
+ line.append((byte)b);
                       }
                       */
                      byte[] bytes = {( byte ) b};

Modified: trunk/src/ise/antelo​pe/common/AntProgres​sListener.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​AntProgressListener.​java?view=diff&r​ev=157&p1=trunk/​src/ise/antelope/com​mon/AntProgressListe​ner.java&p2=trun​k/src/ise/antelope/c​ommon/AntProgressLis​tener.java&r1=15​6&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/AntProgres​sListener.java (original)
+++ trunk/src/ise/antelo​pe/common/AntProgres​sListener.java 2008-07-19 00:30:07-0700
@@ -54,6 +54,7 @@
 package ise.antelope.common;
 
 import ise.library.PrivilegedAccessor;
+import java.lang.reflect.Field;
 
 import java.awt.Color;
 import javax.swing.*;
@@ -179,6 +180,74 @@
      */
     public void taskStarted( BuildEvent be ) {
         // does nothing
+ /*
+ try {
+ Task task = be.getTask();
+ String name = task.getTaskName();
+ System.out.println("+++++ task name = " + name);
+ if ( "import".equals( name ) ) {
+ System.out.println( "+++++ executed an import task" );
+ if (task instanceof UnknownElement) {
+ UnknownElement ue = (UnknownElement)task;
+ ue.maybeConfigure();
+ task = ue.getTask();
+ String filename = ( String ) PrivilegedAccessor.getValue( task, "file" );
+ System.out.println("+++++ filename: " + filename);
+ File file = new File( filename );
+ String ph = System.getProperty("​org.apache.tools.ant​.ProjectHelper");
+ System.setProperty( "org.apache.tools.an​t.ProjectHelper", "ise.antelope.common​.AntelopeProjectHelp​er2" );
+ Project p = new Project();
+ p.init();
+ ProjectHelper helper = ProjectHelper.getPro​jectHelper();
+ p.addReference("ant.​projectHelper", helper);
+ helper.parse(p, file);
+ p.executeTarget( "" );
+ System.setProperty( "org.apache.tools.an​t.ProjectHelper", ph );
+
+ try {
+ Object property_helper = be.getProject().getReference( "ant.PropertyHelper" );
+ if ( property_helper != null ) {
+ try {
+ Hashtable build_properties = ( Hashtable ) getValue( property_helper, "properties" );
+ if ( build_properties != null ) {
+ Hashtable import_properties = (Hashtable)getValue( helper, "properties");
+ if (import_properties != null) {
+ build_properties.put​All(import_propertie​s);
+ }
+ }
+ }
+ catch ( Exception e ) {
+ // ignore
+ }
+ try {
+ Hashtable build_user_properties = ( Hashtable ) getValue( property_helper, "userProperties" );
+ if ( build_user_properties != null ) {
+ Hashtable import_user_properties = (Hashtable)getValue( helper, "userProperties");
+ if (import_user_properties != null) {
+ build_user_propertie​s.putAll(import_user​_properties);
+ }
+ }
+ }
+ catch ( Exception e ) {
+ // ignore
+ }
+ }
+ ComponentHelper build_component_helper = ComponentHelper.getC​omponentHelper(be.ge​tProject());
+ ComponentHelper import_component_helper = ComponentHelper.getC​omponentHelper(p);
+ Hashtable bch_dtd = build_component_help​er.getDataTypeDefini​tions();
+ Hashtable ich_dtd = import_component_hel​per.getDataTypeDefin​itions();
+ bch_dtd.putAll(ich_dtd);
+ }
+ catch ( Exception e ) {
+ // ignore, could be Ant 1.5
+ }
+ }
+ }
+ }
+ catch ( Exception e ) {
+ e.printStackTrace();
+ }
+ */
     }
 
     /**
@@ -433,4 +502,23 @@
         }
         return map;
     }
+
+ private Object getValue( Object instance, String fieldName )
+ throws IllegalAccessException, NoSuchFieldException {
+ Field field = getField( instance.getClass(), fieldName );
+ field.setAccessible( true );
+ return field.get( instance );
+ }
+ private Field getField( Class thisClass, String fieldName ) throws NoSuchFieldException {
+ if ( thisClass == null ) {
+ throw new NoSuchFieldException( "Invalid field : " + fieldName );
+ }
+ try {
+ return thisClass.getDeclaredField( fieldName );
+ }
+ catch ( NoSuchFieldException e ) {
+ return getField( thisClass.getSuperclass(), fieldName );
+ }
+ }
+
 }

Modified: trunk/src/ise/antelo​pe/common/AntelopePa​nel.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​AntelopePanel.java?v​iew=diff&rev=157​&p1=trunk/src/is​e/antelope/common/An​telopePanel.java​&p2=trunk/src/ise/an​telope/common/Antelo​pePanel.java&r1=​156&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/AntelopePa​nel.java (original)
+++ trunk/src/ise/antelo​pe/common/AntelopePa​nel.java 2008-07-19 00:30:07-0700
@@ -94,7 +94,6 @@
     private ArrayList _execute_targets = null;
     private DeckPanel _center_panel = null;
     private JPanel _button_panel = null;
- private JTabbedPane _tabs = null;
     private SAXPanel _sax_panel = null;
 
     private JPanel _control_panel = null;
@@ -135,7 +134,6 @@
 
     // basic logger settings
     private Logger _logger = null;
- private Handler _console = null;
     private Level _log_level = Level.ALL;
 
     /** Description of the Field */
@@ -260,12 +258,11 @@
                     _edit = false;
                     _trace = false;
                     _center_panel.show( "panel" );
- _button_panel.setBackground( Color.WHITE );
+ _button_panel.setBackground( AntelopePanel.this.g​etBackground() );
                 }
             }
         );
- if ( _helper != null ) {
- if ( _helper.getRunButtonAction() != null )
+ if ( _helper != null && helper.getRunButtonAction() != null ) {
                 _run_btn.addActionListener( _helper.getRunButtonAction() );
         }
         _run_btn.setSelected( true );
@@ -284,8 +281,7 @@
                 }
             }
         );
- if ( _helper != null ) {
- if ( _helper.getTraceButtonAction() != null )
+ if ( _helper != null && _helper.getTraceButtonAction() != null ) {
                 _trace_btn.addActionListener( _helper.getTraceButtonAction() );
         }
 
@@ -599,7 +595,6 @@
         new ActionListener() {
             public void actionPerformed( ActionEvent ae ) {
                 final ActionEvent event = ae;
- final AbstractButton button;
                 final String target_name = event.getActionCommand();
 
                 // maybe stop any running targets
@@ -1010,13 +1005,12 @@
             }
             if ( _button_panel == null ) {
                 _button_panel = new JPanel( new KappaLayout() );
- _button_panel.setBackground( Color.white );
+ _button_panel.setBackground( AntelopePanel.this.g​etBackground() );
                 _button_panel.setBorder( new javax.swing.border.EmptyBorder( 3, 3, 3, 3 ) );
                 _scroller = new JScrollPane( _button_panel );
                 _scroller.getVertica​lScrollBar().setUnit​Increment(50);
                 _btn_container = new JPanel( new BorderLayout() );
                 _btn_container.add( _scroller, BorderLayout.CENTER );
- JPanel multi_panel = new JPanel();
                 _btn_container.add( _multi, BorderLayout.SOUTH );
             }
             else {
@@ -1074,7 +1068,6 @@
                     loadPropertyFiles();
 
                     // set up "Execute" button for multiple targets
- ArrayList last_used_targets = null;
                     if ( new_file ) {
                         _multi.setSelected( _settings.getMultipleTargets() );
                     }
@@ -1237,7 +1230,7 @@
                             button.setText( btn_text );
                             button.addActionListener( _cb_listener );
                             button.setBackground( _button_panel.getBackground() );
- if ( node.isDefaultTarget() )
+ if ( node != null && node.isDefaultTarget() )
                                 _default_btn = button;
                         }
                         else {
@@ -1358,7 +1351,7 @@
             }
 
             // add the gui input handler
- setInputHandler( p, "ise.antelope.common​.AntInputHandler" );
+ setInputHandler( p );
 
             p.init(); // this takes as much as 9 seconds the first time, less than 1/2 second later
 
@@ -1487,7 +1480,7 @@
         }
     }
 
- private void setInputHandler( Project p, String inputHandler ) {
+ private void setInputHandler( Project p ) {
         try {
             AntInputHandler ih = new AntInputHandler(Ante​lopePanel.this);
             PrivilegedAccessor.i​nvokeMethod( p, "setInputHandler", new Object[] {ih} );
@@ -1592,7 +1585,7 @@
         try {
             recent = Constants.PREFS.get( Constants.RECENT_LIST, "" );
         }
- catch ( Exception e ) {}
+ catch ( Exception e ) {} // NOPMD
         ActionListener al =
             new ActionListener() {
                 public void actionPerformed( ActionEvent ae ) {
@@ -1622,7 +1615,7 @@
         try {
             recent = Constants.PREFS.get( Constants.RECENT_LIST, "" );
         }
- catch ( Exception e ) {}
+ catch ( Exception e ) {} // NOPMD
         StringTokenizer st = new StringTokenizer( recent, File.pathSeparator );
         while ( st.hasMoreTokens() ) {
             String filename = st.nextToken();
@@ -1654,7 +1647,7 @@
         try {
             recent = Constants.PREFS.get( Constants.RECENT_LIST, "" );
         }
- catch ( Exception e ) {}
+ catch ( Exception e ) {} // NOPMD
         if ( recent.startsWith( last_used.getAbsolutePath() ) )
             return ;
         ArrayList list = new ArrayList();

Modified: trunk/src/ise/antelo​pe/common/AntelopePr​ojectHelper2.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​AntelopeProjectHelpe​r2.java?view=diff​&rev=157&p1=tru​nk/src/ise/antelope/​common/AntelopeProje​ctHelper2.java&p​2=trunk/src/ise/ante​lope/common/Antelope​ProjectHelper2.java​&r1=156&r2=15​7
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/AntelopePr​ojectHelper2.java (original)
+++ trunk/src/ise/antelo​pe/common/AntelopePr​ojectHelper2.java 2008-07-19 00:30:07-0700
@@ -166,7 +166,7 @@
 
     /* executes the <property> targets in the implicit target so the imported
     targets show up in the Antelope panel. */
- private void executeImplicitProperties( Project project, Target implicit ) {
+ public void executeImplicitProperties( Project project, Target implicit ) {
         Task[] tasks = implicit.getTasks();
         for ( int i = 0; i < tasks.length; i++ ) {
             if ( tasks[ i ].getTaskName().equals( "property" ) ) {
@@ -178,7 +178,7 @@
 
     /* executes the <import> targets in the implicit target so the imported
     targets show up in the Antelope panel. */
- private void executeImplicitImports( Project project, Target implicit ) {
+ public void executeImplicitImports( Project project, Target implicit ) {
         Task[] tasks = implicit.getTasks();
         for ( int i = 0; i < tasks.length; i++ ) {
             if ( tasks[ i ].getTaskName().equals( "import" ) ) {
@@ -199,7 +199,10 @@
      */
     public void parse( Project project, Object source, RootHandler handler )
     throws BuildException {
-
+ System.out.println("+++++ source: " + source.toString());
+ if (source != null) {
+ System.out.println("+++++ source is a " + source.getClass().getName());
+ }
         AntXMLContext context = handler.context;
 
         File buildFile = null;
@@ -228,6 +231,7 @@
             throw new BuildException( "Source " + source.getClass().getName()
                     + " not supported by this plugin" );
         }
+ System.out.println("+++++ buildFileName: " + buildFileName);
 
         InputStream inputStream = null;
         InputSource inputSource = null;
@@ -241,6 +245,7 @@
 
             String uri = null;
             if ( buildFile != null ) {
+ System.out.println("+++++ buildFile = " + buildFile + ", absolutePath = " + buildFile.getAbsolutePath());
                 uri = fu.toURI( buildFile.getAbsolutePath() );
                 inputStream = new FileInputStream( buildFile );
             }

Modified: trunk/src/ise/antelo​pe/common/SAXNodeHan​dler.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​SAXNodeHandler.java?​view=diff&rev=15​7&p1=trunk/src/i​se/antelope/common/S​AXNodeHandler.java​&p2=trunk/src/ise/​antelope/common/SAXN​odeHandler.java&​r1=156&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/SAXNodeHan​dler.java (original)
+++ trunk/src/ise/antelo​pe/common/SAXNodeHan​dler.java 2008-07-19 00:30:07-0700
@@ -52,11 +52,11 @@
     private Logger _logger = Logger.getLogger("is​e.antelope.Antelope"​);
 
     // need to update occassionally as new versions of Ant are released.
- // these lists are from Ant 1.6.1.
+ // these lists are from Ant 1.7.0.
     // -- shouldn't need these any longer, the lists are now loaded from the default.properties
     // files from Ant itself, see the init() method.
- private List default_taskList = Arrays.asList(new String[]{"propertyfile", "importtypelib", "vsscheckin", "sql", "cvspass", "p4reopen", "csc", "dirname", "wlrun", "p4label", "p4revert", "replaceregexp", "get", "jjtree", "sleep", "jarlib-display", "dependset", "zip", "patch", "jspc", "style", "test", "tstamp", "unwar", "vsshistory", "icontract", "cvschangelog", "p4submit", "ccmcheckin", "p4change", "bzip2", "sync", "p4delete", "vssadd", "javadoc", "p4integrate", "translate", "signjar", "cclock", "chown", "vajload", "jarlib-available", "WsdlToDotnet", "buildnumber", "jpcovmerge", "ejbjar", "war", "rename", "sequential", "serverdeploy", "property", "subant", "move", "ildasm", "copydir", "cccheckin", "ccunlock", "wljspc", "fixcrlf", "sosget", "pathconvert", "record", "p4sync", "exec", "ccmklabel", "p4edit", "manifest", "maudit", "antlr", "netrexxc", "jpcovreport", "execon", "ccmcheckout", "ant", "xmlvalidate", "xslt", "p4resolve", "iplanet-ejbc", "ccmcheckintask", "gzip", "native2ascii", "ccrmtype", "starteam", "ear", "input", "presetdef", "rmic", "checksum", "mail", "loadfile", "vsscheckout", "stylebook", "soscheckin", "mimemail", "stlabel", "gunzip", "concat", "cab", "touch", "parallel", "splash", "antcall", "ccmkbl", "cccheckout", "typedef", "p4have", "filter", "xmlproperty", "import", "copy", "jsharpc", "symlink", "antstructure", "script", "ccmcreatetask", "rpm", "delete", "replace", "mmetrics", "attrib", "waitfor", "untar", "loadproperties", "available", "echoproperties", "chgrp", "vajexport", "bunzip2", "whichresource", "copyfile", "p4labelsync", "vsscreate", "macrodef", "ejbc", "unjar", "vbc", "wsdltodotnet", "mkdir", "condition", "cvs", "tempfile", "junitreport", "taskdef", "echo", "ccupdate", "java", "vsslabel", "renameext", "basename", "javadoc2", "tar", "vsscp", "vajimport", "p4fstat", "setproxy", "p4counter", "wlstop", "ilasm", "soscheckout", "apply", "ccuncheckout", "jarlib-resolve", "jlink", "cvstagdiff", "javacc", "chmod", "pvcs", "jarlib-manifest", "jar", "ccmklbtype", "sound", "scriptdef", "defaultexcludes", "mparse", "blgenclient", "uptodate", "jjdoc", "genkey", "javah", "ccmreconfigure", "fail", "unzip", "javac", "p4add", "jpcoverage", "soslabel", "depend", "vssget", "deltree", "ddcreator"});
- private List default_typeList = Arrays.asList(new String[]{"patternset", "assertions", "propertyset", "filterset", "libfileset", "filterreader", "scriptfilter", "extension", "fileset", "dirset", "filelist", "filterchain", "path", "classfileset", "selector", "xmlcatalog", "description", "mapper", "zipfileset", "substitution", "extensionSet", "regexp"});
+ private List default_taskList = Arrays.asList(new String[]{"ant", "antcall", "antstructure", "apply", "available", "basename", "buildnumber", "bunzip2", "bzip2", "checksum", "chmod", "classloader", "concat", "condition", "copy", "cvs", "cvschangelog", "cvspass", "cvstagdiff", "cvsversion", "defaultexcludes", "delete", "dependset", "diagnostics", "dirname", "ear", "echo", "exec", "fail", "filter", "fixcrlf", "genkey", "get", "gunzip", "gzip", "import", "input", "jar", "java", "javac", "javadoc", "length", "loadfile", "loadproperties", "loadresource", "macrodef", "mail", "manifest", "manifestclasspath", "mkdir", "move", "nice", "parallel", "patch", "pathconvert", "presetdef", "property", "record", "replace", "rmic", "sequential", "signjar", "sleep", "sql", "subant", "sync", "tar", "taskdef", "tempfile", "touch", "tstamp", "typedef", "unjar", "untar", "unwar", "unzip", "uptodate", "waitfor", "war", "whichresource", "xmlproperty", "xslt", "zip", "antlr", "apt", "attrib", "blgenclient", "cab", "cccheckin", "cccheckout", "cclock", "ccmcheckin", "ccmcheckintask", "ccmcheckout", "ccmcreatetask", "ccmkattr", "ccmkbl", "ccmkdir", "ccmkelem", "ccmklabel", "ccmklbtype", "ccmreconfigure", "ccrmtype", "ccuncheckout", "ccunlock", "ccupdate", "chgrp", "chown", "csc", "ddcreator", "depend", "echoproperties", "echoxml", "ejbc", "ejbjar", "ftp", "ilasm", "ildasm", "image", "importtypelib", "iplanet-ejbc", "jarlib-available", "jarlib-display", "jarlib-manifest", "jarlib-resolve", "javacc", "javah", "jdepend", "jjdoc", "jjtree", "jsharpc", "jspc", "junit", "junitreport", "makeurl", "native2ascii", "netrexxc", "p4add", "p4change", "p4counter", "p4delete", "p4edit", "p4fstat", "p4have", "p4integrate", "p4label", "p4labelsync", "p4reopen", "p4resolve", "p4revert", "p4submit", "p4sync", "propertyfile", "pvcs", "replaceregexp", "resourcecount", "rexec", "rpm", "schemavalidate", "scp", "script", "scriptdef", "serverdeploy", "setproxy", "soscheckin", "soscheckout", "sosget", "soslabel", "sound", "splash", "sshexec", "stcheckin", "stcheckout", "stlabel", "stlist", "stylebook", "symlink", "telnet", "translate", "vbc", "verifyjar", "vssadd", "vsscheckin", "vsscheckout", "vsscp", "vsscreate", "vssget", "vsshistory", "vsslabel", "wljspc", "wlrun", "wlstop", "wsdltodotnet", "xmlvalidate", "copydir", "copyfile", "copypath", "deltree", "execon", "javadoc2", "jlink", "mimemail", "rename", "renameext", "starteam", "style", "WsdlToDotnet"});
+ private List default_typeList = Arrays.asList(new String[]{"description", "filterchain", "filterreader", "filterset", "mapper", "redirector", "patternset", "regexp", "substitution", "xmlcatalog", "extensionSet", "extension", "selector", "signedselector", "scriptfilter", "assertions", "concatfilter", "mavenrepository", "scriptselector", "scriptmapper", "identitymapper", "flattenmapper", "globmapper", "mergemapper", "regexpmapper", "packagemapper", "unpackagemapper", "compositemapper", "chainedmapper", "filtermapper", "isfileselected", "scriptcondition", "dirset", "filelist", "fileset", "path", "propertyset", "zipfileset", "classfileset", "libfileset", "files", "restrict", "union", "difference", "intersect", "sort", "resources", "first", "tarfileset", "tokens", "resource", "file", "url", "string", "zipentry", "propertyresource", "tarentry", "gzipresource", "bzip2resource", "javaresource", "linetokenizer", "stringtokenizer", "filetokenizer"});
     private List taskList = default_taskList;
     private List typeList = default_typeList;
 

Modified: trunk/src/ise/antelo​pe/common/version.tx​t
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/common/​version.txt?view=dif​f&rev=157&p1​=trunk/src/ise/antel​ope/common/version.t​xt&p2=trunk/src/​ise/antelope/common/​version.txt&r1=1​56&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/common/version.tx​t (original)
+++ trunk/src/ise/antelo​pe/common/version.tx​t 2008-07-19 00:30:07-0700
@@ -1,2 +1,2 @@
-VERSION=3.4.0
-DATE=March 24 2007
\ No newline at end of file
+VERSION=3.4.5
+DATE=July 19 2008
\ No newline at end of file

Modified: trunk/src/ise/antelo​pe/plugin/AntelopePl​uginPanel.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/plugin/​AntelopePluginPanel.​java?view=diff&r​ev=157&p1=trunk/​src/ise/antelope/plu​gin/AntelopePluginPa​nel.java&p2=trun​k/src/ise/antelope/p​lugin/AntelopePlugin​Panel.java&r1=15​6&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/plugin/AntelopePl​uginPanel.java (original)
+++ trunk/src/ise/antelo​pe/plugin/AntelopePl​uginPanel.java 2008-07-19 00:30:07-0700
@@ -47,25 +47,19 @@
 */
 package ise.antelope.plugin;
 
-
-import java.awt.Component;
+import java.awt.Color;
 import java.awt.Dimension;
 import java.awt.Point;
 import java.awt.event.ActionListener;
 import java.awt.event.ActionEvent;
 import java.io.*;
-import java.lang.reflect.Constructor;
 import java.util.*;
-import java.util.prefs.Preferences;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 import java.util.jar.*;
 import javax.swing.*;
-import ise.library.Log;
 import org.gjt.sp.jedit.jEdit;
 import org.gjt.sp.jedit.View;
-import org.gjt.sp.jedit.EditPlugin;
-import org.gjt.sp.jedit.PluginJAR;
 import org.gjt.sp.jedit.gui​.DockableWindowManag​er;
 import org.gjt.sp.jedit.io.VFSManager;
 
@@ -73,7 +67,6 @@
 import errorlist.*;
 
 import ise.antelope.common.*;
-import ise.library.PrivilegedAccessor;
 
 /**
  * This is the panel displayed and manipulated by jEdit. It wraps the
@@ -95,7 +88,7 @@
      * the preferred size may or may not be set.
      *
      * Initially, this shows a "Loading Ant..." message. The actual loading of
- * Ant happens in the Plugin class and in the <code>init()</code> method. Once
+ * Ant happens in the Plugin class and in the <code>init()</code> method. Once
      * Ant is loaded, the AntelopePanel is shown.
      *
      * @param position this is passed in by the DockableWindowManager, it will
@@ -104,7 +97,7 @@
      */
     public AntelopePluginPanel( View view, String position ) {
         super( new java.awt.BorderLayout() );
- setBackground( java.awt.Color.WHITE );
+ setBackground( jEdit.getColorProper​ty("view.bgColor", Color.WHITE) );
         _view = view;
         JLabel label = new JLabel( "<html><cen​ter><b><​i>Please wait,<p>Loading Ant...</i><​/b></center​></html>", SwingConstants.CENTER );
         add( label );
@@ -167,6 +160,7 @@
                         // create and add Antelope
                         try {
                             antelopePanel = new AntelopePanel( file, new CommonHelperWrapper( AntelopePluginPanel.this ), true, menu_items );
+ antelopePanel.setBackground( jEdit.getColorProper​ty("view.bgColor", Color.WHITE) );
                         }
                         catch ( Throwable t ) {
                             t.printStackTrace();
@@ -176,7 +170,7 @@
                             return ;
                         }
                         removeAll();
- setBackground( java.awt.Color.WHITE );
+ setBackground( jEdit.getColorProper​ty("view.bgColor", Color.WHITE) );
                         add( antelopePanel );
                         AntelopePlugin.addPanel( _view, AntelopePluginPanel.this );
 
@@ -395,7 +389,7 @@
                             }
                         );
                     }
- catch ( Exception e ) {
+ catch ( Exception e ) { // NOPMD
                         // ignore this
                     }
                 }
@@ -432,6 +426,7 @@
         }
     }
 
+ /*
     private Class loadAnt() {
         try {
             File jar_file = AntelopePlugin.getAn​telopePluginJAR().ge​tFile();
@@ -443,4 +438,5 @@
             return null;
         }
     }
+ */
 }

Modified: trunk/src/ise/antelo​pe/plugin/ConsolePlu​ginHandler.java
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/plugin/​ConsolePluginHandler​.java?view=diff&​rev=157&p1=trunk​/src/ise/antelope/pl​ugin/ConsolePluginHa​ndler.java&p2=tr​unk/src/ise/antelope​/plugin/ConsolePlugi​nHandler.java&r1​=156&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/plugin/ConsolePlu​ginHandler.java (original)
+++ trunk/src/ise/antelo​pe/plugin/ConsolePlu​ginHandler.java 2008-07-19 00:30:07-0700
@@ -1,13 +1,14 @@
 package ise.antelope.plugin;
 
 import java.awt.Color;
+import java.awt.Font;
 import java.util.logging.Handler;
 import java.util.logging.Level;
 import java.util.logging.LogRecord;
 import console.*;
 import errorlist.*;
+import org.gjt.sp.jedit.jEdit;
 import org.gjt.sp.jedit.View;
-import ise.library.Log;
 import org.gjt.sp.jedit.gui​.DockableWindowManag​er;
 
 
@@ -24,12 +25,16 @@
     private Console console = null;
     private AntelopeShell shell = null;
     private Color GREEN = new Color( 0, 153, 51 );
+ private Color YELLOW = new Color(0xefef8f);
+ private Color RED = new Color(0xff4444);
+ private Color foreground;
 
     public ConsolePluginHandler( AntelopePluginPanel panel ) {
         _panel = panel;
         view = panel.getView();
         error_source = panel.getErrorSource();
         setupConsole();
+ foreground = jEdit.getColorProper​ty("view.fgColor");
     }
 
     public ConsolePluginHandler( View view, DefaultErrorSource es ) {
@@ -48,6 +53,8 @@
             console = ( Console ) mgr.getDockable( "console" );
         }
         console.setShell( shell );
+ Font font = view.getEditPane().g​etTextArea().getPain​ter().getFont();
+ console.getConsolePa​ne().setFont(font);
     }
 
 
@@ -57,13 +64,13 @@
      * @param record a LogRecord
      */
     public void publish( LogRecord record ) {
-
+
         /* some jedit 'update' messages get dumped on System.out, which is what
         Ant writes to, so those messages end up here mixed with the Ant output.
         This may not be sufficient, but all I've seen so far are DockableWindowUpdate
         and ErrorSourceUpdate messages, so this regex works for now. */
         if (record.getMessage()​.matches("(.*)?(Upda​te\\[)(.*)")) {
- return;
+ return;
         }
         if ( _panel.getBuildFile() == null ) {
             return ;
@@ -115,12 +122,12 @@
 
     private Color getColorForLevel( Level level ) {
         if ( level.equals( Level.SEVERE ) )
- return Color.RED;
+ return RED;
         if ( level.equals( Level.CONFIG ) )
- return Color.BLACK;
+ return YELLOW;
         if ( level.equals( Level.WARNING ) )
             return GREEN;
- return Color.BLUE;
+ return foreground;
     }
 
     /**

Modified: trunk/src/ise/antelo​pe/tasks/SplitTask.j​ava
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/tasks/S​plitTask.java?view=d​iff&rev=157&​p1=trunk/src/ise/ant​elope/tasks/SplitTas​k.java&p2=trunk/​src/ise/antelope/tas​ks/SplitTask.java​&r1=156&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/tasks/SplitTask.j​ava (original)
+++ trunk/src/ise/antelo​pe/tasks/SplitTask.j​ava 2008-07-19 00:30:07-0700
@@ -320,12 +320,12 @@
         if ( size <= BUFFER_SIZE ) {
             buffer_size = size;
         }
- byte[] buffer = new byte[ Math.min( BUFFER_SIZE, size ) ];
+ byte[] buffer = new byte[ java.lang.Math.min( BUFFER_SIZE, size ) ];
         int bytes_read;
         int total = 0;
         int offset = 0;
         while ( true ) {
- bytes_read = from.read( buffer, 0, Math.min( buffer_size, size - offset ) );
+ bytes_read = from.read( buffer, 0, java.lang.Math.min( buffer_size, size - offset ) );
             if ( bytes_read == -1 )
                 break;
             to.write( buffer, 0, bytes_read );

Modified: trunk/src/ise/antelo​pe/tasks/antelope.ta​skdefs
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/tasks/a​ntelope.taskdefs?vie​w=diff&rev=157​&p1=trunk/src/ise/​antelope/tasks/antel​ope.taskdefs&p2=​trunk/src/ise/antelo​pe/tasks/antelope.ta​skdefs&r1=156​&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/tasks/antelope.ta​skdefs (original)
+++ trunk/src/ise/antelo​pe/tasks/antelope.ta​skdefs 2008-07-19 00:30:07-0700
@@ -17,7 +17,7 @@
 if=ise.antelope.tasks.IfTask
 limit=ise.antelope.tasks.Limit
 math=ise.antelope.ta​sks.MathTask
-new=ise.antelope.tasks.New
+#new=ise.antelope.tasks.New
 pw=ise.antelope.task​s.PasswordHandlerTas​k
 post=ise.antelope.ta​sks.PostTask
 readlog=ise.antelope​.tasks.ReadLog
@@ -33,7 +33,7 @@
 unset=ise.antelope.tasks.Unset
 until=ise.antelope.t​asks.BooleanConditio​nTask
 var=ise.antelope.tasks.Variable
-xmlprop=ise.antelop​e.tasks.XmlPropertyT​ask
+#xmlprop=ise.antelo​pe.tasks.XmlProperty​Task
 
 prop=ise.antelope.ta​sks.typedefs.Prop
 

Modified: trunk/src/ise/antelo​pe/tasks/antlib.xml
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​ise/antelope/tasks/a​ntlib.xml?view=diff​&rev=157&p1=t​runk/src/ise/antelop​e/tasks/antlib.xml​&p2=trunk/src/ise/​antelope/tasks/antli​b.xml&r1=156​&r2=157
====================​====================​====================​==================
--- trunk/src/ise/antelo​pe/tasks/antlib.xml (original)
+++ trunk/src/ise/antelo​pe/tasks/antlib.xml 2008-07-19 00:30:07-0700
@@ -21,7 +21,6 @@
    <taskdef name="if" classname="ise.antel​ope.tasks.IfTask"/​>
    <taskdef name="limit" classname="ise.antel​ope.tasks.Limit"/​>
    <taskdef name="math" classname="ise.antel​ope.tasks.MathTask"/​>
- <taskdef name="new" classname="ise.antel​ope.tasks.New"/>
    <taskdef name="pw" classname="ise.antel​ope.tasks.PasswordHa​ndlerTask"/>
    <taskdef name="post" classname="ise.antel​ope.tasks.PostTask"/​>
    <taskdef name="readlog" classname="ise.antel​ope.tasks.ReadLog"/​>
@@ -37,10 +36,9 @@
    <taskdef name="unset" classname="ise.antel​ope.tasks.Unset"/​>
    <taskdef name="until" classname="ise.antel​ope.tasks.BooleanCon​ditionTask"/>
    <taskdef name="var" classname="ise.antel​ope.tasks.Variable"/​>
- <taskdef name="xmlprop" classname="ise.antel​ope.tasks.XmlPropert​yTask"/>
-
+
    <typedef name="prop" classname="ise.antel​ope.tasks.typedefs.P​rop"/>
-
+
    <typedef name="contains" classname="ise.antel​ope.tasks.condition.​Contains"/>
    <typedef name="datedifference" classname="ise.antel​ope.tasks.condition.​DateTimeDifference"/​>
    <typedef name="timedifference" classname="ise.antel​ope.tasks.condition.​DateTimeDifference"/​>
@@ -51,11 +49,11 @@
    <typedef name="mathequals" classname="ise.antel​ope.tasks.condition.​MathEquals"/>
    <typedef name="endswith" classname="ise.antel​ope.tasks.condition.​EndsWith"/>
    <typedef name="startswith" classname="ise.antel​ope.tasks.condition.​StartsWith"/>
-
+
    <typedef name="and" classname="ise.antel​ope.tasks.condition.​And"/>
    <typedef name="or" classname="ise.antel​ope.tasks.condition.​Or"/>
    <typedef name="not" classname="ise.antel​ope.tasks.condition.​Not"/>
-
+
    <typedef name="lowercase" classname="ise.antel​ope.tasks.typedefs.s​tring.LowerCase"/​>
    <typedef name="uppercase" classname="ise.antel​ope.tasks.typedefs.s​tring.UpperCase"/​>
    <typedef name="trim" classname="ise.antel​ope.tasks.typedefs.s​tring.Trim"/>
@@ -66,7 +64,7 @@
    <typedef name="length" classname="ise.antel​ope.tasks.typedefs.s​tring.Length"/>
    <typedef name="messagebox" classname="ise.antel​ope.tasks.typedefs.s​tring.MessageBox"/​>
    <typedef name="sort" classname="ise.antel​ope.tasks.typedefs.s​tring.Sort"/>
-
+
    <typedef name="canread" classname="ise.antel​ope.tasks.typedefs.f​ile.CanRead"/>
    <typedef name="canwrite" classname="ise.antel​ope.tasks.typedefs.f​ile.CanWrite"/>
    <typedef name="filecount" classname="ise.antel​ope.tasks.typedefs.f​ile.FileCount"/>
@@ -76,5 +74,5 @@
    <typedef name="isdirectory" classname="ise.antel​ope.tasks.typedefs.f​ile.IsDirectory"/​>
    <typedef name="isfile" classname="ise.antel​ope.tasks.typedefs.f​ile.IsFile"/>
    <typedef name="lastmodified" classname="ise.antel​ope.tasks.typedefs.f​ile.LastModified"/​>
-
+
 </antlib>

Modified: trunk/src/test/antel​ope_task_test.xml
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​test/antelope_task_t​est.xml?view=diff​&rev=157&p1=tru​nk/src/test/antelope​_task_test.xml&p​2=trunk/src/test/ant​elope_task_test.xml​&r1=156&r2=15​7
====================​====================​====================​==================
--- trunk/src/test/antel​ope_task_test.xml (original)
+++ trunk/src/test/antel​ope_task_test.xml 2008-07-19 00:30:07-0700
@@ -2,7 +2,7 @@
 <project name="antelope_task_test" default="test" basedir=".">
 
    <typedef resource="ise/antelo​pe/tasks/antelope.ta​skdefs"
- classpath="${ant.li​brary.dir}/AntelopeT​asks_3.2.19.jar"/​>
+ classpath="${ant.li​brary.dir}/AntelopeT​asks_3.4.2.jar"/>​
 
    <target name="test">
       <suite name="Antelope Task Tests">
@@ -23,7 +23,8 @@
          <testcase file="repeattest.xml" enabled="false"/>
          <testcase file="unset_test.xml" enabled="false"/>
          <testcase file="split_test.xml" enabled="false"/>
- <testcase file="stringutil_test.xml" enabled="true"/>
+ <testcase file="fileutil_test.xml" enabled="true"/>
+ <testcase file="stringutil_test.xml" enabled="false"/>
          <testcase file="uid_test.xml" enabled="false"/>
          <testcase file="trycatch_test.xml" enabled="false"/>
          <testcase file="hostname_test.xml" enabled="false"/>

Modified: trunk/src/test/fileu​til_test.xml
Url: http://antelope.tigr​is.org/source/browse​/antelope/trunk/src/​test/fileutil_test.x​ml?view=diff&rev​=157&p1=trunk/sr​c/test/fileutil_test​.xml&p2=trunk/sr​c/test/fileutil_test​.xml&r1=156&​r2=157
====================​====================​====================​==================
--- trunk/src/test/fileu​til_test.xml (original)
+++ trunk/src/test/fileu​til_test.xml 2008-07-19 00:30:07-0700
@@ -3,19 +3,21 @@
    <description>
       Tests for the FileUtil task.
    </description>
-
+
    <target name="setUp">
-
+
    </target>
-
+
    <target name="test1">
- <length property="output" mode="each">
- <fileset dir="${ant.library.dir}">
- <include name="*.jar"/>
- </fileset>
- </length>
- <echo>${outpu​t}</echo>
+ <fileutil file="${ant.library.dir}" property="file_list">
+ <listfiles includepath="false"/>
+ </fileutil>
+
+ <stringutil string="${file_list}" property="first_8">
+ <substring endindex="8"/>
+ </stringutil>
+ <echo>first 8 characters of file name = ${first_8}</echo>
    </target>
-</project>
-
+</project>
+
Messages per page: