com.hp.hpl.jena.sparql.core
Class Prologue

java.lang.Object
  extended by com.hp.hpl.jena.sparql.core.Prologue
Direct Known Subclasses:
Query, UpdateRequest

public class Prologue
extends Object


Constructor Summary
Prologue()
           
Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap)
           
Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap, com.hp.hpl.jena.n3.IRIResolver resolver)
           
Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap, String base)
           
Prologue(Prologue other)
           
 
Method Summary
 Prologue copy()
           
 String expandPrefixedName(String qname)
          Expand prefixed name
 boolean explicitlySetBaseURI()
           
 String getBaseURI()
           
 String getPrefix(String prefix)
          Lookup a prefix for this query, including the default prefixes
 com.hp.hpl.jena.shared.PrefixMapping getPrefixMapping()
          Return the prefix map from the parsed query
 com.hp.hpl.jena.n3.IRIResolver getResolver()
          Get the IRI resolver
 void setBaseURI(com.hp.hpl.jena.n3.IRIResolver resolver)
           
 void setBaseURI(String baseURI)
           
 void setPrefix(String prefix, String expansion)
          Set a prefix for this query
 void setPrefixMapping(com.hp.hpl.jena.shared.PrefixMapping pmap)
          Set the mapping
 void setResolver(com.hp.hpl.jena.n3.IRIResolver resolver)
          Set the IRI resolver
 String shortForm(String uri)
          Use the prefix map to turn a URI into a qname, or return the original URI
 Prologue sub(com.hp.hpl.jena.shared.PrefixMapping newMappings)
           
 Prologue sub(com.hp.hpl.jena.shared.PrefixMapping newMappings, String base)
           
 Prologue sub(String base)
           
 void usePrologueFrom(Prologue other)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Prologue

public Prologue()

Prologue

public Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap)

Prologue

public Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap,
                String base)

Prologue

public Prologue(com.hp.hpl.jena.shared.PrefixMapping pmap,
                com.hp.hpl.jena.n3.IRIResolver resolver)

Prologue

public Prologue(Prologue other)
Method Detail

copy

public Prologue copy()

usePrologueFrom

public void usePrologueFrom(Prologue other)

sub

public Prologue sub(com.hp.hpl.jena.shared.PrefixMapping newMappings)

sub

public Prologue sub(String base)

sub

public Prologue sub(com.hp.hpl.jena.shared.PrefixMapping newMappings,
                    String base)

explicitlySetBaseURI

public boolean explicitlySetBaseURI()
Returns:
True if the query has an explicitly set base URI.

getBaseURI

public String getBaseURI()
Returns:
Returns the baseURI, if set.

setBaseURI

public void setBaseURI(String baseURI)
Parameters:
baseURI - The baseURI to set.

setBaseURI

public void setBaseURI(com.hp.hpl.jena.n3.IRIResolver resolver)
Parameters:
resolver - IRI resolver

setPrefix

public void setPrefix(String prefix,
                      String expansion)
Set a prefix for this query


getPrefixMapping

public com.hp.hpl.jena.shared.PrefixMapping getPrefixMapping()
Return the prefix map from the parsed query


setPrefixMapping

public void setPrefixMapping(com.hp.hpl.jena.shared.PrefixMapping pmap)
Set the mapping


getPrefix

public String getPrefix(String prefix)
Lookup a prefix for this query, including the default prefixes


getResolver

public com.hp.hpl.jena.n3.IRIResolver getResolver()
Get the IRI resolver


setResolver

public void setResolver(com.hp.hpl.jena.n3.IRIResolver resolver)
Set the IRI resolver


expandPrefixedName

public String expandPrefixedName(String qname)
Expand prefixed name

Parameters:
qname - The prefixed name to be expanded
Returns:
URI, or null if not expanded.

shortForm

public String shortForm(String uri)
Use the prefix map to turn a URI into a qname, or return the original URI



Licenced under the Apache License, Version 2.0