I have this class
public class Item
{
public Coordinate coordinate { get; set; }
...
...
}
With Coordinate being def
There is an overload to the GrouBy method that takes an IEqualityComparer as a parameter, but is there the equivalent using the group clause?
You can always group by an anonymous type, if you just want a quick inline solution and aren't worried about hitting the exact type for the keys:
var grouped =
from it in items
group it by new {it.Coordinate.Latitude, it.Coordinate.Longitude};