$ude ("compile")

Compile development objects in the Repository.

$ude("compile", ObjectType,ObjectProfile {,"",OptionList} )

Parameters

Table 1. Parameters

Parameter

Data Type

Description

ObjectType

String

List of development object types. See Object Types.

ObjectProfile

String

String specifying an object name or retrieve profile for one or more objects of type ObjectType

OptionList

String

Associative list containing one or more options that are appropriate to the operation or the ObjectType. See Option List.

Arguments can also be a field, variable, or function that evaluates to a string or list.

Option List

The OptionList enables you to influence how the operation works. It is an associative list containing at least one option and value. Use GOLD ; in specifying multiple options.

For example, the following command compiles all menus starting with F in the MyLib library:

 $result = $ude ("compile", "menu", "F*", "", "library=MyLib")
Table 2. Options

Option

Description

library=LibraryName

Compiles the objects in the given library; supported only for global objects:

ObjectType = variables | proc | menu | panel | message |format | glyph | translation_table | device_table

language=Language

Compiles language-independent objects (variables, ProcScript, tables, and panels), plus the language-dependent objects (menus, messages, glyphs, and formats) that match the specified language. Supported only for global objects:

ObjectType = menu | message | glyph | format

palettes=Language

Compiles palettes of the specified object type. Supported only for main development objects.

templates=Language

Compiles templates of the specified object type.

If ObjectType does not specify a global object, the library and language options are ignored.

Table 3. Supported Profile and Options for Global Objects

ObjectType

ObjectProfile

OptionList

language

library

library

Y

Y

Y

variables

Y

proc

Y

Y

device_table

Y

Y

translation_table

Y

Y

panel

Y

Y

menu

Y

Y

Y

message

Y

Y

Y

glyph

Y

Y

Y

format

Y

Y

Y

Specifying the ObjectType as library is the same as specifying all global objects. You can use the library and language options to restrict compilation to a specific library or to a specific language.

Return Values

Table 4. Values returned by $ude and entitycopy

Value

Description

>=0

Success. Number of records where an attempt was made to process them. Detailed information is returned in $procReturnContext.

<0

An error occurred. $procerror contains the exact error and $procerrorcontext provides the details.

8066

8066- Copy failed: Open error on input file/table.

This error can occur when no entity descriptors cannot be found.

Table 5. Items Returned by $procreturncontext .

Items are omitted if their value is zero or an empty string.

Item

Description

Context=Context

Context of the information. For $ude("compile"), the value is UDE Compile.

Error=Number

Error number if process failed on error

InputSignatures=Number

Signatures found for compilation

OutputSignatures=Number

Signatures compiled

InputComponents=Number

Components found for compilation

OutputComponents=Number

Components compiled

InputApplications=Number

Applications found for compilation

OutputApplications=Number

Applications compiled

InputModels=Number

Models found for compilation

OutputModels=Number

Models compiled

InputDescriptors=Number

Entities found for compilation

OutputDescriptors=Number

Entities compiled

InputLibraryItems =Number

Library items found for compilation, such as menus, glyphs, global ProcScript

OutputLibraryItems=Number

Library items compiled

Infos=Number

Information messages generated during compilation

Warnings=Number

Warning messages generated during compilation

Errors=Number

Error messages generated during compilation

Release=ReleaseNumber

Number of the Uniface release of the source data.

DETAILS=String

Messages, warnings, and errors encountered during processing, structured as a list.

Object Types

When using $ude to compile objects, you must specify the development objects, providing the object type and profile. Use GOLD ; in specifying specific types of objects. Depending on the object type, you can also specify additional options.

The following object types are supported by $ude("compile"):

For variables it is not possible to specify individual variables with the ObjectProfile The ObjectProfile is ignored, and all variables are compiled for the specified library (or for all libraries if no library was specified).

Example: Compiling Entities

The following instruction analyzes (compiles) a single entity and generates and entity descriptor file (.edc).

 $result = $ude ("compile" ,"model" , "Entity.Model" ,"")

The following instruction compiles all entities in MYMODEL:

 $result = $ude ("compile" ,"model" , "*.MYMODEL" ,"")

Example: Compiling Components

The following instruction compiles all components beginning with my:

 $result = $ude("compile", "component", "my*")

For example, this returns 0 in $result and the following in $procreturncontext:

 Context=UDE Compile·;
InputComponents=4·;
OutputComponents=4·;
Infos=5·;
Warnings=19·;
Details=
 ID=1016·!·!·;
  MESSAGE=(Fields for) entity ENTITYEX not found in application model, generating now...·!·!·;
  SEVERITY=Warning·!·;
 ID=1043·!·!·;
  MESSAGE=Field CAL assumed maximum length of 40.·!·!·;
  SEVERITY=Warning·!·;
 ID=1043·!·!·;
  MESSAGE=Field SELDATE assumed maximum length of 40.·!·!·;
  SEVERITY=Warning·!·;
 ID=1016·!·!·;
  MESSAGE=(Fields for) entity BTNS not found in application model, generating now...·!·!·; 
  SEVERITY=Warning·!·;

...

Example: Compiling Libraries and Global Objects

Compile all global objects in all libraries:

 $result = $ude ("compile", "library")

Compile all global objects in the MyLib library:

 $result = $ude ("compile", "library", "", "*", "library=MyLib")

Compile all French-language messages and help texts in all libraries (language=FRA):

 $result = $ude ("compile", "message", "", "", "language=FRA")

Compile all menus in the MyLib library:

 $result = $ude ("compile", "menu", "", "", "library=MyLib")

Compile all File menus, in all libraries:

 $result = $ude ("compile", "menu", "file")

Example: Compiling DTDs

 $result = $ude("compile", "DTD", "myEntity", "", "model=myModel")

 

Uniface logo and link to website

Send feedback about this topic to Uniface.