/// <exception cref="RelationException">
/// The language of <paramref name="_base"/> does not equal.-or-
/// <paramref name="_base"/> is earlier added base.-or-
/// <paramref name="_base"/> is descendant of the interface.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="_base"/> is null.
/// </exception>
internal void AddBase(InterfaceType _base)
{
if (_base == null)
{
throw new ArgumentNullException("_base");
}
if (BaseList.Contains(_base))
{
throw new RelationException(
Strings.GetString("error_cannot_add_same_base_interface"));
}
if (_base.IsAncestor(this))
{
throw new RelationException(Strings.GetString("error_cyclic_base",
Strings.GetString("interface")));
}
if (_base.Language != this.Language)
{
throw new RelationException(Strings.GetString("error_languages_do_not_equal"));
}
BaseList.Add(_base);
Modified();
}