Hi I have class to sen via ria service. class look like
[DataContract]
public partial class AttributeNode
{
[DataMember]
[Key]
public int Uid { get; set; }
public AttributeNode()
{
this.Children = new List<String>();
}
private String text;
[DataMember]
public String Text
{
get
{
return text;
}
set
{
text = value;
this.Uid = text.GetHashCode();
}
}
[DataMember]
[Include]
[Association("AttributeNode_AttributeNode", "Uid", "Uid")]
public List<AttributeNode> Children { get; set; }
public void AddChild(AttributeNode child)
{
this.Children.Add(child);
}
}
The problem is that when I recive object to client it's not ok. It always as a Children contain itself. Problem is on List of same type. Help?
Tnx!!