static void ExecProgram(ref Keep_User keep_) { int tamp = 0; do { User_Write(ref keep_, ref tamp); } while (true); }
public static void Start_program(ref Keep_User keep_) { do { Console.WriteLine("If you have not account write 'add' at nick and password "); Enter(ref keep_); } while (true); }
public static void Enter(ref Keep_User keep_) { Write_foo(out string a, out string b); User user = new User(a, b); if (a == "add" && b == "add") { Registretion(ref keep_, a, b); } else { keep_.Enter_User(user); } }
static void User_Write(ref Keep_User keep_, ref int tamp) { string a = "", b = ""; Write_foo(ref a, ref b); User user = new User(a, b); if (tamp == 1) { keep_.Add_User(user); } if (a == "add" && b == "add" || tamp == 1) { tamp++; } }
public static void Registretion(ref Keep_User keep_, string a, string b) { Console.WriteLine("Create account"); User user; do { if (a != "add" && b != "add") { Console.WriteLine("Replay please"); } Write_foo(out string name, out string pass); if (pass == "random") { Randomizer(out pass); } Console.Clear(); user = new User(name, pass); }while (keep_.Add_Control(user)); keep_.Add_User(user); }
static void Main() { Keep_User keep_ = new Keep_User(); ExecProgram(ref keep_); }