PageRenderTime 49ms CodeModel.GetById 24ms RepoModel.GetById 1ms app.codeStats 0ms

/libraries/pattemplate/patTemplate/Stat.php

https://bitbucket.org/StasPiv/playzone
PHP | 70 lines | 15 code | 4 blank | 51 comment | 0 complexity | 7e815077b7ad605aa885a64365c549e2 MD5 | raw file
Possible License(s): Apache-2.0, BSD-3-Clause, GPL-2.0, LGPL-2.1
  1. <?PHP
  2. /**
  3. * Base class for patTemplate Stat
  4. *
  5. * $Id: Stat.php 10381 2008-06-01 03:35:53Z pasamio $
  6. *
  7. * A stat component should be implemented for each reader
  8. * to support caching. Stats return information about the
  9. * template source.
  10. *
  11. * @package patTemplate
  12. * @subpackage Stat
  13. * @author Stephan Schmidt <schst@php.net>
  14. */
  15. // Check to ensure this file is within the rest of the framework
  16. defined('JPATH_BASE') or die();
  17. /**
  18. * Base class for patTemplate Stat
  19. *
  20. * $Id: Stat.php 10381 2008-06-01 03:35:53Z pasamio $
  21. *
  22. * A stat component should be implemented for each reader
  23. * to support caching. Stats return information about the
  24. * template source.
  25. *
  26. * @package patTemplate
  27. * @subpackage Stat
  28. * @author Stephan Schmidt <schst@php.net>
  29. * @abstract
  30. */
  31. class patTemplate_Stat extends patTemplate_Module
  32. {
  33. /**
  34. * options, are identical to those of the corresponding reader
  35. *
  36. * @access private
  37. * @var array
  38. */
  39. var $_options = array();
  40. /**
  41. * get the modification time of a template
  42. *
  43. * Needed, if a template cache should be used, that auto-expires
  44. * the cache.
  45. *
  46. * @abstract must be implemented in the template readers
  47. * @param mixed input to read from.
  48. * This can be a string, a filename, a resource or whatever the derived class needs to read from
  49. * @return integer unix timestamp
  50. */
  51. function getModificationTime( $input )
  52. {
  53. return -1;
  54. }
  55. /**
  56. * set options
  57. *
  58. * @access public
  59. * @param array array containing options
  60. */
  61. function setOptions( $options )
  62. {
  63. $this->_options = $options;
  64. }
  65. }
  66. ?>