DeviceDependentGenerator can now add suffix to the name of the generated types.
This commit is contained in:
1 parent
0b226c76e8
commit
af7c9491e4
3 files changed
+41
-18
No files matched your search
@@ -5,11 +5,13 @@ namespace PerfectNumbers.Core;
|
||||
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct, Inherited = false, AllowMultiple = false)]
|
||||
public sealed class DeviceDependentTemplateAttribute : Attribute
|
||||
{
|
||||
public DeviceDependentTemplateAttribute(Type enumType)
|
||||
public DeviceDependentTemplateAttribute(Type enumType, string? suffix = null)
|
||||
{
|
||||
EnumType = enumType ?? throw new ArgumentNullException(nameof(enumType));
|
||||
Suffix = suffix;
|
||||
}
|
||||
|
||||
public Type EnumType { get; }
|
||||
}
|
||||
|
||||
public string? Suffix { get; }
|
||||
}
|
||||
Reference in new issue
Block a user