{"id":66326,"date":"2021-07-18T11:24:59","date_gmt":"2021-07-18T15:24:59","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/recent-posts\/skeleton-of-the-ant-file-java-short-notes\/"},"modified":"2021-07-18T11:24:59","modified_gmt":"2021-07-18T15:24:59","slug":"skeleton-of-the-ant-file-java-short-notes","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=66326","title":{"rendered":"Skeleton of the Ant File #Java Short Notes"},"content":{"rendered":"<p>Ant can be used to compile and deploy Java applications. Struts and Spring applications also make use of Ant. Here, we have provided the structure of the build.xml file with examples that is used to carry out the functionalities. The redistribution of this file is in compatible with the copyright law of The Apache Foundation. <\/p>\n<pre style='font-size:12px;padding-left:10px'><!--     General purpose build script for web applications and web services,     including enhanced support for deploying directly to a Tomcat 5     based server.     This build script assumes that the source code of your web application     is organized into the following subdirectories underneath the source     code directory from which you execute the build script:        docs                 Static documentation files to be copied to                             the \"docs\" subdirectory of your distribution.        src                  Java source code (and associated resource files)                             to be compiled to the \"WEB-INF\/classes\"                             subdirectory of your web applicaiton.        web                  Static HTML, JSP, and other content (such as                             image files), including the WEB-INF subdirectory                             and its configuration file contents.     $Id: build.xml.txt 565211 2007-08-13 00:09:38Z markt $--><!-- A \"project\" describes a set of targets that may be requested     when Ant is executed.  The \"default\" attribute defines the     target which is executed if no specific target is requested,     and the \"basedir\" attribute defines the current working directory     from which Ant executes the requested task.  This is normally     set to the current working directory.--><!-- ===================== Property Definitions =========================== --><!--  Each of the following properties are used in the build script.  Values for these properties are set by the first place they are  defined, from the following list:  * Definitions on the \"ant\" command line (ant -Dfoo=bar compile).  * Definitions from a \"build.properties\" file in the top level    source directory of this application.  * Definitions from a \"build.properties\" file in the developer's    home directory.  * Default definitions in this build.xml file.  You will note below that property values can be composed based on the  contents of previously defined properties.  This is a powerful technique  that helps you minimize the number of changes required when your development  environment is modified.  Note that property composition is allowed within  \"build.properties\" files as well as in the \"build.xml\" script.-->    <!-- ==================== File and Directory Names ======================== --><!--  These properties generally define file and directory names (or paths) that  affect where the build process stores its outputs.  app.name             Base name of this application, used to                       construct filenames and directories.                       Defaults to \"myapp\".  app.path             Context path to which this application should be                       deployed (defaults to \"\/\" plus the value of the                       \"app.name\" property).  app.version          Version number of this iteration of the application.  build.home           The directory into which the \"prepare\" and                       \"compile\" targets will generate their output.                       Defaults to \"build\".  catalina.home        The directory in which you have installed                       a binary distribution of Tomcat 5.  This will                       be used by the \"deploy\" target.  dist.home            The name of the base directory in which                       distribution files are created.                       Defaults to \"dist\".  manager.password     The login password of a user that is assigned the                       \"manager\" role (so that he or she can execute                       commands via the \"\/manager\" web application)  manager.url          The URL of the \"\/manager\" web application on the                       Tomcat installation to which we will deploy web                       applications and web services.  manager.username     The login username of a user that is assigned the                       \"manager\" role (so that he or she can execute                       commands via the \"\/manager\" web application)-->           <!-- UPDATE THIS! -->          <!-- ================== Custom Ant Task Definitions ======================= -->&lt;!--  These properties define custom tasks for the Ant build tool that interact  with the &quot;\/manager&quot; web application installed with Tomcat 5.  Before they  can be successfully utilized, you must perform the following steps:  - Copy the file &quot;server\/lib\/catalina-ant.jar&quot; from your Tomcat 5    installation into the &quot;lib&quot; directory of your Ant installation.  - Create a &quot;build.properties&quot; file in your application&#039;s top-level    source directory (or your user login home directory) that defines    appropriate values for the &quot;manager.password&quot;, &quot;manager.url&quot;, and    &quot;manager.username&quot; properties described above.  For more information about the Manager web application, and the functionality  of these tasks, see .--&gt;        <!--  ==================== Compilation Control Options ==================== -->&lt;!--  These properties control option settings on the Javac compiler when it  is invoked using the  task.  compile.debug        Should compilation include the debug option?  compile.deprecation  Should compilation include the deprecation option?  compile.optimize     Should compilation include the optimize option?--&gt;      <!-- ==================== External Dependencies =========================== --><!--  Use property values to define the locations of external JAR files on which  your application will depend.  In general, these values will be used for  two purposes:  * Inclusion on the classpath that is passed to the Javac compiler  * Being copied into the \"\/WEB-INF\/lib\" directory during execution    of the \"deploy\" target.  Because we will automatically include all of the Java classes that Tomcat 5  exposes to web applications, we will not need to explicitly list any of those  dependencies.  You only need to worry about external dependencies for JAR  files that you are going to include inside your \"\/WEB-INF\/lib\" directory.--><!-- Dummy external dependency -->&lt;!--  --&gt;<!-- ==================== Compilation Classpath =========================== --><!--  Rather than relying on the CLASSPATH environment variable, Ant includes  features that makes it easy to dynamically construct the classpath you  need for each compilation.  The example below constructs the compile  classpath to include the servlet.jar file, as well as the other components  that Tomcat makes available to web applications automatically, plus anything  that you explicitly added.-->      <!-- Include all JAR files that will be included in \/WEB-INF\/lib -->    <!-- *** CUSTOMIZE HERE AS REQUIRED BY YOUR APPLICATION *** -->&lt;!--    --&gt;    <!-- Include all elements that Tomcat exposes to applications -->                                                    <!-- ==================== All Target ====================================== --><!--  The \"all\" target is a shortcut for running the \"clean\" target followed  by the \"compile\" target, to force a complete recompile.-->  <!-- ==================== Clean Target ==================================== --><!--  The \"clean\" target deletes any previous \"build\" and \"dist\" directory,  so that you can be ensured the application can be built from scratch.-->            <!-- ==================== Compile Target ================================== --><!--  The \"compile\" target transforms source files (from your \"src\" directory)  into object files in the appropriate location in the build directory.  This example assumes that you will be including your classes in an  unpacked directory hierarchy under \"\/WEB-INF\/classes\".-->      <!-- Compile Java classes as necessary -->                        <!-- Copy application resources -->                <!-- ==================== Dist Target ===================================== --><!--  The \"dist\" target creates a binary distribution of your application  in a directory structure ready to be archived in a tar.gz or zip file.  Note that this target depends on two others:  * \"compile\" so that the entire web application (including external    dependencies) will have been assembled  * \"javadoc\" so that the application Javadocs will have been created-->      <!-- Copy documentation subdirectories -->                      <!-- Create application JAR file -->        <!-- Copy additional files to ${dist.home} as necessary -->  <!-- ==================== Install Target ================================== --><!--  The \"install\" target tells the specified Tomcat 5 installation to dynamically  install this web application and make it available for execution.  It does  *not* cause the existence of this web application to be remembered across  Tomcat restarts; if you restart the server, you will need to re-install all  this web application.  If you have already installed this application, and simply want Tomcat to  recognize that you have updated Java classes (or the web.xml file), use the  \"reload\" target instead.  NOTE:  This target will only succeed if it is run from the same server that  Tomcat is running on.  NOTE:  This is the logical opposite of the \"remove\" target.-->        <!-- ==================== Javadoc Target ================================== --><!--  The \"javadoc\" target creates Javadoc API documentation for the Java  classes included in your application.  Normally, this is only required  when preparing a distribution release, but is available as a separate  target in case the developer wants to create Javadocs independently.-->                      <!-- ====================== List Target =================================== --><!--  The \"list\" target asks the specified Tomcat 5 installation to list the  currently running web applications, either loaded at startup time or  installed dynamically.  It is useful to determine whether or not the  application you are currently developing has been installed.-->        <!-- ==================== Prepare Target ================================== --><!--  The \"prepare\" target is used to create the \"build\" destination directory,  and copy the static contents of your web application to it.  If you need  to copy static files from external dependencies, you can customize the  contents of this task.  Normally, this task is executed indirectly when needed.-->      <!-- Create build directories as needed -->                <!-- Copy static content of this web application -->                  <!-- Copy external dependencies as required -->    <!-- *** CUSTOMIZE HERE AS REQUIRED BY YOUR APPLICATION *** -->    &lt;!--    --&gt;    <!-- Copy static files from external dependencies as needed -->    <!-- *** CUSTOMIZE HERE AS REQUIRED BY YOUR APPLICATION *** -->  <!-- ==================== Reload Target =================================== --><!--  The \"reload\" signals the specified application Tomcat 5 to shut itself down  and reload. This can be useful when the web application context is not  reloadable and you have updated classes or property files in the  \/WEB-INF\/classes directory or when you have added or updated jar files in the  \/WEB-INF\/lib directory.  NOTE: The \/WEB-INF\/web.xml web application configuration file is not reread  on a reload. If you have made changes to your web.xml file you must stop  then start the web application. -->        <!-- ==================== Remove Target =================================== --><!--  The \"remove\" target tells the specified Tomcat 5 installation to dynamically  remove this web application from service.  NOTE:  This is the logical opposite of the \"install\" target.-->        <\/pre>\n<p>  Licensed to the Apache Software Foundation (ASF) under one or more  contributor license agreements.  See the NOTICE file distributed with  this work for additional information regarding copyright ownership.  The ASF licenses this file to You under the Apache License, Version 2.0  (the &#8220;License&#8221;); you may not use this file except in compliance with  the License.  You may obtain a copy of the License at      http:\/\/www.apache.org\/licenses\/LICENSE-2.0  Unless required by applicable law or agreed to in writing, software  distributed under the License is distributed on an &#8220;AS IS&#8221; BASIS,  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the License for the specific language governing permissions and  limitations under the License.<\/p>\n<p> From: http:\/\/sitestree.com\/?p=4961<br \/> Categories:Java Short Notes<br \/>Tags:<br \/> Post Data:2007-06-06 02:04:10<\/p>\n<p>\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com\/' target='new' rel=\"noopener\">https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\t(Big Data, Cloud, Security, Machine Learning): Courses: <a href='http:\/\/Training.SitesTree.com' target='new' rel=\"noopener\"> http:\/\/Training.SitesTree.com<\/a><br \/>\n\t\tIn Bengali: <a href='http:\/\/Bangla.SaLearningSchool.com' target='new' rel=\"noopener\">http:\/\/Bangla.SaLearningSchool.com<\/a><br \/>\n\t\t<a href='http:\/\/SitesTree.com' target='new' rel=\"noopener\">http:\/\/SitesTree.com<\/a><br \/>\n\t\t8112223 Canada Inc.\/JustEtc: <a href='http:\/\/JustEtc.net' target='new' rel=\"noopener\">http:\/\/JustEtc.net (Software\/Web\/Mobile\/Big-Data\/Machine Learning) <\/a><br \/>\n\t\tShop Online: <a href='https:\/\/www.ShopForSoul.com'> https:\/\/www.ShopForSoul.com\/<\/a><br \/>\n\t\tMedium: <a href='https:\/\/medium.com\/@SayedAhmedCanada' target='new' rel=\"noopener\"> https:\/\/medium.com\/@SayedAhmedCanada <\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ant can be used to compile and deploy Java applications. Struts and Spring applications also make use of Ant. Here, we have provided the structure of the build.xml file with examples that is used to carry out the functionalities. The redistribution of this file is in compatible with the copyright law of The Apache Foundation. &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=66326\">Continue reading<\/a><\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1917],"tags":[],"class_list":["post-66326","post","type-post","status-publish","format-standard","hentry","category-fromsitestree-com","item-wrap"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":74781,"url":"http:\/\/bangla.sitestree.com\/?p=74781","url_meta":{"origin":66326,"position":0},"title":"Playlist: Anything Java","author":"Sayed","date":"May 31, 2022","format":false,"excerpt":"Playlist: Anything Java: https:\/\/www.youtube.com\/playlist... #SaLearningSchoolShopForSoulSitesTree, #SaLearningSchool, #ShopForSoul, #SitesTree Starting Java training basic file operations in java basic java language concepts bengali javascript debugging data conversion in jsf applications debugging javascript code Docker and Vagrant Optional Java and\/or PHP Platform ejb application with bea weblogic eclipse experiment eclipse ant how to\u2026","rel":"","context":"In &quot;\u09ac\u09cd\u09b2\u0997 \u0964 Blog&quot;","block_context":{"text":"\u09ac\u09cd\u09b2\u0997 \u0964 Blog","link":"http:\/\/bangla.sitestree.com\/?cat=182"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":65977,"url":"http:\/\/bangla.sitestree.com\/?p=65977","url_meta":{"origin":66326,"position":1},"title":"Writing your first Spring application #Java Short Notes","author":"Author-Check- Article-or-Video","date":"July 18, 2021","format":false,"excerpt":"Requirements: JDK 1.4.2 (or above), Tomcat 5.0+, Ant 1.6.1+ Also, you can use cygwin in windows to emulate linux like commands set JAVA_HOME, ANT_HOME, CATALINA_HOME environment variables - paths to the installed software Add to PATH: JAVA_HOME\/bin, ANT_HOME\/bin, CATALINA_HOME\/bin You can start with the minimal application like struts-blanke.war or webapp-minimal\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":66344,"url":"http:\/\/bangla.sitestree.com\/?p=66344","url_meta":{"origin":66326,"position":2},"title":"Creating Java Development Environment with Struts for Your Home PC #Java Short Notes","author":"Sayed","date":"July 18, 2021","format":false,"excerpt":"Creating Java Development Environment with Struts for Your Home PC.......................... Why Struts? Just take a look at the web-sites using Struts J2EE does not meet all the requirements for web-applications. Struts addresses these requirements. Check this article for details Components Required J2SE 5\/6 or J2EE 5 - both JRE and\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":65981,"url":"http:\/\/bangla.sitestree.com\/?p=65981","url_meta":{"origin":66326,"position":3},"title":"Maven 1.0: A pretty good article: Compare Ant and Maven #Java Short Notes","author":"Author-Check- Article-or-Video","date":"July 18, 2021","format":false,"excerpt":"Maven 1.0 (Latest version is Maven 2.0) Maven 2.0 Your first Maven project From: http:\/\/sitestree.com\/?p=4928 Categories:Java Short NotesTags: Post Data:2007-02-02 16:28:00 Shop Online: https:\/\/www.ShopForSoul.com\/ (Big Data, Cloud, Security, Machine Learning): Courses: http:\/\/Training.SitesTree.com In Bengali: http:\/\/Bangla.SaLearningSchool.com http:\/\/SitesTree.com 8112223 Canada Inc.\/JustEtc: http:\/\/JustEtc.net (Software\/Web\/Mobile\/Big-Data\/Machine Learning) Shop Online: https:\/\/www.ShopForSoul.com\/ Medium: https:\/\/medium.com\/@SayedAhmedCanada","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":67364,"url":"http:\/\/bangla.sitestree.com\/?p=67364","url_meta":{"origin":66326,"position":4},"title":"What is Hibernate? #Java Short Notes","author":"Author-Check- Article-or-Video","date":"July 20, 2021","format":false,"excerpt":"Why Hibernate? A database is an integral part of many different types of applications. Standalone single-person applications to multi-user distributed business and enterprise applications make extensive use of databases. Many high end technology applications in industries including telecommunications, and surveillance systems make extensive use of databases. However, in recent years,\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":67374,"url":"http:\/\/bangla.sitestree.com\/?p=67374","url_meta":{"origin":66326,"position":5},"title":"Java Skills for Job #Java Short Notes","author":"Author-Check- Article-or-Video","date":"July 20, 2021","format":false,"excerpt":"AWT Swing JSF Applet Midlet JDBC JSP Servlet Java Beans EJB J2ME RMI JNDI Network Programming XML processing Web Services and SOAP JavaFX Java Connector Java Mail Java AVK (Application Verification Kit) Java ACC Java Message Service API Java Persistence API Java Transaction API Java Transaction Service Hibernate Struts Spring\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/66326","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=66326"}],"version-history":[{"count":0,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/66326\/revisions"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=66326"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=66326"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=66326"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}