import { Http } from '@angular/http';
import { MatDialogRef, MatSnackBar } from '@angular/material';
import { Store } from '@ngrx/store';
import { BehaviorSubject } from 'rxjs/BehaviorSubject';
import { Observable } from 'rxjs/Observable';
import { IProject } from '../redux/project';
import { IInteractiveVersion } from '../redux/sync';
import 'rxjs/add/observable/interval';
import 'rxjs/add/operator/combineLatest';
import 'rxjs/add/operator/publishReplay';
import 'rxjs/add/operator/switchMap';
import 'rxjs/add/operator/take';
import 'rxjs/add/operator/takeUntil';
import { IInteractiveJoin } from '../redux/connect';
export declare enum State {
    LoggingIn = 0,
    Connecting = 1,
    AwaitingGameClient = 2,
    NotifyMismatched = 3,
}
/**
 * The Launch Dialog prompts the user to log in, and connect to Interactive
 * for them. It calls back with connection details, or undefined if the dialog
 * was dismissed beforehand.
 */
export declare class LaunchDialogComponent {
    private readonly http;
    private readonly dialogRef;
    private readonly snackRef;
    private readonly store;
    /**
     * Exposed State enum for the template to consume.
     */
    State: typeof State;
    /**
     * Curre state of the component.
     */
    state: BehaviorSubject<State>;
    /**
     * Mismatched version data, used to display a message if the user is
     * connecting to a version different than what's linked to their project.
     */
    versionMismatch: {
        intendedVersion: IInteractiveVersion;
        actualVersion: IInteractiveVersion;
    };
    /**
     * Dots used to subtly indicate progress.
     */
    dots: Observable<string>;
    /**
     * Data loaded from a successful join response.
     */
    private loadedData;
    constructor(http: Http, dialogRef: MatDialogRef<IInteractiveJoin>, snackRef: MatSnackBar, store: Store<IProject>);
    onLoggedIn(): void;
    /**
     * Closes the dialog with the data to connect to Interactive.
     */
    acceptConnect(): void;
    /**
     * Cancels connecting and closes the dialog.
     */
    cancelConnect(): void;
    /**
     * Attempts to create a connection to Interactive. Closes the dialog
     * when it successfully does so.
     */
    private connect();
    /**
     * Waits for the game client connect, polling occasionally.
     */
    private waitForConnect();
}
