Package org.openrdf.model

Examples of org.openrdf.model.Value


  }

  public Literal objectLiteral()
    throws ModelException
  {
    Value obj = objectValue();
    if (obj == null) {
      return null;
    }
    if (obj instanceof Literal) {
      return (Literal)obj;
View Full Code Here


  }

  public Resource objectResource()
    throws ModelException
  {
    Value obj = objectValue();
    if (obj == null) {
      return null;
    }
    if (obj instanceof Resource) {
      return (Resource)obj;
View Full Code Here

  }

  public URI objectURI()
    throws ModelException
  {
    Value obj = objectValue();
    if (obj == null) {
      return null;
    }
    if (obj instanceof URI) {
      return (URI)obj;
View Full Code Here

  }

  public String objectString()
    throws ModelException
  {
    Value obj = objectValue();
    if (obj == null) {
      return null;
    }
    return obj.stringValue();
  }
View Full Code Here

    s.writeInt(statements.size());
    // Write in all elements
    for (ModelStatement st : statements) {
      Resource subj = st.getSubject();
      URI pred = st.getPredicate();
      Value obj = st.getObject();
      Resource ctx = st.getContext();
      s.writeObject(new StatementImpl(subj, pred, obj, ctx));
    }
  }
View Full Code Here

  }

  private Iterator find(Statement st) {
    Resource subj = st.getSubject();
    URI pred = st.getPredicate();
    Value obj = st.getObject();
    Resource ctx = st.getContext();
    return match(subj, pred, obj, ctx);
  }
View Full Code Here

    public Value objectValue()
      throws ModelException
    {
      Iterator<Value> iter = objects().iterator();
      if (iter.hasNext()) {
        Value obj = iter.next();
        if (iter.hasNext()) {
          throw new ModelException();
        }
        return obj;
      }
View Full Code Here

    }

    public Literal objectLiteral()
      throws ModelException
    {
      Value obj = objectValue();
      if (obj == null) {
        return null;
      }
      if (obj instanceof Literal) {
        return (Literal)obj;
View Full Code Here

    }

    public Resource objectResource()
      throws ModelException
    {
      Value obj = objectValue();
      if (obj == null) {
        return null;
      }
      if (obj instanceof Resource) {
        return (Resource)obj;
View Full Code Here

    }

    public URI objectURI()
      throws ModelException
    {
      Value obj = objectValue();
      if (obj == null) {
        return null;
      }
      if (obj instanceof URI) {
        return (URI)obj;
View Full Code Here

TOP

Related Classes of org.openrdf.model.Value

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.