public SPARQLRole addRole(string role, object id, object newId) { SPARQLRole roleObj = new SPARQLRole() { Role = role, Id = id, newId = newId }; return(this.Add(roleObj)); }
public SPARQLRole Add(SPARQLRole role) { var items = from query in this.Roles where query.Role == role.Role select query; if (items.Count <SPARQLRole>() == 0) { this.Roles.Add(role); return(role); } else { return(items.First <SPARQLRole>()); } }