rsv


Namersv JSON
Version 1.5.0 PyPI version JSON
download
home_pagehttps://github.com/romanin-rf/rsv
SummaryA module for reading and writing an RSV document file.
upload_time2024-11-12 00:43:40
maintainerNone
docs_urlNone
authorRomanin
requires_python>=3.8
licenseMIT
keywords rsv csv io file format dump load read write
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # rsv.py
# Description
A module for reading and writing an [RSV](https://github.com/Stenway/RSV-Challenge) document file.

# Using
```python
import rsv

sample_data = [
    ["Name", "Description", None],
    [],
    [None, ":)"]
]

with open("document.rsv", "wb") as file:
    rsv.dump(sample_data, file)

# The first load method.
# It is the most efficient and suitable for working even with large arrays.
# Since it loads data from the file sequentially when loading.
with open("document.rsv", "rb") as file:
    data = rsv.load(file)

# The second load method.
# It is suitable for working with small arrays.
# Since it loads the entire file into memory at once and only then parses it.
with open("document.rsv", "rb") as file:
    data = rsv.load_split(file)

# The third load method.
# This is the most efficient possible method suitable for working with any arrays of any size.
# Loads the file line by line, the use of `for` is required.
with open("document.rsv", "rb") as file:
    lines = []
    for line in file.load_generator():
        # And here you can do whatever you want...
        lines.append(line)
```

## Notes
It is also worth noting that no one forbids you to use the `Encoder`/`Decoder` directly:
```python
import rsv

rsv_encoder = rsv.Encoder(open("document.rsv", "wb"))
rsv_decoder = rsv.Decoder(open("document.rsv", "rb"))
```
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/romanin-rf/rsv",
    "name": "rsv",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "rsv, csv, io, file, format, dump, load, read, write",
    "author": "Romanin",
    "author_email": "semina054@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/f1/7a/1424d0df916625be0d08503b87c57d0454400994dd680d8e4d949298ab80/rsv-1.5.0.tar.gz",
    "platform": null,
    "description": "# rsv.py\n# Description\nA module for reading and writing an [RSV](https://github.com/Stenway/RSV-Challenge) document file.\n\n# Using\n```python\nimport rsv\n\nsample_data = [\n    [\"Name\", \"Description\", None],\n    [],\n    [None, \":)\"]\n]\n\nwith open(\"document.rsv\", \"wb\") as file:\n    rsv.dump(sample_data, file)\n\n# The first load method.\n# It is the most efficient and suitable for working even with large arrays.\n# Since it loads data from the file sequentially when loading.\nwith open(\"document.rsv\", \"rb\") as file:\n    data = rsv.load(file)\n\n# The second load method.\n# It is suitable for working with small arrays.\n# Since it loads the entire file into memory at once and only then parses it.\nwith open(\"document.rsv\", \"rb\") as file:\n    data = rsv.load_split(file)\n\n# The third load method.\n# This is the most efficient possible method suitable for working with any arrays of any size.\n# Loads the file line by line, the use of `for` is required.\nwith open(\"document.rsv\", \"rb\") as file:\n    lines = []\n    for line in file.load_generator():\n        # And here you can do whatever you want...\n        lines.append(line)\n```\n\n## Notes\nIt is also worth noting that no one forbids you to use the `Encoder`/`Decoder` directly:\n```python\nimport rsv\n\nrsv_encoder = rsv.Encoder(open(\"document.rsv\", \"wb\"))\nrsv_decoder = rsv.Decoder(open(\"document.rsv\", \"rb\"))\n```",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A module for reading and writing an RSV document file.",
    "version": "1.5.0",
    "project_urls": {
        "Homepage": "https://github.com/romanin-rf/rsv",
        "Repository": "https://github.com/romanin-rf/rsv"
    },
    "split_keywords": [
        "rsv",
        " csv",
        " io",
        " file",
        " format",
        " dump",
        " load",
        " read",
        " write"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d2f470cf7d892d41beba6f00f51eb14317aa6cd72cabb9614d1ba107cf3b8f37",
                "md5": "f9d405c9cba8d4ddd0b6a1b385a08f36",
                "sha256": "e62483dfe2d63d86aaa4920e50f37ff8c7614a76cf309b964a734bfb1924a90d"
            },
            "downloads": -1,
            "filename": "rsv-1.5.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f9d405c9cba8d4ddd0b6a1b385a08f36",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 4264,
            "upload_time": "2024-11-12T00:43:39",
            "upload_time_iso_8601": "2024-11-12T00:43:39.159433Z",
            "url": "https://files.pythonhosted.org/packages/d2/f4/70cf7d892d41beba6f00f51eb14317aa6cd72cabb9614d1ba107cf3b8f37/rsv-1.5.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f17a1424d0df916625be0d08503b87c57d0454400994dd680d8e4d949298ab80",
                "md5": "45512df14bd210030341ca31b14fb732",
                "sha256": "e536ac0eb349419917a85f75db46e20362b76d41f9e1308f01c5ceb73d7e44ca"
            },
            "downloads": -1,
            "filename": "rsv-1.5.0.tar.gz",
            "has_sig": false,
            "md5_digest": "45512df14bd210030341ca31b14fb732",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 3316,
            "upload_time": "2024-11-12T00:43:40",
            "upload_time_iso_8601": "2024-11-12T00:43:40.721245Z",
            "url": "https://files.pythonhosted.org/packages/f1/7a/1424d0df916625be0d08503b87c57d0454400994dd680d8e4d949298ab80/rsv-1.5.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-12 00:43:40",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "romanin-rf",
    "github_project": "rsv",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "rsv"
}
        
Elapsed time: 1.24090s