1018 When a QFile is opened using this function, close() does not actually |
1018 When a QFile is opened using this function, close() does not actually |
1019 close the file, but only flushes it. |
1019 close the file, but only flushes it. |
1020 |
1020 |
1021 \bold{Warning:} |
1021 \bold{Warning:} |
1022 \list 1 |
1022 \list 1 |
1023 \o If \a fh is \c stdin, \c stdout, or \c stderr, you may not be able |
1023 \o If \a fh does not refer to a regular file, e.g., it is \c stdin, |
1024 to seek(). See QIODevice::isSequential() for more information. |
1024 \c stdout, or \c stderr, you may not be able to seek(). size() |
|
1025 returns \c 0 in those cases. See QIODevice::isSequential() for |
|
1026 more information. |
1025 \o Since this function opens the file without specifying the file name, |
1027 \o Since this function opens the file without specifying the file name, |
1026 you cannot use this QFile with a QFileInfo. |
1028 you cannot use this QFile with a QFileInfo. |
1027 \endlist |
1029 \endlist |
1028 |
1030 |
1029 \note For Windows CE you may not be able to call seek() and resize(). |
1031 \note For Windows CE you may not be able to call resize(). |
1030 Also, size() is set to \c 0. |
|
1031 |
1032 |
1032 \sa close(), {qmake Variable Reference#CONFIG}{qmake Variable Reference} |
1033 \sa close(), {qmake Variable Reference#CONFIG}{qmake Variable Reference} |
1033 |
1034 |
1034 \bold{Note for the Windows Platform} |
1035 \bold{Note for the Windows Platform} |
1035 |
1036 |
1079 */ |
1080 */ |
1080 |
1081 |
1081 /*! |
1082 /*! |
1082 \overload |
1083 \overload |
1083 |
1084 |
1084 Opens the existing file descripter \a fd in the given \a mode. |
1085 Opens the existing file descriptor \a fd in the given \a mode. |
1085 Returns true if successful; otherwise returns false. |
1086 Returns true if successful; otherwise returns false. |
1086 |
1087 |
1087 When a QFile is opened using this function, close() does not |
1088 When a QFile is opened using this function, close() does not |
1088 actually close the file. |
1089 actually close the file. |
1089 |
1090 |
1090 The QFile that is opened using this function is automatically set |
1091 The QFile that is opened using this function is automatically set |
1091 to be in raw mode; this means that the file input/output functions |
1092 to be in raw mode; this means that the file input/output functions |
1092 are slow. If you run into performance issues, you should try to |
1093 are slow. If you run into performance issues, you should try to |
1093 use one of the other open functions. |
1094 use one of the other open functions. |
1094 |
1095 |
1095 \warning If \a fd is 0 (\c stdin), 1 (\c stdout), or 2 (\c |
1096 \warning If \a fd is not a regular file, e.g, it is 0 (\c stdin), |
1096 stderr), you may not be able to seek(). size() is set to \c |
1097 1 (\c stdout), or 2 (\c stderr), you may not be able to seek(). In |
1097 LLONG_MAX (in \c <climits>). |
1098 those cases, size() returns \c 0. See QIODevice::isSequential() |
|
1099 for more information. |
1098 |
1100 |
1099 \warning For Windows CE you may not be able to call seek(), setSize(), |
1101 \warning For Windows CE you may not be able to call seek(), setSize(), |
1100 fileTime(). size() is set to \c 0. |
1102 fileTime(). size() returns \c 0. |
1101 |
1103 |
1102 \warning Since this function opens the file without specifying the file name, |
1104 \warning Since this function opens the file without specifying the file name, |
1103 you cannot use this QFile with a QFileInfo. |
1105 you cannot use this QFile with a QFileInfo. |
1104 |
1106 |
1105 \sa close() |
1107 \sa close() |