• Articles
  • Api Documentation

    Show / Hide Table of Contents
    • Yort.Humm.InStore
      • CreateKeyRequest
      • CreateKeyResponse
      • HummApiUrlSelector
      • HummClient
      • HummClientConfiguration
      • HummCountry
      • HummEnvironment
      • HummResponseSignatureException
      • HummStatusCodes
      • IHummApiUrlSelector
      • IHummClient
      • InviteRequest
      • InviteResponse
      • PendingAuthorisationEventArgs
      • ProcessAuthorisationRequest
      • ProcessAuthorisationResponse
      • ProcessSalesAdjustmentRequest
      • ProcessSalesAdjustmentResponse
      • ProcessSalesAdjustmentReversalRequest
      • ProcessSalesAdjustmentReversalResponse
      • PurchaseItemsCollection
      • RequestStates
      • SendReceiptRequest
      • SendReceiptResponse
    • Yort.Humm.InStore.Infrastructure
      • Hmac256SignatureGenerator
      • ISignatureGenerator
      • RequestBase
      • ResponseBase
      • SignedRequestWriter

    Interface ISignatureGenerator

    A generic interface for components that can calculate a digital signature for values from a Humm request or response.

    Inherited Members
    IDisposable.Dispose()
    Namespace: Yort.Humm.InStore.Infrastructure
    Assembly: Yort.Humm.InStore.dll
    Syntax
    public interface ISignatureGenerator : IDisposable

    Methods

    | Improve this Doc View Source

    GenerateSignature(IEnumerable<KeyValuePair<String, Object>>)

    Generates the signature and returns it as a string.

    Declaration
    string GenerateSignature(IEnumerable<KeyValuePair<string, object>> properties)
    Parameters
    Type Name Description
    IEnumerable<KeyValuePair<String, Object>> properties

    A dictionary of values to be considered for use in the signature generation. See remarks for more details.

    Returns
    Type Description
    String

    A string containing the signature calculated from the properties provided.

    Remarks

    Humm signatures are currently case-insensitive hexadecimal strings.

    Only values from the properties argument where the key starts with "x_" will be used, so the caller may pass the full property set if desired. Values of type decimal are treated as dollar values and will be automatically multiplied by 100, so should be passed as their decimal dollar representation. Values that are null will be ignored (treated as a missing/undeclared property and excluded from the signature generation).

    Exceptions
    Type Condition
    ArgumentNullException

    Thrown if properties is null.

    See Also

    IDisposable
    • Improve this Doc
    • View Source
    Back to top Copyright (c) 2020 Troy Willmot