Skip to content

rehmetjan/book-examples

 
 

Repository files navigation

Book Examples

Source code for the code examples in the Book of Vaadin and some more.

Requirements:

  • Eclipse IDE for Java EE Developers
  • Java 8 JDK installed in Eclipse
  • Apache TomEE 1.7 or newer
  • Vaadin Plugin for Eclipse
  1. Cloning

You have two options:

a) To clone the repository read-only from Github:

$ git clone https://github.com/vaadin/book-examples

b) To clone the repository from the read-write code review repository:

$ git clone ssh://<username>@dev.vaadin.com:29418/book-examples.git

Where <username> is your username in the review system.

See the contribution instructions for information about registering: https://vaadin.com/wiki/-/wiki/Main/Contributing+Code. Also note the required repository configuration for submitting code for review.

  1. Importing

You should create the server before importing, as the project files may refer to it as a compilation target. Not sure if it is relevant

  1. Create TomEE server in Eclipse

  2. In the Servers view, right-click → NewServer

  3. In the "New Server" wizard: - Select ApacheTomcat 7.0 Server - Set Server name: "Apache TomEE 1.7 at localhost" - Click Next

  4. In the Tomcat Servet step: - Name: "Apache TomEE 1.7 at localhost" - Installation Directory: "/opt/apache-tomee-webprofile-1.7.1" - JRE: Workbench default or Java 8 JRE - Click Finish

  5. Import project

  6. FileImportExisting projects intro workspace

  7. In the import wizard: - Select the cloned project directory - Click Finish

  8. Building


  1. Some Vaadin add-ons may require a snapshot version, which must be built and installed to the local Maven repository.

    For example, for Vaadin Charts:

    $ git clone https://github.com/vaadin/charts
    $ cd charts
    $ mvn install -DskipTests
  1. Refresh Ivy
  • Right-click on project, select IvyRefresh
  1. Install license keys for commercial Vaadin add-ons (Charts, etc.)

  2. Compile the widget set

  3. Select Java Resources → src/com.vaadin.book.widgetset/BookExamplesWidgetSet.gwt.xml

  4. Click Compile Widgetset in the toolbar (requires Vaadin Plugin for Eclipse)

You can also compile the themes here, or let them be compiled on-the-fly.

  1. Deployment

Just add the project to the previously created TomEE server.

You should then be able to run the application with:

http://localhost:8080/book-examples-vaadin7/book
  1. Development

Things you should notice:

  • The examples are formatted by hand, so you must not have any automatic code formatting enabled in your Eclipse default settings.
  1. Contributions

Contributions must go through the Gerrit code review system.

  • You must install the commit-msg hook as instructed
  • You must push to review as instructed

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 95.4%
  • CSS 3.0%
  • HTML 1.1%
  • Python 0.2%
  • JavaScript 0.2%
  • Scala 0.1%