UNPKG

@microsoft/msgraph-beta-sdk-devicemanagement

Version:
66 lines 3.39 kB
/* tslint:disable */ /* eslint-disable */ // Generated by Microsoft Kiota // @ts-ignore import { createCloudCertificationAuthorityLeafCertificateFromDiscriminatorValue } from '@microsoft/msgraph-beta-sdk/models/index.js'; // @ts-ignore import { createODataErrorFromDiscriminatorValue } from '@microsoft/msgraph-beta-sdk/models/oDataErrors/index.js'; /** * Creates a new instance of the appropriate class based on discriminator value * @param parseNode The parse node to use to read the discriminator value and create the object * @returns {RevokeLeafCertificateBySerialNumberPostRequestBody} */ // @ts-ignore export function createRevokeLeafCertificateBySerialNumberPostRequestBodyFromDiscriminatorValue(parseNode) { return deserializeIntoRevokeLeafCertificateBySerialNumberPostRequestBody; } /** * The deserialization information for the current model * @param RevokeLeafCertificateBySerialNumberPostRequestBody The instance to deserialize into. * @returns {Record<string, (node: ParseNode) => void>} */ // @ts-ignore export function deserializeIntoRevokeLeafCertificateBySerialNumberPostRequestBody(revokeLeafCertificateBySerialNumberPostRequestBody = {}) { return { "backingStoreEnabled": n => { revokeLeafCertificateBySerialNumberPostRequestBody.backingStoreEnabled = true; }, "certificateSerialNumber": n => { revokeLeafCertificateBySerialNumberPostRequestBody.certificateSerialNumber = n.getStringValue(); }, }; } /** * Serializes information the current object * @param isSerializingDerivedType A boolean indicating whether the serialization is for a derived type. * @param RevokeLeafCertificateBySerialNumberPostRequestBody The instance to serialize from. * @param writer Serialization writer to use to serialize this model */ // @ts-ignore export function serializeRevokeLeafCertificateBySerialNumberPostRequestBody(writer, revokeLeafCertificateBySerialNumberPostRequestBody = {}, isSerializingDerivedType = false) { if (!revokeLeafCertificateBySerialNumberPostRequestBody || isSerializingDerivedType) { return; } writer.writeStringValue("certificateSerialNumber", revokeLeafCertificateBySerialNumberPostRequestBody.certificateSerialNumber); writer.writeAdditionalData(revokeLeafCertificateBySerialNumberPostRequestBody.additionalData); } /** * Uri template for the request builder. */ export const RevokeLeafCertificateBySerialNumberRequestBuilderUriTemplate = "{+baseurl}/deviceManagement/cloudCertificationAuthority/{cloudCertificationAuthority%2Did}/revokeLeafCertificateBySerialNumber"; /** * Metadata for all the requests in the request builder. */ export const RevokeLeafCertificateBySerialNumberRequestBuilderRequestsMetadata = { post: { uriTemplate: RevokeLeafCertificateBySerialNumberRequestBuilderUriTemplate, responseBodyContentType: "application/json", errorMappings: { XXX: createODataErrorFromDiscriminatorValue, }, adapterMethodName: "send", responseBodyFactory: createCloudCertificationAuthorityLeafCertificateFromDiscriminatorValue, requestBodyContentType: "application/json", requestBodySerializer: serializeRevokeLeafCertificateBySerialNumberPostRequestBody, requestInformationContentSetMethod: "setContentFromParsable", }, }; /* tslint:enable */ /* eslint-enable */ //# sourceMappingURL=index.js.map