IdmaServiceRegistry

Provides access to registry elements that maintain information about the implementation of DMA Service Objects

IdmaServiceRegistry::FindNextRegistryElement

This method must be supported in every implementation of this interface.

Syntax
DmaRC IdmaServiceRegistry::FindNextRegistryElement (
pDmaId pPrevRegistrationId,
pDmaId pServiceObjectIdFilter,
pDmaId pServiceObjectTypeIdFilter,
pDmaInteger32 plCharSetEncodingIdFilter,
pDmaBoolean pbPublishedFilter,
pDmaId pRegistrationId,
pDmaId pServiceObjectId,
pDmaId pServiceObjectTypeId,
ppDmaString ppProfile,
pDmaId pModuleTypeId,
ppDmaString ppModuleLocation,
pDmaInteger32 plCharSetEncodingId,
pDmaBoolean pbPublished)

Parameters

Name

Mode

Description

pPrevRegistrationId

input

A reference to the registration Id of an existing Registry element or NULL.

pServiceObjectIdFilter

input

A reference to the Id of a Service Object or NULL. If non-NULL, this method will only return registration elements with Service Object Ids that match the dereferenced value of this parameter.

pServiceObjectTypeIdFilter

input

A reference to the Id of a Service Object Type or NULL. If non-NULL, this method will only return registration elements with Service Object Type Ids that match the dereferenced value of this parameter.

plCharSetEncodingIdFilter

input

A reference to a Character Set Encoding Id or NULL. If non-NULL, this method will only return registration elements with Character Set Encoding Ids that match the dereferenced value of this parameter.

pbPublishedFilter

input

A reference to a boolean or NULL. If non-NULL, this method will only return registration elements with Published values that match the dereferenced value of this parameter.

pRegistrationId

output

(optional) The registration Id of a previously registered registry element. This parameter uniquely identifies the registry element accessed by this method.

pServiceObjectId

output

(optional) The Id of a Service Object that is registered with the System.

pServiceObjectTypeId

output

(optional) Returns the Type Id for the service object.

ppProfile

output

(optional) Returns a copy of the profile string that is supplied to the Service Object when it is activated.

pModuleTypeId

output

(optional) A DmaId value that specifies of the type of Module used to implement the Service Object, e.g. a WIN32 DLL.

ppModuleLocation

output

(optional) Returns a string that identifies the location of the Module.

plCharSetEncodingId

output

(optional) Returns the character set encoding that is supported by this service object.

pbPublished

output

(optional) Returns a boolean indicating whether this registration element has been published.

Description

Returns the selected registration information for the registry element "following" the PrevRegistrationId in whatever order the Service Registry implementation maintains registry element entries.

The list of registered service element entries can be browsed by calling this method initially with a NULL value for pPrevRegistrationId. Subsequent methods calls would specify pRegistrationId as pPrevRegistrationId while this method returns DMARC_OK. A DMARC_BAD_PARAMETER value will be returned if pPrevRegistrationId is not NULL and a registry entry with that RegistrationId does not exist. A DMARC_NOT_FOUND value will be returned if all parameters are valid and no registry entry is found that meets the specified criteria.

This method supports filtering the list of registered service element entries based upon a combination of Service Object Id, Service Object Type Id, Character Set Encoding Id and bPublished through the specification of non-NULL values for any of the corresponding filter input parameters. Providing specific values for Service Object Id, Service Object Type Id, Character Set Encoding Id and a NULL value for pPrevRegistrationId is guaranteed to return at most one registry element.

If an output parameter reference is NULL, the value for that information will not be returned.

Return Values

Name

Description

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NOT_FOUND

Requested item not found.

DMARC_OK

(S_OK) Success.

IdmaServiceRegistry::GetRegistryElement

This method must be supported in every implementation of this interface.

Syntax
DmaRC IdmaServiceRegistry::GetRegistryElement (
pDmaId pRegistrationId,
pDmaId pServiceObjectId,
pDmaId pServiceObjectTypeId,
ppDmaString ppProfile,
pDmaId pModuleTypeId,
ppDmaString ppModuleLocation,
pDmaInteger32 plCharSetEncodingId,
pDmaBoolean pbPublished)

Parameters

Name

Mode

Description

pRegistrationId

input

The registration Id of a previously registered registry element. This parameter uniquely identifies the registry element accessed by this method.

pServiceObjectId

output

(optional) The Id of a Service Object that is registered with the System.

pServiceObjectTypeId

output

(optional) Returns the type the service object.

ppProfile

output

(optional) Returns a copy of the profile string that is supplied to the Service Object when it is activated.

pModuleTypeId

output

(optional) A DmaId GUID value that specifies of the type of Module is used to implement the Service Object, e.g. WIN32 DLL.

ppModuleLocation

output

(optional) Returns a string that identifies the location of the Module.

plCharSetEncodingId

output

(optional) Returns the character set encoding that is supported by this service object.

pbPublished

output

(optional) Returns a boolean indicating whether this registration element has been published.

Description

Returns the selected registration information for the identified registry element. If an output parameter reference is NULL, the value for that information will not be returned.

Return Values

Name

Description

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NOT_FOUND

