Document revision date: 19 July 1999
[Compaq] [Go to the documentation home page] [How to order documentation] [Help on this site] [How to contact us]
[OpenVMS documentation]

OpenVMS System Services Reference Manual


Previous Contents Index

You must have control access to the parent directory.

You must specify the following input value item code:

You can specify the following input value item codes:

DNS$_CREATE_DIRECTORY

This request creates a master directory in the specified clearinghouse.

You must have write or control access to the parent directory and write access to the master replica's clearinghouse.

You must specify the following input value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

DNS$_CREATE_LINK

This request creates a soft link to a directory, object, soft link, or clearinghouse in the namespace. Specify the target to which the soft link points in the DNS$_TARGETNAME item code. Use the DNS$_RESOLVE_NAME function code to check the existence of the target.

You must have write or control access to the directory in which the soft link is being created.

You must specify the following input value item codes:

You can specify the following input value item codes:

You can specify the following output value item code:

DNS$_CREATE_OBJECT

This request creates an object in the namespace. Initially, the object has the attributes of DNS$CTS, DNS$UTS, DNS$Class, DNS$ClassVersion, and DNS$ACS. The name service creates the DNS$CTS, DNS$UTS, and DNS$ACS attributes. The client application supplies the DNS$Class and DNS$ClassVersion attributes. You can add attributes using the DNS$_MODIFY_ATTRIBUTE function.

The DECdns clerk cannot guarantee that an object has been created. Another DNS$_CREATE_OBJECT request could supersede the object created by your call. To verify an object creation, wait until the directory is skulked and then check to see if the requested object is present. If the value of the directory's DNS$ALLUPTO attribute is greater than the DNS$CTS of the object, your object has been successfully created.

If specified, DNS$_OUTCTS holds the creation timestamp of the newly created object.

This function code returns the following:

You must have write access to the directory where the object will reside.

You must specify the following input value item codes:

You can specify the following input value item codes:

You can specify the following output value item code:

DNS$_DELETE_DIRECTORY

This request removes a directory from the namespace.

You must have delete access to the directory being deleted and write, control, or delete access to the parent directory.

You must specify the following input value item code:

You can specify the following input value item codes:

DNS$_DELETE_OBJECT

This request removes the specified object from the namespace.

This function code returns the following:

You must have delete access to the object.

You must specify the following input value item code:

You can specify the following input value item codes:

$DNS returns the following qualifying status:

DNS$_DISALLOW_CH

This request prevents a directory from storing clearinghouse objects. This request takes as input the name of a directory (DNS$_DIRECTORY).

You must have control access to the parent directory, and read or control access to any child directories.

You must specify the following input value item code:

You can specify the following input value item codes:

DNS$_ENUMERATE_ATTRIBUTES

This request returns a set of attribute names in DNS$_OUTATTRIBUTESET that are associated with the directory, object, soft link, or clearinghouse. Specify the entry type in the DNS$_LOOKINGFOR item code. The function returns either DNS$K_SET or DNS$K_SINGLE along with the set of attribute names.

To manipulate the attribute names returned by this call, you should use the DNS$REMOVE_FIRST_SET_VALUE run-time library routine.

The DECdns clerk enumerates attributes in alphabetical order. A return status of DNS$_MOREDATA implies that not all attributes have been enumerated. You should make further calls, setting DNS$_CONTEXTVARNAME to the last attribute in the set returned, until the procedure returns SS$_NORMAL.

This function code returns the following:

You must have read access to the directory, object, soft link, or clearinghouse.

You must specify the following input value item codes:

You must specify the following output value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

$DNS returns the following qualifying status:

DNS$_ENUMERATE_CHILDREN

This request takes as input a directory name with an optional simple name that uses a wildcard. The DECdns clerk matches the input against child directory entries in the specified directory.

The DECdns clerk returns a set of simple names of child directories in the target directory that match the name with the wildcard. A null set is returned when there is no match or the directory has no child directories.

To manipulate the values returned by this call, you should use the DNS$REMOVE_FIRST_SET_VALUE run-time routine. The value returned is a simple name.

The clerk enumerates child directories in alphabetical order. If the call returns DNS$_MOREDATA, not all child directories have been enumerated and the client should make further calls, setting DNS$_CONTEXTVARNAME to the last child directory in the set returned, until the procedure returns SS$_NORMAL. Subsequent calls return the child directories, starting with the directory specified in DNS$_CONTEXTVARNAME and continuing in alphabetical order.

This function code returns the following:

You must have read access to the parent directory.

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

$DNS returns the following qualifying status:

DNS$_ENUMERATE_OBJECTS

