Friday, June 24, 2011

Setting CLOB in Hibernate annotation

Setting CLOB in Hibernate annotation

@Lob @Basic(fetch=FetchType.EAGER)
@Column(name = "news")      
   private String news;

Wednesday, June 22, 2011

Specify username, password and timeout in jboss webservice client

Specify the username, password and timeout ,in a jboss web service client.


In your generated client class , getting Soap instance method ,
eg:


public TESTGenericDataAccessSoap getTESTGenericDataAccessSoap(){
{
TESTGenericDataAccessSoap soap = super.getPort(TESTGenericDataAccessSoap , TESTGenericDataAccessSoap .class);
        BindingProvider bp = (BindingProvider)soap;
         Stub stub = (Stub)soap;
         stub._setProperty(StubExt.PROPERTY_CLIENT_TIMEOUT, 10); //Time out
        bp.getRequestContext().put(BindingProvider.USERNAME_PROPERTY, "jijo");//Username
        bp.getRequestContext().put(BindingProvider.PASSWORD_PROPERTY, "jijo");//Password
        return soap;
}

The import classes are given,

import java.net.URL;
import javax.xml.namespace.QName;
import javax.xml.rpc.Stub;
import javax.xml.ws.BindingProvider;
import javax.xml.ws.WebEndpoint;
import javax.xml.ws.WebServiceClient;
import javax.xml.ws.WebServiceFeature;
import javax.xml.ws.Service;
import org.jboss.ws.core.StubExt;

Friday, June 10, 2011

Div is going behind the SWF

When the div is going behind the SWF, give the following paramter 

<param name="wmode" value="transparent" />
eg:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
            id="Test" width="100%" height="100%"
            codebase="http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab">
            <param name="movie" value="Test.swf" />
            <param name="quality" value="high" />
            <param name="bgcolor" value="#869ca7" />
            <param name="allowScriptAccess" value="sameDomain" />
            <param name="wmode" value="transparent" />
            <embed src="Test.swf" quality="high" bgcolor="#869ca7"
                width="100%" height="100%" name="Test" align="middle"
                play="true"
                loop="false"
                quality="high"
                allowScriptAccess="sameDomain"
                wmode="transparent"
                type="application/x-shockwave-flash"
                pluginspage="http://www.adobe.com/go/getflashplayer">
            </embed>
    </object>