import { ValueType, FilterOperator } from "./enums"; import { ServiceManager } from "../service-manager"; import { ICacheDataProvider } from "../interfaces/utils.interface"; export declare class CacheDataFilter { PropertyName?: string; Operator?: FilterOperator; Value?: any; valueType?: ValueType; internalValue: string; defaultValue: any; constructor(PropertyName?: string, Operator?: FilterOperator, Value?: any, valueType?: ValueType); } /** * ESTA CLASE HA SIDO DESARROLLADA PARA MATERIALIZAR RELACIONES ENTRE DOS OBJECTOS ATRAVES DE UN MIEMPRO DE CADA OBJETO * @property {any} sourceOject para guardar la referencia del objecto de cual se obtendra o acutlizara * @property {any} targetObject * @property {string} leftMember string que representa el nombre del miembro de la izquierda * @property {string} rightMember? string que representa el nombre del miembro de la derecha * @property {any} value? any que representa el valor que se le asigna al miembre de la izquierda */ export declare class MappingItem { sourceOject: any; targetObject: any; leftMember: string; rightMember?: string; value?: any; constructor(leftMember: string, rightMember?: string, value?: any); } export declare class CacheDataMapping { source: string; mapOnPushOlny: boolean; defaultValue: any; supportUnbindOnly: boolean; targets: MappingItem[]; constructor(source: string, mapOnPushOlny: boolean, defaultValue: any, supportUnbindOnly: boolean); } export declare class Relationship { targetObject: string; keys: MappingItem[]; /** * @param targetObject: string que contiene el nombre del CacheDataRequest.Key que recibirá la notificacion de relación * @param keys: MappingItem[] arreglo de objetos */ constructor(targetObject: string, keys: MappingItem[]); } export declare class CacheDataRequest { Filters: Array; Key: string; Method: string; Alias: string; constructor(provider: any); } export declare class CacheDataObject { loading: boolean; container: CacheDataContainer; cacheDataRequest: CacheDataRequest; List: any[]; lookupMapping: MappingItem; mappings: Array; relationships: Array; asyncBind: boolean; useRelationship: boolean; bindFirstItemOnChange: boolean; constructor(provider: any, container: CacheDataContainer); private _loadRelationship; private _internalbind; push(...items: any[]): void; get(item?: CacheDataRequest): void; find(predicate: (value: any, index: number, obj: any[]) => boolean, thisArg?: any): any; filter(callbackfn: (value: any, index: number, array: any[]) => any, thisArg?: any): any[]; bind(item: any): void; notifyChanges(item: any): void; } export declare class NotifierEventArgs { sender: string; relationships: Relationship[]; constructor(sender: string, relationships: Relationship[]); } export declare class CacheDataContainer { providerOptions?: ICacheDataProvider; private _initialized; dataService: ServiceManager; providers: CacheDataRequest[]; targetObjects: Map; constructor(dataservice: ServiceManager, providerOptions?: ICacheDataProvider); init(): void; get(cacheDataRequests?: CacheDataRequest[]): void; refresh(): void; update(data: any): void; destroy(): void; addTarget(alias: string, targetObject: any): void; getCacheDataRequests(cacheDataRequests?: CacheDataRequest[]): CacheDataRequest[]; }