Files
spark/src/DataStreamSuite/DataStreamCore/DynamicLoading/StreamArgumentAttribute.cs
T
John Colvin ada7d4bed1 refactor: Load IDataStreamFactory(s) with dependency injection
So we can create ViewStreams that depend on other services, config, etc.
Previously, the PrimitiveManager relied purely on static construction of
types through reflection.
2025-11-14 14:52:07 -05:00

27 lines
823 B
C#

#nullable enable
namespace Bts.DataStreamCore;
using System;
[AttributeUsage(AttributeTargets.Property)]
public class StreamArgumentAttribute : Attribute {
public StreamArgumentAttribute(params string[] names) {
Names = names;
RegexNames = Array.Empty<string>();
}
public StreamArgumentAttribute(WellKnownStreamArgumentType wellKnownType, params string[] names) {
WellKnownType = wellKnownType;
Names = names;
RegexNames = Array.Empty<string>();
}
public string[] Names { get; }
public string[] RegexNames { get; set; }
public int Position { get; set; } = -1;
public WellKnownStreamArgumentType WellKnownType { get; }
public bool IsRequired { get; set; }
public bool AllowCommaSeparatedAliases { get; set; } = true;
public Type? ParserType { get; set; }
}