Wednesday, June 27, 2012

Basics of mobile terminologies

Disclaimer - I am posting this article from Economic Times.

Below are some terms we have heard these days in smart phone comparisons, and there are some of the more important considerations -

1. Display 

Today, we have displays of different sizes and compositions, each one claiming to be better than the other. 

Associated Terms: AMOLED, LCD, Super LCD, Retina, PPI, ClearBlack. What you need to know: Bigger displays might look better but also drain battery life. And while we recommend going for the highest resolution screen within your budget, do remember to check if the apps you want to use support that resolution. As for the AMOLED vs LCD debate, we advise you to trust your eyes to 'see' which one works best for you. As a general rule, AMOLEDs are brighter and produce richer colours, but LCDs render text better. 

2.  Processor 

The processor is the engine that drives your phone. As phones become more powerful, processors are getting into dual core and quad core territory. 

Associated Terms/ Figures: Dual Core, Quad Core, 800 MHz, 1/1.2/1.5GHz, Snapdragon, Tegra, Intel, Qualcomm. 

What you need to know: A faster processor with more cores will work better, but what you need to keep in mind is whether the operating system and apps on your device are actually designed to use the extra power. If you're only looking for good web browsing, social networking and some casual gaming, a single core 800 MHz processor will do nicely too. 

3.  RAM 

The RAM allows the phone to run multiple applications simultaneously and do various tasks in the background.

Associated Terms/ Figures: 256 MB, 512 MB, 768 MB, 1 GB. 

What you need to know: While some operating systems need more RAM, others will function smoothly with lesser amounts. For instance, you'll see a lot of new Android devices with 1 GB of RAM, but most Windows Phone devices run fine at 512 MB and many Symbian devices work fine at even 256 MB. It is not really about the amount of RAM but about the OS of your device. 

4.  Camera 

Once considered a luxury in smartphones, the camera is now an integral part of smartphones. 

Associated terms: 3.2/5/8/12/41 Megapixels, Auto Focus, Shooting Modes, HD video, LED/Xenon flash. 

What you need to know: There is a whole lot more to any camera than megapixels. The quality of the lens, the camera software and the presence of options like autofocus and different scene settings make a world of difference - so much so, that many 5MP cameraphones outperform 8MP ones. If you want to take loads of photographs, check for features like auto focus/touch focus, xenon flash, face detection, macro mode and red eye reduction. 

5.  Battery 

The battery (with a capacity expressed in mAh or milli ampere hour) determines how long your phone keeps working on a single charge. As phones get bigger, so do their batteries. 

Associated terms: Li-ion, mAh, removable, non-removable 

What you need to know: While battery life varies a lot depending on how you use a phone, a phone with a battery that has a high mAh count will generally offer better backup. Operating systems like Symbian and BlackBerry also tend to manage battery life better than the likes of Android and iOS. As for the 'removable vs non-removable' issue, we have not seen it making a major difference - unless you plug your phone in several times a day, necessitating a battery replacement before you actually need to change your phone.

Monday, June 25, 2012

Difference between Pram and Stroller

Recently I became a first time father, father of my son "Varenya Bisht." These days I and my wife (Nirmala) buying out lot of new things for Varenya, and while looking for Pram and Stroller we were confused between these two terms - Pram and Stroller.
Me and Nirmala, googled the term and found this difference between two -


Pram and stroller are used interchangeably; however, their main difference is that prams are used to carry new born babies until they are able to sit up while strollers are used to carry toddlers or infants who are already able to sit up. Another significant difference between the two is prams are bulky and heavy which is not a good choice for child transport when going to the malls or when carrying them in the car while strollers are lightweight and most models of strollers are collapsible. Additionally, prams’ carriages are high while the strollers’ seats ride low to the ground.
There are baby carriages that are hybrid of prams and strollers which are practical to buy as you will not have to change the carriage quickly as your child gets older. However, in choosing the best carriage, you should consider your child’s comfort.


Source:- http://www.differencebetween.com/difference-between-pram-and-vs-stroller/#ixzz1ymnOrrni

Thursday, May 10, 2012


Solution to - On creating apache cxf web service getting error: org.apache.cxf.service.factory.ServiceConstructionException and xxx counts of com.sun.xml.bind.v2.runtime.IllegalAnnotationExceptions


