* @return the string represents user preference of gadget application
* @throws Exception when can't convert object to string
*/
public String getUserPref() throws Exception {
DataStorage service = getApplicationComponent(DataStorage.class);
org.exoplatform.portal.pom.spi.gadget.Gadget pp = service.load(state, ApplicationType.GADGET);
return pp != null ? pp.getUserPref() : null;
}
public void addUserPref(String addedUserPref) throws Exception {
DataStorage service = getApplicationComponent(DataStorage.class);