Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
UnauthorizeSource.cs
1using System;
2using System.Threading.Tasks;
3
5{
10 {
15 : base()
16 {
17 }
18
22 public override string LocalName => nameof(UnauthorizeSource);
23
28 public override IStateMachineNode Create()
29 {
30 return new UnauthorizeSource();
31 }
32
37 public override async Task Execute(EvaluationArguments Arguments)
38 {
39 object Source = await this.Source.Evaluate(Arguments);
40 if (!(Source is string SourceString))
41 throw new Exception("Expected text source.");
42
43 Arguments.RemoveSource(SourceString);
44 }
45 }
46}
override async Task Execute(EvaluationArguments Arguments)
Evaluates the action node
override IStateMachineNode Create()
Creates a new node of the corresponding type.
UnauthorizeSource()
Unauthorizes a source from performing external notes.
Contains information required for evaluating script in a state-machine.
void RemoveSource(CaseInsensitiveString Source)
Removes an authorization.
Task< object > Evaluate(EvaluationArguments Arguments)
Evaluates the value node.
Definition: Value.cs:146