src/gen/models/ObjectSerializer

ObjectSerializer

class ObjectSerializer 

findCorrectType

public static findCorrectType(data: any, expectedType: string) 

serialize

public static serialize(data: any, type: string, format: string): any 

deserialize

public static deserialize(data: any, type: string, format: string): any 

normalizeMediaType

Normalize media type We currently do not handle any media types attributes, i.e. anything after a semicolon. All content is assumed to be UTF-8 compatible.
public static normalizeMediaType(mediaType: string | undefined): string | undefined 

getPreferredMediaType

From a list of possible media types, choose the one we can handle best. The order of the given media types does not have any impact on the choice made.
public static getPreferredMediaType(mediaTypes: Array<string>): string 

stringify

Convert data to a string according the given media type
public static stringify(data: any, mediaType: string): string 

parse

Parse data from a string according to the given media type
public static parse(rawData: string, mediaType: string | undefined) 
Start typing to search the documentation Press ESC to close