public static RegNumber AssignRegNumber() { if (instance == null) { instance = new RegNumber(); } instance.Number++; return(instance); }
public Registrant(string name, DateTime dateOfBirth, Address address, long phoneNumber) : this(name, dateOfBirth, address, phoneNumber, RegNumber.AssignRegNumber().Number) { }
public Club(string name, Address address, long phoneNumber) : this(name, address, phoneNumber, RegNumber.AssignRegNumber().Number) { }