com.hp.hpl.jena.util
Class ModelLoader

java.lang.Object
  extended by com.hp.hpl.jena.util.ModelLoader

public class ModelLoader
extends Object

A set of static convenience methods for getting models The loader will guess the language/type of the model using guessLang

Version:
$Id: ModelLoader.java,v 1.1 2009-06-29 08:55:47 castagna Exp $
Author:
Andy Seaborne

Field Summary
static String langN3
          Deprecated. Use FileUtils.langN3
static String langNTriple
          Deprecated. Use FileUtils.langNTriple
static String langXML
          Deprecated. Use FileUtils.FileUtils.langXML
static String langXMLAbbrev
          Deprecated. Use FileUtils.langXMLAbbrev
 
Constructor Summary
ModelLoader()
           
 
Method Summary
static String guessLang(String urlStr)
          Deprecated. Use FileUtils.guessLang
static String guessLang(String urlStr, String defaultLang)
          Deprecated. Use FileUtils.guessLang
static Model loadModel(Model model, String urlStr)
          Deprecated. Use FileManager.get().readModel(model, urlStr) instead
static Model loadModel(Model model, String urlStr, String lang)
          Deprecated. Use FileManager.get().readModel(model, urlStr, lang) instead
static Model loadModel(String urlStr)
          Deprecated. Use FileManager.get().loadModel(urlStr)
static Model loadModel(String urlStr, String lang)
          Deprecated. Use FileManager.get().loadModel(urlStr, lang)
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

langXML

@Deprecated
public static final String langXML
Deprecated. Use FileUtils.FileUtils.langXML
See Also:
Constant Field Values

langXMLAbbrev

@Deprecated
public static final String langXMLAbbrev
Deprecated. Use FileUtils.langXMLAbbrev
See Also:
Constant Field Values

langNTriple

@Deprecated
public static final String langNTriple
Deprecated. Use FileUtils.langNTriple
See Also:
Constant Field Values

langN3

@Deprecated
public static final String langN3
Deprecated. Use FileUtils.langN3
See Also:
Constant Field Values
Constructor Detail

ModelLoader

public ModelLoader()
Method Detail

loadModel

@Deprecated
public static Model loadModel(String urlStr)
Deprecated. Use FileManager.get().loadModel(urlStr)

Load a model

Parameters:
urlStr - The URL or file name of the model

loadModel

@Deprecated
public static Model loadModel(String urlStr,
                                         String lang)
Deprecated. Use FileManager.get().loadModel(urlStr, lang)

Load a model or attached a persistent store (but not a database).

Parameters:
urlStr - The URL or file name of the model
lang - The language of the data - if null, the system guesses

loadModel

@Deprecated
public static Model loadModel(Model model,
                                         String urlStr)
Deprecated. Use FileManager.get().readModel(model, urlStr) instead

Load a model from a file into a model.

Parameters:
model - Model to read into
urlStr - URL (or filename) to read from
Returns:
Returns the model passed in.

loadModel

@Deprecated
public static Model loadModel(Model model,
                                         String urlStr,
                                         String lang)
Deprecated. Use FileManager.get().readModel(model, urlStr, lang) instead

Load a model from a file into a model.

Parameters:
model - Model to read into
urlStr - URL (or filename) to read from
lang - Null mean guess based on the URI String
Returns:
Returns the model passed in.

guessLang

@Deprecated
public static String guessLang(String urlStr,
                                          String defaultLang)
Deprecated. Use FileUtils.guessLang

Guess the language/type of model data. Updated by Chris, hived off the model-suffix part to FileUtils as part of unifying it with similar code in FileGraph.

Parameters:
urlStr - URL to base the guess on
defaultLang - Default guess
Returns:
String Guessed syntax - or the default supplied

guessLang

@Deprecated
public static String guessLang(String urlStr)
Deprecated. Use FileUtils.guessLang

Guess the language/type of model data

Parameters:
urlStr - URL to base the guess on
Returns:
String Guessed syntax - null for no guess.


Licenced under the Apache License, Version 2.0