public ActionResult Image(string location, string id) { Response.Cache.SetOmitVaryStar(true); IContractFactory <IResourceAccess> builder = Actor.Public.GetNamedExport <IContractFactory <IResourceAccess> >(location); if (builder.IsNull()) { return(Content("no resource")); } return(File(builder.Build().GetImage(id), "image/png")); }
public ActionResult Script(string location, string id) { Response.Cache.SetOmitVaryStar(true); IContractFactory <IResourceAccess> builder = Actor.Public.GetNamedExport <IContractFactory <IResourceAccess> >(location); if (builder.IsNull()) { return(Content("no resource")); } return(Content(builder.Build().GetScript(id), "text/javascript")); }