@documentica/webdav
Version:
Documentica Webdav Client
30 lines (29 loc) • 1.07 kB
TypeScript
import Property, { IProperty } from './Property';
import { ExtChildNode } from './types';
export declare type WebdavDepthType = "0" | "1" | "infinity";
export declare type ReponsePart = 'href' | 'status' | 'error' | 'responsedescription' | 'location' | 'propstat';
export interface INamespace {
[index: string]: IProperty;
}
export interface INamespaces {
[index: string]: INamespace;
}
export interface IResponse {
getProperty: (namespace: string, prop: string) => IProperty | undefined;
getPropertyNames: (namespace: string) => string[];
href: string | null;
}
export default class Response implements IResponse {
_namespaces: INamespaces;
href: string | null;
status: string | null;
error: string | null;
responsedescription: string | null;
location: string | null;
propstat?: any;
constructor(xmlNode?: ExtChildNode);
addProperty(property: Property): this;
getProperty(namespace: string, prop: string): IProperty | undefined;
getNamespaceNames(): string[];
getPropertyNames(namespace: string): any[];
}