Apache ANT Basics
- ANT - Build Files
- ANT - Property Task
- ANT - Property Files
- ANT - Data Types
- ANT - Building Projects
- ANT - Build Documentation
- ANT - Creating JAR files
- ANT - Create WAR Files
- ANT - Packaging Applications
- ANT - Deploying Applications
Apache ANT Advanced
Apache ANT Useful Examples
- ANT - Using Token
- ANT - Using Command Line Arguments
- ANT - Using If Else arguments
- ANT - Custom Components
- ANT - Listeners and Loggers
Apache ANT Useful Resources
Ant Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to Ant. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Q 1 - What ANT stands for?
Answer : C
Explanation
ANT stands for Another Neat Tool.
Q 2 - Which of the following is true about target?
A - A target is a collection of tasks that you want to run as one unit.
Answer : A
Explanation
A target is a collection of tasks that you want to run as one unit.
Q 3 - Which of the following property defines the version of Ant installation?
Answer : A
Explanation
ant.version - The version of the Apache Ant installation.
Q 4 - Which of the following property defines the base directory of current project?
Answer : C
Explanation
basedir - The basedir of the build, as specified in the basedir attribute of the project element.
Q 5 - Which of the following is correct about ? meta character in patternset data type?
A - ? - Matches one character only.
B - ? - Matches zero or many characters.
Answer : A
Explanation
? - Matches one character only.
Q 6 - Which of the following is correct about path data type?
A - The path data type is commonly used to represent a class-path.
B - Entries in the path are separated using semicolons or colons.
Answer : D
Explanation
The path data type is commonly used to represent a class-path. Entries in the path are separated using semicolons or colons. However, these characters are replaced at the run-time by the executing system's path separator character.
Q 7 - Which of the following is correct about javadoc task?
A - sourcepathref is used to point to the folder of the source files (e.g. src folder).
C - sourcepathref is used when you want to specify the individual files as a comma separated list.
Answer : B
Explanation
sourcepathref is used to refer a path that is referenced by the path attribute (e.g, delegates.src.dir).
Q 8 - Which of the following task is used to create a ear file?
Answer : A
Explanation
ear task can be used to create a ear file.
Q 9 - Which of the following is correct about deploy target?
A - The deploy target copies the files from the web directory to the deploy directory.
B - It preserves the last date time stamp
C - This is useful when deploying to a server that supports hot deployment.
Answer : D
Explanation
The deploy target copies the files from the web directory to the deploy directory preserving the last modified date time stamp. This is useful when deploying to a server that supports hot deployment.