Java Doc for JarBundler.java in  » Swing-Library » jEdit » net » sourceforge » jarbundler » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Swing Library » jEdit » net.sourceforge.jarbundler 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


net.sourceforge.jarbundler.JarBundler

JarBundler
public class JarBundler extends MatchingTask (Code)

An ant task which creates a Mac OS X Application Bundle for a Java application.

dir
The directory into which to put the new application bundle.
name
The name of the application bundle. Note that the maximum length of this name is 16 characters, and it will be silently cropped if it is longer than this.
mainclass
The main Java class to call when running the application.

One of the following three MUST be used:

  1. jars Space or comma-separated list of JAR files to include.; OR
  2. One or more nested <jarfileset>s. These are normal ANT FileSets; OR
  3. One or more nested <jarfilelist>s. These are standard ANT FileLists.

Optional attributes:

The following attributes are not required, but you can use them to override default behavior.

verbose
If true, show more verbose output while running the task
version
Version information about your application (e.g., "1.0")
infostring
String to show in the "Get Info" dialog
These attributes control the fine-tuning of the "Mac OS X" look and feel.
arguments
Command line arguments. (no default)
smalltabs
Use small tabs. (default "false") Deprecated under JVM 1.4.1
antialiasedgraphics
Use anti-aliased graphics (default "false")
antialiasedtext
Use anti-aliased text (default "false")
bundleid
Unique identifier for this bundle, in the form of a Java package. No default.
buildnumber
Unique identifier for this build
developmentregion
Development Region. Default "English".
execs
Files to be copied into "Resources/MacOS" and made executable
liveresize
Use "Live resizing" (default "false") Deprecated under JVM 1.4.1
growbox
Show growbox (default "true")
growboxintrudes
Intruding growbox (default "false") Deprecated under JVM 1.4.1
screenmenu
Put swing menu into Mac OS X menu bar.
type
Bundle type (default "APPL")
signature
Bundle Signature (default "????")
stubfile
The Java Application Stub file to copy for your application (default MacOS system stub file)

Rarely used optional attributes.

chmod
Full path to the chmod command. This almost certainly does NOT need to be set.

The task also supports nested <execfileset> and/or <execfilelist> elements, and <resourcefileset> and/or <resourcefilelist> elements, which are standard Ant FileSet and FileList elements. In the first case, the referenced files are copied to the Contents/MacOS directory and made executable, and in the second they are copied to the Contents/Resources directory and not made executable. If you winrces, note that in fact the files are installed in locations which have the same relation to the Contents/Resources directory as the files in the FileSet or FileList have to the 'dir' attribute. Thus in the case:

 <resourcefileset dir="builddir/architectures"
 includes="ppc/*.jnilib"/>
 

the *.jnilib files will be installed in Contents/Resources/ppc.

The task supports a nested <javaproperty> element, which allows you to specify further properties which are set for the JVM when the application is launched. This takes a required key attribute, giving the property key, plus an attribute giving the property value, which may be one of value, giving the string value of the property, file, setting the value of the property to be the absolute path of the given file, or path, which sets the value to the given path. If you are setting paths here, recall that, within the bundle, $APP_PACKAGE is set to the root directory of the bundle (ie, the path to the foo.app directory), and $JAVAROOT to the directory Contents/Resources/Java.

Minimum example:

 <jarbundler dir="release" name="Bar Project" mainclass="org.bar.Main"
 jars="bin/Bar.jar" />
 

Using Filesets

 <jarbundler dir="release" name="Bar Project" mainclass="org.bar.Main">
 <jarfileset dir="bin">
 <include name="*.jar" />
 <exclude name="test.jar" />
 </jarfileset>
 <execfileset dir="execs">
 <include name="**" />
 </execfileset>
 </jarbundler>
 

Much Longer example:

 <jarbundler dir="release"
 name="Foo Project"
 mainclass="org.bar.Main"
 version="1.0 b 1"
 infostring="Foo Project (c) 2002" 
 type="APPL"
 jars="bin/foo.jar bin/bar.jar"
 execs="exec/foobar"
 signature="????"
 workingdirectory="temp"
 icon="resources/foo.icns"
 jvmversion="1.4.1+"
 vmoptions="-Xmx256m"/>
 
http://developer.apple.com/documentation/MacOSX/Conceptual/BPRuntimeConfig/




Method Summary
public  voidaddConfiguredDocumentType(DocumentType documentType)
    
public  voidaddConfiguredHelpBook(HelpBook helpBook)
    
public  voidaddConfiguredJavaProperty(JavaProperty javaProperty)
    
public  voidaddConfiguredService(Service service)
    
public  voidaddExecfilelist(FileList fl)
    
public  voidaddExecfileset(FileSet fs)
    
public  voidaddExtraclasspathfilelist(FileList fl)
    
public  voidaddExtraclasspathfileset(FileSet fs)
    
