summaryrefslogtreecommitdiffstats
path: root/src/DotNetOAuth/Messaging/MessagePartAttribute.cs
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2008-09-21 12:39:32 -0700
committerAndrew <andrewarnott@gmail.com>2008-09-21 12:39:32 -0700
commit76c4a164c8af4b5239834934bfa8915a60678ed5 (patch)
treebcf40394f040fced8b7b121d4a2d7f9367c78985 /src/DotNetOAuth/Messaging/MessagePartAttribute.cs
parent3b3a1836352fc2d50cb2698f9a2910aa1f9ba0d2 (diff)
downloadDotNetOpenAuth-76c4a164c8af4b5239834934bfa8915a60678ed5.zip
DotNetOpenAuth-76c4a164c8af4b5239834934bfa8915a60678ed5.tar.gz
DotNetOpenAuth-76c4a164c8af4b5239834934bfa8915a60678ed5.tar.bz2
StylCop and FxCop work.
Diffstat (limited to 'src/DotNetOAuth/Messaging/MessagePartAttribute.cs')
-rw-r--r--src/DotNetOAuth/Messaging/MessagePartAttribute.cs25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/DotNetOAuth/Messaging/MessagePartAttribute.cs b/src/DotNetOAuth/Messaging/MessagePartAttribute.cs
index a8de784..ae88b61 100644
--- a/src/DotNetOAuth/Messaging/MessagePartAttribute.cs
+++ b/src/DotNetOAuth/Messaging/MessagePartAttribute.cs
@@ -9,24 +9,49 @@ namespace DotNetOAuth.Messaging {
using System.Net.Security;
using System.Reflection;
+ /// <summary>
+ /// Applied to fields and properties that form a key/value in a protocol message.
+ /// </summary>
[AttributeUsage(AttributeTargets.Property | AttributeTargets.Field, Inherited = true, AllowMultiple = false)]
internal sealed class MessagePartAttribute : Attribute {
+ /// <summary>
+ /// The overridden name to use as the serialized name for the property.
+ /// </summary>
private string name;
+ /// <summary>
+ /// Initializes a new instance of the <see cref="MessagePartAttribute"/> class.
+ /// </summary>
internal MessagePartAttribute() {
}
+ /// <summary>
+ /// Initializes a new instance of the <see cref="MessagePartAttribute"/> class.
+ /// </summary>
+ /// <param name="name">
+ /// A special name to give the value of this member in the serialized message.
+ /// When null or empty, the name of the member will be used in the serialized message.
+ /// </param>
internal MessagePartAttribute(string name) {
this.Name = name;
}
+ /// <summary>
+ /// Gets or sets the name of the serialized form of this member in the message.
+ /// </summary>
public string Name {
get { return this.name; }
set { this.name = string.IsNullOrEmpty(value) ? null : value; }
}
+ /// <summary>
+ /// Gets or sets the level of protection required by this member in the serialized message.
+ /// </summary>
public ProtectionLevel RequiredProtection { get; set; }
+ /// <summary>
+ /// Gets or sets a value indicating whether this member is a required part of the serialized message.
+ /// </summary>
public bool IsRequired { get; set; }
}
}