Platform SDK: Active Directory, ADSI, and Directory Services |
In the example provider component, an example of the directory service path name parser is in parse.cpp. The path name parser is a key component in ADs provider components. It checks the syntactic validity of an ADs path name passed in to this provider. If the syntax is valid, an OBJECTINFO structure is constructed, which contains a componentized version of the ADs pathname for this object.
Note that all that is being done is a syntax check. Rather than special-case every nuance new to path names, all path checking must conform to the grammar rules laid out by the parser.
Called from GetObjectW in getobj.cpp.
<ADsObject> -> <ProviderName> <SampleDSObject>
<SampleDSObject> -> "\\" <identifier> "\" <SampleDSObject>
<Pathname> -> <Component> "\\" <Pathname> OR
<Pathname> -> <Component>
<Identifier> OR
<Identifier> "=" <Identifier>