<a href="[https://ibb.co/r4RCDff](https://i.ibb.co/wMF95rr/ctype.png)"><img src="https://i.ibb.co/wMF95rr/ctype.png" alt="flowa" border="0" width="145"></a>
# [ctype - Interact with cython, python, ctypes, and use other c/c++ tools](https://pypi.org/project/ctype/)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/notepads-py/ctype/blob/main/LICENSE)
[![Python Versions](https://img.shields.io/badge/python-3.7%20|%203.8%20|%203.9%20|%203.10%20|%203.11%20|%203.12%20-blue)](https://www.python.org/downloads/)
```
ctype: (V7.4.2)
Interact with cython, python, ctypes, and use other c/c++ tools
```
## Installing
```shell
# Linux/macOS
python3 pip install -U ctype
# Windows
py -3 -m pip install -U ctype
```
```python
import ctype
```
```python
# Base Classes
ctype.CType # Decorator Class
ctype.Structure
```
```python
ctype.uint
ctype.uint4
ctype.uint8
ctype.uint16
ctype.uint32
ctype.uint64
```
```python
ctype.ints
ctype.int4
ctype.int8
ctype.int16
ctype.int32
ctype.int64
```
```python
ctype.floats
ctype.float4
ctype.float8
ctype.float16
ctype.float32
ctype.float64
```
```python
ctype.double
ctype.double4
ctype.double8
ctype.double16
ctype.double32
ctype.double64
```
```python
ctype.long
ctype.longlong
ctype.short
```
```python
ctype.ulong
ctype.ulonglong
ctype.ushort
```
```python
ctype.char
ctype.wchar
ctype.chararray
ctype.wchararray
```
```python
ctype.struct
ctype.union
ctype.enum
```
```python
ctype.typedef
ctype.volatile
```
```python
ctype.boolean
```
```python
ctype.void
```
```python
ctype.ptr
```
```python
ctype.cout, ctype.stdout, ctype.printf
ctype.cin, ctype.stdin
ctype.cerr, ctype.stderr
ctype.clog, ctype.log
ctype.cexit, ctype.exit
ctype.cabort, ctype.abort
ctype.endl
```
```python
# ctype.Exceptions
ctype.ctype_err <cerr_type> <cobject> <cmessage>
ctype.CTypeException
ctype.CTypeRuntime
ctype.CTypeIndex
ctype.CTypeName
ctype.CTypeImport
ctype.CTypeAttr
ctype.CTypeKey
ctype.CTypeValue
ctype.CTypeIndent
ctype.CTypeError
ctype.CTypeKeyboard
ctype.CTypeUnfinished
```
# Use ctypes in ctype
```python
# Comes inside of the ctype lib
from ctype import cdll, c_int, c_char_p, c_void_p, c_double, c_bool, ...
```
```python
# View all defined CType's
ctype.types
# CType
ctype.ctype
ctype.CType
# Structure
ctype.Structure
ctype.Struct
ctype.structure
```
```python
ctype.require('a_module', 'numpy', 'some_other_module')
```
# Links
- [Github](https://github.com/notepads-ai)
- [Project](https://pypi.org/project/ctype/)
Raw data
{
"_id": null,
"home_page": "https://github.com/notepads/ctype",
"name": "ctype",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": "",
"keywords": "ctype,ctypes,cython,cpython,cpy,python,c,c++",
"author": "notepads",
"author_email": "notepads.py@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/3e/58/9d02ace52884875dc403cb4656a7d29a2fe4814f7705534022f5bfd88ab7/ctype-7.4.2.tar.gz",
"platform": null,
"description": "<a href=\"[https://ibb.co/r4RCDff](https://i.ibb.co/wMF95rr/ctype.png)\"><img src=\"https://i.ibb.co/wMF95rr/ctype.png\" alt=\"flowa\" border=\"0\" width=\"145\"></a>\n\n# [ctype - Interact with cython, python, ctypes, and use other c/c++ tools](https://pypi.org/project/ctype/)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/notepads-py/ctype/blob/main/LICENSE)\n[![Python Versions](https://img.shields.io/badge/python-3.7%20|%203.8%20|%203.9%20|%203.10%20|%203.11%20|%203.12%20-blue)](https://www.python.org/downloads/)\n\n```\nctype: (V7.4.2)\n\nInteract with cython, python, ctypes, and use other c/c++ tools\n```\n\n## Installing\n```shell\n# Linux/macOS\npython3 pip install -U ctype\n\n# Windows\npy -3 -m pip install -U ctype\n```\n\n```python\nimport ctype\n```\n```python\n# Base Classes\nctype.CType # Decorator Class\nctype.Structure\n```\n```python\nctype.uint\nctype.uint4\nctype.uint8\nctype.uint16\nctype.uint32\nctype.uint64\n```\n```python\nctype.ints\nctype.int4\nctype.int8\nctype.int16\nctype.int32\nctype.int64\n```\n```python\nctype.floats\nctype.float4\nctype.float8\nctype.float16\nctype.float32\nctype.float64\n```\n```python\nctype.double\nctype.double4\nctype.double8\nctype.double16\nctype.double32\nctype.double64\n```\n```python\nctype.long\nctype.longlong\nctype.short\n```\n```python\nctype.ulong\nctype.ulonglong\nctype.ushort\n```\n```python\nctype.char\nctype.wchar\nctype.chararray\nctype.wchararray\n```\n```python\nctype.struct\nctype.union\nctype.enum\n```\n```python\nctype.typedef\nctype.volatile\n```\n```python\nctype.boolean\n```\n```python\nctype.void\n```\n```python\nctype.ptr\n```\n```python\nctype.cout, ctype.stdout, ctype.printf\nctype.cin, ctype.stdin\nctype.cerr, ctype.stderr\nctype.clog, ctype.log\nctype.cexit, ctype.exit\nctype.cabort, ctype.abort\nctype.endl\n```\n```python\n# ctype.Exceptions\nctype.ctype_err <cerr_type> <cobject> <cmessage>\n\nctype.CTypeException\nctype.CTypeRuntime\nctype.CTypeIndex\nctype.CTypeName\nctype.CTypeImport\nctype.CTypeAttr\nctype.CTypeKey\nctype.CTypeValue\nctype.CTypeIndent\nctype.CTypeError\nctype.CTypeKeyboard\nctype.CTypeUnfinished\n```\n# Use ctypes in ctype\n```python\n# Comes inside of the ctype lib\n\nfrom ctype import cdll, c_int, c_char_p, c_void_p, c_double, c_bool, ...\n```\n```python\n# View all defined CType's\nctype.types\n\n# CType\nctype.ctype\nctype.CType\n\n# Structure\nctype.Structure\nctype.Struct\nctype.structure\n```\n```python\nctype.require('a_module', 'numpy', 'some_other_module')\n```\n\n# Links\n- [Github](https://github.com/notepads-ai)\n- [Project](https://pypi.org/project/ctype/)\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Interact with cython, python, ctypes, and use other c/c++ tools",
"version": "7.4.2",
"project_urls": {
"Homepage": "https://github.com/notepads/ctype"
},
"split_keywords": [
"ctype",
"ctypes",
"cython",
"cpython",
"cpy",
"python",
"c",
"c++"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "05af43f664e4040b57dc7ba041b7273538f434c95b56e83c13766f0f6e0688c2",
"md5": "38a797243201ef84488fc3e802df45a1",
"sha256": "f223242977c2d2e803f8946d0d668333461dc023431f9653a592c64acf79c58a"
},
"downloads": -1,
"filename": "ctype-7.4.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "38a797243201ef84488fc3e802df45a1",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 15391,
"upload_time": "2024-01-08T11:00:36",
"upload_time_iso_8601": "2024-01-08T11:00:36.444449Z",
"url": "https://files.pythonhosted.org/packages/05/af/43f664e4040b57dc7ba041b7273538f434c95b56e83c13766f0f6e0688c2/ctype-7.4.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "3e589d02ace52884875dc403cb4656a7d29a2fe4814f7705534022f5bfd88ab7",
"md5": "653939a2f84fc47ce1f2f8a7d66f4d2a",
"sha256": "9482457b15e1efff6af7b43df5a68d6578910fe3d19938b3b6b7682ab96bf6e7"
},
"downloads": -1,
"filename": "ctype-7.4.2.tar.gz",
"has_sig": false,
"md5_digest": "653939a2f84fc47ce1f2f8a7d66f4d2a",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 8694,
"upload_time": "2024-01-08T11:00:37",
"upload_time_iso_8601": "2024-01-08T11:00:37.644609Z",
"url": "https://files.pythonhosted.org/packages/3e/58/9d02ace52884875dc403cb4656a7d29a2fe4814f7705534022f5bfd88ab7/ctype-7.4.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-01-08 11:00:37",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "notepads",
"github_project": "ctype",
"github_not_found": true,
"lcname": "ctype"
}