logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class SignalFlowScanner

    Editor-only scanner that builds the signal → dispatchers/modals/reactions/emitters graph from project types and assets. Kept separate from the window so the data collection can be reused/tested independent of GUI drawing, mirroring AudioMixerRelationshipScanner's split for the mixer topology window.

    Inheritance
    object
    SignalFlowScanner
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.EventDispatcher.Infrastructure.Editor
    Assembly: Serenity.UnityEventDispatcher.Infrastructure.Editor.dll
    Syntax
    public static class SignalFlowScanner
    Remarks

    Three different string formats flow into signal resolution, each with exactly one resolver — mixing them up silently mis-resolves or drops a signal:

    ProducerFormat → resolver
    signalTypeName fields (definition/modal/reaction assets)AssemblyQualifiedName → Serenity.EventDispatcher.Infrastructure.Editor.SignalFlowScanner.ResolveSignalType(System.String,System.Collections.Generic.Dictionary{System.String,System.Type})
    UnityActionDefinition.Signalbare FullName → the signalsByFullName lookup ONLY, never GetType(string)
    [SerializeReference] slots (menu/modal option and view-level signals, via Serenity.EventDispatcher.Infrastructure.Editor.SignalFlowViewSignalCollector)"<Assembly> <FullName>" → split at the first space, then signalsByFullName

    Methods

    Scan(bool)

    Rebuilds the signal → dispatchers / modals / reactions / emitters maps from project types and assets.

    Declaration
    public static SignalFlowScanner.ScanResult Scan(bool includeScenesAndPrefabs = false)
    Parameters
    Type Name Description
    bool includeScenesAndPrefabs

    When true, additionally scans prefab assets (exact, via SignalEmitterComponent and SignalReactionComponent components) and scene assets (coarse, via a text search for each component's script GUID) for signal emitter and reaction usages. Off by default because it walks every prefab and scene in the project and reads every scene file from disk — a cost the default graph (types + authored assets only) does not pay.
    Scenes are NEVER opened: EditorSceneManager.OpenScene is never called. Opening a scene fires Awake/OnEnable on the user's behalf, can raise unsaved-changes dialogs, and costs seconds per scene — not destroying the user's unsaved work outranks result precision here. Scene results are therefore coarse: a scene is attributed to a signal when it contains an emitter whose definition asset is a scene dependency, but WHICH GameObject emits it is not reported, and two emitters in one scene merge their definitions (over-reporting). The same coarseness applies to reaction components: a scene is attributed to a signal when its own raw text contains a matching signalTypeName value (see SignalFlowSceneTextProbe), with no GameObject path and no finer de-duplication than one entry per signal. That is the correct trade-off for a read-only diagnostic.

    Returns
    Type Description
    SignalFlowScanner.ScanResult
    In this article
    © 2026 Serenity. All Rights Reserved