This request takes as input the directory name, a simple name that can use a wildcard, and a class name that uses a wildcard. The DECdns clerk matches these against objects in the directory. If a wildcard and class filter are not specified, all objects in the directory are returned.

The function returns (in DNS$_OUTOBJECTS) a set of simple names of object entries in the directory that match the name with the wildcard. The function also returns the class of the object entries, if specified with DNS$_RETURNCLASS. If no object entries match the wildcard or the directory contains no object entries, a null set is returned.

To manipulate the values returned by this call, you should use the DNS$REMOVE_FIRST_SET_VALUE run-time routine. The value returned is a simple name structure.

The clerk enumerates objects in alphabetical order. If the call returns DNS$_MOREDATA, not all objects have been enumerated and the client should make further calls, setting DNS$_CONTEXTVARNAME to the last object in the set returned, until the procedure returns SS$_NORMAL. If the class filter is specified, only those objects of the specified classes are returned.

This function code returns the following:

You must have read access to the directory.

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

$DNS returns the following qualifying status:

DNS$_ENUMERATE_SOFTLINKS

This request takes as input the name of a directory and a wildcarded simple name. The DECdns clerk matches these against soft links in the directory. It returns (in DNS$_OUTSOFTLINKS) a set consisting of simple names of soft links in the directory that match the wildcarded name. If no soft link entries match the wildcard or the directory contains no soft links, a null set is returned.

If no wildcard is specified, then all soft links in the directory are returned.

To manipulate the values returned by this call, use the DNS$REMOVE_FIRST_SET_VALUE run-time library routine. The value returned is a simple name.

The clerk enumerates soft links in alphabetical order. If the call returns DNS$_MOREDATA, not all matching soft links have been enumerated and the client should make further calls, setting DNS$_CONTEXTVARNAME to the last soft link in the set returned, until the procedure returns SS$_NORMAL.

This function code returns the following:

You must have read access to the directory.

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

$DNS returns the following qualifying status:

DNS$_FULL_OPAQUE_TO_STRING

This request converts a full name in opaque format to its equivalent in string format. To prevent the namespace nickname from being included in the string name, set the byte referred to by DNS$_SUPPRESS_NSNAME to 1.

This function code returns the following:

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item code:

DNS$_MODIFY_ATTRIBUTE

This request applies one update to the specified entry in the namespace. The update operations are as follows:

To add a value to a single-valued or set-valued attribute, specify a value in the DNS$_MODVALUE item code. If you do not specify a value for a single-valued attribute, you receive the error DNS$_INVALIDUPDATE. Single-valued attributes cannot exist without a value.

If you do not specify a value for a set-valued attribute, the clerk creates the attribute with an empty set.

To delete an attribute value, use the DNS$_MODVALUE item code to remove the specified value from an attribute set. If you do not specify the item code, the name service removes the attribute and all its values.

This function code returns the following:

You must have write or delete access to the directory, object, soft link, or clearinghouse whose attribute is being modified, depending on whether the operation adds or removes the attribute.

You must specify the following input value item codes:

You can specify the following input value item codes:

$DNS returns the following qualifying status:

DNS$_NEW_EPOCH

This request reconstructs an entire replica set of a directory and synchronizes the copies to recover as much of the original directory state as possible. You can also use the function to change a replica type for configuration management purposes.

This request takes as input the full name of a clearinghouse (DNS$_CLEARINGHOUSE) and directory (DNS$_DIRECTORY). Specify, optionally, the full names of clearinghouses in which to store secondary and read-only replicas (DNS$_SECCHSET and DNS$_READCHSET).

You must have control access to the parent directory and write access to each clearinghouse for which the replica type will be changed from its current value to a new value.

You must specify the following input value item codes:

You can specify the following input value item codes:

DNS$_PARSE_FULLNAME_STRING

This request takes a full name in string format and converts it to its equivalent in opaque format. If you specify the DNS$_NEXTCHAR_PTR item code, the clerk examines the name specified in DNS$_FROMSTRINGNAME for invalid characters. The buffer returns the address of the character in the name that immediately follows a valid DECdns name.

This function code returns the following:

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item code:

DNS$_PARSE_SIMPLENAME_STRING

This request takes a simple name in string format and converts it to its equivalent in opaque format. If you specify the DNS$_NEXTCHAR_PTR item code, the clerk examines the name specified in DNS$_FROMSTRINGNAME for invalid characters. The buffer returns the address of the character in that name that immediately follows a valid DECdns name.

This function code returns the following:

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item code:

DNS$_READ_ATTRIBUTE

This request returns (in DNS$_OUTVALSET) a set whose members are the values of the specified attribute.

