Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
None.
Inherited By:
TUnixPathNameParser
Purpose:
This abstract class provides protocol for parsing file system pathnames.
Instantiation:
None.
Deriving Classes:
Derived classes should implement parsers for specific host file system pathnames. All public member functions should be overridden, except for the static function GetDefaultParser and (probably) the streaming operators (because these classes generally have no data members).
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
Member Function: TPathNameParser::SetPathComponentArray
static void SetPathComponentArray (TPathName & pathName, TPathComponentArray * newStorage)
Interface Category:
API.
Purpose:
Installs the components of a path into a TPathName.
Calling Context:
Call this function directly.
Parameters:
- TPathName & pathName -The pathname into which to install the components.
- TPathComponentArray * newStorage -A pointer to a component array.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
The caller is responsible for freeing newStorage.
Member Function: TPathNameParser::GetPathComponentArray
static TPathComponentArray * GetPathComponentArray (const TPathName & pathName)
Interface Category:
API.
Purpose:
Returns the components of a path in an array
Calling Context:
Call this function directly.
Parameters:
- const TPathName & pathName -The pathname whose components are desired.
Return Value:
A TPathComponentArray containing the components of the specified pathname.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
The caller must not delete the returned TPathComponentArray.
Member Function: TPathNameParser::GetDefaultParser
static const TPathNameParser & GetDefaultParser ()
Interface Category:
API.
Purpose:
Gets an instance of a derived class of this class that will parse file pathnames for the underlying host file system.
Calling Context:
Call this function directly.
Parameters:
Return Value:
A parser for the underlying host file system.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TPathNameParser & operator =(const TPathNameParser & copyMe)
Interface Category:
API.
Purpose:
Assignment operator.
Calling Context:
Called when an object is assigned to another compatible object.
Parameters:
Return Value:
A non-const reference to the left-hand side object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
- TPathNameParser ()
- TPathNameParser (const TPathNameParser & copyMe)
Interface Category:
API.
Purpose:
- Default constructor.
- Copy constructor.
Calling Context:
- Called by the stream-in operators and by derived classes.
- Called to copy an object.
Parameters:
- Takes no parameters.
- const TPathNameParser & copyMe -The pathname parser to copy from.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual TStream & operator <<= (TStream & fromWhere)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data.
Parameters:
- TStream & fromwhere -The stream the object streams itself in from.
Return Value:
Returns a reference to the stream the object streams itself in from.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual TStream & operator >>=(TStream & toWhere) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data.
Parameters:
- TStream & toWhere -The stream the object streams itself out to.
Return Value:
Returns a reference to the stream the object streams itself out to.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TPathNameParser::PathNameToHostSpecific
virtual void PathNameToHostSpecific (const TPathName & anArray, THostSpecificPathName & path) const
Interface Category:
API.
Purpose:
Converts from a TPathName object to a host-specific pathname string (for example, /usr/include/sys/mode.h).
Calling Context:
Call this function directly.
Parameters:
- const TPathName & anArray -The TPathName to be converted a host-specific syntax.
- THostSpecificPathName & path -The object to receive the conversion result.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TPathNameParser::HostSpecificToPathName
virtual void HostSpecificToPathName (const THostSpecificPathName & path, TPathName & anArray) const
Interface Category:
API.
Purpose:
Converts from a host-specific path (for example, /usr/include/sys/mode.h) to a TPathName object.
Calling Context:
Call this function directly.
Parameters:
- const THostSpecificPathName & path -The host-specific pathname to be converted to a TPathName.
- TPathName & anArray -The TPathName object to receive the conversion result.
Return Value:
None.
Exceptions:
Throws TFileSystemEntityNotAvailable for ill-formed paths (but not for well-formed paths specifying entities that do not exist; that is, the path must be well-formed but need not represent an existing on-disk entity).
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TPathNameParser ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.