/// <summary> /// Determine whether another actor is a direct child of the actor. /// </summary> /// <param name="actor"> /// The actor. /// </param> /// <param name="otherActor"> /// The other actor. /// </param> /// <returns> /// <c>true</c>, if <paramref name="otherActor"/> is a direct child of <paramref name="actor"/>; otherwise, <c>false</c>. /// </returns> public static bool IsChildOf(this IActorRef actor, IActorRef otherActor) { if (actor == null) { throw new ArgumentNullException(nameof(actor)); } if (otherActor == null) { throw new ArgumentNullException(nameof(otherActor)); } return(otherActor.IsParentOf(actor)); }