diff --git a/src/Nitload.RegularAnalysis/Abstraction/Mix.cs b/src/Nitload.RegularAnalysis/Abstraction/Mix.cs index df1ab372..7418472e 100644 --- a/src/Nitload.RegularAnalysis/Abstraction/Mix.cs +++ b/src/Nitload.RegularAnalysis/Abstraction/Mix.cs @@ -39,6 +39,8 @@ namespace Nitload.RegularAnalysis.Abstraction public interface IMixEvaluator { + public Relation>[] DownstreamPorts { get; } + TValue Evaluate( Span> relations ); diff --git a/src/Nitload.RegularAnalysis/PropertyRegex/PropertyEvaluator.cs b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyEvaluator.cs new file mode 100644 index 00000000..87f7c92a --- /dev/null +++ b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyEvaluator.cs @@ -0,0 +1,25 @@ +// ----------------------------------------------------------------------------- +// file="PropertyEvaluator" +// Project: StgSharp +// Copyright (c) Nitload. +// SPDX-License-Identifier: MIT +// ----------------------------------------------------------------------------- + +using Nitload.RegularAnalysis.Abstraction; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Nitload.RegularAnalysis.PropertyRegex +{ + internal abstract class PropertyEvaluator : IRelationEvaluator + { + + public abstract PropertyMatchState Evaluate( + ReadOnlySpan sequence + ); + + } +} diff --git a/src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchEngine.cs b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchEngine.cs new file mode 100644 index 00000000..b95123f7 --- /dev/null +++ b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchEngine.cs @@ -0,0 +1,32 @@ +// ----------------------------------------------------------------------------- +// file="PropertyMatchEngine" +// Project: StgSharp +// Copyright (c) Nitload. +// SPDX-License-Identifier: MIT +// ----------------------------------------------------------------------------- + +using Nitload.RegularAnalysis.Abstraction; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Nitload.RegularAnalysis.PropertyRegex +{ + public class PropertyMatchEngine + { + + private readonly List> _nodes = []; + private readonly List>> _relations = []; + + } + + public class FrozenPropertyMatchEngine + { + + private readonly Mix[] _nodes; + private readonly Relation>[] _relations; + + } +} diff --git a/src/Nitload.RegularAnalysis/AttributeRegex/PropertyMatchEngine.cs b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchState.cs similarity index 74% rename from src/Nitload.RegularAnalysis/AttributeRegex/PropertyMatchEngine.cs rename to src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchState.cs index 8ae52ead..e1fb96d4 100644 --- a/src/Nitload.RegularAnalysis/AttributeRegex/PropertyMatchEngine.cs +++ b/src/Nitload.RegularAnalysis/PropertyRegex/PropertyMatchState.cs @@ -1,5 +1,5 @@ // ----------------------------------------------------------------------------- -// file="PropertyMatchEngine" +// file="PropertyMatchState" // Project: StgSharp // Copyright (c) Nitload. // SPDX-License-Identifier: MIT @@ -11,7 +11,7 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -namespace Nitload.RegularAnalysis.AttributeRegex +namespace Nitload.RegularAnalysis.PropertyRegex { - internal class PropertyMatchEngine { } + internal class PropertyMatchState { } }