Package com.franz.agbase

Examples of com.franz.agbase.AllegroGraphConnection


     * Otherwise, it uses access()
     */
    _Conn(boolean renew) throws ServletException {
      log.info("Connecting to triple store...");
      try {
        ags = new AllegroGraphConnection();
        ags.setHost(serverHost);
        ags.setPort(serverPort);
        ags.enable();
      }
      catch (Throwable e) {
View Full Code Here


   * @throws AllegroGraphException
   */
  public static void main(String[] args) throws AllegroGraphException {
   
    // Connect to the server, which must already be running.
    AllegroGraphConnection ags = new AllegroGraphConnection();
    try {
      ags.enable();
    } catch (Exception e) {
      throw new AllegroGraphException("Server connection problem.", e);
    }

    // Access a store -- default is read-write access
    System.out.println("Access: open a store, creating if necessary.");
    AllegroGraph ts = ags.access("ooici", "/tmp");
   
   
//    addStatements(ts);
    getStatements(ts);
   
//    String graphUri = "http://mmisw/org/ont/graph/ooici";
//    String filename = "/Users/carueda/mmiworkspace/cisemanticprototype/rdf/cdm.owl";
//    loadRdf(ts, filename, graphUri);

   
//    Object context = "<http://example.org/wilburwine>";
//    Object context = "<http://mmisw/org/ont/graph/ooici>";
//    Object context = null;
//    removeAllStatements(ts, context);
   
   
    ts.closeTripleStore();

    // Disconnect from the server
    System.out.println("Disconnecting from the server.");
    ags.disable();
    System.out.println("Done.");
   
  }
View Full Code Here

TOP

Related Classes of com.franz.agbase.AllegroGraphConnection

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.