|
Re: How do to...... [message #1208718 is a reply to message #1207637] |
Mon, 25 November 2013 06:28 |
|
On 11/24/2013 12:07 PM, Jose Fdz Garcia wrote:
> Hi all!!
>
> I'm new in Eclipse and want to know how to do :
>
> -Reduce code segments to his methods names,automatically when opening
> a random class
>
> For example:
>
>
> public boolean consultar(Pelicula pelicula){
> boolean bandera=false;
> try{
> String sql=new String();
> sql="SELECT * FROM peliculas WHERE CODIGO =
> "+pelicula.getCodigo()+";";
> objBBDD.resultado=objBBDD.sentencia.executeQuery(sql);
> objBBDD.resultado.next();
> pelicula.setCodigo(objBBDD.resultado.getInt("CODIGO"));
> pelicula.setTitulo(objBBDD.resultado.getString("TITULO"));
>
> pelicula.setDirector(objBBDD.resultado.getInt("COD_DIRECTOR"));
>
> pelicula.setTematica(objBBDD.resultado.getInt("COD_TEMA"));
>
> pelicula.setCaratula(objBBDD.resultado.getString("CARATULA"));
> bandera=!bandera;
> }catch (SQLException e) {
> e.printStackTrace();
> JOptionPane.showMessageDialog(null, "BD:ERROR AL
> CONSULTAR");
> }
> return bandera;
> }
>
>
> AS
>
>
> public boolean consultar(Pelicula pelicula){ ..
>
>
> I use the "PLUS BOTTOM" at left of the code, but every time i close and
> open the class the methods appears extended.
>
> Thanks for read!!
Do Window -> Preferences -> Java -> Editor -> Folding and examine the
following link. This should explain all.
http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.jdt.doc.user%2Freference%2Fpreferences%2Fjava%2Feditor%2Fref-preferences-folding.htm
|
|
|
Powered by
FUDForum. Page generated in 0.07904 seconds