src/Codec/TimestampFirstCombCodec.php
protected function swapTimestampAndRandomBits(array &$components)
    {
        $last48Bits = $components[4];
        if (count($components) == 6) {
            $last48Bits = $components[5];
            $components[5] = $components[0] . $components[1];
        } else {
            $components[4] = $components[0] . $components[1];
        }

        $components[0] = substr($last48Bits, 0, 8);
        $components[1] = substr($last48Bits, 8, 4);
    }
protected function swapTimestampAndRandomBits(array &$components)
    {
        $last48Bits = $components[4];
        if (count($components) == 6) {
            $last48Bits = $components[5];
            $components[5] = $components[0] . $components[1];
        } else {
            $components[4] = $components[0] . $components[1];
        }

        $components[0] = substr($last48Bits, 0, 8);
        $components[1] = substr($last48Bits, 8, 4);
    }
protected function swapTimestampAndRandomBits ( array & $ components ) { $ last48Bits = $ components [ 4 ] ; if ( count ( $ components ) == 6 ) { $ last48Bits = $ components [ 5 ] ; $ components [ 5 ] = $ components [ 0 ] . $ components [ 1 ] ; } else { $ components [ 4 ] = $ components [ 0 ] . $ components [ 1 ] ; } $ components [ 0 ] = substr ( $ last48Bits , 0 , 8 ) ; $ components [ 1 ] = substr ( $ last48Bits , 8 , 4 ) ; }
Swaps the first 48 bits with the last 48 bits

@param array $components An array of UUID components (the UUID exploded on its dashes)

@return void
Swaps the first 48 bits with the last 48 bits