Posts

Showing posts from March, 2010

JEE

HttpServlet implements Serializable. JAX-RPC : Java API for XML based RPC. In reality JAX-RPC uses a protocol like SOAP but the complexity is hidden from developer. All a developer needs to do is following. Server Side : 1. Define a interface by extending javax.rmi.Remote ( SEI ) which specifies remote methods. 2. Create implementation class. 3. Use wscompile to generate WSDL and mappings service 4. Package and deploy the web service.( Th3e tie classes , which are used to communicate with clients are generating at this time by app server). Client Side : 1. use wscompile to generate and compile stub files 2. Code client class as following: Create stub object. (Stub)(new MyHelloService_Impl().getHelloIFPort()) Set the enpoint address stub._setProperty (javax.xml.rpc.Stub.ENDPOINT_ADDRESS_PROPERTY, args[0]); Cast stub to SEI object and make the procedure call. We can only use the jAX-PRC support types as param...

Jar Search

One of my colleague sent this to me. $ find . -name '*.[jwes]ar' | while read LINE; do grep -q OMSourcedElementImpl "$LINE"; if [ $? -eq 0 ];then echo "$LINE"; jar tvf "$LINE" | grep OMSourcedElementImpl;echo;fi;done

Math.abs()

Math.abs(-9223372036854775808L) == -9223372036854775808L = Long.MIN_VALUE