Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个托管对象数组。每个都有一个标题(名称)。我想不按字母顺序对这些进行排序,而是按与某个字符串最接近的字符串(搜索查询)进行排序
我该怎么做?
谢谢
如果您定义“最接近”匹配函数并简单地将接近值分配给这些对象(与搜索查询相比)并按此排序,这可能是最好的。
I have a List<object> which is a collection of various type of objects.
List<object>
I am writing a helper method which will return a specific type of object. The helper method will accept type