PulseShell<P, R extends Receptor<Cell> > class
A specialized Shell providing a Perceptual Projection of a Pulse to facilitate pre-execution validation and security gating.
PulseShell acts as a high-integrity Defensive Proxy that wraps a core kernel (the actual Pulse) to facilitate the Ingress Phase of the framework's reactive update cycle. It implements the Reciprocal Handshake protocol, ensuring that sensitive data is only released to nodes that satisfy specific security and business invariants.
When to use
- Identity-Gated Propagation: When a signal contains sensitive information that should only be accessible to authorized Receptors.
- Reciprocal Handshake: To initiate a mutual authorization protocol between a Pulse and a Cell during the Ingress Phase.
- Defensive Projection: Providing a terminal, read-only view of a stimulus that cannot be further evolved or modified.
- Validation Before Execution: Gating access to the
payloaduntil the target node satisfies specific Integrity Gates.
How it works
- Encapsulation: Wraps a core
PulseBasekernel within a Defensive Perimeter, acting as a projection layer. - Payload Masking: Intentionally returns
nullfor thepayloadandtraceproperties, effectively "cloaking" the stimulus until authorized. - Identity Challenge: During the Ingress Phase, the Receptor must invoke scrutinize, passing its own identity and context to the shell.
- Reciprocal Authorization: The shell executes the kernel's internal validation logic against the receptor's authority tokens.
- Kernel Release: If authorized, the internal kernel is released for the transformation phase; otherwise, the interaction is Neutralized.
Example
void onPulse(PulseShell<int, MyReceptor> shell, MyReceptor receptor) {
// Accessing payload directly returns null before the handshake
print(shell.payload); // null
// Perform the Reciprocal Handshake
final kernel = shell.scrutinize(receptor, []);
if (kernel != null) {
// Now authorized to access the real Causal Provenance and payload
print(kernel.payload);
}
}
Type Parameters:
P: The type of the underlying data payload.R: The specific type of Receptor qualified to challenge this shell.
Returns:
A PulseShell instance acting as a Defensive Proxy.
See Also:
- Shell: The core interface for mutual authorization.
- Pulse: The underlying stimulus being protected.
- Receptor: The primary consumer that interacts with these shells.
- PulseContext: The metadata governing the shell's security tier.
- Implemented types
- Mixed-in types
- Available extensions
Constructors
-
PulseShell(PulseBase<
P> _kernal) -
Encapsulates the Pulse kernel within a perceptual boundary.
const
Properties
- context → PulseContext
-
The operational tier and security authority under which this pulse propagates.
no setteroverride
- first → Pulse
-
The first element.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- isComposite → bool
-
Indicates whether this pulse is a multi-message bundle (a collection).
no setteroverride
- isEmpty → bool
-
Whether this collection has no elements.
no setterinherited
- isGoverned → bool
-
Indicates whether this pulse is subject to explicit governance.
no setteroverride
- isInvalidated → bool
-
Indicates whether this message has reached its terminal lifecycle state.
no setteroverride
- isNotEmpty → bool
-
Whether this collection has at least one element.
no setterinherited
-
iterator
→ Iterator<
Pulse> -
Returns an iterator over the sub‑pulses in this pulse.
no setteroverride
- last → Pulse
-
The last element.
no setterinherited
- length → int
-
The number of elements in this Iterable.
no setterinherited
- payload → P?
-
The primary data or instruction carried by this signal.
no setteroverride
- policy → PulseEphemeralPolicy?
-
The lifecycle governance policy for this pulse.
no setteroverride
- priority → int
-
The execution priority of this pulse (0‑100, higher = more urgent).
no setteroverride
-
root
→ Pulse<
P> -
The primordial ancestor that initiated this pulse's causal lineage.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
shell
→ PulseShell<
P, R> -
Returns a Defensive Proxy of this pulse for untrusted receivers.
no setteroverride
- single → Pulse
-
Checks that this iterable has only one element, and returns that element.
no setterinherited
- source → Cell?
-
The cell that originally emitted this pulse's lineage.
no setteroverride
- timestamp → DateTime
-
The exact moment this pulse was synthesised.
no setteroverride
-
trace
→ List<
String> -
An ordered sequence of steps documenting the signal's journey.
no setteroverride
- type → dynamic
-
A semantic identifier representing the category or intent of the pulse.
no setteroverride
-
unmodifiable
→ Pulse<
P> -
Returns a read‑only projection of this pulse, ensuring structural and
payload-level finality for the current propagation hop.
no setteroverride
Methods
-
any(
bool test(Pulse element)) → bool -
Checks whether any element of this iterable satisfies
test.inherited -
attach(
dynamic context) → Pulse< P> -
Available on Pulse<
Returns a new version of this pulse with updatedP> , provided by the PulseExtension extensioncontextmetadata. -
attach(
dynamic context) → Iterable< Pulse> -
Available on Iterable<
Returns a new collection of pulses, each with the providedPulse> , provided by the PulseIterableExtension extensioncontextmetadata attached. -
batch(
) → Pulse -
Available on Iterable<
Aggregates multiple signals into a single, flat CollectivePulse.Pulse> , provided by the PulseIterableExtension extension -
cast<
R> () → Iterable< R> -
A view of this iterable as an iterable of
Rinstances.inherited -
cast<
T> () → Pulse< T> -
Available on Pulse<
Re-casts the pulse payload to typeP> , provided by the PulseExtension extensionTwhile maintaining causal history. -
compareTo(
Pulse other) → int -
Compares this pulse with another to determine relative execution precedence.
override
-
contains(
Object? element) → bool -
Whether the collection contains an element equal to
element.inherited -
elementAt(
int index) → Pulse -
Returns the
indexth element.inherited -
every(
bool test(Pulse element)) → bool -
Checks whether every element of this iterable satisfies
test.inherited -
evolve(
{Pulse? pulse, String? step, covariant PulseContext? context}) → Pulse -
Creates a derived version of this pulse for the next processing stage.
override
-
expand<
T> (Iterable< T> toElements(Pulse element)) → Iterable<T> -
Expands each element of this Iterable into zero or more elements.
inherited
-
firstWhere(
bool test(Pulse element), {Pulse orElse()?}) → Pulse -
The first element that satisfies the given predicate
test.inherited -
flatten(
) → Iterable< Pulse> -
Available on Iterable<
Recursively flattens any nested CollectivePulse structures into a sequence of simple pulses.Pulse> , provided by the PulseIterableExtension extension -
fold<
T> (T initialValue, T combine(T previousValue, Pulse element)) → T -
Reduces a collection to a single value by iteratively combining each
element of the collection with an existing value
inherited
-
followedBy(
Iterable< Pulse> other) → Iterable<Pulse> -
Creates the lazy concatenation of this iterable and
other.inherited -
forEach(
void action(Pulse element)) → void -
Invokes
actionon each element of this iterable in iteration order.inherited -
join(
[String separator = ""]) → String -
Converts each element to a String and concatenates the strings.
inherited
-
lastWhere(
bool test(Pulse element), {Pulse orElse()?}) → Pulse -
The last element that satisfies the given predicate
test.inherited -
lineage<
T> (LineageArgument arg) → List< T> -
Traverses the causal chain from the root ancestor to this pulse to
reconstruct a historical timeline of values.
override
-
map<
T> (T toElement(Pulse e)) → Iterable< T> -
The current elements of this iterable modified by
toElement.inherited -
map<
T> (T mapper(P payload)) → Pulse< T> -
Available on Pulse<
Transforms the payload of this pulse into a new typeP> , provided by the PulseExtension extensionTwhile preserving its causal history. -
mapEach<
T> (T mapper(dynamic payload)) → Iterable< Pulse< T> > -
Available on Iterable<
Transforms the payload of every pulse in the collection while preserving their individual causal traces.Pulse> , provided by the PulseIterableExtension extension -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
reduce(
Pulse combine(Pulse value, Pulse element)) → Pulse -
Reduces a collection to a single value by iteratively combining elements
of the collection using the provided function.
inherited
-
scrutinize(
covariant Receptor< Cell> receptor, List? positionalArguments, [Map<Symbol, dynamic> ? namedArguments]) → dynamic -
Challenges a receptor to prove it has the authority to see this pulse.
override
-
singleWhere(
bool test(Pulse element), {Pulse orElse()?}) → Pulse -
The single element that satisfies
test.inherited -
skip(
int count) → Iterable< Pulse> -
Creates an Iterable that provides all but the first
countelements.inherited -
skipWhile(
bool test(Pulse element)) → Iterable< Pulse> -
Creates an
Iterablethat skips leading elements whiletestis satisfied.inherited -
take(
int count) → Iterable< Pulse> -
Creates a lazy iterable of the
countfirst elements of this iterable.inherited -
takeWhile(
bool test(Pulse element)) → Iterable< Pulse> -
Creates a lazy iterable of the leading elements satisfying
test.inherited -
tap(
void action(P payload)) → Pulse< P> -
Available on Pulse<
Executes a side-effectP> , provided by the PulseExtension extensionactionusing the current payload and returns this pulse instance. -
toList(
{bool growable = true}) → List< Pulse> -
Creates a List containing the elements of this Iterable.
inherited
-
toSet(
) → Set< Pulse> -
Creates a Set containing the same elements as this iterable.
inherited
-
toString(
) → String -
Returns a string representation of (some of) the elements of
this.inherited -
where(
bool test(Pulse element)) → Iterable< Pulse> -
Creates a new lazy Iterable with all elements that satisfy the
predicate
test.inherited -
whereType<
T> () → Iterable< R> -
Creates a new lazy Iterable with all elements that have type
T.inherited -
withStep(
String step) → Iterable< Pulse> -
Available on Iterable<
Appends a diagnostic stage to the causal trace of every pulse in this collection.Pulse> , provided by the PulseIterableExtension extension -
withStep(
String step) → Pulse< P> -
Appends
stepto the pulse's causal trace without branching the causal chain.override
Operators
-
operator +(
covariant Pulse other) → Pulse -
Combines this pulse and
otherinto a composite CollectivePulse.override -
operator ==(
Object other) → bool -
The equality operator.
inherited