最佳答案
As I was writing some extension methods for my business logic objects, I came to the question of renaming the conversion methods. someObject.ToAnotherObject()
would go fine with the widely used object.ToString()
.
However LINQ, for example, mixes up both variants and I can't find a difference between them. ToDictionary()
, ToList()
, AsParallel()
, AsQueryable()
, ...
What are the differences between these two naming conventions and what should I know to decide whether to use for my own classes?