<?php

class ThdDoctrineListener extends Doctrine_Record_Listener {

  public function postInsert(Doctrine_Event $event) {
    $obj = $event->getInvoker();

    // Index in solr
    sfContext::getInstance()->getLogger()->info("Insert object. Index in solr");
  }

  public function postUpdate(Doctrine_Event $event) {
    $obj = $event->getInvoker();

    // Reindex in solr
    sfContext::getInstance()->getLogger()->info("Update object. Reindex in solr");
  }
}