Guest User

Untitled

a guest
Jan 21st, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.48 KB | None | 0 0
  1. // Entrada.java
  2.  
  3.     // Lee del fichero binario un caracter
  4.     public char Leer() throws EOFException{
  5.         char cas = ' ';
  6.         try{
  7.             cas = entrada.readChar();
  8.         }catch(IOException e) {System.err.println(e);}
  9.        
  10.         return cas;
  11.     }
  12.  
  13. // Salida.java
  14.  
  15.     // Escribe en el fichero binario el caracter que se le pasa por parametro
  16.     public void EscribirCasilla(char casilla){
  17.         if(casilla!=' '){
  18.             try{
  19.                 salida.writeChar(casilla);
  20.             }catch(IOException e) {System.err.println(e);}
  21.         }
  22.     }
Add Comment
Please, Sign In to add comment