¿Cuál es el acceso directo de Eclipse para " public static void main (String args [])"?


Conozco un atajo genial para System.out.println(): sysout Ctrl + Espacio .

Hay algo similar para public static void main(String args[])?

Author: ROMANIA_engineer, 2011-10-19

6 answers

Esto es solo main y Ctrl-Espacio .

 198
Author: corsiKa,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2011-10-18 20:25:24

En Eclipse, seleccione preferencias.

En preferencias, busque Java/Editor/Templates.

Aquí verá una lista de todos ellos. E incluso puedes añadir la tuya.

 42
Author: bmargulies,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2011-10-18 20:21:16

Simplemente escriba ma y presione Ctrl + Espacio , obtendrá una opción para ello.

 18
Author: Vishwa,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2013-02-04 10:17:50

Como bmargulies mencionó:

Preferencias > Java > Editor>Plantillas > Nuevo...

introduzca la descripción de la imagen aquí

introduzca la descripción de la imagen aquí

Ahora, escriba psvm y luego Ctrl + Space en Mac o Windows.

 2
Author: raja777m,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2016-10-28 15:04:49

Escriba main y mantenga presionado Ctrl y luego presione Espacio Space (double space) y selecciónelo o presione enter para centrarse en la opción principal. esta es la manera más rápida para usted

Amo realmente mi propia mente

 1
Author: ABOLFAZL_GH_IN_LOVE_WITH_JAVA,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2017-04-15 17:09:02

Alternativamente, puede iniciar un programa que contenga la línea con un clic.

Simplemente seleccione el stub del método para crear la nueva clase Java, donde el código dice,

¿Qué stubs de método te gustaría crear?

[casilla de verificación] public static void main (String [] args)

[casilla de verificación] Constructores de superclase

[casilla de verificación] Métodos abstractos heredados

 0
Author: Caleb Woodman,
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2015-09-21 17:12:07