name: Filename : public String

synopsis:

g++ [flags ...] file ...

#include <Filename.h>

Filename(const Filename& arg);
boolean transformUniquely();
boolean getBase(String& base) const;
boolean getExt(String& ext) const;
boolean makeTemp();
boolean makeTemp(const String& basename);
quick start:
String extension;

// declare the filename
//
Filename filename;
filename.assign(L"image.jpg");

// get the extension of the filename
//
filename.getExt(extension);
description:

The Filename class provides the facility to transform files and rename files. This class also helps in creating temporary file names and to find the required information about the file. This class decomposes a filename into {dirname}{basename}.{extension}. It can transform this name into a number of new forms.

For example, the filename "/home/joe.sof" has a dirname of "/home", a basename of "joe" and an extension of "sof". The transform method is capable of transforming this name into: {new_dirname}{basename}{new_suffix}.{new_extension}. Hence, "/home/joe.sof" can be transformed to "/user/files/joe_0.dat" (new_dirname="/user/files", basename="joe", new_suffix="_0", and new_extension="dat"). A variety of methods are provided to facilitate such transformations.

dependencies:

public constants: error codes:

protected data:

required public methods:

class-specific public methods:

private methods: examples:

notes: