Move element from sequence, member from mapping.

        :param dest: the destination
        :type dest: Pointer
        :param src: the source
        :type src: Pointer
        :return: resolved document
        :rtype: Target

        .. note::

            This operation is functionally identical to a "remove" operation on
            the "from" location, followed immediately by an "add" operation at
            the target location with the value that was just removed.

            The "from" location MUST NOT be a proper prefix of the "path"
            location; i.e., a location cannot be moved into one of its children

def move(self, dest, src):
        """Move element from sequence, member from mapping.

        :param dest: the destination
        :type dest: Pointer
        :param src: the source
        :type src: Pointer
        :return: resolved document
        :rtype: Target

        .. note::

            This operation is functionally identical to a "remove" operation on
            the "from" location, followed immediately by an "add" operation at
            the target location with the value that was just removed.

            The "from" location MUST NOT be a proper prefix of the "path"
            location; i.e., a location cannot be moved into one of its children

        """

        doc = deepcopy(self.document)

        # delete
        parent, fragment = None, doc
        for token in Pointer(src):
            parent, fragment = fragment, token.extract(fragment,
                                                       bypass_ref=True)

        if isinstance(parent, Mapping):
            del parent[token]

        if isinstance(parent, MutableSequence):
            parent.pop(int(token))

        # insert
        return Target(doc).add(dest, fragment)