Exemplo n.º 1
0
        public static GenericExtrinsicCall RemoveClaim(string mogwaicoinAddress, string account)
        {
            var address = new Vec <U8>();

            address.Create(
                Encoding.ASCII.GetBytes(mogwaicoinAddress).ToList().Select(p => {
                var u = new U8(); u.Create(p); return(u);
            }).ToList()
                );

            var accountId = new RawAccountId();

            accountId.Create(Utils.GetPublicKeyFrom(account));

            return(RemoveClaim(address, accountId));
        }
Exemplo n.º 2
0
        public static GenericExtrinsicCall UpdateClaim(string mogwaicoinAddress, string account, ClaimState claimState, RawBalance balanceAmount)
        {
            var address = new Vec <U8>();

            address.Create(
                Encoding.ASCII.GetBytes(mogwaicoinAddress).ToList().Select(p => {
                var u = new U8(); u.Create(p); return(u);
            }).ToList()
                );

            var accountId = new RawAccountId();

            accountId.Create(Utils.GetPublicKeyFrom(account));

            var state = new EnumType <ClaimState>();

            state.Create(claimState);

            return(UpdateClaim(address, accountId, state, balanceAmount));
        }
Exemplo n.º 3
0
 public static GenericExtrinsicCall RemoveClaim(Vec <U8> address, RawAccountId account)
 {
     return(new GenericExtrinsicCall("DotMogBase", "remove_claim", address, account));
 }
Exemplo n.º 4
0
 public static GenericExtrinsicCall UpdateClaim(Vec <U8> address, RawAccountId account, EnumType <ClaimState> state, RawBalance balance)
 {
     return(new GenericExtrinsicCall("DotMogBase", "update_claim", address, account, state, balance));
 }
Exemplo n.º 5
0
 public static GenericExtrinsicCall Claim(Vec <U8> address, RawAccountId account, Vec <U8> signature)
 {
     return(new GenericExtrinsicCall("DotMogBase", "claim", address, account, signature));
 }
Exemplo n.º 6
0
 public static GenericExtrinsicCall Transfer(RawAccountId to, Hash mogwaiId)
 {
     // TODO check if RawAccountId or AccountId ...
     return(new GenericExtrinsicCall("DotMogModule", "transfer", to, mogwaiId));
 }