RecordingForgePlatform class
Recording ForgePlatform fake: accepts every facade call, remembers the metadata passed to createVideo, and returns platformVideo for every created video view.
- Implemented types
Constructors
Properties
-
calls
→ List<
String> -
Platform calls in order (
subscriptions:a,b,answer:id), so a test can assert ordering.final -
capturePlans
→ Stream<
Map< String, Object?> > -
Push stream of kernel capture-plan changes as canonical camelCase plan
maps. On Flutter Web the plan is consumed inside @npaw/forge-web itself,
so the web stream stays silent.
no setteroverride
-
commandAnswers
→ List<
({String commandId, Map< String, String> details, bool handled})> -
Every remote-command answer forwarded, in order.
final
-
commandRequests
→ Stream<
Map< String, Object?> > -
Push stream of subscribed remote commands as canonical
{id, name, args}maps. Delivered once, never replayed.no setteroverride -
commandSubscriptions
→ List<
List< String> > -
Every remote-command subscription set forwarded, in order.
final
-
connectionTypes
→ List<
String?> -
Every connection class reported through setAutoConnectionType, in
order, including the
nullthat clears it.final -
createVideoMetadata
↔ Map<
String, Object?> ? -
Metadata map of the most recent createVideo call.
getter/setter pair
-
createVideoOptions
↔ Map<
String, Object?> ? -
Options map of the most recent createVideo call.
getter/setter pair
-
endSessionParams
→ List<
Map< String, Object?> ?> -
final
-
events
→ Stream<
Map< String, Object?> > -
Push streams of drained diagnostic payloads. Implementations own the
mechanism (FFI drain timer, Web listener bridge).
no setteroverride
- experimentFetchResult ↔ bool
-
getter/setter pair
-
experimentState
↔ Map<
String, Object?> -
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
-
logs
→ Stream<
Map< String, Object?> > -
no setteroverride
- nativeVersion → String?
-
no setteroverride
-
final
- platformVideo → RecordingForgePlatformVideo
-
The video fake returned by every createVideo call.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
sessionUpdates
→ List<
({Map< String, double> metrics, Map<String, String> params})> -
Hot session updates captured per call.
final
-
startSessionParams
→ List<
Map< String, Object?> ?> -
Session lifecycle params captured per call (null when omitted).
final
Methods
-
answerCommand(
String commandId, bool handled, Map< String, String> details) → Future<ForgeOutcome> -
Answers a delivered command; the kernel keeps the first answer per id.
override
-
applicationForeground(
bool foreground) → Future< ForgeOutcome> -
override
-
capturePlan(
) → Future< Map< String, Object?> ?> -
Pull accessor for the latest kernel-emitted capture plan, or null before
the first plan emission (plans emit from the first session start onward).
override
-
createVideo(
Map< String, Object?> ? options, Map<String, Object?> ? metadata) → Future<ForgePlatformVideo> -
override
-
destroy(
) → Future< void> -
override
-
emitCommandRequest(
ForgeCommand command) → void - Test hook mirroring the kernel's command delivery.
-
endSession(
[Map< String, Object?> ? params]) → Future<ForgeOutcome> -
Closes the application session.
override
-
experimentsSnapshot(
) → Map< String, Object?> -
override
-
fetchExperiments(
) → Future< bool> -
override
-
identityEvent(
String kind, Map< String, String> fields) → Future<ForgeOutcome> -
Reports one typed identity transition.
kindis the camelCase kernel identity kind (loginSuccess|loginFailed|logout|profileCreated| profileSelected|profileDeleted);fieldscarries the recognized userId/profileId/profileType/method/errorCode/reason/userType entries plus extra session-event params, all stringified by the facade.override -
initialize(
ForgeConfig config) → Future< void> -
Creates the underlying runtime. Throws ForgeInitException on invalid
configuration.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
reportNetworkEvent(
Map< String, Object?> observation) → Future<ForgeOutcome> -
override
-
sessionUpdate(
Map< String, String> params, Map<String, double> metrics) → Future<ForgeOutcome> -
Hot session update (session-update mode): flat stringified dimension
params plus numeric session metrics staged by the kernel and carried on
the next session event or an update beat.
override
-
setAutoConnectionType(
String? connectionType) → Future< ForgeOutcome> -
Reports the connection class the device is on (
wifi,cellular,ethernet,other,unknown), ornullto clear it.override -
setCommandSubscriptions(
List< String> names) → Future<ForgeOutcome> -
Replaces the full set of remote command names the host listens to
(replace semantics). Unsubscribed names are auto-answered
handled=falseby the kernel.override -
startSession(
[Map< String, Object?> ? params]) → Future<ForgeOutcome> -
Opens the application session, optionally carrying initial session
params (initial dimensions such as
screenNameorparam1..param20).override -
toString(
) → String -
A string representation of this object.
inherited
-
trackSessionEvent(
String name, Map< String, Object?> ? params) → Future<ForgeOutcome> -
override
-
Reports a session navigation (
sessionnav).override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited