pub fn store<KeyType: 'static>(keyname: impl ToString, child: PersistentChild)Expand description
Store a PersistentChild process for retrieval on a future
reload.
In order to store the Child, you must provide a type and a
name. The type is provided in order to prevent others from
accessing this child (it’s not fully safe, but it takes effort
to break this), while the name is used to identify this
specific Child.
For the type, you should create a new type specifically for this, and this type should not be publicly available. If the type is renamed in between reload cycles, the child will become an inaccessible zombie.
Returns Some if there was already a PersistentChild in
storage with the same key.