public void RemoveActor( Actor actor, String oldNameStartTag, String oldNameEndTag, String newNameStartTag, String newNameEndTag, Boolean dontMarkOccurrences) { ValidateActor(actor); this.PurgeReferences( actor, null, oldNameStartTag, oldNameEndTag, newNameStartTag, newNameEndTag, dontMarkOccurrences); Actors.Remove(actor); }
public void RemoveActiveActor(Actor actor) { ActiveActor aactor = (ActiveActor)this.ActiveActors.FindByUniqueID(actor.UniqueID); if(aactor != null) { this.ActiveActors.Remove(aactor); } }
public void AddActiveActor(Actor actor) { ActiveActor aactor = new ActiveActor(); aactor.ActorUniqueID = actor.UniqueID; aactor.IsPrimary = false; this.ActiveActors.Add(aactor); }
public void AddActor(Actor actor) { ValidateActor(actor); actor.Owner = this; Actors.Add(actor); }
void ValidateActor(Actor actor) { if(actor == null) { throw new NullReferenceException("Actor cannot be null"); } if(actor.ID == -1) { throw new InvalidOperationException("Actor must have a valid ID"); } }
public Actor NewActor(String name, String prefix, Int32 id) { Actor actor = new Actor(name,prefix,id,this); return actor; }