Skip to content

Instantly share code, notes, and snippets.

@hykilpikonna
Last active March 10, 2020 02:41
Show Gist options
  • Select an option

  • Save hykilpikonna/28d130b9beda3a1f6aae48b1c06c5fb5 to your computer and use it in GitHub Desktop.

Select an option

Save hykilpikonna/28d130b9beda3a1f6aae48b1c06c5fb5 to your computer and use it in GitHub Desktop.
Eclipse Notes

Useful Eclipse Stuff

Hotkeys:

  • Ctrl + Space: Autocomplete
  • Ctrl + 1: Quick Fix (Gonna change that to Alt + Enter)
  • F11: Run debug
  • Ctrl + Shift + O: Auto import
  • Ctrl + Shift + F: Auto format
  • Alt + Shift + R: Auto rename
  • F3: Find declaration (source)
  • Ctrl + D: Delete line

Shortcuts

  • main > complete: Create public static void main...
  • sysout > complete: Create System.out.println();
  • right click > references: Find references
  • right click > source: Auto generate methods

Debugging

  • Double click the left margin to add breakpoints
  • When paused, the right pane is the current state, the left is the stacktrace
  • It would automatically pause on error
  • F5: Step into (pause at the next execution step)
  • F6: Step over (pause at the next line)
  • F7: Step return (return out of method that you stepped into)
  • Ctrl + Alt + B: Disable breakpointing

Changes to make before contest starts

  • Prefs > Java > Code Style > Formatter > Change brackets to next line
  • Prefs > General > Keys > Change ctrl + 1 to alt + enter
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment