|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xml.sax.helpers.DefaultHandler nz.ac.waikato.mcennis.rat.parser.xmlHandler.Handler nz.ac.waikato.mcennis.rat.parser.xmlHandler.FOAF2Graph
public class FOAF2Graph
SAX XML parser for reading FOAF files of the LiveJournal dialect. See the DataAquisition modules CrawlLastFM, FileReader, or FileReader2 for a description of the modes, relations, and property IDs produced by this parser. TODO: include a DTD of the LiveJournal FOAF.
Constructor Summary | |
---|---|
FOAF2Graph()
Create a new Parser using the default graph |
|
FOAF2Graph(Graph m)
Create a new Parser using this graph to load data into |
|
FOAF2Graph(Graph m,
WebCrawler c)
Create a new Parser using this graph and parsing new FOAF sites using this crawler |
Method Summary | |
---|---|
void |
characters(char[] arg0,
int arg1,
int arg2)
|
Handler |
duplicate()
Create a complete duplicate of this class |
void |
endDocument()
|
void |
endElement(java.lang.String arg0,
java.lang.String arg1,
java.lang.String arg2)
|
ParsedObject |
get()
Return the underlying parsed object |
Crawler |
getCrawler()
Return the crawler used or null if none is assigned. |
void |
set(ParsedObject o)
Set the underlying parsed object for parsing |
void |
setActorClass(java.lang.String actorClass)
Set the class used to create new actors |
void |
setActorType(java.lang.String actorType)
Set the type (mode) of new actors |
void |
setCrawler(Crawler crawler)
Set the crawler to be used for spidering new pages |
void |
setGraph(Graph foaf)
Set this graph for loading. |
void |
setLinkClass(java.lang.String linkClass)
Class of Link used for new Links |
void |
setLinkType(java.lang.String linkType)
Type (relation) to use for new links |
void |
setPropertyClass(java.lang.String propertyClass)
Class of Property to use |
void |
startDocument()
|
void |
startElement(java.lang.String arg0,
java.lang.String arg1,
java.lang.String arg2,
org.xml.sax.Attributes arg3)
|
Methods inherited from class nz.ac.waikato.mcennis.rat.parser.xmlHandler.Handler |
---|
error, fatalError, warning |
Methods inherited from class org.xml.sax.helpers.DefaultHandler |
---|
endPrefixMapping, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startPrefixMapping, unparsedEntityDecl |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FOAF2Graph()
public FOAF2Graph(Graph m)
m
- graph to be loadedpublic FOAF2Graph(Graph m, WebCrawler c)
m
- graph to be loadedc
- crawler to parse new sitesMethod Detail |
---|
public Crawler getCrawler()
public void setCrawler(Crawler crawler)
Handler
setCrawler
in class Handler
crawler
- crawler to be parsing.public ParsedObject get()
Handler
get
in class Handler
public void setGraph(Graph foaf)
foaf
- graph to be loaded.public void characters(char[] arg0, int arg1, int arg2) throws org.xml.sax.SAXException
characters
in interface org.xml.sax.ContentHandler
characters
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
public void endDocument() throws org.xml.sax.SAXException
endDocument
in interface org.xml.sax.ContentHandler
endDocument
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
public void endElement(java.lang.String arg0, java.lang.String arg1, java.lang.String arg2) throws org.xml.sax.SAXException
endElement
in interface org.xml.sax.ContentHandler
endElement
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
public void startDocument() throws org.xml.sax.SAXException
startDocument
in interface org.xml.sax.ContentHandler
startDocument
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
public void startElement(java.lang.String arg0, java.lang.String arg1, java.lang.String arg2, org.xml.sax.Attributes arg3) throws org.xml.sax.SAXException
startElement
in interface org.xml.sax.ContentHandler
startElement
in class org.xml.sax.helpers.DefaultHandler
org.xml.sax.SAXException
public Handler duplicate()
Handler
duplicate
in class Handler
public void set(ParsedObject o)
Handler
set
in class Handler
o
- underlying parsed objectpublic void setActorClass(java.lang.String actorClass)
actorClass
- classname of actors to be createdpublic void setActorType(java.lang.String actorType)
actorType
- mode of new actorspublic void setLinkClass(java.lang.String linkClass)
linkClass
- class name for new linkspublic void setLinkType(java.lang.String linkType)
linkType
- type (relation) of new linkspublic void setPropertyClass(java.lang.String propertyClass)
propertyClass
- class name of property to use for new properties
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |