pfun.immutable.Immutable
Super class that makes subclasses immutable using dataclasses
Examples:
1 2 3 4 5 6 7 |
|
clone(self, **kwargs)
Make a shallow copy of an instance, potentially overwriting
fields given by kwargs
Examples:
1 2 3 4 5 6 |
|
Parameters:
Name | Type | Description | Default |
---|---|---|---|
kwargs |
|
fields to overwrite |
{} |
Returns:
Type | Description |
---|---|
~T |
New instance of same type with copied and overwritten fields |