Skip to main content

DDD base framework for python

Project description

DDD Base Framework

Build Status Pypi Status Coveralls Status

Installation

From source code:

python setup.py install

From pypi:

pip install ddd-base

Usage

from ddd_base.value_object import ValueObject


class TheValueObject(ValueObject):

    def __init__(self, name):
        super(TheValueObject, self).__init__()
        self.name = name

    def __eq__(self, other):
        if not isinstance(other, ValueObject):
            return NotImplemented

        return self.name == other.name


def test_value_object_compare():
    a_value_object = TheValueObject("name")
    b_value_object = TheValueObject("name")

    assert a_value_object.same_as(b_value_object)

License

This software is licensed under the MIT license

See License file

Changelog

0.0.5

  • Add use example

0.0.4

  • Friendly readme

0.0.3

  • Smart setup

0.0.2

  • Minimise description

0.0.1

  • Initial public release

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for ddd-base, version 0.0.5
Filename, size File type Python version Upload date Hashes
Filename, size ddd-base-0.0.5.tar.gz (2.5 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page