Version: 5.0.0-alpha.105.0.0-alpha.115.0.0-alpha.125.0.0-alpha.135.0.0-alpha.145.0.0-beta.05.0.0-beta.15.0.0-beta.25.0.0-beta.35.0.0-beta.45.0.0-beta.55.0.0-beta.65.0.0-beta.75.0.0-beta.85.0.0-beta.95.0.0-beta.105.0.0-beta.115.0.0-beta.125.0.0-rc.15.0.0-rc.25.0.0-rc.35.0.0-rc.45.0.0-rc.55.0.05.0.15.0.25.0.35.1.05.1.15.2.05.2.1-smooth5.3.05.3.15.3.35.4.05.4.15.4.25.4.35.5.0-beta.05.5.0-beta.15.5.0-beta.25.5.0-beta.35.5.0-beta.45.5.0-beta.55.5.0-beta.75.5.05.5.15.5.25.5.35.5.45.5.55.5.65.5.75.5.85.5.95.5.105.5.115.5.125.6.0-forward-compat.05.6.0-forward-compat.15.6.0-forward-compat.25.6.0-forward-compat.35.6.0-forward-compat.45.6.0-forward-compat.56.0.0-alpha.06.0.0-alpha.16.0.0-alpha.26.0.0-alpha.36.0.0-alpha.46.0.0-beta.06.0.0-beta.16.0.0-beta.26.0.0-beta.36.0.0-beta.46.0.0-rc.06.0.0-rc.16.0.0-smoosh.06.0.0-smoosh.16.0.0-smoosh.26.0.0-tactical-rc.16.0.0-tenacious-rc.26.0.0-terrific-rc.36.0.0-turbo-rc.46.0.0-uber-rc.56.0.0-ucandoit-rc.66.0.0-uncanny-rc.76.0.06.1.06.2.06.2.16.2.26.3.06.3.16.3.26.3.36.4.06.5.06.5.16.5.26.5.36.5.46.5.56.6.06.6.16.6.26.6.36.6.46.6.66.6.77.0.0-alpha.07.0.0-alpha.17.0.0-beta.07.0.0-beta.17.0.0-beta.27.0.0-beta.37.0.0-beta.47.0.0-beta.57.0.0-beta.67.0.0-beta.77.0.0-beta.87.0.0-beta.97.0.0-beta.107.0.0-beta.117.0.0-beta.127.0.0-beta.137.0.0-beta.147.0.0-beta.157.0.0-rc.07.0.0-rc.17.0.0-rc.27.0.0-rc.37.0.07.0.17.1.07.2.07.3.07.3.17.4.07.5.07.5.17.5.27.5.37.5.47.5.57.5.67.5.77.6.07.7.07.8.07.8.17.8.28.0.0-alpha.08.0.0-alpha.18.0.0-alpha.28.0.0-alpha.38.0.0-alpha.48.0.0-alpha.58.0.0-alpha.68.0.0-alpha.78.0.0-alpha.88.0.0-alpha.98.0.0-alpha.108.0.0-alpha.118.0.0-alpha.128.0.0-alpha.138.0.0-alpha.14
import { Observable } from '../Observable';
import { ConnectableObservable } from '../observable/ConnectableObservable';
import { UnaryFunction } from '../types';
/**
* Returns a connectable observable sequence that shares a single subscription to the
* underlying sequence containing only the last notification.
*
* 
* Similar to {@link publish}, but it waits until the source observable completes and stores
* the last emitted value.
* Similarly to {@link publishReplay} and {@link publishBehavior}, this keeps storing the last
* value even if it has no more subscribers. If subsequent subscriptions happen, they will
* immediately get that last stored value and complete.
* ## Example
* ```ts
* import { ConnectableObservable, interval, publishLast, tap, take } from 'rxjs';
* const connectable = <ConnectableObservable<number>>interval(1000)
* .pipe(
* tap(x => console.log('side effect', x)),
* take(3),
* publishLast()
* );
* connectable.subscribe({
* next: x => console.log('Sub. A', x),
* error: err => console.log('Sub. A Error', err),
* complete: () => console.log('Sub. A Complete')
* });
* next: x => console.log('Sub. B', x),
* error: err => console.log('Sub. B Error', err),
* complete: () => console.log('Sub. B Complete')
* connectable.connect();
* // Results:
* // 'side effect 0' - after one second
* // 'side effect 1' - after two seconds
* // 'side effect 2' - after three seconds
* // 'Sub. A 2' - immediately after 'side effect 2'
* // 'Sub. B 2'
* // 'Sub. A Complete'
* // 'Sub. B Complete'
* ```
* @see {@link ConnectableObservable}
* @see {@link publish}
* @see {@link publishReplay}
* @see {@link publishBehavior}
* @return A function that returns an Observable that emits elements of a
* sequence produced by multicasting the source sequence.
* @deprecated Will be removed in v8. To create a connectable observable with an
* {@link AsyncSubject} under the hood, use {@link connectable}.
* `source.pipe(publishLast())` is equivalent to
* `connectable(source, { connector: () => new AsyncSubject(), resetOnDisconnect: false })`.
* If you're using {@link refCount} after `publishLast`, use the {@link share} operator instead.
* `source.pipe(publishLast(), refCount())` is equivalent to
* `source.pipe(share({ connector: () => new AsyncSubject(), resetOnError: false, resetOnComplete: false, resetOnRefCountZero: false }))`.
* Details: https://rxjs.dev/deprecations/multicasting
*/
export declare function publishLast<T>(): UnaryFunction<Observable<T>, ConnectableObservable<T>>;
//# sourceMappingURL=publishLast.d.ts.map