Requested item not found.

DMARC_OK

(S_OK) Success.

IdmaServiceRegistry::PublishRegistryElement

Support for this method is optional.

Syntax
DmaRC IdmaServiceRegistry::PublishRegistryElement (
pDmaId pRegistrationId)

Parameters

Name

Mode

Description

pRegistrationId

input

The registration Id of a previously registered registry element. This parameter uniquely identifies the registry element that will be published by this method.

Description

This method publishes a Service Registry element. Upon successful completion of this method, the registry element’s bPublished attribute will have a value of DMA_TRUE.

A Service Object that is initially registered is known only at the point of presence where it is registered. Publishing the registration entry makes the service element known to all points-of-presence that can reach the point-of-service having the service object.

Return Values

Name

Description

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NOT_FOUND

Requested item not found.

DMARC_NOT_SUPPORTED

This method is not supported in the context of this session or object.

DMARC_OK

(S_OK) Success.

IdmaServiceRegistry::RegisterServiceElement

Support for this method is optional.

Syntax
DmaRC IdmaServiceRegistry::RegisterServiceElement (
pDmaId pServiceObjectId,
pDmaId pServiceObjectTypeId,
pDmaString pProfile,
pDmaId pModuleTypeId,
pDmaString pModuleLocation,
DmaInteger32 lCharSetEncodingId,
pDmaId pRegistrationId)

Parameters

Name

Mode

Description

pServiceObjectId

input

The DmaId to use as the Service Object’s instance Id. If NULL, a DmaId GUID value will be assigned by the RegisterServiceElement operation

pServiceObjectTypeId

input

The Service Object's type, e.g. a System, DocSpace, ScopeFactory, TextOrdering, or other registry-supported type.

pProfile

input

(optional) The profile string that will be supplied to the Service Object when it is activated via its GetServiceObject function.

pModuleTypeId

input

Specifies the type of Module used to implement the Service Object, e.g. a Win32 DLL.

pModuleLocation

input

The location of the Module containing the service-object implementation program code.

lCharSetEncodingId

input

The character set encoding that is supported by this implementation of the service object.

pRegistrationId

output

Returns the registration that uniquely identifies the registry element registered by this method.

Description

This method adds an unpublished registry element to the Service Registry database.

The combination of ServiceObjectId, ServiceObjectTypeId and CharSetEncodingId must be unique across all registered elements. An attempt to register an element that would violate this uniqueness invariant condition will result in a DMARC_NOT_UNIQUE return code.

DMA 1.0 defines well-known ServiceType values dmaServiceType_System, dmaServiceType_DocSpace, dmaServiceType_ScopeFactory, dmaServiceType_OIIDParser, dmaServiceType_TextOrdering for the Service Objects of the named types, respectively.

The ServiceObjectId is an instance Id associated with the service object and is defined as the SystemId for System service objects, the DocSpaceId for DocSpace service objects, or the TextOrderingId (Collation Id) for TextOrdering service objects. For an OIIDParser, the ServiceObjectId is the unique dmaService_ OIIDParser value. Any module registered as a dmaServiceType_OIIDParser service must support the IdmaOIID interface for OIID strings in the character set encoding for which it is registered.

Return Values

Name

Description

DMARC_ACCESS_DENIED

(E_ACCESSDENIED) The requester has insufficient access rights to perform the requested operation.

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NO_MEMORY

(E_OUTOFMEMORY) Insufficient memory to complete the operation.

DMARC_NOT_SUPPORTED

This method is not supported in the context of this session or object.

DMARC_NOT_UNIQUE

A uniqueness requirement has been violated.

DMARC_OK

(S_OK) Success.

IdmaServiceRegistry::RemoveRegistryElement

Support for this method is optional.

Syntax
DmaRC IdmaServiceRegistry::RemoveRegistryElement (
pDmaId pRegistrationId)

Parameters

Name

Mode

Description

pRegistrationId

input

The registration Id of a previously registered registry element. This parameter uniquely identifies the registry element which will be removed by this method.

Description

This method removes a registry element from the Service Registry database. If the registry element was published, it is unpublished prior to removal. The Registration Id is guaranteed not to be reused by the Service Registry.

Return Values

Name

Description

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NOT_FOUND

Requested item not found.

DMARC_NOT_SUPPORTED

This method is not supported in the context of this session or object.

DMARC_OK

(S_OK) Success.

IdmaServiceRegistry::UnpublishRegistryElement

Support for this method is optional.

Syntax
DmaRC IdmaServiceRegistry::UnpublishRegistryElement (
pDmaId pRegistrationID)

Parameters

Name

Mode

Description

pRegistrationID

input

The registration Id of a previously registered registry element. This parameter uniquely identifies the registry element which will be removed by this method.

Description

This method unpublishes a Service Registry element. Upon successful completion of this method, the registry element’s bPublished attribute will have a value of DMA_FALSE.

Return Values

Name

Description

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_NOT_FOUND

Requested item not found.

DMARC_NOT_PUBLISHED

The service registry entry is not currently published.

DMARC_NOT_SUPPORTED

This method is not supported in the context of this session or object.

DMARC_OK

(S_OK) Success.