Classloader Directive

Nested Elements

Element Occurance Description
classpath 0..1 The classloader classpath descriptor.
library 0..1 Jar file option extensions repository.
grant 0..1 Granting permissions to code level security.

Description

An engine directive declares the defintion of a classloader to be used assigned as the context classloader for the container it is defined within.

Example XML

<classloader>
  <classpath>
    <repository>
      <resource id="tutorial:composition-api" version="1.0"/>
    </repository>
  </classpath>
  <grant>
    <permission class="java.lang.RuntimePermission" name="getClassLoader" />
    <permission class="java.util.PropertyPermission" name="java.*" >
      <action>read</action>
    </permission>
    <permission class="java.util.PropertyPermission" name="com.mycompany.*" >
      <action>read</action>
      <action>write</action>
    </permission>
  </grant>
</classloader>