Main.java

/**
 * Copyright (c) 2013 Nokia Corporation. All rights reserved.
 * Nokia and Nokia Connecting People are registered trademarks of Nokia Corporation.
 * Oracle and Java are trademarks or registered trademarks of Oracle and/or its
 * affiliates. Other product and company names mentioned herein may be trademarks
 * or trade names of their respective owners.
 * See LICENSE.TXT for license information.
 */

package com.nokia.example.nnaclientexample;

import javax.microedition.lcdui.Display;
import javax.microedition.midlet.MIDlet;

/**
 * The application main class.
 */
public class Main extends MIDlet
{
    private MainView mainView;

    /**
     * Constructor.
     */
    public Main() {
    }

    /**
     * @see javax.microedition.midlet.MIDlet#startApp()
     */
    public void startApp() {
        mainView = new MainView(this);
        Display.getDisplay(this).setCurrent(mainView);
    }

    /**
     * @see javax.microedition.midlet.MIDlet#pauseApp() 
     */
    public void pauseApp() {
    }

    /**
     * @see javax.microedition.midlet.MIDlet#destroyApp(boolean) 
     */
    public void destroyApp(boolean unconditional) {
    }

    /**
     * Quits the application.
     */
    public void quit() {
        destroyApp(true);
        notifyDestroyed();
    }
}