Social Network App Development
Contents
Eclipse
Style and code templates have been defined for Eclipse users. These templates are located in the SocialNetwork/dev directory in the repository. Instructions for setting up these templates are provided below. The instructions assume that the code has already been pulled from the repository and successfully loaded into Eclipse.
Right-click on the Social Network App project in Eclipse and click Properties
Go to the Java Code Style drop-down menu and click on it. Four options will be presented to you: Clean Up, Code Templates, Formatter, Organize Imports
Configuring Clean Up Settings
Go to Clean Up
Click Enable Project Specific Settings
Import SocialNetworkApp_Clean_Up.xml (located at SocialNetwork/dev)
Configuring Code Templates
Go to Code Templates
Click Enable Project Specific Settings
Import SocialNetworkApp_Code_Templates.xml (located at SocialNetwork/dev)
Configuring Formatter Settings
Go to Formatter
Click Enable Project Specific Settings
Import SocialNetworkApp_Formatter.xml (located at SocialNetwork/dev)
The Eclipse Formatter can be invoked at any time by pressing Command + Shift + F simultaneously. Alternatively, the same task can be accomplished by clicking on Source (in the menu bar) and then Format.
The Eclipse Formatter can also be invoked after every save action. To enable this feature:
Right-click on the Social Network App project in Eclipse and click Properties
Go to the Java Editor drop-down menu and click on it. Click Save Actions.
- Check off:
Enable Project Specific Settings
Perform the selected actions on save
Organize Imports
Additional Actions
Afterwards go to Configure ... and modify the settings so that they are identical to those defined in the template.