def get_type_item(self, value):
        """
        Converts the given value to a ``UsedVolume`` or ``SharedVolume`` tuple for attached volumes. It
        accepts strings, lists, tuples, and dicts as input.

        For strings and collections of a single element, the first item is considered to be an alias for lookup on the map.
        It is converted to a ``SharedVolume`` tuple.
        For two-element collections, the first item defines a new volume alias that can be re-used by other instances and
        the second item is considered to be the mount point for the volume.
        All attached volumes are considered as read-write access.

        :param value: Input value for conversion.
        :return: UsedVolume or SharedVolume tuple.
        :rtype: UsedVolume | SharedVolume
        """
        if isinstance(value, (UsedVolume, SharedVolume)):
            if value.readonly:
                raise ValueError("Attached volumes should not be read-only.")
            return value
        elif isinstance(value, six.string_types):
            return SharedVolume(value)
        elif isinstance(value, (list, tuple)):
            v_len = len(value)
            if v_len == 2:
                if value[1]:
                    return UsedVolume(value[0], value[1])
                return SharedVolume(value[0])
            elif v_len == 1:
                return SharedVolume(value[0])
            raise ValueError("Invalid element length; only tuples and lists of length 1-2 can be converted to a "
                             "UsedVolume or SharedVolume tuple; found length {0}.".format(v_len))
        elif isinstance(value, dict):
            v_len = len(value)
            if v_len == 1:
                k, v = list(value.items())[0]
                if k == 'name':
                    return SharedVolume(v)
                return UsedVolume(k, v)
            elif 'path' in value:
                return UsedVolume(**value)
            return SharedVolume(**value)
        raise ValueError(
            "Invalid type; expected a list, tuple, dict, or string type, found {0}.".format(type(value).__name__))
Converts the given value to a ``UsedVolume`` or ``SharedVolume`` tuple for attached volumes. It
        accepts strings, lists, tuples, and dicts as input.

        For strings and collections of a single element, the first item is considered to be an alias for lookup on the map.
        It is converted to a ``SharedVolume`` tuple.
        For two-element collections, the first item defines a new volume alias that can be re-used by other instances and
        the second item is considered to be the mount point for the volume.
        All attached volumes are considered as read-write access.

        :param value: Input value for conversion.
        :return: UsedVolume or SharedVolume tuple.
        :rtype: UsedVolume | SharedVolume