Featured
-
How Regression Testing Detects Integral Errors In Business Processes
Humans are forever changing and evolving and so to
by kristina.rigina -
Get Display Banner Advertising Opportunity on FindNerd Platform
“Do you have a product or service that nee
by manoj.rawat -
Android O Released with Top 7 New Features for App Developers
Android was founded by Andy Rubin, Rich Miner, Nic
by sudhanshu.tripathi -
Top 5 Features That Make Laravel the Best PHP Framework for Development
Laravel is a free open source Web Framework of PHP
by abhishek.tiwari.458 -
Objective C or Swift - Which Technology to Learn for iOS Development?
Swift programming language is completely based on
by siddharth.sindhi
Tags
Include Empty/Null Variable to Json while serialize with Gson Android
Are you using Gson for Serializing Json String from Java Bean/Model class? If yes then It may be useful for you.
Gson ignore null/empty value while serialize Object to Json String. Like
Gson gson = new Gson();
String jsonData = gson.to...
Using context:component-scan to pick up @Configuration Classes
In Spring 3.0 using the tag context:component-scan in xml file, the entry of the class(or bean) defined under the scan tag is automatically created. The example to show use of context:component-scan tag is as below:
Example:-
JavaConfig.jav...
@Resource annotaion in Spring
@Resource annotation allows you to specify a name of the injected bean. @Resource annotation takes a 'name' attribute which will be treated as the bean name we want to inject in the class. In other words we can say, it follows by-name autowiring ...
How to exclude a bean from auto-wiring?
When configuring beans in configuration file, set the "autowire-candidate" attribute of the bean element in .xml file to false, by doing this the container will exclude that specific bean from auto-wiring.
By using the below example we can eas...