Package org.ontoware.rdf2go.exception

Examples of org.ontoware.rdf2go.exception.ModelRuntimeException


  public static String modelToString(Model model, Syntax syntax) {
    StringWriter buffer = new StringWriter();
    try {
      model.writeTo(buffer, syntax);
    } catch(Exception e) {
      throw new ModelRuntimeException(e);
    }
    return buffer.toString();
  }
View Full Code Here


  public static String modelToString(ModelSet modelset, Syntax syntax) {
    StringWriter buffer = new StringWriter();
    try {
      modelset.writeTo(buffer, syntax);
    } catch(Exception e) {
      throw new ModelRuntimeException(e);
    }
    return buffer.toString();
  }
View Full Code Here

    StringReader s = new StringReader(string);
    try {
      m.readFrom(s, syntax);
      return m;
    } catch(Exception e) {
      throw new ModelRuntimeException(e);
    } finally {
      s.close();
    }
  }
View Full Code Here

    @Override
    public void close() {
      try {
        this.idIterator.close();
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    @Override
    public boolean hasNext() {
      try {
        return this.idIterator.hasNext();
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    @Override
    public URI next() {
      try {
        return (URI)ConversionUtil.toRdf2go(this.idIterator.next());
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    @Override
    public void close() {
      try {
        this.result.close();
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    @Override
    public boolean hasNext() {
      try {
        return this.result.hasNext();
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    public Statement next() {
      try {
        org.openrdf.model.Statement statement = this.result.next();
        return new StatementWrapper(null, statement);
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

    @Override
    public void remove() {
      try {
        this.result.remove();
      } catch(RepositoryException e) {
        throw new ModelRuntimeException(e);
      }
    }
View Full Code Here

TOP

Related Classes of org.ontoware.rdf2go.exception.ModelRuntimeException

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.