import { AnyOptions, ValOrFunc } from './types'; /** * Get property descriptor from object or its prototype chain * @param obj * @param prop * * @category JS Object */ export declare function getPropertyDescriptor(obj: T, prop: keyof T): PropertyDescriptor | undefined; /** * Check if property is writable in object or its prototype chain * @param object - object to check * @param prop - property to check * @param allowWritable - allow writable properties without setter * @param allowAny - allow any property (even if it doesn't exist) * * @category JS Object */ export declare function isPropertyWritable(object: T, prop: keyof T, allowWritable?: boolean, allowAny?: boolean): boolean; /** * Set value only if setter exists * @param object - object to set * @param prop - property to set * @param value - value to set * @param allowWritable - allow writable properties without setter * @param allowAny - allow any property (even if it doesn't exist) * * @category JS Object */ export declare function safeSetProperty(object: T | undefined | null, prop: K, value: NonNullable[K], allowWritable?: boolean, allowAny?: boolean): boolean; /** * Get value, but if it is a function, call it with args * @param s - value or function * @param args - arguments to pass to function * * @category JS Object */ export declare function getOrCall(s: ValOrFunc, ...args: any[]): T | undefined; /** * Copy properties from source to dest. Similar to Object.assign, but only copies properties that exist in source, dest and propList. * @param source - source object * @param dest - destination object * @param propList - list of properties to copy * * @category JS Object */ export declare function copyProps(source: Record, dest: T, propList: (keyof T)[]): T; //# sourceMappingURL=obj-property.d.ts.map