/// <summary>
 /// Validate the object.
 /// </summary>
 /// <exception cref="ValidationException">
 /// Thrown if validation fails
 /// </exception>
 public virtual void Validate()
 {
     if (HostPartner == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "HostPartner");
     }
     if (GuestPartner == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "GuestPartner");
     }
     if (HostIdentity == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "HostIdentity");
     }
     if (GuestIdentity == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "GuestIdentity");
     }
     if (Content == null)
     {
         throw new ValidationException(ValidationRules.CannotBeNull, "Content");
     }
     if (HostIdentity != null)
     {
         HostIdentity.Validate();
     }
     if (GuestIdentity != null)
     {
         GuestIdentity.Validate();
     }
     if (Content != null)
     {
         Content.Validate();
     }
 }
 public static AssetsFound New(HostIdentity hostIdentity, params Asset[] assets)
 {
     return new AssetsFound(new [] { hostIdentity }, assets);
 }
 public AssetsFound(HostIdentity[] hostIdentities, Asset[] assets)
 {
     HostIdentities = hostIdentities;
     Assets = assets;
 }
 public HostCreated(Guid hostId, int version, HostIdentity[] hostIdentities)
 {
     HostId = hostId;
     Version = version;
     HostIdentities = hostIdentities;
 }
 public ResolveHost(HostIdentity[] hostIdentities)
 {
     HostIdentities = hostIdentities;
 }