static KeyResponseStatus ParseKeyResponseStatus(ApduResponseStatus raw) { switch (raw) { case ApduResponseStatus.NoError: return(KeyResponseStatus.Success); case ApduResponseStatus.ConditionsNotSatisfied: return(KeyResponseStatus.TestOfuserPresenceRequired); case ApduResponseStatus.WrongData: return(KeyResponseStatus.BadKeyHandle); default: return(KeyResponseStatus.Failure); } }
static KeyResponseStatus ParseKeyResponseStatus(ApduResponseStatus raw) { switch (raw) { case ApduResponseStatus.NoError: return KeyResponseStatus.Success; case ApduResponseStatus.ConditionsNotSatisfied: return KeyResponseStatus.TestOfuserPresenceRequired; case ApduResponseStatus.WrongData: return KeyResponseStatus.BadKeyHandle; default: return KeyResponseStatus.Failure; } }
public static KeyResponse <TData> Empty(ApduResponseStatus apduStatus, KeyResponseStatus status) { return(new KeyResponse <TData>(ApduResponse.Empty(apduStatus), null, status)); }
public static ApduResponse Empty(ApduResponseStatus status) { return(new ApduResponse(status, EmptyArraySegment <byte> .Value)); }
public ApduResponse(ApduResponseStatus status, ArraySegment <byte> responseData) { Status = status; ResponseData = responseData; }
public static ApduResponse Empty(ApduResponseStatus status) { return new ApduResponse(status, EmptyArraySegment<byte>.Value); }
public ApduResponse(ApduResponseStatus status, ArraySegment<byte> responseData) { Status = status; ResponseData = responseData; }