Beispiel #1
0
 public SignerOutput(JwsRepresentation jwsRepresentation, QrData qrData = null)
 {
     JwsRepresentation = jwsRepresentation;
     if (qrData != null)
     {
         SignedQrData = new SignedQrData(qrData, jwsRepresentation.Signature);
     }
 }
Beispiel #2
0
 public Receipt(
     ReceiptNumber number,
     RegisterIdentifier registerIdentifier,
     TaxData taxData,
     CurrencyValue turnover,
     CertificateSerialNumber certificateSerialNumber,
     JwsRepresentation previousJwsRepresentation,
     byte[] key,
     LocalDateTime created = null)
     : this(number, registerIdentifier, taxData, certificateSerialNumber, key, created)
 {
     PreviousJwsRepresentation = previousJwsRepresentation;
     ChainValue        = ComputeChainValue();
     Turnover          = turnover ?? throw new ArgumentException("The turnover has to be specified.");
     EncryptedTurnover = EncryptTurnover();
 }
Beispiel #3
0
 public Receipt(
     ReceiptNumber number,
     RegisterIdentifier registerIdentifier,
     TaxData taxData,
     CurrencyValue turnover,
     CertificateSerialNumber certificateSerialNumber,
     JwsRepresentation previousJwsRepresentation,
     byte[] key,
     LocalDateTime created = null)
 {
     Number                    = number ?? throw new ArgumentException("The receipt number has to be specified.");
     RegisterIdentifier        = registerIdentifier ?? throw new ArgumentException("The register identifier has to be specified.");
     TaxData                   = taxData ?? throw new ArgumentException("The tax data have to be specified.");
     Turnover                  = turnover ?? throw new ArgumentException("The turnover has to be specified.");
     CertificateSerialNumber   = certificateSerialNumber ?? throw new ArgumentException("The certificate serial number has to be specified.");
     PreviousJwsRepresentation = previousJwsRepresentation;
     Created                   = created ?? LocalDateTime.Now;
     Suite             = "R1-AT1";
     Key               = key;
     ChainValue        = ComputeChainValue();
     EncryptedTurnover = EncryptTurnover();
 }