Serializer.php 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?php
  2. /**
  3. * Zend Framework
  4. *
  5. * LICENSE
  6. *
  7. * This source file is subject to the new BSD license that is bundled
  8. * with this package in the file LICENSE.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * http://framework.zend.com/license/new-bsd
  11. * If you did not receive a copy of the license and are unable to
  12. * obtain it through the world-wide-web, please send an email
  13. * to license@zend.com so we can send you a copy immediately.
  14. *
  15. * @category Zend
  16. * @package Zend_Amf
  17. * @subpackage Parse
  18. * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. */
  21. /**
  22. * Base abstract class for all AMF serializers.
  23. *
  24. * @package Zend_Amf
  25. * @subpackage Parse
  26. * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
  27. * @license http://framework.zend.com/license/new-bsd New BSD License
  28. */
  29. abstract class Zend_Amf_Parse_Serializer
  30. {
  31. /**
  32. * Refrence to the current output stream being constructed
  33. *
  34. * @var string
  35. */
  36. protected $_stream;
  37. /**
  38. * Constructor
  39. *
  40. * @param Zend_Amf_Parse_OutputStream $stream
  41. * @return void
  42. */
  43. public function __construct(Zend_Amf_Parse_OutputStream $stream)
  44. {
  45. $this->_stream = $stream;
  46. }
  47. /**
  48. * Find the PHP object type and convert it into an AMF object type
  49. *
  50. * @param mixed $content
  51. * @param int $markerType
  52. * @return void
  53. */
  54. public abstract function writeTypeMarker($content, $markerType=null);
  55. }