* @returns string a new, unique sync marker. */
()
| 118 | * @returns string a new, unique sync marker. |
| 119 | */ |
| 120 | private static function generateSyncMarker() |
| 121 | { |
| 122 | // From https://php.net/manual/en/function.mt-rand.php comments |
| 123 | return pack( |
| 124 | 'S8', |
| 125 | random_int(0, 0xffff), |
| 126 | random_int(0, 0xffff), |
| 127 | random_int(0, 0xffff), |
| 128 | random_int(0, 0xffff) | 0x4000, |
| 129 | random_int(0, 0xffff) | 0x8000, |
| 130 | random_int(0, 0xffff), |
| 131 | random_int(0, 0xffff), |
| 132 | random_int(0, 0xffff) |
| 133 | ); |
| 134 | } |
| 135 | |
| 136 | /** |
| 137 | * Writes the header of the AvroIO object container |