Package org.inguelberth.app

Examples of org.inguelberth.app.AbstractAppRol


public class Principal{
  public void iniciar(){
    do{
      Decodificador decodificador = new Decodificador();
      AbstractAppRol appRol = null;

      String nick, password;
      System.out.println("Ingrese Nick:");
      nick = Input.getInstancia().leer();

      System.out.println("Ingrese contraseña:");
      password= Input.getInstancia().leer();

      boolean resultado = ManejadorUsuario.getInstancia().autenticarUsuario(nick, password);

      if(resultado==true){
        System.out.println("Bienvenido "+ManejadorUsuario.getInstancia().obtenerUsuarioAutenticado().getNombre() + "!");
        switch(ManejadorUsuario.getInstancia().obtenerUsuarioAutenticado().getRol()){
          case "admin":
            appRol=new AppAdmin(decodificador);
            break;
          case "empleado":
            appRol=new AppEmpleado(decodificador);
            break;
          case "cliente":
            //appRol=new AppCliente();
            break;
          default:
            System.out.println("Lo sentimos, su Rol esta en construccion...");
        }
        appRol.iniciar();
        System.out.println("");
        System.out.println("  Bye :)");
        System.out.println("");
        System.out.println("");
      }else
View Full Code Here

TOP

Related Classes of org.inguelberth.app.AbstractAppRol

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.