Pular para o conteúdo principal

PadesSignatureStarter

Namespace: Lacuna.RestPki.Client
Assembly: Lacuna.RestPki.Client
Class

Utility class to facilitate the startup of a PADeS signature process with Rest PKI

public class PadesSignatureStarter : SignatureStarter

Hierarquia: objectSignatureStarterPadesSignatureStarter

Construtores

PadesSignatureStarter(RestPkiClient)

public PadesSignatureStarter(RestPkiClient client)

Parâmetros

NomeTipoDescrição
clientRestPkiClient

Propriedades

BypassMarksIfSigned

public bool BypassMarksIfSigned { get; set; }

Retorno

bool


CertificationLevel

public PadesCertificationLevel CertificationLevel { get; set; }

Retorno

PadesCertificationLevel


CustomSignatureFieldName

public string CustomSignatureFieldName { get; set; }

Retorno

string


MeasurementUnits

public PadesMeasurementUnits MeasurementUnits { get; set; }

Retorno

PadesMeasurementUnits


PageOptimization

public PadesPageOptimization PageOptimization { get; set; }

Retorno

PadesPageOptimization


PdfMarks

public List<PdfMark> PdfMarks { get; set; }

Retorno

List<PdfMark>


Reason

public string Reason { get; set; }

Retorno

string


VisualRepresentation

public PadesVisualRepresentation VisualRepresentation { get; set; }

Retorno

PadesVisualRepresentation


Métodos

SetPdfToSign(byte[])

Sets the content to sign via a byte array

public void SetPdfToSign(byte[] content)

Parâmetros

NomeTipoDescrição
contentbyte[]The byte array representing the content to be signed

SetPdfToSign(FileResult)

Sets the PDf to sign from a file result from a previous call to Rest PKI

public void SetPdfToSign(FileResult pdf)

Parâmetros

NomeTipoDescrição
pdfFileResult

SetPdfToSign(Stream)

Sets the content to sign via a stream object

public void SetPdfToSign(Stream pdfStream)

Parâmetros

NomeTipoDescrição
pdfStreamStreamThe stream representing thye content to be signed

SetPdfToSign(string)

Sets the content to sign via a file path string

public void SetPdfToSign(string path)

Parâmetros

NomeTipoDescrição
pathstringThe path where the file will be found

Exceções

TipoCondição
FileNotFoundExceptionIn case a file cannot be found with the given path string

SetVisualRepresentation(PadesVisualRepresentation)

Indicates that the signature created with this starter will have a visual representation indicated by

visualRepresentation
public void SetVisualRepresentation(PadesVisualRepresentation visualRepresentation)

Parâmetros

NomeTipoDescrição
visualRepresentationPadesVisualRepresentationThe visual representation that should be added to the result pdf

Start()

Starts the signature without the web pki support

public override ClientSideSignatureInstructions Start()

Retorno

ClientSideSignatureInstructions — The instructions to proceed with the signature


StartAsync()

Starts the signature without the web pki support

public override Task<ClientSideSignatureInstructions> StartAsync()

Retorno

Task<ClientSideSignatureInstructions> — The instructions to proceed with the signature


StartWithWebPki()

Starts the signature leveraging the presence of the web pki

public override string StartWithWebPki()

Retorno

string — The signature token


StartWithWebPkiAsync()

Starts the signature leveraging the presence of the web pki

public override Task<string> StartWithWebPkiAsync()

Retorno

Task<string> — The signature token


Membros herdados

Client, Done, CertificateInfo, SetSignerCertificate(byte[]), SetSignaturePolicy(Guid), SetSecurityContext(Guid), SetCallbackArgument(string), GetCertificateInfo(), SignerCertificate, SignaturePolicyId, SecurityContextId, CallbackArgument, IgnoreRevocationStatusUnknown, GetType(), MemberwiseClone(), ToString(), Equals(object), Equals(object, object), ReferenceEquals(object, object), GetHashCode()