ConForM.CoopnTools.Pack
Class Pack

java.lang.Object
  |
  +--ConForM.CoopnTools.Pack.Pack
All Implemented Interfaces:
CoopnTool, java.lang.Runnable

public class Pack
extends java.lang.Object
implements CoopnTool

Package tool. This tool allows user to interact with their packages. More precisely, a package tool tries to open and lock (in writing) a package file. If the package file is already locked in writing, this tool tries to display the GUI of the currently locking tool. Else, it let the user to view and modify the package file. Such a tool is a "CoopnTool". Hence, it can be started either from a command line, or by another CoopnTool. In this case, a checker is likely to by started as a new thread.

See Also:
run

Field Summary
static java.lang.String TOOL
          Package tool tool name.
static java.lang.String VERSION
          Package tool version.
 
Constructor Summary
protected Pack(PackEnv env, PackEnvMgr envMgr)
          Simple constructor.
 
Method Summary
 CoopnEnv getEnv()
          Get the environment.
static Pack getTool(CoopnEnv env)
          Creates a new package tool, based on an existing environment, or null if the tool cannot be created.
static Pack getTool(PackEnv env)
          Creates a new package tool, based on an existing environment, or null if the tool cannot be created.
static void main(java.lang.String[] args)
          Main program.
 void run()
          Implementation of the package tool.
 void show()
          Show the tool's window, if the tool has its own GUI.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

VERSION

public static final java.lang.String VERSION
Package tool version.

TOOL

public static final java.lang.String TOOL
Package tool tool name.
Constructor Detail

Pack

protected Pack(PackEnv env,
               PackEnvMgr envMgr)
Simple constructor.
Parameters:
env - the simple CoopnTools environment
Method Detail

getTool

public static Pack getTool(CoopnEnv env)
Creates a new package tool, based on an existing environment, or null if the tool cannot be created.

getTool

public static Pack getTool(PackEnv env)
Creates a new package tool, based on an existing environment, or null if the tool cannot be created.

getEnv

public CoopnEnv getEnv()
Get the environment.
Specified by:
getEnv in interface CoopnTool

show

public void show()
Show the tool's window, if the tool has its own GUI. Do nothing else.
Specified by:
show in interface CoopnTool

run

public void run()
Implementation of the package tool.
Specified by:
run in interface java.lang.Runnable

main

public static void main(java.lang.String[] args)
Main program. This method creates a new environment from the command line, creates a new checker according to the environment, and call its run method.