To manipulate the values returned by this call, use the DNS$REMOVE_FIRST_SET_VALUE run-time library routine. The run-time library routine returns the value of a single-valued attribute or the first value from a set-valued attribute. The contents of DNS$_OUTVALSET are passed to DNS$REMOVE_FIRST_SET_VALUE, and the routine returns the value of the attribute.

The attribute values are returned in the order in which they were created. If the call returns DNS$_MOREDATA, not all of the set members have been returned. The client application can make further calls, setting DNS$_CONTEXTVARTIME to the timestamp of the last attribute in the set returned, until the procedure returns SS$_NORMAL.

If the client sets the DNS$_MAYBEMORE item code to 1, the name service attempts to make subsequent DNS$_READ_ATTRIBUTE calls for the same value more efficient.

This function code returns the following:

You must have read access to the object whose attribute is to be read.

You must specify the following input value item codes:

You must specify the following output value item code:

You can specify the following input value item codes:

You can specify the following output value item code:

$DNS returns the following qualifying status:

DNS$_REMOVE_LINK

This request deletes a soft link from the namespace. Only the soft link is deleted. Any DECdns name that is referenced by the soft link remains unaffected by the operation.

You must have delete access to the soft link, or delete or control access to its parent directory.

You must specify the following input value item code:

You can specify the following input value item codes:

DNS$_REMOVE_REPLICA

This request removes the specified replica of a directory.

You must have control access to the replica being removed and write access to the replica's clearinghouse.

You must specify the following input value item codes:

You can specify the following input value item codes:

DNS$_RESOLVE_NAME

This request follows a chain of soft links to its target. The function returns the full name of the target.

Applications that maintain their own databases of opaque DECdns names should use DNS$_RESOLVE_NAME any time they receive the qualifying status DNS$V_DNSB_OUTLINKED. The qualifying status indicates that a soft link was followed to make the request to the DECdns server. After receiving the resolved name, the application should store it, so future references to the name do not incur the overhead of following a soft link.

If the application provides a name that does not contain any soft links, DNS$_NOTLINKED status is returned. If the target of any of the chain of soft links followed does not exist, the DNS$_DANGLINGLINK status is returned. To obtain the target of any particular soft link, use the DNS$_READ_ATTRIBUTE function with DNS$_LOOKINGFOR set to DNS$K_SOFTLINK and request the attribute DNS$LINKTARGET. This can be useful in discovering which link in a chain does not point to an existing target. If the DECdns clerk detects a loop, it returns DNS$_POSSIBLECYCLE status.

This function code returns the following:

You must have read access to each of the soft links in the chain.

You must specify the following input value item code:

You must specify the following output value item code:

You can specify the following input value item codes:

$DNS returns the following qualifying status:

DNS$_SIMPLE_OPAQUE_TO_STRING

This request takes a simple name in opaque format and converts it to its equivalent in string format.

This function code returns the following:

You must specify the following input value item code:

You must specify the following output value item code:

DNS$_SKULK

This request attempts to ensure that all replicas of the specified directory have absorbed all updates applied to any replica prior to the time the skulk began. Successful update of the replica set requires all replicas to be available for an extended time.

You must have control access to the directory being skulked.

You must specify the following input value item code:

DNS$_TEST_ATTRIBUTE

This request tests an object for the presence of a particular attribute value. This function returns DNS$_TRUE in the $DNS status block if the specified attribute has one of the following characteristics:

If the attribute is not present or if the specified attribute does not exist, the function returns DNS$_FALSE in the $DNS status block.

This function code returns the following:

You must have test or read access to the directory, object, soft link, or clearinghouse whose attribute is to be tested.

You must specify the following input value item codes:

You can specify the following input value item codes:

$DNS returns the following qualifying status:

DNS$_TEST_GROUP

This request tests a group object for a particular member. It returns DNS$_TRUE in the $DNS status block if the specified member is a member of the specified group (or a subgroup thereof), and DNS$_FALSE otherwise. If the clerk searches a subgroup and one or more of the subgroups is unavailable, the clerk returns the status encountered in trying to access that group.

The DNS$_INOUTDIRECT argument, on input, controls the scope of the search. If you set this item code to 1, the clerk searches only the top-level group. If you set it to 0, the clerk searches all of the subgroups. On output, the clerk returns a 1 in the DNS$V_DNSB_INOUTDIRECT qualifying status if the member was found in the top-level group; it returns a 0 if the member was found in a subgroup.

This function code returns the following:

You must have test or read access to each of the groups being tested or control access to their respective directories.

You must specify the following input value item codes:

You can specify the following input value item codes:

$DNS returns the following qualifying status:

Item Codes Table SYS-7 provides a summary of item codes that are valid as an item descriptor in the itmlst argument. The table lists the item codes and their data types. Complete descriptions of each item code are provided after the table.

