mirror of
https://github.com/Theodor-Springmann-Stiftung/hamann-ausgabe-core.git
synced 2025-10-28 16:55:32 +00:00
13 lines
402 B
C#
13 lines
402 B
C#
using System;
|
|
using HaDocument.Models;
|
|
using System.Collections.Generic;
|
|
|
|
namespace HaDocument.Comparers {
|
|
public class PersonComparer : IComparer<Person> {
|
|
public int Compare(Person first, Person second) {
|
|
var cmp = String.Compare(first.Surname, second.Surname);
|
|
if (cmp == 0) cmp = String.Compare(first.Name, second.Name);
|
|
return cmp;
|
|
}
|
|
}
|
|
} |