Skip to content

Commit 2e0f688

Browse files
committed
Ensured all attributes are sealed
Attribute lookups are faster when they're `sealed`; this is considered a best practice from Microsoft's framework design guidelines.
1 parent 847a511 commit 2e0f688

4 files changed

Lines changed: 4 additions & 4 deletions

File tree

Ignia.Topics/AttributeSetterAttribute.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ namespace Ignia.Topics {
4141
/// </para>
4242
/// </remarks>
4343
[System.AttributeUsage(System.AttributeTargets.Property)]
44-
sealed class AttributeSetterAttribute : System.Attribute {
44+
public sealed class AttributeSetterAttribute : System.Attribute {
4545

4646
} //Class
4747

Ignia.Topics/Mapping/AttributeKeyAttribute.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ namespace Ignia.Topics.Mapping {
2222
/// decoupled from the source attribute key.
2323
/// </remarks>
2424
[System.AttributeUsage(System.AttributeTargets.Property)]
25-
public class AttributeKeyAttribute : System.Attribute {
25+
public sealed class AttributeKeyAttribute : System.Attribute {
2626

2727
/*==========================================================================================================================
2828
| PRIVATE VARIABLES

Ignia.Topics/Mapping/InheritAttribute.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ namespace Ignia.Topics.Mapping {
2323
/// useful when an attribute is expected to be inherited by all child topics.
2424
/// </remarks>
2525
[System.AttributeUsage(System.AttributeTargets.Property)]
26-
public class InheritAttribute : System.Attribute {
26+
public sealed class InheritAttribute : System.Attribute {
2727

2828
} //Class
2929

Ignia.Topics/Mapping/MetadataAttribute.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ namespace Ignia.Topics.Mapping {
1919
/// value property) or a collection of the metadata (in the case of a collection).
2020
/// </remarks>
2121
[System.AttributeUsage(System.AttributeTargets.Property)]
22-
public class MetadataAttribute : System.Attribute {
22+
public sealed class MetadataAttribute : System.Attribute {
2323

2424
/*==========================================================================================================================
2525
| PRIVATE VARIABLES

0 commit comments

Comments
 (0)