NAME

OUX_Pathname - Class for deriving information about a pathname.

SYNOPSIS


#include <OUX/files/pathname.hh>

class OUX_Pathname : public OTC_Pathname
{
  public:
    static os_typespec* get_os_typespec();
    ~OUX_Pathname();
    OUX_Pathname();
    OUX_Pathname(char const* thePath);
    OUX_Pathname(OTC_String const& thePath);
    OUX_Pathname(OTC_Pathname const& thePath);
    OUX_Pathname(OUX_Pathname const& thePath);
    OUX_Pathname& operator=(OTC_String const& thePath);
    OUX_Pathname& operator=(OTC_Pathname const& thePath);
    OUX_Pathname& operator=(OUX_Pathname const& thePath);
    OUX_Pathname absolute() const;
    OUX_Pathname dirname() const;
    OUX_Pathname basename() const;
    OTC_String basename(char const* theSuffix) const;
    OTC_Boolean isAbsolute() const;
    OTC_Boolean isRelative() const;
};

CLASS TYPE

Concrete

DESCRIPTION

This class extends OTC_Pathname to allow information specific to UNIX to be derived from the pathname.

INITIALISATION

OUX_Pathname();
OUX_Pathname(char const* thePath);
OUX_Pathname(OTC_String const& thePath);
OUX_Pathname(OTC_Pathname const& thePath);
OUX_Pathname(OUX_Pathname const& thePath);
OUX_Pathname& operator=(OTC_String const& thePath);
OUX_Pathname& operator=(OTC_Pathname const& thePath);
OUX_Pathname& operator=(OUX_Pathname const& thePath);

QUERY

OUX_Pathname absolute() const;
OUX_Pathname dirname() const;
OUX_Pathname basename() const;
OTC_String basename(char const* theSuffix) const;
Note that if the pathname is empty both isAbsolute() and isRelative() will return OTCLIB_FALSE.
OTC_Boolean isAbsolute() const;
OTC_Boolean isRelative() const;

SEE ALSO

OTC_Pathname, dirname(1), basename(1)

LIBRARY

OUX

AUTHOR(S)

Graham Dumpleton

COPYRIGHT

Copyright 1992 OTC LIMITED
Copyright 1994 DUMPLETON SOFTWARE CONSULTING PTY LIMITED