Application

An application is a Studio’s project.

Programming tasks

Recover an application

In the project module, you may recover every created application. The following example shows how to get one from its system name and its organization.

IProjectModule projectModule = Modules.getProjectModule();
try {
	IProject project = projectModule.getProject( context, PROJECT_NAME, myOrganization );
} catch (ModuleException e) {
	// Manage Exception
} finally {
	Modules.releaseModule( projectModule );
}

Use the configurations

Process lets the integrators define the parameters for the specific development on the server, organization or application levels.

public void project_useConfiguration( IProject project ) {
	// retrieving the configuration from an application
	IConfiguration configuration = project.getConfiguration();
}

public void catalog_useConfiguration( ICatalog catalog ) {
	// retrieving the configuration from a catalog
	IConfiguration configuration = catalog.getConfiguration();
}

Settings

Server settings

From a configuration object, you may recover the standard parameters by using the methods getProperty() or getProperties().

The interface com.axemble.vdp.configuration.interfaces.ConfigurationParameters defines a certain number of keywords that permits to retrieve server information.

List of available keywords:

Key word Description
SMTP_SERVER SMTP_SERVER SMTP server address
SMTP_ENCODING Encoding used by the SMTP server
SERVER_BASE_URL Server URL for the links to the server
MAX_FILE_SIZE File maximum size
SUPPORTED_LANGUAGES Supported languages
DEFAULT_LANGUAGE Default language
ADMIN_EMAIL Messaging address of the administrator account
DEFAULT_EMAIL_SENDER Messaging address of the default sender account
SUPPORTED_FILE_EXTENSIONS File extensions supported by the downloading
XLS_DATE_FORMAT Date format for Excel documents
DEFAULT_MIN_DATE Date fields minimum limit
DEFAULT_MAX_DATE Date fields maximum limit

The following example indicates how to recover, from the server parameters, the default sender messaging address.

public void getProperty( IConfiguration configuration ) {
	// retrieving the default sender
	String emailSender = configuration.getProperty( ConfigurationParameters.DEFAULT_EMAIL_SENDER );
	System.out.println( "Default email sender" + defaultEmailSender );
}

User settings

From a configuration object, you may recover the “user” parameters by using the methods getUserProperty() or getUserProperties().

public void getUserProperty( IConfiguration configuration ) {
	// retrieving the user parameters
	String anyParameterValue = configuration.getUserProperty( "any.parameter" );
	String anotherParameterValue = configuration.getUserProperty( "another.parameter" );

	System.out.println( "any.parameter : " + anyParameterValue );
	System.out.println( "another.parameter : " + anotherParameterValue );
}

Recover a process version

From a ICatalog object, you may recover every process versions. The following example shows how to recover a particular version from its system name.

public void catalog_getWorkflow( IContext context, IWorkflowModule workflowModule, ICatalog catalog ) throws WorkflowModuleException {
	IWorkflow workflow = workflowModule.getWorkflow( context, catalog, "documentManagement_1.0" );
}