Commit graph

198 commits

Author SHA1 Message Date
Mike Bierlee eaac0eb7ce Add initializedOnceBy() to create singleton instances via injection initializer 2021-04-29 01:45:08 +03:00
Mike Bierlee 8f4a64cf4c Move injection initializer to registration scope 2021-04-29 01:45:08 +03:00
Mike Bierlee 89512e0cb0 Move initializer to its own example 2021-04-29 01:45:08 +03:00
Mike Bierlee bb4eaf8676 Clean-up initializer 2021-04-29 01:45:08 +03:00
Mike Bierlee ef00ec4f6f Merge remote-tracking branch 'origin/master' into develop 2021-01-04 02:11:17 +03:00
Mike Bierlee 3f6636109e Update copyrights 2021-01-04 02:04:20 +03:00
heromyth cad0200904 ConcreteType should be a class 2020-03-29 21:34:02 +03:00
Mike Bierlee 7a26dd12e0
Merge pull request #28 from huntlabs/develop
Instance initialization improved
2020-03-18 21:25:02 +03:00
Mike Bierlee 81de14a1ee Update copyrights 2020-03-11 23:38:54 +03:00
heromyth 0c8c1434f7 Check if a Type is registered 2020-03-11 09:55:15 +08:00
heromyth 3b11c4aec4 Add a constuction handler 2020-02-26 16:14:12 +08:00
heromyth 55726e84db All the unittests passed 2020-02-11 10:19:08 +08:00
heromyth 15d8c7e754 Restore callPostConstructors 2020-02-10 15:34:00 +08:00
heromyth b9d4bd1b83 Register with an initializer. 2020-02-09 23:46:06 +08:00
heromyth 4ebeeb9c9f isFunction may not work 2020-02-09 23:43:11 +08:00
Mike Bierlee 343dd65fdf Update copyrights 2019-07-14 12:40:16 +03:00
Mike Bierlee dc48c87948 Prevent registration, resolving and constructor injection selection of structs
Fixes #25
2018-06-11 18:45:27 +03:00
Carlin St Pierre d52d2d963e Support types that have recursive template arguments with createImportsString 2018-04-14 14:00:30 +10:00
Mike Bierlee 4410206ec4 Update copyrigths
And convert tabs to spaces
2018-01-01 15:56:47 +01:00
Mike Bierlee 93d4d3c20f Recursively import types everywhere
#20
2017-08-13 18:21:03 +02:00
Mike Bierlee 91fcefa7ed Recursively import template type's modules
In case when the template type itself is a template type. Fixes #20
2017-08-13 18:13:19 +02:00
Mike Bierlee 4c25b91c63 Import modules of argument types of registration type's template before calling post-constructor 2017-08-13 17:49:40 +02:00
Mike Bierlee e90306ef57 Update copyrights 2017-02-13 20:20:35 +01:00
Mike Bierlee cc0ea0d9e4 Add backwards compatiblity for isFunction 2016-12-26 18:31:39 +01:00
Mike Bierlee 925c3f4119 Fix check on whether a member was a function
Checks on some kinds of members, such as constants, would trip up with the isCallable trait.
2016-12-26 18:17:51 +01:00
Mike Bierlee 10d24eb9fb Remove workaround 2016-12-26 18:17:51 +01:00
Mike Bierlee 898dfd8943 Remove deprecated getInstance() 2016-12-26 18:17:51 +01:00
Mike Bierlee 4ac095c25b Revert minimal D compatibility to 2.068.2
Now that GDC has been officially upgraded to 2.068.2 we can drop baseline support to that version.
2016-12-26 18:17:51 +01:00
Mike Bierlee 0d5180c98f Also fix memory corruption for GDC 2016-12-18 01:21:56 +01:00
Mike Bierlee 708ec67070 Prevent memory corruption in DMD 2.066.1
As a consequence registations will NOT be cleared during deconstruction of the container in that version
2016-12-18 01:16:00 +01:00
Mike Bierlee 3d9a449766 Fix aliases tripping up UDA discovery 2016-12-17 23:58:37 +01:00
Mike Bierlee b6dea95c0d Add pre-destruction 2016-12-17 23:09:56 +01:00
Mike Bierlee fbef764b48 Add post construction 2016-12-17 21:14:16 +01:00
Mike Bierlee 7ba8e545f6 Move context registration related method out of container
Should be still usable as before because of UFCS
2016-12-14 22:04:13 +01:00
Mike Bierlee 68c8d6b6a6 Fix documentation 2016-12-14 21:12:52 +01:00
Mike Bierlee 8fe5b8da9b Adjust package documentation according extended use of derived work 2016-12-13 23:23:05 +01:00
Mike Bierlee 5ed3a6ae29 Add Phobos 2.066.1 forwards-compatibility for GDC 2016-12-13 22:00:34 +01:00
Mike Bierlee 2bbbbac416 Add forwards compatibility for older Phobos distributions 2016-12-11 02:44:35 +01:00
Mike Bierlee 86fb525066 Add mandatory injection of values 2016-12-11 01:31:09 +01:00
Mike Bierlee 52dcecef9a Add optional value injection when values cannot be injected by injectors 2016-12-11 01:15:30 +01:00
Mike Bierlee 9eb3a89695 Make it clear when a value injector is missing 2016-12-11 00:53:21 +01:00
Mike Bierlee d3ed3e91b9 Add value injector 2016-12-09 02:15:59 +01:00
Mike Bierlee c75b025a68 Fix else case not being properly excluded from compiled code 2016-12-09 00:48:32 +01:00
Mike Bierlee ea41a04657 Determine qualifier earlier in process 2016-12-06 23:41:08 +01:00
Mike Bierlee ee35b07a87 Fix incorrect documentation 2016-12-06 23:23:55 +01:00
Mike Bierlee 6d1907bb3d Fix missing import for release build 2016-12-06 23:17:38 +01:00
Mike Bierlee 2a52fc9af4 Fix nullpointer exception when debugging with poodinisVerbose 2016-12-06 23:14:19 +01:00
Mike Bierlee f1bd2260d1 Split autowire code up into multiple functions 2016-12-06 23:00:30 +01:00
Mike Bierlee e1f0cca5c5 Fix injection of dependencies from foreign modules
Fixes issue #12
2016-09-05 19:37:53 +02:00
Mike Bierlee c60fc496d9 Fix release build 2016-09-03 18:51:01 +02:00