Files
auth/backend/keycloak/kc-client/models/RolesRepresentation.ts
2022-09-05 17:02:45 +02:00

73 lines
1.8 KiB
TypeScript

/* tslint:disable */
/* eslint-disable */
/**
* Keycloak Admin REST API
* This is a REST API reference for the Keycloak Admin
*
* The version of the OpenAPI document: 1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { exists, mapValues } from '../runtime';
import {
RoleRepresentation,
RoleRepresentationFromJSON,
RoleRepresentationFromJSONTyped,
RoleRepresentationToJSON,
} from './';
/**
*
* @export
* @interface RolesRepresentation
*/
export interface RolesRepresentation {
/**
*
* @type {{ [key: string]: object; }}
* @memberof RolesRepresentation
*/
client?: { [key: string]: object; };
/**
*
* @type {Array<RoleRepresentation>}
* @memberof RolesRepresentation
*/
realm?: Array<RoleRepresentation>;
}
export function RolesRepresentationFromJSON(json: any): RolesRepresentation {
return RolesRepresentationFromJSONTyped(json, false);
}
export function RolesRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RolesRepresentation {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'client': !exists(json, 'client') ? undefined : json['client'],
'realm': !exists(json, 'realm') ? undefined : ((json['realm'] as Array<any>).map(RoleRepresentationFromJSON)),
};
}
export function RolesRepresentationToJSON(value?: RolesRepresentation | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'client': value.client,
'realm': value.realm === undefined ? undefined : ((value.realm as Array<any>).map(RoleRepresentationToJSON)),
};
}