| | |
- FormatError(...)
- FormatError([integer]) -> string
Convert a win32 error code into a string. If the error code is not
given, the return value of a call to GetLastError() is used.
- Lock = allocate_lock(...)
- allocate_lock() -> lock object
(allocate() is an obsolete synonym)
Create a new lock object. See LockType.__doc__ for information about locks.
- addressof(...)
- addressof(C instance) -> integer
Return the address of the C instance internal buffer
- alignment(...)
- alignment(C type) -> integer
alignment(C instance) -> integer
Return the alignment requirements of a C instance
- byref(...)
- byref(C instance) -> byref-object
Return a pointer lookalike to a C instance, only usable
as function argument
- resize(...)
- Resize the memory buffer of a ctypes instance
- set_conversion_mode(...)
- set_conversion_mode(encoding, errors) -> (previous-encoding, previous-errors)
Set the encoding and error handling ctypes uses when converting
between unicode and strings. Returns the previous values.
- sizeof(...)
- sizeof(C type) -> integer
sizeof(C instance) -> integer
Return the size in bytes of a C instance
- stack_size(...)
- stack_size([size]) -> size
Return the thread stack size used when creating new threads. The
optional size argument specifies the stack size (in bytes) to be used
for subsequently created threads, and must be 0 (use platform or
configured default) or a positive integer value of at least 32,768 (32k).
If changing the thread stack size is unsupported, a ThreadError
exception is raised. If the specified size is invalid, a ValueError
exception is raised, and the stack size is unmodified. 32k bytes
currently the minimum supported stack size value to guarantee
sufficient stack space for the interpreter itself.
Note that some platforms may have particular restrictions on values for
the stack size, such as requiring a minimum stack size larger than 32kB or
requiring allocation in multiples of the system memory page size
- platform documentation should be referred to for more information
(4kB pages are common; using multiples of 4096 for the stack size is
the suggested approach in the absence of more specific information).
|