A Web registry is a file with a key maintained by Net.Data to allow you to add, retrieve, and delete entries easily. You can create multiple Net.Data Web registries on a single system. Each registry has a name and can contain multiple entries. Net.Data provides functions to maintain registries and the entries they contain.
Restriction: Do not use asterisks (*) for the registry, registryVariable, and registryData parameters when using OS/2.
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Adds an entry to a Web registry.
Format
@DTWR_ADDENTRY(registry, registryVariable, registryData, index)
@DTWR_ADDENTRY(registry, registryVariable, registryData)
Values
Table 102. DTWR_ADDENTRY Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to which the entry is added. |
| string | registryVariable | IN | The value of the registryVariable string portion of the registry entry to add. |
| string | registryData | IN | The value of the registryData string portion of the registry entry to add. |
| string | index | IN | The value of the index portion of the registryVariable string in an indexed entry to add. This parameter is optional. If specified, an indexed entry is added to the specified registry. |
Examples
Example 1:
@DTWR_ADDENTRY("Myregistry", "Jones", "http://Advantis.com/~Jones/webproj")
Example 2:
@DTWR_ADDENTRY("URLLIST", "SMITH", "http://www.software.ibm.com/",
"WORK_URL,")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Clears entries from a Web registry.
Format
@DTWR_CLEARREG(registry)
Values
Table 103. DTWR_CLEARREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to clear. |
Examples
Example 1:
@DTWR_CLEARREG("Myregistry")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
|
|
|
|
| X |
|
|
|
Purpose
Closes a Web registry
Format
@DTWR_CLOSEREG(registry)
Values
Table 104. DTWR_CLOSEREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to close.
Restriction: Do not use special characters such as the asterisk (*) and the backslash (\) in Web registry names. |
Examples
Example 1: Close a registry
@DTWR_CLOSEREG("/qsys.lib/mylib.lib/myreg.file")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Creates a new Web registry.
Re
Format
@DTWR_CREATEREG(registry, security)
@DTWR_CREATEREG(registry)
Values
Table 105. DTWR_CREATEREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to create.
Restriction: Do not use special characters such as the asterisk (*) and the backslash (\) in Web registry names. |
| string | security | IN | The type of security with which to create registry. On UNIX operating systems, the default security is the same as the directory where the registry is created. Specify security for the three security groups: user, group, and public. R gives read permission, W gives write permission, and X give execute permission. For example, to give all three groups full authority, specify *RWX, *RWX, *RWX for this parameter. This parameter it optional. |
Examples
Example 1:
@DTWR_CREATEREG("myRegistry")
Example 2:
@DTWR_CREATEREG("URLLIST", "*RWX, *RWX, *R")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Deletes an entry from a Web registry.
Format
@DTWR_DELENTRY(registry, registryVariable, index)
@DTWR_DELENTRY(registry, registryVariable)
Values
Table 106. DTWR_DELENTRY Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry from which the entry is removed. |
| string | registryVariable | IN | The value of the registryVariable string portion of the entry to remove. |
| string | index | IN | The value of the index portion of the registryVariable string in an indexed entry. This is an optional parameter. If specified, the indexed entry is removed from the registry. |
Examples
Example 1:
@DTWR_DELENTRY("Myregistry", "Jones")
Example 2:
@DTWR_DELENTRY("URLLIST", "SMITH", "WORK_URL")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Deletes a Web registry
Format
@DTWR_DELREG(registry)
Values
Table 107. DTWR_DELREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to delete. |
Examples
Example 1:
@DTWR_DELREG("Myregistry")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Lists an entire Web registry. DTWR_LISTREG returns information about the registry entries in an OUT table variable passed by the user. The table variable is defined in the user macro before being passed as a parameter to the FUNCTION block for the LISTREG registry operation.
If the user defined the table variable using the ALL option for the maximum number of rows for the table, this operation lists all available registry entries in the table, one for each table row. On the other hand if the user specified a value X for the maximum number of table rows, then if there are more then X entries in the specified registry only the first X entries are listed and an error code is sent back to indicate that only a partial listing could be done because not enough table rows were available to list additional entries. All registry entries are listed if the value X exceeds the number of available entries in the specified registry.
There are always 2 columns in the table. The Column headers for the table are set to "REGISTRY_VARIABLE" and "REGISTRY_DATA" by the Web Registry language environment.
Format
@DTWR_LISTREG(registry, registryTable)
Values
Table 108. DTWR_LISTREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to list. |
| string | registryTable | OUT | The name of the table variable in which the registry entries are placed. |
Examples
Example 1:
%DEFINE RegistryTable = %TABLE(ALL)
@DTWR_LISTREG("URLLIST", RegistryTable)
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
|
|
|
|
|
|
|
| X |
Purpose
Lists immediate subkey entries in a Web registry. DTWR_LISTSUB returns information about the registry entries in an OUT table parameter passed by the user. The table variable is defined in the macro before being passed as a parameter to the LISTSUB registry operation.
If the user has defined the table variable using the ALL option for the maximum number of rows for the table, this operation lists all available registry entries in the table, one for each table row. On the other hand, if the user specified a value X for the maximum number of table rows then if there are more then X entries in the specified registry only the first X entries are listed and an error code is sent back to indicate that only a partial listing could be done because not enough table rows are available to list additional entries. All registry entries are listed if the value X exceeds the number of available entries in the specified registry. The number of columns in the table is always one.
The column header for the table is set to "REGISTRY_SUBKEY".
This function is only valid on operating system that are compatible Windows 95 System Registries.
Format
@DTWR_LISTSUB(registry, registryTable)
Values
Table 109. DTWR_LISTSUB Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to list. |
| string | registryTable | OUT | The name of the table variable in which the registry entries are placed. |
Examples
Example 1:
%DEFINE RegistryTable = %TABLE(ALL)
@DTWR_LISTSUB("URLLIST", RegistryTable)
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
|
|
|
|
| X |
|
|
|
Purpose
Opens a Web registry.
Format
@DTWR_OPENREG(registry, commit)
@DTWR_OPENREG(registry)
Values
Table 110. DTWR_OPENREG Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry to open. |
| string | commit | IN | A single symbol or literal string specifying whether the registry is
opened under commitment control or not. The possible values are:
|
Examples
Example 1: Open the registry under commitment control
@DTWR_OPENREG("/qsys.lib/mylib.lib/myreg.file", "Y")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Retrieves the registryData string from a Web registry entry.
Format
@DTWR_RTVENTRY(registry, registryVariable, registryData, index)
@DTWR_RTVENTRY(registry, registryVariable, registryData)
@DTWR_rRTVENTRY(registry, registryVariable, index)
@DTWR_rRTVENTRY(registry, registryVariable)
Values
Table 111. DTWR_RTVENTRY Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry with entries to retrieve. |
| string | registryVariable | IN | The value of the registryVariable string portion of the registry entry whose registryData string is retrieved. |
| string | registryData | OUT | Returns the value of the registryData string portion of the registry entry that matches the registryVariable. |
| string | index | IN | The value of the index portion of the registryVariable string in an indexed entry whose registryData string is returned. This is an optional parameter. If specified, the registryData string of the indexed entry is returned. |
Examples
Example 1:
%DEFINE RegistryData = ""
@DTWR_RTVENTRY("Myregistry", "Jones", RegistryData)
Example 2:
@DTWR_RTVENTRY("URLLIST", "SMITH", RegistryData, "WORK_URL")
Example 3:
@DTWR_rRTVENTRY("Myregistry", "Jones")
Example 4:
@DTWR_rRTVENTRY("URLLIST", "SMITH", "WORK_URL")
| AIX | HP-UX | OS/2 | OS/390 | OS/400 | SCO | SUN | Win NT |
| X | X | X |
| X | X | X | X |
Purpose
Replaces the existing registryData string value for the specified registry entry with the new value specified by the caller. The registerVariable string cannot be changed.
Format
@DTWR_UPDATEENTRY(registry, registryVariable, newData, index)
@DTWR_UPDATEENTRY(registry, registryVariable, newData)
Values
Table 112. DTWR_UPDATEENTRY Parameters
| Data Type | Parameter | Use | Description |
|---|---|---|---|
| string | registry | IN | The name of the registry with the entry to update. |
| string | registryVariable | IN | The value of the registryVariable string portion of the registry entry to update. |
| string | newData | IN | The new value for the registryData string portion of the registry entry to update. |
| string | index | IN | The value of the index portion of the registryVariable string in an indexed entry to update. This is an optional parameter. If specified, the indexed entry is updated. |
Examples
Example 1:
@DTWR_UPDATEENTRY("Myregistry", "Jones", "http://advantis.com/~Jones/personal")
Example 2:
@DTWR_UPDATEENTRY("URLLIST", "SMITH", "http://www.software.ibm.com/personal", "WORK_URL")