com.googlecode.fascinator.harvester.skos
Class SkosHarvester

java.lang.Object
  extended by com.googlecode.fascinator.common.harvester.impl.GenericHarvester
      extended by com.googlecode.fascinator.harvester.skos.SkosHarvester
All Implemented Interfaces:
com.googlecode.fascinator.api.harvester.Harvester, com.googlecode.fascinator.api.Plugin

public class SkosHarvester
extends com.googlecode.fascinator.common.harvester.impl.GenericHarvester

This plugin harvest SKOS rdf/xml Concept Scheme. Sample of rdf/xml file for concept can be downloaded from http://namespace.adfi.usq.edu. au/anzsrc/

Configuration

Sample configuration file for SKOS harvester: anzsrc-for.json and anzsrc-seo.json.

Option Description Required Default
baseFile File of the rdf/xml skos scheme Yes ${fascinator.home}/skos/for.rdf

Examples

  1. Harvesting for concept scheme
        "harvester": {
             "type": "skos",
             "skos": {
                 "baseFile": "${fascinator.home}/skos/for.rdf"
             }
         }
     

Rule file

Sample rule file for the Geonames harvester: skos.py

Wiki Link

None

Author:
Linda Octalina

Constructor Summary
SkosHarvester()
          Skos harvester constructor
 
Method Summary
 org.ontoware.rdf2go.model.node.URI getConceptScheme()
          Get conceptScheme value
 Set<String> getObjectIdList()
          Harvest the next set of skos concept, and return their Object IDs
 org.ontoware.rdf2go.model.Model getRdfModel(InputStream rdfIn)
          Parse RDF data from an inputstream
 boolean hasMoreObjects()
           
 void init()
          Init method to initialise skos harvester
 
Methods inherited from class com.googlecode.fascinator.common.harvester.impl.GenericHarvester
getDeletedObjectIdList, getId, getJsonConfig, getName, getObjectId, getPluginDetails, getStorage, hasMoreDeletedObjects, init, init, setStorage, shutdown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SkosHarvester

public SkosHarvester()
Skos harvester constructor

Method Detail

init

public void init()
          throws com.googlecode.fascinator.api.harvester.HarvesterException
Init method to initialise skos harvester

Specified by:
init in class com.googlecode.fascinator.common.harvester.impl.GenericHarvester
Throws:
com.googlecode.fascinator.api.harvester.HarvesterException

getObjectIdList

public Set<String> getObjectIdList()
                            throws com.googlecode.fascinator.api.harvester.HarvesterException
Harvest the next set of skos concept, and return their Object IDs

Returns:
Set The set of object IDs just harvested
Throws:
com.googlecode.fascinator.api.harvester.HarvesterException - If there are errors

getConceptScheme

public org.ontoware.rdf2go.model.node.URI getConceptScheme()
Get conceptScheme value

Returns:
the conceptscheme

hasMoreObjects

public boolean hasMoreObjects()

getRdfModel

public org.ontoware.rdf2go.model.Model getRdfModel(InputStream rdfIn)
Parse RDF data from an inputstream

Parameters:
rdfIn, - the inputstream to read and parse
Returns:
Model object after parsing


Copyright © 2009-2011. All Rights Reserved.