eFace is the Worldwide First XAML solution for Java. It provides an unified programming model for building both rich client application and RIA. It keeps insulation for applications from the technology/environment change such as Swing, SWT or Web/Ajax.

    Vote for it on EPIC :

eFace Eclipse Environment

  • Prerequisites
  • Component development
  • Develop and Deploy a RCP application
  •  

    Prerequisites

    To build the application that is developed over the course of this tutorial, you will need to have eclipse 3.3 and Java Development Kit (JDK) 1.5 above installed.

    Download the eFace package from http://www.soyatec.com/eface/installation/ . You should register first.

    To install, open Eclipse, select Help-> Software Updates->Find and Install as below. 

     Select "Search for new features and install" and click Next.

    Click new Local Site, select Computer option, and find your eclipse directory, choose install->plugins, then click OK button as following.

     In the pop Edit Local Site dialog, click OK. Select the soyatec/install option and click Next.

     Select eFace and click Ok.

    In the following dialog, read carefully all the license agreements and select "I accept the terms in the license agreements", if you accpet, click Next button and in the next dialog click Finish button.
    You will see Verification dialog, then click Install All.

    In the next Install/Update pop dialog, click "Yes".
    Select Help->About Eclipse SDK, if you see the dialog below, then eFace successfully completed.

    After meeting all the above, then you can develop your application on eFace.

     

    Component development

    1. Create an eFace project
    Create a java project named eFace and  then expand eFace project, select src folder and call the context menu New->Other->eFace XAML->Window component, in the coming wizard dialog, click Next.

    2. Create a XAML component
    Fill Package name as "com.eface", component name as "Sample",then click Finish button. The fundamentals of eFace XAML resource and corresponding Java file are generated automatically together.

    In this step, it will list a simple sample for teaching how to use eFace for developing.
    Source is XAML editor, for example, you can create a button and you can define the width and height of the window as following. Then the button is displayed in the live display area.

    3. Test your application
    There are two ways to test your application. The first is to click preview for a view.

    If you want add an action for the button. Add a Click property to the button as following.

    Then click  to generate the Java code, please see the Java editor, then you can add code here, it's like this:


    The second way is to find .xaml file in Package Explorer, right select Sample.xaml->XAML Open->open.

                           

     

    Develop and Deploy a RCP application

  • 1.eFace RCP
  • 2.Eclipse RCP
  • 1. eFace RCP

    The following sample shows the eFace approach. It brings the hello World application into rich client environment. All elements are build on eFace, including the main menu.

    To create a plug-in project, open Eclipse, select New->Project->Plug-in Project, click Next, fill the project name as "DemoRCP" and click Next.

    In the following dialog, uncheck the Generate an activator option check box and select the Yes radio button to create a RCP application, then click Next.

    In the Available Templates, choose eFace-Hello RCP, click Next button and in the coming dialog select the Add branding check box to generate the deployment configuration files, then click Finish.

    Choose src->demorcp->Main.xaml, select the Source tab. Then close Main.xaml to go back to plugin configuration.

    Click the Launch an Eclipse application link to run the application in testing mode.  

    If you see the dialog below, close it. Then can go on RCP application deployment.

    Open DemoRCP.product to setup the deployment configuration, select the Configuration tab, click AddRequired Plug-ins button to add the platform dependence plugins.

    Select the Overview tab, click the Eclipse Product export wizard link.

    In the following dialog, fill your Directory and click Finish button.

    Find your deploy directory, select deploy->elipse, double click eclipse.exe to execute the application.

    2. Eclipse RCP

    The following sample uses the Eclipse RCP as main infrastructure, same as a standard Eclipse RCP application. The eFace view is only embedded in a specific view of Eclipse, but its content is loaded directly from XAML files.

    To create a plug-in project, open Eclipse, select New->Project->Plug-in Project, click Next, fill the project name as "RCPView" and click Next.

    In the following dialog, uncheck the Generate an activator option check box and select the Yes radio button to create a RCP application, then click Next. In the coming dialog select eFace-RCP application with a view. click Next button.

    Select the Add branding check box to generate the deployment configuration files, then click Finish.

    Choose src->rcpview->View.xaml, Then close the View.xaml tab.

    Click the Launch an Eclipse application link to test the application in development environment.

    If you see the dialog below, close it. Then can go on deploy the application.

    Open RCPView.product, select the configuration tab, click Add Required Plug-ins button to add the platform dependence plugins. Then select Overview tab, click the Eclipse Product export wizard link.

    In the following dialog, locate your Directory to "c:\deploy"and click Finish button. Find your deploy directory, select deploy->elipse, double click eclipse.exe to execute the application.