.. (parent)AntDocAntDocGUIManual
You are here: Documentation >> AntDoc
Meta

Table of contents

Frequently Asked Questions

AntDoc task documentation

This page explains how to use AntDoc combined with AntDocGUI.

The overall documentation of AntDoc is far from being perfect and exhaustive. However, concerning the Ant AntDoc task itself, you should find all the necessary information: browse the manual here.

Each built-in and optional task is an hyperlink that enables to understand more quickly a script. You may even customize the generated CSS file in order to provide to the documentation a look that is in harmony with your web pages.

Run Ant from HTML

AntDoc offers the opportunity to execute Ant targets from the generated HTML pages.

But first, in order to to make that possible, the generated pages must have been yielded with an AntDoc task with runtime attribute set to true within the Ant buildfile that generates the documentation. When you set that attribute, the generated HTML will embed a signed applet, which is actually an AntDocClient. If this is correctly set, the generated pages must show the AntDoc icon in front of each target. Moreover, you must see an applet at the top of each builfile documentation:AntDoc applet screenshotimages/AntDocApplet.gif

You are browsing the generated documentation and would like to run an Ant target? In order to execute a target, you must beforehand launch AntDocGUI (which implements the AntDocServer Java interface).

In order to launch AntDocGUI, simply type in a console "AntDocGUI": a Swing GUI must appear: this application listens to requests coming from the applet, which is embedded in the HTML pages. Now that AntDocGUI is launched, you need to connect to it from the HTML pages: click on the "Connect" button, in order to connect to AntDocGUI: you mandatorily need to proceed this step under Internet Explorer, since the JVM will not permit socket connection until the end-user actually clicks a button on the applet (I must admit that I do not understand very well this issue...)! In order to check that the applet is actually connected to AntDocGUI, look at the Java console which should show "Currently connected to the AntDoc server".

Now, AntDocGUI is launched, you are connected to it from the HTML pages. Just click the AntDoc icon in front of the Ant target that you wish to run. This selects the task within AntDocGUI. Go back to AntDocGUI and run the target. Now, if you want the target to be automatically run inside AntDocGUI without having to manually run it, check the "Autorun under GUI" box in the HTML page.

With that feature, you may even execute targets remotedly: imagine that you have generated the AntDoc for a builfile, that you have uploaded this documentation on your intranet website: if you are working on another machine and want to execute a target, open an HTML browser, go to the AntDoc page, connect to the AntDocGUI which must be running on the target machine, specify the server host name ("Server name" input field on the applet), the port it listens to ("Port number" on the same applet), and click on the target's facing icon.


Current date: 2024.03.29 8:51:28 Number of hit: 19172