blob: 39bfa58bdffb18d74a3ade79defa7a5a75abcdd0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
//-----------------------------------------------------------------------
// <copyright file="TestBaseMessage.cs" company="Outercurve Foundation">
// Copyright (c) Outercurve Foundation. All rights reserved.
// </copyright>
//-----------------------------------------------------------------------
namespace DotNetOpenAuth.Test.Mocks {
using System;
using System.Collections.Generic;
using System.Runtime.Serialization;
using DotNetOpenAuth.Messaging;
using DotNetOpenAuth.Messaging.Reflection;
internal class TestBaseMessage : IProtocolMessage, IBaseMessageExplicitMembers {
private Dictionary<string, string> extraData = new Dictionary<string, string>();
[MessagePart("age", IsRequired = true)]
public int Age { get; set; }
[MessagePart]
public string Name { get; set; }
[MessagePart("explicit")]
string IBaseMessageExplicitMembers.ExplicitProperty { get; set; }
Version IMessage.Version {
get { return new Version(1, 0); }
}
MessageProtections IProtocolMessage.RequiredProtection {
get { return MessageProtections.None; }
}
MessageTransport IProtocolMessage.Transport {
get { return MessageTransport.Indirect; }
}
IDictionary<string, string> IMessage.ExtraData {
get { return this.extraData; }
}
internal string PrivatePropertyAccessor {
get { return this.PrivateProperty; }
set { this.PrivateProperty = value; }
}
[MessagePart("private")]
private string PrivateProperty { get; set; }
void IMessage.EnsureValidMessage() { }
}
}
|