Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
HeaderAttribute.cs
1using System;
2
4{
8 [AttributeUsage(AttributeTargets.Property | AttributeTargets.Field, AllowMultiple = false, Inherited = true)]
9 public class HeaderAttribute : Attribute
10 {
14 public const int DefaultPriority = 100;
15
16 private readonly int stringId;
17 private readonly string header;
18 private readonly int priority;
19
24 public HeaderAttribute(string Header)
25 : this(0, Header, DefaultPriority)
26 {
27 }
28
34 public HeaderAttribute(int StringId, string Header)
36 {
37 }
38
44 public HeaderAttribute(string Header, int Priority)
45 : this(0, Header, Priority)
46 {
47 }
48
55 public HeaderAttribute(int StringId, string Header, int Priority)
56 {
57 this.stringId = StringId;
58 this.header = Header;
59 this.priority = Priority;
60 }
61
65 public int StringId => this.stringId;
66
70 public string Header => this.header;
71
75 public int Priority => this.priority;
76 }
77}
Defines a localizable header string for the property.
const int DefaultPriority
Default priority of parameters (100).
HeaderAttribute(int StringId, string Header)
Defines a localizable header string for the property.
HeaderAttribute(string Header)
Defines a header string for the property.
HeaderAttribute(string Header, int Priority)
Defines a header string for the property.
int Priority
Priority of parameter (default=100).
string Header
Default header string, in the default language defined for the class.
HeaderAttribute(int StringId, string Header, int Priority)
Defines a localizable header string for the property.
int StringId
String ID in the namespace of the current class, in the default language defined for the class.