Skip to content

ehsun7b/Shuli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 

Repository files navigation

Shuli

Very light HTTP Server for desktop applications. It lets the developer develops desktop applications using HTML5 and REST services. JavaScript is supported at both server-side and client-side.

Simplest Application

public class App extends Application {

  @Override
  protected void setup() throws Exception {
    addResource("/", new Resource(Thread.currentThread().getContextClassLoader().getResource("index.html"), "text/html"));
  }

  public static void main(String[] args) throws ApplicationException {
    App app = new App();

    Properties config = new Properties();
    config.setProperty("scan_package", "some.package");
    app.setConfig(config);

    app.start();
  }
}



Configuration by properties file

Include ,b>shuli.properties in your classpath

scan_package=some.package
port=6265
context=/app
public class App extends Application {

  @Override
  protected void setup() throws Exception {
    addResource("/", new Resource(Thread.currentThread().getContextClassLoader().getResource("index.html"), "text/html"));
  }

  public static void main(String[] args) throws ApplicationException {
    App app = new App();
    app.start();
  }
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages