Xindice API
version 1.2m1

org.apache.xindice.core
Class DBObserver

java.lang.Object
  extended byorg.apache.xindice.core.DBObserver
Direct Known Subclasses:
DatabaseChangeObserver

public abstract class DBObserver
extends Object

Observer for Xindice DB activities

Version:
$Revision: 541508 $, $Date: 2007-05-24 21:54:12 -0400 (Thu, 24 May 2007) $

Constructor Summary
DBObserver()
           
 
Method Summary
abstract  void createCollection(Collection col)
          Called after Collection.create()
abstract  void dropCollection(Collection col)
          Called before Collection.drop()
abstract  void dropDocument(Collection col, Key key)
          Called before Collection.remove(key)
abstract  void flushDatabaseConfig(Database db, Configuration cfg)
          Called after Database.flushConfig()
static DBObserver getInstance()
          Returns the observer instance, must be non-null
abstract  void loadDocument(Collection col, Record record, org.w3c.dom.Document document)
          Called after Collection.getDocument()
abstract  void putDocument(Collection col, Key key, org.w3c.dom.Document document, boolean create)
          Called after Collection.putDocument()
abstract  void setCollectionConfig(Collection col, Configuration cfg)
          Called after Collection.setConfig()
abstract  void setDatabaseConfig(Database db, Map collections, Configuration cfg)
          Called after Database.setConfig()
static void setInstance(DBObserver obs)
          Sets the default observer instance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DBObserver

public DBObserver()
Method Detail

setInstance

public static void setInstance(DBObserver obs)
Sets the default observer instance


getInstance

public static DBObserver getInstance()
Returns the observer instance, must be non-null


setDatabaseConfig

public abstract void setDatabaseConfig(Database db,
                                       Map collections,
                                       Configuration cfg)
Called after Database.setConfig()


setCollectionConfig

public abstract void setCollectionConfig(Collection col,
                                         Configuration cfg)
Called after Collection.setConfig()


flushDatabaseConfig

public abstract void flushDatabaseConfig(Database db,
                                         Configuration cfg)
Called after Database.flushConfig()


dropCollection

public abstract void dropCollection(Collection col)
                             throws DBException
Called before Collection.drop()

Throws:
DBException

createCollection

public abstract void createCollection(Collection col)
                               throws DBException
Called after Collection.create()

Throws:
DBException

putDocument

public abstract void putDocument(Collection col,
                                 Key key,
                                 org.w3c.dom.Document document,
                                 boolean create)
                          throws DBException
Called after Collection.putDocument()

Throws:
DBException

loadDocument

public abstract void loadDocument(Collection col,
                                  Record record,
                                  org.w3c.dom.Document document)
                           throws DBException
Called after Collection.getDocument()

Throws:
DBException

dropDocument

public abstract void dropDocument(Collection col,
                                  Key key)
                           throws DBException
Called before Collection.remove(key)

Throws:
DBException

Xindice API
version 1.2m1

Copyright (c) 1999-2007 The Apache Software Foundation. All Rights Reserved.