Union of necessary methods for the OData URI conversion. In v2/uri-conversion/odata-uri.ts and v4/uri-conversion/odata-uri.ts the instance for v2 and v4 are created.

interface ODataUri<DeSerializersT extends DeSerializers> {
    convertToUriFormat(
        value: any,
        edmType: EdmTypeCommon | ExclusiveEdmTypeV2 | ExclusiveEdmTypeV4,
    ): string;
    getEntityKeys<EntityT extends EntityBase>(
        entity: EntityT,
        entityApi: EntityApi<EntityT, DeSerializersT>,
    ): Record<string, any>;
    getExpand<EntityT extends EntityBase>(
        selects: Selectable<EntityT, DeSerializersT>[],
        expands: Expandable<EntityT, DeSerializersT>[],
        entityApi: EntityApi<EntityT, DeSerializersT>,
    ): Partial<{ expand: string }>;
    getFilter<EntityT extends EntityBase>(
        filter: Filterable<EntityT, DeSerializersT>,
        entityApi: EntityApi<EntityT, DeSerializersT>,
    ): Partial<{ filter: string }>;
    getOrderBy<EntityT extends EntityBase>(
        orderBy: Orderable<EntityT>[],
    ): Partial<{ orderby: string }>;
    getResourcePathForKeys<EntityT extends EntityBase>(
        keys: Record<string, any>,
        _entityApi: EntityApi<EntityT, DeSerializersT>,
    ): string;
    getSelect<EntityT extends EntityBase>(
        selects: Selectable<EntityT, DeSerializersT>[],
    ): Partial<{ select: string }>;
}

Type Parameters

Methods

convertToUriFormat getEntityKeys getExpand getFilter getOrderBy getResourcePathForKeys getSelect

Copyright Ⓒ 2024 SAP SE or an SAP affiliate company. All rights reserved.

Methods