Source Code Cross Referenced for JNLPGeneratorTask.java in  » IDE-Eclipse » Eclipse-plug-in-development » org » eclipse » pde » internal » build » tasks » 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 » IDE Eclipse » Eclipse plug in development » org.eclipse.pde.internal.build.tasks 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*******************************************************************************
002:         * Copyright (c) 2005, 2007 IBM Corporation and others.
003:         * All rights reserved. This program and the accompanying materials
004:         * are made available under the terms of the Eclipse Public License v1.0
005:         * which accompanies this distribution, and is available at
006:         * http://www.eclipse.org/legal/epl-v10.html
007:         *
008:         * Contributors:
009:         *     IBM Corporation - initial API and implementation
010:         *     G&H Softwareentwicklung GmbH - internationalization implementation (bug 150933)
011:         *******************************************************************************/package org.eclipse.pde.internal.build.tasks;
012:
013:        import java.util.Locale;
014:
015:        import org.apache.tools.ant.BuildException;
016:        import org.apache.tools.ant.Task;
017:
018:        public class JNLPGeneratorTask extends Task {
019:
020:            private String feature;
021:            private String jnlp = null;
022:            private String codebase = null;
023:            private String j2se;
024:            private Locale locale = Locale.getDefault();
025:            private boolean generateOfflineAllowed = true;
026:            private String configs = null;
027:
028:            /**
029:             * The URL location of a feature.xml file.  This can be either a jar: URL to the feature.xml,
030:             * or a file: url to the feature.
031:             * @param value
032:             */
033:            public void setFeature(String value) {
034:                feature = value;
035:            }
036:
037:            /**
038:             * The location the output jnlp file.  The value may be null (or simply not set).  If it is
039:             * null then the output file will be placed beside the feature dir or jar (as appropriate)
040:             * and its name will be derived from the feature id and version.  If this is set
041:             * it must be a file path.  If it ends in a "/" or "\" then the output file is places in this
042:             * directory with the file name derived as described.  Finally, if the value is a file name,
043:             * the output is placed in that file.
044:             * @param value the location to write the output or null if the default
045:             * computed location is to be used.
046:             */
047:            public void setJNLP(String value) {
048:                jnlp = value;
049:            }
050:
051:            /**
052:             * The codebase of the output.  This shoudl be a URL that will be used as the
053:             * root of all relative URLs in the output.  Typically this is the root of the application
054:             * deployment website.
055:             * @param value the URL root of for the application content.
056:             */
057:            public void setCodebase(String value) {
058:                codebase = value;
059:            }
060:
061:            /**
062:             * The j2se spec of the output
063:             * @param value the JNLP j2se spec to use in the output.
064:             */
065:            public void setJ2SE(String value) {
066:                j2se = value;
067:            }
068:
069:            /**
070:             * The locale in which the jnlp file generated should be translated into.
071:             *The translation values are read from the feature_<locale>.properties file.
072:             * @param the locale in which to generate the jnlp files.
073:             * */
074:            public void setLocale(String nlsString) {
075:                String[] strings = nlsString.split("_"); //$NON-NLS-1$
076:                if (nlsString.charAt(0) == '$')
077:                    return;
078:
079:                if (strings != null) {
080:                    switch (strings.length) {
081:                    case 1:
082:                        locale = new Locale(strings[0]);
083:                        break;
084:                    case 2:
085:                        locale = new Locale(strings[0], strings[1]);
086:                        break;
087:                    case 3:
088:                        locale = new Locale(strings[0], strings[1], strings[2]);
089:                        break;
090:                    }
091:                }
092:            }
093:
094:            public void execute() throws BuildException {
095:                JNLPGenerator generator = new JNLPGenerator(feature, jnlp,
096:                        codebase, j2se, locale, generateOfflineAllowed, configs);
097:                generator.process();
098:            }
099:
100:            public void setGenerateOfflineAllowed(String generateOfflineAllowed) {
101:                if (generateOfflineAllowed.equalsIgnoreCase("false")) //$NON-NLS-1$
102:                    this .generateOfflineAllowed = false;
103:                if (generateOfflineAllowed.equalsIgnoreCase("true")) //$NON-NLS-1$
104:                    this .generateOfflineAllowed = false;
105:            }
106:
107:            public void setConfigInfo(String configs) {
108:                this.configs = configs;
109:            }
110:
111:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.