public  voidaddJarfilelist(FileList fl)
    
public  voidaddJarfileset(FileSet fs)
    
public  voidaddJavafilelist(FileList fl)
    
public  voidaddJavafileset(FileSet fs)
    
public  voidaddResourcefilelist(FileList fl)
    
public  voidaddResourcefileset(FileSet fs)
    
public  voidexecute()
    
public  voidsetAboutmenuname(String s)
    
public  voidsetAntialiasedgraphics(boolean b)
    
public  voidsetAntialiasedtext(boolean b)
    
public  voidsetArguments(String s)
    
public  voidsetBuild(String s)
     Setter for the "buildnumber" attribute (optional) This key specifies the exact build version of the bundle.
public  voidsetBundleid(String s)
     Setter for the "bundleid" attribute (optional) This key specifies a unique identifier string for the bundle.
public  voidsetChmod(String s)
     Set the 'chmod' executable.
public  voidsetDevelopmentregion(String s)
     Setter for the "developmentregion" attribute(optional) Default "English".
public  voidsetDir(File f)
    
public  voidsetExecs(String s)
    
public  voidsetExtraclasspath(String s)
    
public  voidsetGrowbox(boolean b)
    
public  voidsetGrowboxintrudes(boolean b)
    
public  voidsetHelpBookFolder(String s)
    
public  voidsetHelpBookName(String s)
    
public  voidsetIcon(File f)
    
public  voidsetInfoString(String s)
     Setter for the "infostring" attribute (optional) This key identifies a human-readable plain text string displaying the copyright information for the bundle.
public  voidsetJar(File s)
    
public  voidsetJars(String s)
    
public  voidsetJvmversion(String s)
    
public  voidsetLiveresize(boolean b)
    
public  voidsetMainClass(String s)
    
public  voidsetName(String s)
    
public  voidsetScreenmenu(boolean b)
    
public  voidsetShortInfoString(String s)
     Setter for the "shortinfostring" attribute (optional) This key identifies the marketing version of the bundle.
public  voidsetShortName(String s)
     Setter for the "shortname" attribute (optional) This key identifies the short name of the bundle.
public  voidsetShowPlist(boolean showPlist)
    
public  voidsetSignature(String s)
    
public  voidsetSmallTabs(boolean b)
    
public  voidsetStubFile(File file)
    
public  voidsetType(String s)
    
public  voidsetVerbose(boolean verbose)
    
public  voidsetVersion(String s)
     Setter for the version attribute (optional).
public  voidsetVmoptions(String s)
    
public  voidsetWorkingDirectory(String s)
    



Method Detail
addConfiguredDocumentType
public void addConfiguredDocumentType(DocumentType documentType) throws BuildException(Code)



addConfiguredHelpBook
public void addConfiguredHelpBook(HelpBook helpBook)(Code)



addConfiguredJavaProperty
public void addConfiguredJavaProperty(JavaProperty javaProperty) throws BuildException(Code)
Nested tasks - new tasks with custom attributes



addConfiguredService
public void addConfiguredService(Service service)(Code)



addExecfilelist
public void addExecfilelist(FileList fl)(Code)



addExecfileset
public void addExecfileset(FileSet fs)(Code)



addExtraclasspathfilelist
public void addExtraclasspathfilelist(FileList fl)(Code)



addExtraclasspathfileset
public void addExtraclasspathfileset(FileSet fs)(Code)



addJarfilelist
public void addJarfilelist(FileList fl)(Code)



addJarfileset
public void addJarfileset(FileSet fs)(Code)
Nested tasks - derived from FileList and FileSet



addJavafilelist
public void addJavafilelist(FileList fl)(Code)



addJavafileset
public void addJavafileset(FileSet fs)(Code)



addResourcefilelist
public void addResourcefilelist(FileList fl)(Code)



addResourcefileset
public void addResourcefileset(FileSet fs)(Code)



execute
public void execute() throws BuildException(Code)
The method executing the task



setAboutmenuname
public void setAboutmenuname(String s)(Code)
Setter for the "aboutmenuname" attribute (optional)



setAntialiasedgraphics
public void setAntialiasedgraphics(boolean b)(Code)
Setter for the "antialiasedgraphics" attribute (optional)



setAntialiasedtext
public void setAntialiasedtext(boolean b)(Code)
Setter for the "antialiasedtext" attribute (optional)



setArguments
public void setArguments(String s)(Code)
Arguments to the
Parameters:
  s - The arguments to pass to the application being launched.



setBuild
public void setBuild(String s)(Code)
Setter for the "buildnumber" attribute (optional) This key specifies the exact build version of the bundle. This string is usually of the form nn.n.nxnnn where n is a digit and x is a character from the set [abdf]. The first number is the major version number of the bundle and can contain one or two digits to represent a number in the range 0-99. The second and third numbers are minor revision numbers and must be a single numeric digit. The fourth set of digits is the specific build number for the release. You may omit minor revision and build number information as appropriate. You may also omit major and minor revision information and specify only a build number. For example, valid version numbers include: 1.0.1, 1.2.1b10, 1.2d200, d125, 101, and 1.0. The value of this key typically changes between builds and is displayed in the Cocoa About panel in parenthesis. To specify the version information of a released bundle, use the CFBundleShortVersionString key.



