org.openrdf.elmo.smusher.listener
Class SameAsListener

java.lang.Object
  extended by org.openrdf.elmo.smusher.listener.SameAsListener
All Implemented Interfaces:
SmusherListener

public class SameAsListener
extends Object
implements SmusherListener

A listener that represents matches using a given property (owl:sameAs) by default and adds them to a given repository.

Author:
Peter Mika (pmika@cs.vu.nl)

Field Summary
protected static Logger _logger
           
 
Constructor Summary
SameAsListener(Repository repository)
          Default constructor creates a listener where owl:sameAs statements are added symmetrically (i.e.
SameAsListener(Repository repository, boolean symmetric)
          Constructor that allows you to set whether you want owl:sameAs statements to be symmetric and whether the matches reported should be immediately committed to the store.
SameAsListener(Repository repository, URI property)
           
 
Method Summary
 void commit()
           
 void finish()
           
 void matchFound(Resource first, Resource second)
           
 void setThreshold(int threshold)
           
 void start()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_logger

protected static final Logger _logger
Constructor Detail

SameAsListener

public SameAsListener(Repository repository)
Default constructor creates a listener where

Parameters:
repository -

SameAsListener

public SameAsListener(Repository repository,
                      URI property)

SameAsListener

public SameAsListener(Repository repository,
                      boolean symmetric)
Constructor that allows you to set whether you want owl:sameAs statements to be symmetric and whether the matches reported should be immediately committed to the store. If autoCommit is set to false, the statements are committed whenever the preset threshold is reached or commit() is called.

Parameters:
repository -
symmetric -
autoCommit -
Method Detail

setThreshold

public void setThreshold(int threshold)

start

public void start()
Specified by:
start in interface SmusherListener

matchFound

public void matchFound(Resource first,
                       Resource second)
Specified by:
matchFound in interface SmusherListener

commit

public void commit()
Specified by:
commit in interface SmusherListener

finish

public void finish()
Specified by:
finish in interface SmusherListener


Copyright © 2004-2008 Aduna. All Rights Reserved.