Logo Search packages:      
Sourcecode: pwlib version File versions

BOOL PWAVFile::Open ( const PFilePath name,
OpenMode  mode = ReadWrite,
int  opts = ModeDefault 
) [virtual]

Open the specified WAV file name in the specified mode and with the specified options. If the file object already has an open file then it is closed. This reads (and validates) the header for existing files. For new files, it creates a new file (and header) using the type of WAV file specified in the class constructor.

Note: if mode# is StandardInput, StandardOutput or StandardError, then the name# parameter is ignored.

Returns:
TRUE if the file was successfully opened.

Reimplemented from PFile.

Definition at line 350 of file pwavfile.cxx.

References Close(), PChannel::IsOpen(), Open(), and PFile::SetFilePath().

{
  if (IsOpen())
    Close();
  SetFilePath(name);
  return Open(mode, opts);
}


Generated by  Doxygen 1.6.0   Back to index