Package lexicon.jaxb

Examples of lexicon.jaxb.Lexicon


  public static ElementaryTree buildTree(String word) throws
  FileNotFoundException, XMLStreamException, JAXBException,java.lang.NullPointerException{
   
    JAXBContext jc = JAXBContext.newInstance(Lexicon.class)
    Unmarshaller u = jc.createUnmarshaller();
    Lexicon lex =(Lexicon) (u.unmarshal(new File("binding\\En-Fr.xml")));
    System.out.println(lex.getTgt_language());
    System.out.println( "D�but: " );
    System.out.println(lex.getEntryCount());
    System.out.println(lex.getEntry(1).getSource().getForm());
   
    for (int i = 0; i < lex.getEntryCount(); i++) {
     
      if(lex.getEntry(i).getSource().getForm().equals("John"))
      {
        System.out.println(lex.getEntry(i).getSource().getLexicalisation().getTree_id());
      }
     
    }
          
    return null;
View Full Code Here

TOP

Related Classes of lexicon.jaxb.Lexicon

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.