public bool IsDifferentFrom(ServerInformation other)
{
if (InstanceType != other.InstanceType)
{
return true;
}
if (IsPrimary != other.IsPrimary)
{
return true;
}
if (IsSecondary != other.IsSecondary)
{
return true;
}
if (IsPassive != other.IsPassive)
{
return true;
}
if (IsArbiter != other.IsArbiter)
{
return true;
}
if (MaxDocumentSize != other.MaxDocumentSize)
{
return true;
}
if (MaxMessageLength != other.MaxMessageLength)
{
return true;
}
if ((ReplicaSetInformation == null && other.ReplicaSetInformation != null) || (ReplicaSetInformation != other.ReplicaSetInformation))
{
return true;
}
return false;
}
}