Complete stack trace is: - 



Exception in thread "main" org.apache.cxf.service.factory.ServiceConstructionException
at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:351)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:460)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.buildServiceFromClass(JaxWsServiceFactoryBean.java:548)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:523)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:271)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:177)
at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:100)
at org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:51)
at org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:102)
at org.apache.cxf.jaxws.JaxWsProxyFactoryBean.create(JaxWsProxyFactoryBean.java:115)
at com.landisgyr.iec61968.cl.transports.ummv2ws.ServiceObjectTransport.init(ServiceObjectTransport.java:59)
at com.landisgyr.iec61968.cl.transports.ummv2ws.ServiceObjectTransport.start(ServiceObjectTransport.java:44)
at com.landisgyr.iec61968.cl.protocols.CLProtocol.start(CLProtocol.java:454)
at com.landisgyr.iec61968.cl.common.CommunicationLibrary.start(CommunicationLibrary.java:181)
at c1.test.TestComLibPOC.main(TestComLibPOC.java:113)
Caused by: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 3 counts of IllegalAnnotationExceptions
Two classes have the same XML type name "{http://iec.ch/TC57/2011/schema/message}Response". Use @XmlType.name and @XmlType.namespace to assign different names to them.
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.PublishEventResponse
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.RequestResponse
Two classes have the same XML type name "{http://iec.ch/TC57/2011/schema/message}Response". Use @XmlType.name and @XmlType.namespace to assign different names to them.
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.RequestResponse
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.Response
Two classes have the same XML type name "{http://iec.ch/TC57/2011/schema/message}Response". Use @XmlType.name and @XmlType.namespace to assign different names to them.
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.Response
this problem is related to the following location:
at com.landisgyr.iec61968.cl.transports.ummv2ws.jaxws_asm.ResponseResponse


at com.sun.xml.bind.v2.runtime.IllegalAnnotationsException$Builder.check(IllegalAnnotationsException.java:102)
at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(JAXBContextImpl.java:472)
at com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.java:302)
at com.sun.xml.bind.v2.runtime.JAXBContextImpl$JAXBContextBuilder.build(JAXBContextImpl.java:1136)
at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:154)
at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:121)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at javax.xml.bind.ContextFinder.newInstance(Unknown Source)
at javax.xml.bind.ContextFinder.find(Unknown Source)
at javax.xml.bind.JAXBContext.newInstance(Unknown Source)
at org.apache.cxf.jaxb.JAXBDataBinding.createJAXBContextAndSchemas(JAXBDataBinding.java:510)
at org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:334)
... 14 more

I have found the solution here - 

In my case the web service method name is: - 


    @RequestWrapper(localName = "Request", targetNamespace = "http://iec.ch/TC57/2011/schema/message", className = "IEC61968.ch.iec.tc57.LG._2011.RequestMessageType")
    @WebMethod(operationName = "Request", action = "http://iec.ch/61968/Request")
    @ResponseWrapper(localName = "Response", targetNamespace = "http://iec.ch/TC57/2011/schema/message", className = "IEC61968.ch.iec.tc57.LG._2011.ResponseMessageType")
    public void request(
        @WebParam(mode = WebParam.Mode.INOUT, name = "Header", targetNamespace = "")
        javax.xml.ws.Holder<HeaderType> header,
        @WebParam(name = "Request", targetNamespace = "http://iec.ch/TC57/2011/schema/message")
        RequestType request,
        @WebParam(mode = WebParam.Mode.INOUT, name = "Payload", targetNamespace = "")
        javax.xml.ws.Holder<PayloadType> payload,
        @WebParam(mode = WebParam.Mode.OUT, name = "Reply", targetNamespace = "")
        javax.xml.ws.Holder<ReplyType> reply
    );

In this case the method name is - 'request', and also the method parameter name is - 'request'

JAX-WS generates a class for each method, in this case the class name constructed is-methodName + "Response", which is actually translates toRequestResponse
In my case, the newly generated class by JAX-WS will have the same name as my method parameter  name which is a request by name, JAX-WS also generates the same class name - 'RequestResponse'. That is why the reason for conflict.

I have  changed the method parameter name from 'request' to 'req', and it works perfectly fine, and I am able to start the web service with no issues. Thanks to stackoverflow.com and Rosdi Kasim.