import { ReplaySubject, Subject } from 'rxjs'; import { Authentication } from '../interfaces/authentication.interface'; import * as i0 from "@angular/core"; export interface TicketBody { userId?: string; password?: string; } export interface TicketEntry { entry: { id?: string; userId?: string; }; } export declare class ContentAuth { private readonly appConfigService; private readonly adfHttpClient; private readonly storageService; onLogin: ReplaySubject; onLogout: ReplaySubject; onError: Subject; ticket: string; config: { ticketEcm: any; }; authentications: Authentication; get basePath(): string; constructor(); private setConfig; saveUsername(username: string): void; getUsername(): string; /** * login Alfresco API * * @param username username to login * @param password password to login * @returns A promise that returns {new authentication ticket} if resolved and {error} if rejected. */ login(username: string, password: string): Promise; /** * logout Alfresco API * * @returns A promise that returns { authentication ticket} if resolved and {error} if rejected. */ logout(): Promise; /** * Set the current Ticket * * @param ticket a string representing the ticket */ setTicket(ticket: string): void; /** * @returns the current Ticket */ getToken(): string; invalidateSession(): void; /** * @returns If the client is logged in return true */ isLoggedIn(): boolean; /** * @returns return the Authentication */ getAuthentication(): Authentication; createTicket(ticketBodyCreate: TicketBody): Promise; requireAlfTicket(): Promise; deleteTicket(): Promise; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }