Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
f0b31547
Kaydet (Commit)
f0b31547
authored
Ara 14, 2000
tarafından
Fred Drake
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Update information on the locking() function, added the needed constants.
(Thanks for the info, Tim!)
üst
f7f88b11
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
2 deletions
+26
-2
libmsvcrt.tex
Doc/lib/libmsvcrt.tex
+26
-2
No files found.
Doc/lib/libmsvcrt.tex
Dosyayı görüntüle @
f0b31547
...
...
@@ -20,10 +20,34 @@ API documentation.
\subsection
{
File Operations
\label
{
msvcrt-files
}}
\begin{funcdesc}
{
locking
}{
fd, mode, nbytes
}
Lock part of a file based on a file descriptor from the C runtime.
Raises
\exception
{
IOError
}
on failure.
Lock part of a file based on file descriptor
\var
{
fd
}
from the C
runtime. Raises
\exception
{
IOError
}
on failure. The locked region
of the file extends from the current file position for
\var
{
nbytes
}
bytes, and may continue beyond the end of the file.
\var
{
mode
}
must
be one of the
\constant
{
LK
_
\var
{
*
}}
constants listed below.
Multiple regions in a file may be locked at the same time, but may
not overlap. Adjacent regions are not merged; they must be unlocked
individually.
\end{funcdesc}
\begin{datadesc}
{
LK
_
LOCK
}
\dataline
{
LK
_
RLCK
}
Locks the specified bytes. If the bytes cannot be locked, the
program immediately tries again after 1 second. If, after 10
attempts, the bytes cannot be locked,
\exception
{
IOError
}
is
raised.
\end{datadesc}
\begin{datadesc}
{
LK
_
NBLCK
}
\dataline
{
LK
_
NBRLCK
}
Locks the specified bytes. If the bytes cannot be locked,
\exception
{
IOError
}
is raised.
\end{datadesc}
\begin{datadesc}
{
LK
_
UNLCK
}
Unlocks the specified bytes, which must have been previously locked.
\end{datadesc}
\begin{funcdesc}
{
setmode
}{
fd, flags
}
Set the line-end translation mode for the file descriptor
\var
{
fd
}
.
To set it to text mode,
\var
{
flags
}
should be
\constant
{
os.O
_
TEXT
}
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment