Project management services

 

Overview

In the J language, services are provided for project management.  For example, J provides services for the creation or deletion of projects, as well as for the selection of MDACs, and so on.

 

 

Administration mode - Creating a project

Project Object:createProject

(in String projectName)

This service creates a project named projectName.  The name must be unique.  The project is created with certain MDACs deployed by default.  This service must be called only in administration mode.  The new project is returned if the creation is a success, otherwise the interpreter is stopped.

 

This API run on Object necessitates a particular context which can be retrieved in three ways:

·         in the context of MDAC deployment (the install method)

·         in the initial context of launching J on-line (administration mode)

·         after retrieving the J on-line initialization object (administration mode) using the getStartUpObject() method

 

Example:   MyProject = getStartUpObject() .createProject("MyProject");

 

 

Getting parameter values

boolean Object:getParameterValue (in String name,

in String profile, in String MDAC,

out String value)

This returns in "value" the value of the parameter "name" defined in the "profile" profile of the "MDAC" MDAC.  This returns false if the parameter does not exist.

 

 

Finding predefined types

Object Object:findPredefinedType

(in String TypeName)

This returns the "TypeName"predefined type or returns empty if this is not found.  The type is searched for in the "_predefinedTypes" project.

 

 

Finding an object from its identifiers

Element Object:projectFindFromIds

(in String PhysicalId, in String SiteId)

This looks for an object in the current project from its identifiers.  "PhysicalId" is the base identifier and "SiteId" is the site identifier.  The object is first looked for with regard to its "PhysicalId" and then regarding its "SiteId", if the first search is not successful.

If the object is not found or if there is no current project, an empty object is returned.

 

object:findFromSiteId (in String className, in String siteId)

Finds an Element in the current database from its id.  The Object is void if no object is found.

 

Example:  

C?=findFromSiteId ("Class", "1285576512");

 

 

Finding an element's identifiers

String getIdentifier()

Return the identifier of the object, which is the universal identifier of the element and which is allocated by Objecteering.  This value cannot be set by J.

 

Object:getBothIds (out String PhysicalId,

out String SiteId)

This returns both the physical and logical identifiers of the current element.  An empty string is returned if no identifier exists.