UNPKG

3.81 kBTypeScriptView Raw
1import { EdmTypeShared } from '../../edm-types';
2import { Entity, ODataVersionOf, Constructable } from '../../entity';
3import { Filter } from '../../filter';
4import { Time } from '../../time';
5import { ConstructorOrField } from '../constructor-or-field';
6import { EdmTypeField } from '../edm-type-field';
7/**
8 * @deprecated Since v1.47.0. Use [[OrderableEdmTypeField]] instead.
9 * Represents a property with a time value.
10 * @typeparam EntityT - Type of the entity the field belongs to
11 */
12export declare class TimeFieldBase<EntityT extends Entity, SelectableT extends boolean = false> extends EdmTypeField<EntityT, Time, false, SelectableT> {
13 /**
14 * Creates an instance of Filter for this field and the given value using the operator 'gt', i.e. `>`.
15 * @param value - Value to be used in the filter
16 * @returns The resulting filter
17 */
18 greaterThan(value: Time): Filter<EntityT, Time>;
19 /**
20 * Creates an instance of Filter for this field and the given value using the operator 'ge', i.e. `>=`.
21 * @param value - Value to be used in the filter
22 * @returns The resulting filter
23 */
24 greaterOrEqual(value: Time): Filter<EntityT, Time>;
25 /**
26 * Creates an instance of Filter for this field and the given value using the operator 'lt', i.e. `<`.
27 * @param value - Value to be used in the filter
28 * @returns The resulting filter
29 */
30 lessThan(value: Time): Filter<EntityT, Time>;
31 /**
32 * Creates an instance of Filter for this field and the given value using the operator 'le', i.e. `<=`.
33 * @param value - Value to be used in the filter
34 * @returns The resulting filter
35 */
36 lessOrEqual(value: Time): Filter<EntityT, Time>;
37}
38/**
39 * @deprecated Since v1.47.0. Use [[OrderableEdmTypeField]] instead.
40 * Represents a selectable property with a time value.
41 * @typeparam EntityT - Type of the entity the field belongs to
42 */
43export declare class TimeField<EntityT extends Entity> extends TimeFieldBase<EntityT, true> {
44}
45/**
46 * @deprecated Since v1.47.0. Use [[OrderableEdmTypeField]] instead.
47 * Represents a complex type property with a time value.
48 * @typeparam EntityT - Type of the entity the field belongs to
49 */
50export declare class ComplexTypeTimePropertyField<EntityT extends Entity, ComplexT = any> extends TimeFieldBase<EntityT> {
51 /**
52 * The constructor of the entity or the complex type this field belongs to
53 */
54 readonly fieldOf: ConstructorOrField<EntityT, ComplexT>;
55 /**
56 * Creates an instance of ComplexTypeTimePropertyField.
57 * @param fieldName - Actual name of the field used in the OData request
58 * @param fieldOf - The constructor of the entity or the complex type this field belongs to
59 * @param edmType - Type of the field according to the metadata description
60 */
61 constructor(fieldName: string, fieldOf: ConstructorOrField<EntityT, ComplexT>, edmType: EdmTypeShared<ODataVersionOf<EntityT>>);
62 /**
63 * @deprecated Since v1.19.0.
64 *
65 * Creates an instance of ComplexTypeTimePropertyField.
66 * @param fieldName - Actual name of the field used in the OData request
67 * @param entityConstructor - Constructor type of the entity the field belongs to
68 * @param parentTypeName - Name of the parent complex type
69 * @param edmType - Type of the field according to the metadata description
70 */
71 constructor(fieldName: string, entityConstructor: Constructable<EntityT>, parentTypeName: string, edmType: EdmTypeShared<ODataVersionOf<EntityT>>);
72 /**
73 * Path to the field to be used in filter and order by queries. Combines the parent complex type name with the field name.
74 * @returns Path to the field to be used in filter and order by queries.
75 */
76 fieldPath(): string;
77}
78//# sourceMappingURL=time-field.d.ts.map
\No newline at end of file