Ejemplo n.º 1
0
        public void Should_Convert_To_Namespace_Alias()
        {
            var namespaceId = new NamespaceId("foo");
            var byteArray   = namespaceId.AliasToRecipient();

            byteArray.Length.Should().Be(25);
        }
Ejemplo n.º 2
0
        public byte[] GetBytes()
        {
            if (Address != null)
            {
                return(Address.Plain.FromBase32String());
            }
            else if (NamespaceId != null)
            {
                return(NamespaceId.AliasToRecipient());
            }

            throw new IllegalStateException("Recipient is not specific");
        }