// A non-public constructor to ensure the factory is used to create the object. // This will prevent memory leaks when handling the HttpResponseMessage. internal ClientEncryptionKeyResponse( HttpStatusCode httpStatusCode, Headers headers, ClientEncryptionKeyProperties keyProperties, ClientEncryptionKey key, CosmosDiagnostics diagnostics) { this.StatusCode = httpStatusCode; this.Headers = headers; this.Resource = keyProperties; this.ClientEncryptionKey = key; this.Diagnostics = diagnostics; }
public override ClientEncryptionKeyResponse CreateClientEncryptionKeyResponse( ClientEncryptionKey clientEncryptionKey, ResponseMessage responseMessage) { return(this.ProcessMessage(responseMessage, (cosmosResponseMessage) => { ClientEncryptionKeyProperties cekProperties = this.ToObjectpublic <ClientEncryptionKeyProperties>(cosmosResponseMessage); return new ClientEncryptionKeyResponse( cosmosResponseMessage.StatusCode, cosmosResponseMessage.Headers, cekProperties, clientEncryptionKey, cosmosResponseMessage.Diagnostics); })); }
public abstract ClientEncryptionKeyResponse CreateClientEncryptionKeyResponse( ClientEncryptionKey clientEncryptionKey, ResponseMessage responseMessage);