NmPlanController class
Plan controller.
- Inheritance
-
- Object
- ChangeNotifier
- NmPlanController
Constructors
- NmPlanController(NmPlanRepository repository, {required int usageCount(String planId)})
- Creates a NmPlanController.
Properties
- commandSetFilter ↔ String?
-
Shows only the plans of this command set; null shows all.
getter/setter pair
- draft ↔ NmPlanDraft?
-
Unsaved edits of the selected plan; null when nothing changed yet.
getter/setter pair
- errorMessage ↔ String?
-
Why the last load or save failed, if it did.
getter/setter pair
- explanationOpen ↔ bool
-
Whether the explanation banner is shown.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
- isDirty → bool
-
Whether the draft has unsaved changes.
no setter
- loadState ↔ NmPlanLoadState
-
Loading, ready or failed.
getter/setter pair
- pendingSelectionId ↔ String?
-
A plan the user picked while the draft had unsaved changes (confirm to switch).
getter/setter pair
- query ↔ String
-
Filter text of the registry pane.
getter/setter pair
-
records
→ List<
NmDialPlan> -
All plans from the repository.
no setter
- repository → NmPlanRepository
-
Where the plans are read from and saved to.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- selected → NmDialPlan?
-
The selected plan, with the draft applied.
no setter
- selectedId ↔ String?
-
Id of the plan shown in the detail pane.
getter/setter pair
- usageCount → int Function(String planId)
-
How many SIMs use a plan (shown in the registry).
final
-
visiblePlans
→ List<
NmDialPlan> -
Visible plans.
no setter
Methods
-
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
cancelDraft(
) → void - Cancel draft.
-
createPlan(
String id, String commandSetId, NmTelecomL10n l10n, {String? cloneFromId}) → void - Create plan.
-
deletePlan(
String id, NmTelecomL10n l10n) → void - Delete plan.
-
discardAndContinue(
) → void - Discard and continue.
-
dispose(
) → void -
Discards any resources used by the object.
inherited
-
inspectDelete(
String id, NmTelecomL10n l10n) → NmPlanDeleteImpact - Inspect delete.
-
keepEditing(
) → void - Keep editing.
-
load(
) → void - Load.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
notifyListeners(
) → void -
Call all the registered listeners.
inherited
-
removeListener(
VoidCallback listener) → void -
Remove a previously registered closure from the list of closures that are
notified when the object changes.
inherited
-
requestSelectPlan(
String id) → bool - Request select plan.
-
resetDemo(
) → void - Reset demo.
-
save(
NmTelecomL10n l10n) → void - Save.
-
setCommandSetFilter(
String? id) → void - Set command set filter.
-
setQuery(
String q) → void - Set query.
-
toggleExplanation(
) → void - Toggle explanation.
-
toString(
) → String -
A string representation of this object.
inherited
-
updateCallModes(
{bool? canIn, bool? canOut, bool? canSout, bool? notVip, Set< String> ? qualityFlags, bool? capOk, bool? capNew, bool? capFail}) → void - Update call modes.
-
updateCapacity(
{int? onlineMax, int? addMax}) → void - Update capacity.
-
updateDirectionSlot(
int slot, {int? alg, bool? nodiff, int? limitSoft, int? limitHard}) → void -
slotmust be 1-4 (the editable directions); 0 and 5 are compatibility-only and silently ignored, matching Specifications' edge-case table. -
updateIdentity(
{String? commandSetId, int? priority, String? proTag, bool clearProTag = false}) → void - Update identity.
-
updateIncomingGeneration(
{int? iattMin, int? iattMax, int? iattSoft, int? inAcdMin, int? inAcdMax, int? outAcdMin, int? outAcdMax, bool? forwarding, int? outInAns, bool? conn, bool? rand, bool? inWait, bool? inSound}) → void - Update incoming generation.
-
updateSmsGeneration(
{int? mayLimit, int? monLimit, int? msmLimit, int? smsoutSoft, int? smsoutHard, int? sattSoft, int? sattHard, int? sattSoftDay, int? sattHardDay, int? sattSoftTotal, int? sattHardTotal, int? nospam}) → void - Update SMS generation.
-
updateTiming(
{int? diffSlow, int? diffMin, int? diffMinOut, int? timeWake, bool clearTimeWake = false, int? timeSleep, bool clearTimeSleep = false, int? timeWorkWake, bool clearTimeWorkWake = false, int? timeWorkSleep, bool clearTimeWorkSleep = false, int? timeHolidayWake, bool clearTimeHolidayWake = false, int? timeHolidaySleep, bool clearTimeHolidaySleep = false}) → void - Update timing.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited