Fixed up File object to support better parameter options.
This commit is contained in:
parent
7341d26852
commit
0ffc410a6a
8
File.cpp
8
File.cpp
@ -9,11 +9,11 @@
|
|||||||
|
|
||||||
namespace coreutils {
|
namespace coreutils {
|
||||||
|
|
||||||
File::File(std::string fileName, int mode, int authority) {
|
// File::File(std::string fileName, int mode, int authority) {
|
||||||
open(fileName, mode, authority);
|
// open(fileName, mode, authority);
|
||||||
}
|
// }
|
||||||
|
|
||||||
File::File(coreutils::ZString &fileName, int mode, int authority) {
|
File::File(coreutils::ZString fileName, int mode, int authority) {
|
||||||
open(fileName.str(), mode, authority);
|
open(fileName.str(), mode, authority);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
4
File.h
4
File.h
@ -16,8 +16,8 @@ namespace coreutils {
|
|||||||
class File {
|
class File {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
File(std::string fileName, int mode, int authority);
|
// File(std::string fileName, int mode, int authority);
|
||||||
File(ZString &fileName, int mode = O_RDONLY, int authority = 0664);
|
File(ZString fileName, int mode = O_RDONLY, int authority = 0664);
|
||||||
~File();
|
~File();
|
||||||
void setBufferSize(size_t size);
|
void setBufferSize(size_t size);
|
||||||
int read();
|
int read();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user