nft-faucet/NftFaucet/Models/IpfsBlockchainContext.cs
2022-04-05 00:29:34 +02:00

22 lines
644 B
C#

namespace NftFaucet.Models;
public class IpfsBlockchainContext
{
public string Address { get; private set; }
public string SignedMessage { get; private set; }
public bool IsInitialized => !string.IsNullOrEmpty(Address) && !string.IsNullOrEmpty(SignedMessage);
public void Initialize(string address, string signedMessage)
{
if (string.IsNullOrEmpty(address))
throw new ArgumentNullException(nameof(address));
if (string.IsNullOrEmpty(signedMessage))
throw new ArgumentNullException(nameof(signedMessage));
Address = address;
SignedMessage = signedMessage;
}
}