CoderanchCorral / Blackjack

Mozilla Public License 2.0
17 stars 2 forks source link

Created cli sub module and added UserInterface and InputUtilities classes to It #10

Closed Ganesh-Patekar closed 3 years ago

Ganesh-Patekar commented 5 years ago

InputUtilities for validating user inputs. UserInterface will be updated as soon as I add Hand as well as Player class.

ksnortum commented 5 years ago

You Ain't Gonna Need It


Knute Snortum (via Gmail)

On Sun, Oct 14, 2018 at 12:39 PM Ganesh Patekar notifications@github.com wrote:

@Ganesh-Patekar commented on this pull request.

In cli/src/main/java/com/coderanch/blackjack/UserInterface.java https://github.com/CoderanchCorral/Blackjack/pull/10#discussion_r225005856 :

+

  • String subMenuStr = "1. Add Balance\n2. Set/Update Bet\n3. Deal\n4. Display Info\n" + "10. Exit\nEnter choice";
  • do {
  • System.out.println(subMenuStr);
  • choice = InputUtilities.isWholeNumber();
  • switch (choice) {
  • case 1:
  • System.out.println("Enter balance");
  • int balance = InputUtilities.isWholeNumber();
  • if (balance == -1) {
  • System.out.println("Invalid balance, only whole number is allowed");
  • break;
  • }
  • // Rest code here
  • break;
  • case 2:

YAGNI ?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/CoderanchCorral/Blackjack/pull/10#discussion_r225005856, or mute the thread https://github.com/notifications/unsubscribe-auth/ACI7wDvemFGFIpWC3wLY48r2AlwmmmWfks5uk5L4gaJpZM4XbBGG .

nibsi commented 5 years ago

@Ganesh-Patekar I merged some changes into this branch. How are you doing?

nibsi commented 3 years ago

It appears this pull request has been abandoned. I'm closing it. You can create a new pull request when you want to continue.