/** * @param string $type * * @return array[] */ private function valueArray($type) { $count = $this->reader->long(); $values = array(); for ($i = 0; $i < $count; $i++) { $values[] = $this->{$type}(); } return $values; }
public function testReadingXDRHexLong() { $value = '0000000001'; $reader = new BinaryReader($value); $reader->byteOrder(); $result = $reader->long(); $this->assertEquals(1, $result); }