Skip to main content

mixed-methods

License Version Downloads Discord

Documentation Check Test Coverage

Mixed methods.

Installing

Python 3.8 or above is required.

pip

Installing the library with pip is quite simple:

$ pip install mixed-methods

Alternatively, the library can be installed from source:

$ git clone https://github.com/nekitdev/mixed-methods.git
$ cd mixed-methods
$ python -m pip install .

poetry

You can add mixed-methods as a dependency with the following command:

$ poetry add mixed-methods

Or by directly specifying it in the configuration like so:

[tool.poetry.dependencies]
mixed-methods = "^1.1.1"

Alternatively, you can add it directly from the source:

[tool.poetry.dependencies.mixed-methods]
git = "https://github.com/nekitdev/mixed-methods.git"

Examples

# main.py

from mixed_methods import mixed_method

class Type:
    @classmethod
    def type_method(cls) -> int:
        return 13

    def instance_method(self) -> int:
        return 42

    method = mixed_method(type_method, instance_method)
>>> from main import Type
>>> Type.method()
13
>>> instance = Type()
>>> instance.method()
42

Documentation

You can find the documentation here.

Support

If you need support with the library, you can send an email or refer to the official Discord server.

Changelog

You can find the changelog here.

Security Policy

You can find the Security Policy of mixed-methods here.

Contributing

If you are interested in contributing to mixed-methods, make sure to take a look at the Contributing Guide, as well as the Code of Conduct.

License

mixed-methods is licensed under the MIT License terms. See License for details.

Metadata

Release files for mixed-methods 1.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mixed-methods 1.1.1
File Size Uploaded
mixed_methods-1.1.1.tar.gz 4.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for mixed-methods 1.1.1
File Interpreter ABI Platform
mixed_methods-1.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 8.4 kB

Release files / mixed_methods-1.1.1.tar.gz

Download URL mixed_methods-1.1.1.tar.gz
Size 4.1 kB
Tags Source
SHA-256 checksum
How to use checksums
6cbd33e1af250d2496c7d3829b55be005ddb000b6980d0c15c599a5abe12125e
BLAKE2b-256 checksum
How to use checksums
0ddaa75790089190201643882df475640b4f1c17d366b08875a7fd2b550b7035
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.0 CPython/3.10.12 Linux/6.2.0-1019-azure

Release files / mixed_methods-1.1.1-py3-none-any.whl

Download URL mixed_methods-1.1.1-py3-none-any.whl
Size 4.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a0332754ab4fb89812bb1f421b9bc3641e260618c4ae4f085b41cf262563f83b
BLAKE2b-256 checksum
How to use checksums
47d9d3d617f179e1ccb6bdc373a0cd5c9c5e03feaa9afdef3a05e7c62d108c01
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.0 CPython/3.10.12 Linux/6.2.0-1019-azure

Release history Release notifications | RSS feed

This release

1.1.1 This release

2 release files

1.1.0

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page