Protege 3.4.8

edu.stanford.smi.protege.storage.xml
Class XMLKnowledgeBaseFactory

java.lang.Object
  extended by edu.stanford.smi.protege.model.AbstractKnowledgeBaseFactory
      extended by edu.stanford.smi.protege.storage.xml.XMLKnowledgeBaseFactory
All Implemented Interfaces:
KnowledgeBaseFactory, KnowledgeBaseFactory2

public class XMLKnowledgeBaseFactory
extends AbstractKnowledgeBaseFactory

Storage backend to maintain a knowledge base in XML format.

Author:
Ray Fergerson

Field Summary
static String DESCRIPTION
           
 
Fields inherited from interface edu.stanford.smi.protege.model.KnowledgeBaseFactory
FACTORY_CLASS_NAME
 
Constructor Summary
XMLKnowledgeBaseFactory()
           
 
Method Summary
 KnowledgeBase createKnowledgeBase(Collection errors)
           
 KnowledgeBaseSourcesEditor createKnowledgeBaseSourcesEditor(String project, PropertyList list)
          Note that this method should really take a URI for a param rather than a string.
 String getDescription()
           
static String getSourceFile(PropertyList sources)
           
 BufferedReader getSourceReader(KnowledgeBase kb, PropertyList sources, Collection errors)
           
static URI getSourceRelativeURI(PropertyList sources)
           
 boolean isComplete(PropertyList sources)
           
 KnowledgeBase loadKnowledgeBase(BufferedReader reader, Collection errors)
           
static void loadKnowledgeBase(KnowledgeBase kb, BufferedReader reader, boolean isInclude, Collection errors)
           
protected  void loadKnowledgeBase(KnowledgeBase kb, PropertyList sources, boolean isInclude, Collection errors)
           
 void loadKnowledgeBase(KnowledgeBase kb, String sourceName, boolean isInclude, Collection errors)
           
 KnowledgeBase loadKnowledgeBase(String filename, Collection errors)
           
 void saveKnowledgeBase(KnowledgeBase kb, PropertyList sources, Collection errors)
           
 void saveKnowledgeBase(KnowledgeBase kb, String filename, Collection errors)
           
static void saveKnowledgeBase(KnowledgeBase kb, Writer writer, Collection errors)
           
static void setSourceFile(PropertyList sources, String filename)
           
static void setSourceURIs(PropertyList sources, URI relativeURI)
           
 
Methods inherited from class edu.stanford.smi.protege.model.AbstractKnowledgeBaseFactory
close, close, createNarrowFrameStore, createReader, createTempFile, createWriter, getProjectFilePath, getSourceUri, includeKnowledgeBase, loadKnowledgeBase, makeTempFilePermanent, prepareToSaveInFormat, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DESCRIPTION

public static final String DESCRIPTION
See Also:
Constant Field Values
Constructor Detail

XMLKnowledgeBaseFactory

public XMLKnowledgeBaseFactory()
Method Detail

createKnowledgeBase

public KnowledgeBase createKnowledgeBase(Collection errors)

createKnowledgeBaseSourcesEditor

public KnowledgeBaseSourcesEditor createKnowledgeBaseSourcesEditor(String project,
                                                                   PropertyList list)
Description copied from interface: KnowledgeBaseFactory
Note that this method should really take a URI for a param rather than a string. I maintain the string for backwards compatibility


getSourceFile

public static String getSourceFile(PropertyList sources)

getSourceRelativeURI

public static URI getSourceRelativeURI(PropertyList sources)

getSourceReader

public BufferedReader getSourceReader(KnowledgeBase kb,
                                      PropertyList sources,
                                      Collection errors)

getDescription

public String getDescription()

isComplete

public boolean isComplete(PropertyList sources)

loadKnowledgeBase

protected void loadKnowledgeBase(KnowledgeBase kb,
                                 PropertyList sources,
                                 boolean isInclude,
                                 Collection errors)
Specified by:
loadKnowledgeBase in class AbstractKnowledgeBaseFactory

loadKnowledgeBase

public static void loadKnowledgeBase(KnowledgeBase kb,
                                     BufferedReader reader,
                                     boolean isInclude,
                                     Collection errors)

loadKnowledgeBase

public void loadKnowledgeBase(KnowledgeBase kb,
                              String sourceName,
                              boolean isInclude,
                              Collection errors)

loadKnowledgeBase

public KnowledgeBase loadKnowledgeBase(BufferedReader reader,
                                       Collection errors)

loadKnowledgeBase

public KnowledgeBase loadKnowledgeBase(String filename,
                                       Collection errors)

saveKnowledgeBase

public void saveKnowledgeBase(KnowledgeBase kb,
                              PropertyList sources,
                              Collection errors)

saveKnowledgeBase

public static void saveKnowledgeBase(KnowledgeBase kb,
                                     Writer writer,
                                     Collection errors)

saveKnowledgeBase

public void saveKnowledgeBase(KnowledgeBase kb,
                              String filename,
                              Collection errors)

setSourceFile

public static void setSourceFile(PropertyList sources,
                                 String filename)

setSourceURIs

public static void setSourceURIs(PropertyList sources,
                                 URI relativeURI)

Protege 3.4.8

Submit a bug report or feature request
Protégé is a trademark of Stanford University.
Copyright (c) 1998-2012 Stanford University.