Class JWSACCMain
- java.lang.Object
-
- org.glassfish.appclient.client.jws.boot.JWSACCMain
-
- All Implemented Interfaces:
Runnable
public class JWSACCMain extends Object implements Runnable
Alternate main class for ACC, used when launched by Java Web Start.This class assigns security permissions needed by the app server code and by the app client code, then starts the regular app client container.
Note that any logic this class executes that requires privileged access must occur either: - from a class in the signed jar containing this class, or - after setPermissions has been invoked. This is because Java Web Start grants elevated permissions only to the classes in the appserv-jwsacc-signed.jar at the beginning. Only after setPermissions has been invoked can other app server-provided code run with all permissions.
- Author:
- tjquinn
-
-
Constructor Summary
Constructors Constructor Description JWSACCMain(String[] args)
Creates a new instance of JWSMain
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static int
firstFreePolicyIndex()
Locates the first free policy.url.x setting.static ClassPathManager
getClassPathManager()
Return the class path manager appropriate to the current version.static void
main(String[] args)
static void
refreshPolicy(File policyFile)
Refreshes the current policy object using the contents of the specified file as additional policy.void
run()
-
-
-
Constructor Detail
-
JWSACCMain
public JWSACCMain(String[] args)
Creates a new instance of JWSMain
-
-
Method Detail
-
main
public static void main(String[] args)
- Parameters:
args
- the command line arguments
-
firstFreePolicyIndex
public static int firstFreePolicyIndex()
Locates the first free policy.url.x setting.- Returns:
- the int value for the first unused policy setting
-
refreshPolicy
public static void refreshPolicy(File policyFile)
Refreshes the current policy object using the contents of the specified file as additional policy.- Parameters:
policyFile
- the file containing additional policy
-
getClassPathManager
public static ClassPathManager getClassPathManager() throws ClassNotFoundException, NoSuchMethodException
Return the class path manager appropriate to the current version.- Returns:
- the correct type of ClassPathManager
- Throws:
ClassNotFoundException
NoSuchMethodException
-
-