def _from_binary_syn_link(cls, binary_stream):
    """See base class."""
    ''' Offset to target name - 2 (relative to 16th byte)
        Length of target name - 2
        Offset to print name - 2 (relative to 16th byte)
        Length of print name - 2
        Symbolic link flags - 4
    '''
    offset_target_name, len_target_name, offset_print_name, \
    len_print_name, syn_flags = \
        cls._REPR.unpack(binary_stream[:cls._REPR.size])

    offset = cls._REPR.size + offset_target_name
    target_name = binary_stream[offset:offset+len_target_name].tobytes().decode("utf_16_le")
    offset = cls._REPR.size + offset_print_name
    print_name = binary_stream[offset:offset+len_print_name].tobytes().decode("utf_16_le")

    nw_obj = cls((target_name, print_name, SymbolicLinkFlags(syn_flags)))

    _MOD_LOGGER.debug("Attempted to unpack Symbolic Link from \"%s\"\nResult: %s", binary_stream.tobytes(), nw_obj)

    return nw_obj
def _from_binary_syn_link ( cls , binary_stream ) : offset_target_name , len_target_name , offset_print_name , len_print_name , syn_flags = cls . _REPR . unpack ( binary_stream [ : cls . _REPR . size ] ) offset = cls . _REPR . size + offset_target_name target_name = binary_stream [ offset : offset + len_target_name ] . tobytes ( ) . decode ( "utf_16_le" ) offset = cls . _REPR . size + offset_print_name print_name = binary_stream [ offset : offset + len_print_name ] . tobytes ( ) . decode ( "utf_16_le" ) nw_obj = cls ( ( target_name , print_name , SymbolicLinkFlags ( syn_flags ) ) ) _MOD_LOGGER . debug ( "Attempted to unpack Symbolic Link from \"%s\"\nResult: %s" , binary_stream . tobytes ( ) , nw_obj ) return nw_obj
See base class.