public bool Quitar(TipoComplejoXsd tipo) { bool quitado = true; if (declaracionTiposComplejos.ContainsKey(tipo)) { declaracionTiposComplejos.Remove(tipo); } else { quitado = false; } return(quitado); }
public bool Añadir(TipoComplejoXsd tipo) { if (tipo.Nombre == null) { throw new XsdException("El tipo complejo tiene que tener nombre o estar dentro de la declaracion de un elemento"); } bool añadir = true; if (!declaracionTiposComplejos.ContainsKey(tipo)) { declaracionTiposComplejos.Add(tipo, null); } else { añadir = false; } return(añadir); }
public void Reemplazar(TipoComplejoXsd tipo) { Quitar(tipo); Añadir(tipo); }
public ElementoXsd(string nombre, TipoComplejoXsd tipoComplejo) : this(nombre, tipoComplejo.Nombre) { }