// // ------ // // SAVOT Sample // // Author: André Schaaff // Address: Centre de Donnees astronomiques de Strasbourg // 11 rue de l'Universite // 67000 STRASBOURG // FRANCE // Email: schaaff@astro.u-strasbg.fr, question@simbad.u-strasbg.fr // // ------- // // In accordance with the international conventions about intellectual // property rights this software and associated documentation files // (the "Software") is protected. The rightholder authorizes : // the reproduction and representation as a private copy or for educational // and research purposes outside any lucrative use, // subject to the following conditions: // // The above copyright notice shall be included. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES // OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON INFRINGEMENT, // LOSS OF DATA, LOSS OF PROFIT, LOSS OF BARGAIN OR IMPOSSIBILITY // TO USE SUCH SOFWARE. IN NO EVENT SHALL THE RIGHTHOLDER BE LIABLE // FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH // THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // // For any other exploitation contact the rightholder. // // ----------- // // Conformement aux conventions internationales relatives aux droits de // propriete intellectuelle ce logiciel et sa documentation sont proteges. // Le titulaire des droits autorise : // la reproduction et la representation a titre de copie privee ou des fins // d'enseignement et de recherche et en dehors de toute utilisation lucrative. // Cette autorisation est faite sous les conditions suivantes : // // La mention du copyright portee ci-dessus devra etre clairement indiquee. // // LE LOGICIEL EST LIVRE "EN L'ETAT", SANS GARANTIE D'AUCUNE SORTE. // LE TITULAIRE DES DROITS NE SAURAIT, EN AUCUN CAS ETRE TENU CONTRACTUELLEMENT // OU DELICTUELLEMENT POUR RESPONSABLE DES DOMMAGES DIRECTS OU INDIRECTS // (Y COMPRIS ET A TITRE PUREMENT ILLUSTRATIF ET NON LIMITATIF, // LA PRIVATION DE JOUISSANCE DU LOGICIEL, LA PERTE DE DONNEES, // LE MANQUE A GAGNER OU AUGMENTATION DE COUTS ET DEPENSES, LES PERTES // D'EXPLOITATION,LES PERTES DE MARCHES OU TOUTES ACTIONS EN CONTREFACON) // POUVANT RESULTER DE L'UTILISATION, DE LA MAUVAISE UTILISATION // OU DE L'IMPOSSIBILITE D'UTILISER LE LOGICIEL, ALORS MEME // QU'IL AURAIT ETE AVISE DE LA POSSIBILITE DE SURVENANCE DE TELS DOMMAGES. // // Pour toute autre utilisation contactez le titulaire des droits. // import java.io.*; import cds.savot.sax.*; /** *
A sample designed to show the SAX usage of the parser
* @author Andre Schaaff * @version 2.5 Copyright CDS 2002-2004 */ public class TestSAX { /** * Constructor * * @param file */ public TestSAX(String file) { try { SavotSAXSample consumer = new SavotSAXSample(); SavotSAXParser sb = new SavotSAXParser(consumer, file); } catch(Exception e) {System.err.println("TestSAX : " + e);}; } /** * Main method * @param argv * @throws IOException */ public static void main (String [] argv) throws IOException{ if (argv.length == 0) System.out.println("Usage: java TestSAX