decl_storage! {
trait Store for Module<T: Trait> as KittyStorage {
Kitties get(kitty): map T::Hash => Kitty<T::Hash, T::Balance>;
What is this
for
use?What is
Store
? is this a trait?then
Module
is what?decl_storage!
macro is for what purpose? create multiple storage object suites?what is
<T: Trait> as KittyStorage
? you give name Module asKittyStorage
?
Kitties get(kitty): map T::Hash => Kitty<T::Hash, T::Balance>;
Kitties
object has get
method, attribute is kitty
, then map iterate T::Hash ,
return Kitty object which has T::Hash and T::Balance trait.
is it right...?