org.wso2.carbon.device.mgt.mobile.windows.api.common.util

## Class ContextInitializer

- java.lang.Object
- - org.wso2.carbon.device.mgt.mobile.windows.api.common.util.ContextInitializer

- All Implemented Interfaces:
    EventListener, javax.servlet.ServletContextListener

      public class ContextInitializer
      extends Object
      implements javax.servlet.ServletContextListener

  This class performs one time operations.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ContextInitializer()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `contextDestroyed(javax.servlet.ServletContextEvent servletContextEvent)`
    `void` | `contextInitialized(javax.servlet.ServletContextEvent servletContextEvent)` This method loads wap-provisioning file and sets wap-provisioning file as attribute in servlet context.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ContextInitializer

          public ContextInitializer()

  - ### Method Detail

    - #### contextInitialized

          public void contextInitialized(javax.servlet.ServletContextEvent servletContextEvent)

      This method loads wap-provisioning file and sets wap-provisioning file as attribute in servlet context.
      Specified by:
        `contextInitialized` in interface `javax.servlet.ServletContextListener`
      Parameters:
        `servletContextEvent` - - Uses when servlet communicating with servlet container.

    - #### contextDestroyed

          public void contextDestroyed(javax.servlet.ServletContextEvent servletContextEvent)

      Specified by:
        `contextDestroyed` in interface `javax.servlet.ServletContextListener`

Copyright © 2017 WSO2. All rights reserved.