public RelationCollection GetRelations()
{
try
{
var retval = new RelationCollection(this.Root);
foreach (var r in this.Relationships.AsEnumerable())
{
var relation = r.Object as Relation;
if (relation != null)
{
if (relation.ChildTable.Generated)
retval.Add(relation);
}
}
return retval;
}
catch (Exception ex)
{
throw;
}
}