GetRowIDsToAverageForVertexColor
(
GroupInfo oGroup,
CollapsedGroupAttributes oCollapsedGroupAttributes,
String sType
)
{
Debug.Assert(oGroup != null);
Debug.Assert(oCollapsedGroupAttributes != null);
Debug.Assert( !String.IsNullOrEmpty(sType) );
List<Int32> oRowIDsOfRowsToAverage = new List<Int32>();
IEnumerable<IVertex> oVerticesToAverage = null;
switch (sType)
{
// Fan, Connector, and Clique fall through as each includes the proper vertices
case CollapsedGroupAttributeValues.FanMotifType:
case CollapsedGroupAttributeValues.DConnectorMotifType:
case CollapsedGroupAttributeValues.CliqueMotifType:
// All of the motif's vertices should be included.
oVerticesToAverage = oGroup.Vertices;
break;
default:
break;
}
if (oVerticesToAverage != null)
{
foreach (IVertex oVertex in oVerticesToAverage)
{
// The row ID is stored in the vertex's Tag, as long as the
// vertex row isn't hidden.
if (oVertex.Tag is Int32)
{
oRowIDsOfRowsToAverage.Add( (Int32)oVertex.Tag );
}
}
}
return (oRowIDsOfRowsToAverage);
}