mirror of
https://github.com/servo/servo.git
synced 2025-07-01 04:23:39 +01:00
32 lines
776 B
Text
32 lines
776 B
Text
// GENERATED CONTENT - DO NOT EDIT
|
|
// Content of this file was automatically extracted from the
|
|
// "Web Budget API" spec.
|
|
// See: https://wicg.github.io/budget-api/
|
|
|
|
[Exposed=Window]
|
|
partial interface Navigator {
|
|
[SameObject] readonly attribute BudgetService budget;
|
|
};
|
|
|
|
[Exposed=Worker]
|
|
partial interface WorkerNavigator {
|
|
[SameObject] readonly attribute BudgetService budget;
|
|
};
|
|
|
|
[Exposed=(Window,Worker)]
|
|
interface BudgetService {
|
|
Promise<double> getCost(OperationType operation);
|
|
Promise<sequence<BudgetState>> getBudget();
|
|
|
|
Promise<boolean> reserve(OperationType operation);
|
|
};
|
|
|
|
[Exposed=(Window,Worker)]
|
|
interface BudgetState {
|
|
readonly attribute double budgetAt;
|
|
readonly attribute DOMTimeStamp time;
|
|
};
|
|
|
|
enum OperationType {
|
|
"silent-push"
|
|
};
|