Planet.php 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  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_Barcode
  17. * @subpackage Object
  18. * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. * @version $Id$
  21. */
  22. /**
  23. * @see Zend_Barcode_Object_Postnet
  24. */
  25. require_once 'Zend/Barcode/Object/Postnet.php';
  26. /**
  27. * @see Zend_Validate_Barcode
  28. */
  29. require_once 'Zend/Validate/Barcode.php';
  30. /**
  31. * Class for generate Planet barcode
  32. *
  33. * @category Zend
  34. * @package Zend_Barcode
  35. * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  36. * @license http://framework.zend.com/license/new-bsd New BSD License
  37. */
  38. class Zend_Barcode_Object_Planet extends Zend_Barcode_Object_Postnet
  39. {
  40. /**
  41. * Coding map
  42. * - 0 = half bar
  43. * - 1 = complete bar
  44. * @var array
  45. */
  46. protected $_codingMap = array(
  47. 0 => "00111",
  48. 1 => "11100",
  49. 2 => "11010",
  50. 3 => "11001",
  51. 4 => "10110",
  52. 5 => "10101",
  53. 6 => "10011",
  54. 7 => "01110",
  55. 8 => "01101",
  56. 9 => "01011"
  57. );
  58. }