Giter Site home page Giter Site logo

ebclark2 / yadi Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 462 KB

Runtime Dependency Injection via YAML

License: MIT License

CMake 3.45% C++ 92.98% Shell 0.84% Python 2.73%
factory yadi conan yaml ptr std dependency-injection dependency-parser configuration config

yadi's People

Contributors

ebclark2 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

yadi's Issues

Type erasure for initializers

There shall only be one large factory which will allow types to be created as the implementation type instead of just as the factory interface type.

Initializers shall either always create a raw pointer, or perhaps use placement new. The results type will be converted to a the desired output type.

Caching initializer

Will require ptr type to be shared_ptr. Will store weak ptr to created types mapped by type/yaml pair. If newly requested type/yaml pair have valid weak ptr then try to lock and return existing instance, otherwise create new.

Initializer overloading

All registering multiple initializers to a single name.

For Map initializers pick the correct initializer by matching the keys.
Possible for sequence/single arg initializers by argument count.

This will replace using a bunch of optionals with error checking/priority in a constructor.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.