setBundleid
public void setBundleid(String s)(Code)
Setter for the "bundleid" attribute (optional) This key specifies a unique identifier string for the bundle. This identifier should be in the form of a Java-style package name, for example com.mycompany.myapp. The bundle identifier can be used to locate the bundle at runtime. The preferences system uses this string to identify applications uniquely. No default.



setChmod
public void setChmod(String s)(Code)
Set the 'chmod' executable.



setDevelopmentregion
public void setDevelopmentregion(String s)(Code)
Setter for the "developmentregion" attribute(optional) Default "English".



setDir
public void setDir(File f)(Code)
Setter for the "dir" attribute (required)



setExecs
public void setExecs(String s)(Code)
Setter for the "execs" attribute (optional)



setExtraclasspath
public void setExtraclasspath(String s)(Code)
Setter for the "extraclasspath" attribute (optional)



setGrowbox
public void setGrowbox(boolean b)(Code)
Setter for the "growbox" attribute (optional)



setGrowboxintrudes
public void setGrowboxintrudes(boolean b)(Code)
Setter for the "growboxintrudes" attribute (optional)



setHelpBookFolder
public void setHelpBookFolder(String s)(Code)



setHelpBookName
public void setHelpBookName(String s)(Code)



setIcon
public void setIcon(File f)(Code)
Setter for the "icon" attribute (optional)



setInfoString
public void setInfoString(String s)(Code)
Setter for the "infostring" attribute (optional) This key identifies a human-readable plain text string displaying the copyright information for the bundle. The Finder displays this information in the Info window of the bundle. (This string was also known as the long version string in Mac OS 9). The format of the key should be of the following format: "© Great Software, Inc, 1999". You can localize this string by including it in the InfoPlist.strings file of the appropriate .lproj directory.



setJar
public void setJar(File s)(Code)
Setter for the "jar" attribute (required if no "jarfileset" is present)



setJars
public void setJars(String s)(Code)
Setter for the "jars" attribute (required if no "jarfileset" is present)



setJvmversion
public void setJvmversion(String s)(Code)
Setter for the "jvmversion" attribute (optional)



setLiveresize
public void setLiveresize(boolean b)(Code)
Setter for the "liveresize" attribute (optional)



setMainClass
public void setMainClass(String s)(Code)
Setter for the "mainclass" attribute (required)



setName
public void setName(String s)(Code)
Setter for the "name" attribute (required) This attribute names the output application bundle and asks as the CFBundleName if 'bundlename' is not specified



setScreenmenu
public void setScreenmenu(boolean b)(Code)
Setter for the "screenmenu" attribute (optional)



setShortInfoString
public void setShortInfoString(String s)(Code)
Setter for the "shortinfostring" attribute (optional) This key identifies the marketing version of the bundle. The marketing version is a string that usually displays the major and minor version of the bundle. This string is usually of the form n.n.n where n is a number. The first number is the major version number of the bundle. The second and third numbers are minor revision numbers. You may omit minor revision numbers as appropriate. The value of this key is displayed in the default About box for Cocoa applications. The value for this key differs from the value for "CFBundleVersion", which identifies a specific build number. The CFBundleShortVersionString value represents a more formal version that does not change with every build.



setShortName
public void setShortName(String s)(Code)
Setter for the "shortname" attribute (optional) This key identifies the short name of the bundle. This name should be less than 16 characters long and be suitable for displaying in the menu and the About box. The name is (silently) cropped to this if necessary.



setShowPlist
public void setShowPlist(boolean showPlist)(Code)



setSignature
public void setSignature(String s)(Code)
Setter for the "signature" attribute (optional)



setSmallTabs
public void setSmallTabs(boolean b)(Code)
Setter for the "smalltabs" attribute (optional)



setStubFile
public void setStubFile(File file)(Code)
Override the stub file path to build on non-MacOS platforms
Parameters:
  file - the path to the stub file



setType
public void setType(String s)(Code)
Setter for the "type" attribute (optional)



setVerbose
public void setVerbose(boolean verbose)(Code)
Setter for the "verbose" attribute (optional)



setVersion
public void setVersion(String s)(Code)
Setter for the version attribute (optional). It is this property, not CFBundleVersion, which should receive the `short' version string. See for example



setVmoptions
public void setVmoptions(String s)(Code)
Setter for the "vmoptions" attribute (optional)



setWorkingDirectory
public void setWorkingDirectory(String s)(Code)
Setter for the "WorkingDirectory" attribute (optional)



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.