Example:
Code: Java
JPasswordField password = new JPasswordField();
        password.setBorder( new LineBorder(Color.BLACK) );
        TableCellEditor editor = new DefaultCellEditor( password );
        table.getColumnModel().getColumn(1).setCellEditor( editor );