Skip to content

Commit bdcd66a

Browse files
committed
marked Named<T> as DataContract to allow serialization
1 parent f25da8e commit bdcd66a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

NetPrints/Core/Named.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
using System;
22
using System.Collections.Generic;
33
using System.Linq;
4+
using System.Runtime.Serialization;
45
using System.Text;
56

67
namespace NetPrints.Core
@@ -10,9 +11,13 @@ namespace NetPrints.Core
1011
/// converted to the class itself.
1112
/// </summary>
1213
/// <typeparam name="T">Type of the value.</typeparam>
14+
[DataContract]
1315
public class Named<T>
1416
{
17+
[DataMember]
1518
public string Name { get; set; }
19+
20+
[DataMember]
1621
public T Value { get; set; }
1722

1823
public Named(string name, T type)

0 commit comments

Comments
 (0)