Example usage for com.google.gwt.core.client EntryPoint onModuleLoad

List of usage examples for com.google.gwt.core.client EntryPoint onModuleLoad

Introduction

In this page you can find the example usage for com.google.gwt.core.client EntryPoint onModuleLoad.

Prototype

void onModuleLoad();

Source Link

Document

The entry point method, called automatically by loading a module that declares an implementing class as an entry point.

Usage

From source file:org.opencms.ade.client.OpenCmsEntryPoint.java

License:Open Source License

/**
 * @see org.opencms.gwt.client.A_CmsEntryPoint#onModuleLoad()
 *//*w w w  .ja va 2  s . c  om*/
@SuppressWarnings("incomplete-switch")
@Override
public void onModuleLoad() {

    EntryPoint entry = null;
    ModuleKey key = getModuleKey();
    if (key != null) {
        switch (key) {
        case containerpage:
            entry = new CmsContainerpageEditor();
            break;
        case contenteditor:
            entry = new CmsContentEditorEntryPoint();
            break;
        case galleries:
            entry = new CmsGallery();
            break;
        case postupload:
            entry = new CmsPostUploadDialogEntryPoint();
            break;
        case publish:
            entry = new CmsPublishEntryPoint();
            break;
        case sitemap:
            entry = new CmsSitemapView();
            break;
        case upload:
            entry = new CmsUpload();
            break;
        case editprovider:
            entry = new CmsDirectEditEntryPoint();
            break;
        case properties:
            entry = new CmsPropertiesEntryPoint();
            break;
        }
    }

    if (entry != null) {
        entry.onModuleLoad();
    }
}