refcount/__init__.py
def value(self):
        """
        Reference count protected value

        Allows access to the protected value as long as a valid reference count is held.

        >>> from refcount import RefcountedValue
        >>> ref = RefcountedValue(value=True)
        >>> ref.value
        True
        >>> ref.dec()
        >>> ref.value # doctest: +IGNORE_EXCEPTION_DETAIL
        Traceback (most recent call last):
        NameError: Value referenced with no reference count

        :return: value
        :raises NameError: Value referenced with no reference count
        """
        if self._usecount == 0:
            raise NameError('Value referenced with no reference count')
        return self._value

        Reference count protected value

        Allows access to the protected value as long as a valid reference count is held.

        >>> from refcount import RefcountedValue
        >>> ref = RefcountedValue(value=True)
        >>> ref.value
        True
        >>> ref.dec()
        >>> ref.value # doctest: +IGNORE_EXCEPTION_DETAIL
        Traceback (most recent call last):
        NameError: Value referenced with no reference count

        :return: value
        :raises NameError: Value referenced with no reference count
        
Reference count protected value
Allows access to the protected value as long as a valid reference count is held.


Reference count protected value Allows access to the protected value as long as a valid reference count is held .
def value(self):
        if self._usecount == 0:
            raise NameError('Value referenced with no reference count')
        return self._value
def value ( self ) : if self . _usecount == 0 : raise NameError ( 'Value referenced with no reference count' ) return self . _value
Reference count protected value
Allows access to the protected value as long as a valid reference count is held.
Reference count protected value Allows access to the protected value as long as a valid reference count is held .
"""
        Reference count protected value

        Allows access to the protected value as long as a valid reference count is held.

        >>> from refcount import RefcountedValue
        >>> ref = RefcountedValue(value=True)
        >>> ref.value
        True
        >>> ref.dec()
        >>> ref.value # doctest: +IGNORE_EXCEPTION_DETAIL
        Traceback (most recent call last):
        NameError: Value referenced with no reference count

        :return: value
        :raises NameError: Value referenced with no reference count
        """
None
Value referenced with no reference count
Value referenced with no reference count
NameError
self