diff --git a/src/dictrule/var_property.py b/src/dictrule/var_property.py index afb899f..bcbbd64 100644 --- a/src/dictrule/var_property.py +++ b/src/dictrule/var_property.py @@ -52,24 +52,24 @@ def __init__( self.__doc__ = doc self.__name__ = fget.__name__ - def __get__(self, obj, objtype=None): + def __get__(self, obj, objtype=None) -> Any: if obj is None: return self if self.fget is None: raise AttributeError("unreadable attribute") return self.fget(obj) - def __set__(self, obj, value): + def __set__(self, obj, value) -> None: if self.fset is None: raise AttributeError("can't set attribute") self.fset(obj, value) - def __delete__(self, obj): + def __delete__(self, obj) -> None: if self.fdel is None: raise AttributeError("can't delete attribute") self.fdel(obj) - def getter(self, fget): + def getter(self, fget) -> "var_property": """Getter decorator Examples: @@ -83,7 +83,7 @@ def getter(self, fget): """ return type(self)(fget, self.fset, self.fdel, self.__doc__) - def setter(self, fset): + def setter(self, fset) -> "var_property": """Setter decorator Examples: @@ -94,7 +94,7 @@ def setter(self, fset): """ return type(self)(self.fget, fset, self.fdel, self.__doc__) - def deleter(self, fdel): + def deleter(self, fdel) -> "var_property": """Deleter decorator Examples: