Source for file SchemaSearch.class.php

Documentation is available at SchemaSearch.class.php

  1. <?php
  2.  
  3. require_once HARMONI."dataManager/search/SearchCriteria.interface.php";
  4.  
  5. /**
  6. * Limits a search to exclude all other {@link Schema}s except the one specified.
  7. *
  8. * @package harmoni.datamanager.search
  9. *
  10. * @copyright Copyright &copy; 2005, Middlebury College
  11. * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License (GPL)
  12. *
  13. * @version $Id: SchemaSearch.class.php,v 1.8 2007/09/04 20:25:32 adamfranco Exp $
  14. */
  15. class SchemaSearch extends SearchCriteria {
  16. var $_type;
  17. /**
  18. * The constructor.
  19. * @param string $id The id that describes the {@link Schema}.
  20. */
  21. function SchemaSearch( $id ) {
  22. throwError(
  23. new Error(
  24. "SchemaSearch has been deprecated. Use RecordManager::getRecordIDsByType().",
  25. "RecordManager",
  26. true
  27. ));
  28. }
  29. function returnSearchString() {
  30. $mgr = Services::getService("SchemaManager");
  31. $id = $mgr->getIDByType($this->_type);
  32. if (!$id) return null;
  33. return "dm_record.fk_schema='".addslashes($id)."'";
  34. }
  35.  
  36. function postProcess($ids) { return $ids; }
  37.  
  38. }
  39.  
  40. ?>

Documentation generated on Wed, 19 Sep 2007 10:26:20 -0400 by phpDocumentor 1.3.0RC3