Thursday, 15 August 2013

Auto Import With Eclipse Snippets -



Auto Import With Eclipse Snippets -

i started using snippets recently. mutual 1 utilize inserts @ cursor:

private logger log = loggerfactory.getlogger(getclass());

however, still have ctrl-shift-o import logger , loggerfactory.

out of pure laziness inquire this: there way automatic import when insert snippet?

i don't think snippet can automatically insert import statement (or anything other insert text @ current cursor location). can set automatic save action organize imports whenever save. open project properties , navigate java editor > save actions.

i set few different things in additional actions including organize imports, removed trailing whitespace, insert missing annotations, etc.

eclipse

No comments:

Post a Comment