@sap-cloud-sdk/odata-common
Version:
SAP Cloud SDK for JavaScript common functions of OData client generator and OpenAPI clint generator.
40 lines (39 loc) • 2.56 kB
TypeScript
import { Filter } from '../filter';
import { EdmTypeField } from './edm-type-field';
import type { EntityBase } from '../entity-base';
import type { EdmTypeShared } from '../edm-types';
import type { DeSerializers } from '../de-serializers';
import type { FieldTypeByEdmType } from './edm-type-field';
/**
* {@link EdmTypeField}, that represents a property with an EDM type, that can be compared with `greaterThan`, `greaterOrEqual`, `lessThan` and `lessOrEqual`.
* @typeParam EntityT - Type of the entity the field belongs to.
* @typeParam EdmT - EDM type of the field.
* @typeParam NullableT - Boolean type that represents whether the field is nullable.
* @typeParam SelectableT - Boolean type that represents whether the field is selectable.
*/
export declare class OrderableEdmTypeField<EntityT extends EntityBase, DeSerializersT extends DeSerializers, EdmT extends EdmTypeShared<'any'>, NullableT extends boolean = false, SelectableT extends boolean = false> extends EdmTypeField<EntityT, DeSerializersT, EdmT, NullableT, SelectableT> {
/**
* Creates an instance of Filter for this field and the given value using the operator 'gt', i.e. `>`.
* @param value - Value to be used in the filter.
* @returns The resulting filter.
*/
greaterThan(value: FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>): Filter<EntityT, DeSerializersT, FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>>;
/**
* Creates an instance of Filter for this field and the given value using the operator 'ge', i.e. `>=`.
* @param value - Value to be used in the filter.
* @returns The resulting filter.
*/
greaterOrEqual(value: FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>): Filter<EntityT, DeSerializersT, FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>>;
/**
* Creates an instance of Filter for this field and the given value using the operator 'lt', i.e. `<`.
* @param value - Value to be used in the filter.
* @returns The resulting filter.
*/
lessThan(value: FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>): Filter<EntityT, DeSerializersT, FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>>;
/**
* Creates an instance of Filter for this field and the given value using the operator 'le', i.e. `<=`.
* @param value - Value to be used in the filter.
* @returns The resulting filter.
*/
lessOrEqual(value: FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>): Filter<EntityT, DeSerializersT, FieldTypeByEdmType<DeSerializersT, EdmT, NullableT>>;
}