1 : <?php
2 :
3 : /**
4 : * \Midi\Event\SequenceNumberEvent
5 : *
6 : * @package Midi
7 : * @subpackage Event
8 : * @copyright © 2009 Tommy Montgomery <http://phpmidiparser.com/>
9 : * @since 1.0
10 : */
11 :
12 : namespace Midi\Event;
13 :
14 : /**
15 : * Represents a sequence number meta event
16 : *
17 : * @package Midi
18 : * @subpackage Event
19 : * @since 1.0
20 : * @todo Document what this event actually does
21 : */
22 1 : class SequenceNumberEvent extends MetaEvent {
23 :
24 : /**
25 : * Constructor
26 : *
27 : * @since 1.0
28 : *
29 : * @param int $msb The most significant bits
30 : * @param int $lsb The least significant bits
31 : */
32 : public function __construct($msb, $lsb) {
33 3 : parent::__construct(array($msb, $lsb));
34 3 : }
35 :
36 : /**
37 : * @since 1.0
38 : *
39 : * @return string
40 : */
41 : public function getParamDescription() {
42 1 : return 'most significant bits: ' . $this->data[0] . ', least significant bits: ' . $this->data[1];
43 : }
44 :
45 : /**
46 : * @since 1.0
47 : * @uses MetaEventType::SEQUENCE_NUMBER
48 : *
49 : * @return int
50 : */
51 : public function getSubtype() {
52 1 : return MetaEventType::SEQUENCE_NUMBER;
53 : }
54 :
55 : }
56 :
|