C # array of objects - conditional check
Sorry for the vague title!
I have a class with multiple member variables (system, zone, site, ...)
public sealed class Cello
{
public String Company;
public String Zone;
public String System;
public String Site;
public String Facility;
public String Process;
//...
}
I have an array of objects of this class.
private Cello[] m_cellos = null;
// ...
I need to know if the array contains objects with the same site, but different systems, zones or companies, as such a situation would be illegal. I have different checks, but they are all similar.
The Array class has a number of functions that look promising, but I'm not very good at defining "key selector" functions and the like.
Any suggestions or pointers are greatly appreciated.
--- Alistair.
+2
a source to share