Class WebInterface

java.lang.Object
net.simplace.sim.wrapper.web.WebInterface

public final class WebInterface extends Object
Routes of the web client (started by WebServer): runs a solution (optionally with a project) from the browser, shows progress and log while it runs, shows the CSV outputs as diagrams and offers the output files written by the run for download. The page is served under /web (/ redirects there).

Every request needs the login web.user / web.password (Basic-Auth, see WebConfig). Like every binding, the web client uses only the public SimplaceWrapper API and the process-wide engine lock (see WebRunner); it does not depend on the REST wrapper. The pages (index.html, app.js, style.css, manifest and icons for the home screen of a phone) are resources of simplace_core (res/files/net/simplace/sim/wrapper/web); uPlot (MIT licence) for the result diagrams is below vendor/ there. The browser polls the state every second; no WebSocket, so it also works behind simple proxies.

Routes below /web/api: files (solutions and projects of the work directory), graph (overview of a solution: resources, transformers, components, outputs and their links, see WebGraph), parameters (the <dyn> variables of a solution as form, see WebParameters), runs (start; single run, existing project, or a project built in the browser as table or sensitivity analysis, see WebProject), state (job and log), outputs/{index} (download), outputs/{index}/data?cols= (columns of a CSV output for the diagram, see WebOutputData) and outputs.zip.

Author:
Andreas Enders, Claude (Anthropic), co-author