The SAS Open Metadata
Interface provides the GetTypes method to get all of the metadata
types defined in a namespace. The following is an example of a GetTypes
request that gets the metadata types that are defined in the SAS namespace
of the SAS Metadata Model. The request is formatted for the INMETADATA
parameter of the DoRequest method:
<GetTypes>
<Types/>
<NS>SAS</NS>
<Flags/>
<Options/>
</GetTypes>
The <NS>, <FLAGS>,
and <OPTIONS> elements are input parameters. This example does
not specify any flags or options. The <TYPES> element is an
output parameter. The <TYPES> element lists the metadata types
in the specified namespace.
To get all of the metadata
types in the SAS Metadata Model, issue the GetTypes method on both
the SAS and REPOS namespaces.
The following is an
example of the method output. Only the first line of the output is
shown:
<Type Id="AbstractExtension" Desc="Abstract Extension"
HasSubtypes="1"/>
In the output, note
the following:
-
Id is a metadata type name.
-
Desc is a system-supplied description
of the metadata type.
-
HasSubtypes is a Boolean indicator
that identifies whether a metadata type has subtypes. A value of 1
indicates that the type has subtypes. A value of 0 indicates that
it does not.