// OntologyGadgets
public PreparedGadget(GadgetSpec gadgetSpec, OpenSocialManager openSocialManager, string view, string optParams, string chromeId)
{
this.gadgetSpec = gadgetSpec;
this.openSocialManager = openSocialManager;
this.securityToken = SocketSendReceive(openSocialManager.GetViewerURI(), openSocialManager.GetOwnerURI(), gadgetSpec.GetGadgetURL());
this.view = view;
this.chromeId = chromeId;
this.optParams = optParams == null || optParams.Trim() == string.Empty ? "{}" : optParams;
}