What a function atom's function gets (Effect's FnContext): its
reads do not make the atom depend on anything.
Attributes#
| Attribute | Type | Description |
|---|---|---|
registry | AtomRegistryService |
Functions#
__call__#
__call__[A](atom) -> A| Parameter | Type | Description |
|---|---|---|
atom | Atom[A] |
Returns A
def __call__[A](self, atom: Atom[A], /) -> A: ...result#
result[A, E](atom, /, *, suspend_on_waiting=False) -> Effect[A, E]| Parameter | Type | Description |
|---|---|---|
atom | Atom[AsyncResult[A, E]] | |
suspend_on_waiting | bool = False |
Returns Effect[A, E]
def result[A, E](
self, atom: Atom[AsyncResult[A, E]], /, *, suspend_on_waiting: bool = False
) -> Effect[A, E]: ...add_finalizer#
add_finalizer(f) -> None| Parameter | Type | Description |
|---|---|---|
f | Callable[[], None] |
def add_finalizer(self, f: Callable[[], None], /) -> None: ...mount#
mount(atom) -> None| Parameter | Type | Description |
|---|---|---|
atom | Atom[Any] |
def mount(self, atom: Atom[Any], /) -> None: ...refresh#
refresh(atom) -> None| Parameter | Type | Description |
|---|---|---|
atom | Atom[Any] |
def refresh(self, atom: Atom[Any], /) -> None: ...self#
self() -> Option[Any]Returns Option[Any]
def self(self) -> Option[Any]: ...set_self#
set_self(value) -> None| Parameter | Type | Description |
|---|---|---|
value | Any |
def set_self(self, value: Any, /) -> None: ...set#
set[W](atom, value) -> None| Parameter | Type | Description |
|---|---|---|
atom | Writable[Any, W] | |
value | W |
def set[W](self, atom: Writable[Any, W], value: W, /) -> None: ...set_result#
set_result[A, E, W](atom, value) -> Effect[A, E]| Parameter | Type | Description |
|---|---|---|
atom | Writable[AsyncResult[A, E], W] | |
value | W |
Returns Effect[A, E]
def set_result[A, E, W](
self, atom: Writable[AsyncResult[A, E], W], value: W, /
) -> Effect[A, E]: ...some#
some[A](atom) -> Effect[A]| Parameter | Type | Description |
|---|---|---|
atom | Atom[Option[A]] |
Returns Effect[A]
def some[A](self, atom: Atom[Option[A]], /) -> Effect[A]: ...stream#
stream[A](atom, /, *, without_initial_value=False) -> Stream[A]| Parameter | Type | Description |
|---|---|---|
atom | Atom[A] | |
without_initial_value | bool = False |
Returns Stream[A]
def stream[A](self, atom: Atom[A], /, *, without_initial_value: bool = False) -> Stream[A]: ...stream_result#
stream_result[A, E](atom, /, *, without_initial_value=False) -> Stream[A, E]| Parameter | Type | Description |
|---|---|---|
atom | Atom[AsyncResult[A, E]] | |
without_initial_value | bool = False |
Returns Stream[A, E]
def stream_result[A, E](
self, atom: Atom[AsyncResult[A, E]], /, *, without_initial_value: bool = False
) -> Stream[A, E]: ...subscribe#
subscribe[A](atom, f, /, *, immediate=False) -> None| Parameter | Type | Description |
|---|---|---|
atom | Atom[A] | |
f | Callable[[A], None] | |
immediate | bool = False |
def subscribe[A](
self, atom: Atom[A], f: Callable[[A], None], /, *, immediate: bool = False
) -> None: ...