Table SYS-7 $DNS Item Codes and Their Data Types
Item Code Data Type
DNS$_ATTRIBUTENAME An opaque simple name, which is limited to 31 ISO Latin-1 characters.
DNS$_ATTRIBUTETYPE A single byte, indicating whether the attribute is a set (DNSK$_SET) or a single value (DNS$K_SINGLE), followed by an opaque simple name.
DNS$_CLASS An opaque simple name, limited to 31 ISO Latin-1 characters.
DNS$_CLASSFILTER An opaque simple name that can contain a wildcard.
DNS$_CLEARINGHOUSE An opaque simple name of a clearinghouse.
DNS$_CONF The confidence setting, which is a 1-byte field with the value DNS$K_LOW, DNS$K_MEDIUM, or DNS$K_HIGH.
DNS$_CONTEXTVARNAME An opaque simple name.
DNS$_CONTEXTVARTIME A creation timestamp (CTS).
DNS$_DIRECTORY An opaque full name of a directory.
DNS$_ENTRY An opaque full name of a directory, soft link, group, or clearinghouse.
DNS$_EXPIRETIME A quadword absolute time representation.
DNS$_EXTENDTIME A quadword relative time representation.
DNS$_FROMFULLNAME An opaque full name.
DNS$_FROMSIMPLENAME An opaque simple name.
DNS$_FROMSTRINGNAME A full or simple name consisting of a string of ISO-1 Latin characters. The length of the name is length stored separately in an item list.
DNS$_GROUP An opaque full name.
DNS$_INOUTDIRECT A 1-byte Boolean field. Valid values are 0 and 1.
DNS$_LINKNAME An opaque full name of a soft link.
DNS$_LOOKINGFOR A 1-byte field. Valid values are DNS$K_OBJECT, DNS$K_SOFTLINK, DNS$K_CHILDDIRECTORY, DNS$K_DIRECTORY, or DNS$K_CLEARINGHOUSE.
DNS$_MAYBEMORE A 1-byte Boolean field. Valid values are DNS$_FALSE and DNS$_TRUE.
DNS$_MEMBER A single byte, indicating whether the member is a principal (DNS$K_GRPMEM_NOT_GROUP) or another group (DNS$K_GRPMEM_IS_GROUP), followed by the opaque full name of the member.
DNS$_MODOPERATION A value indicating that an attribute is being added (DNS$K_PRESENT) or deleted (DNS$K_ABSENT).
DNS$_MODVALUE The structure of this value is dependent on the application.
DNS$_NEXTCHAR_PTR The address of an invalid character following a valid full or simple name.
DNS$_OBJECTNAME An opaque full name.
DNS$_OUTATTRIBUTESET DNS$K_SET or DNS$K_SINGLE in the first byte followed by a single or set of attribute names.
DNS$_OUTCHILDREN A set of opaque simple names of the child directories found in the parent directory.
DNS$_OUTCTS A timestamp.
DNS$_OUTNAME An opaque full name.
DNS$_OUTOBJECTS A set of opaque simple names. Optionally, each simple name can be followed by the value of the DNS$Class attribute.
DNS$_OUTSOFTLINKS A set of opaque simple names of the soft links for an object.
DNS$_OUTVALSET A set of attribute values.
DNS$_READCHSET An opaque full name of a read-only directory.
DNS$_REPLICATYPE The type of directory replica. Valid values are secondary replica (DNS$K_SECONDARY) and read-only replica (DNS$K_READONLY).
DNS$_RETURNCLASS A flag indicating that the value of DNS$Class is returned in DNS$_OUTOBJECTS.
DNS$_SECCHSET An opaque full name of a secondary directory.
DNS$_SUPPRESS_NSNAME A 1-byte value: a value of DNS$_TRUE suppresses the namespace name, and a value of DNS$_FALSE returns the namespace name.
DNS$_TARGETNAME The opaque full name of an entry in the namespace to which a soft link will point.
DNS$_TOFULLNAME The opaque full name of an object. The maximum output of DNS$PARSE_FULLNAME_STRING is 402 bytes.
DNS$_TOSIMPLENAME An opaque simple name. It can be no longer than 257 bytes.
DNS$_TOSTRINGNAME A name string of ISO-1 Latin characters. The name length is stored separately in an item list.
DNS$_VALUE An attribute value in string format.
DNS$_VERSION A 2-byte field: the first byte contains the major version number, the second contains the minor version number.
DNS$_WAIT A quadword time representation.
DNS$_WILDCARD An opaque simple name containing a wildcard character.


Previous Next Contents Index

  [Go to the documentation home page] [How to order documentation] [Help on this site] [How to contact us]  
  privacy and legal statement  
4527PRO_031.HTML