mirror of
https://github.com/hensm/fx_cast.git
synced 2026-06-09 09:09:58 +00:00
26 lines
819 B
TypeScript
26 lines
819 B
TypeScript
"use strict";
|
|
|
|
import { AutoJoinPolicy } from "../../cast/enums";
|
|
|
|
export default class CastOptions {
|
|
public autoJoinPolicy: string = AutoJoinPolicy.TAB_AND_ORIGIN_SCOPED;
|
|
public language: string = null;
|
|
public receiverApplicationId: string = null;
|
|
public resumeSavedSession: boolean = true;
|
|
|
|
constructor (options: CastOptions = ({} as CastOptions)) {
|
|
if (options.autoJoinPolicy) {
|
|
this.autoJoinPolicy = options.autoJoinPolicy;
|
|
}
|
|
if (options.language) {
|
|
this.language = options.language;
|
|
}
|
|
if (options.receiverApplicationId) {
|
|
this.receiverApplicationId = options.receiverApplicationId;
|
|
}
|
|
if (options.resumeSavedSession) {
|
|
this.resumeSavedSession = options.resumeSavedSession;
|
|
}
|
|
}
|
|
}
|