import java.util.Scanner;
public class Main {
public void SearchProduct() {
System.out.println("Searching the product!");
}
public void SaveProduct() {
System.out.println("The product saved successfully!");
}
public void UpdateProduct() {
System.out.println("The product has been updated");
}
public void DeleteProduct() {
System.out.println("The product deleted!");
}
public void DisplayMenu() {
System.out.println("Displaying the menu!");
}
public void CaptureProduct(){
System.out.println("The product has been captured!");
}
public void ExitApplication() {
}
public static void main(String[] args) {
int x;
System.out.print("Choose the operation to perform:\n1.SearchProduct\n2.UpdateProduct\n3.DeleteProduct\n4.DisplayMenu\n5.Capture the product\n6.Exit the application ");
Scanner input=new Scanner (System.in);
x=input.nextInt();
Main P = new Main();
if(x==1){
P.SearchProduct(); }
else if(x==2){
P.UpdateProduct();}
else if(x==3){
P.DeleteProduct();}
else if(x==4){
P.DisplayMenu();}
else if(x==5){
P.CaptureProduct();}
else if(x==6){
P.ExitApplication();}
else{
System.out.print("Invalid option!");}
}
}
Comments
Leave a comment