Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Similar to RoboGuice project. Allows you to declare your own annotations and the template code to be applied when the scan find them, in order to avoid boilerplate code in Android Projects

Notifications You must be signed in to change notification settings

jesantana/SantaGuice

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

SantaGuice

This project is inspired on RoboGuice. It is intended to let the user define new annotations to eliminate boilerplate code when creating an activity. So far, there are only two annotations implemented, but you are able to define your own one and implement its functionality

Example

public class ExampleActivity extends Activity {

	@InjectView(R.id.btnComenzar)
	@InjectContainerAsOnClickListener
	private Button btnComenzar;
	
	@InjectView(R.id.btnPuntuacion)
	@InjectTypeface(typefaceName="myCustomFont")
	private Button btnPuntuaciones;
	
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		
		setContentView(R.layout.select_activity);
		
		//Launch injector scan for annotated properties
		PropertyFiller.getInstance().injectAllFoundProperties(this);
	}
}

About

Similar to RoboGuice project. Allows you to declare your own annotations and the template code to be applied when the scan find them, in order to avoid boilerplate code in Android Projects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages