magneticalc.Validatable

# ``magneticalc`.`Validatable``

module documentation

Validatable module.

Class | `Validatable` | Validatable class.
Function | `require_valid` | Decorator that requires a validatable object to be valid before calling a function.
Function | `validator` | Decorator that invalidates a validatable object and then validates it based on the result of calling a function.

def require_valid(func: `Callable`) -> `Callable`:

Decorator that requires a validatable object to be valid before calling a function.

Parameters
func: `Callable` | Method of a validatable instance

Returns
`Callable` | Function

def validator(func: `Callable`) -> `Callable`:

Decorator that invalidates a validatable object and then validates it based on the result of calling a function.

Parameters
func: `Callable` | Method of a validatable instance

Returns
`Callable` | Function