Releases: DoclerLabs/hexMachina
Releases · DoclerLabs/hexMachina
0.23.0
Behaviour change
Auto-mapping in IDependencyOwner
is now added at the end of the constructor instead of the beginning.
Changelog
Bugs
- Dependencies checking should happen after arguments building [DoclerLabs/hexDSL@3ea74cd]
- fix DependencyOwner on super class usage [DoclerLabs/hexInject@6d007bb]
- use
mapping.toValue
instead ofmapping
for injectInto inMappingChecker
[DoclerLabs/hexInject@603e30f]
Enhancements
- Add
@AfterMapping
metadata inIDependencyOwner
to define custom auto-mapping position - Add recursivity on property, Array construction and new operator in Flow DSL [DoclerLabs/hexDSL@7e06124, DoclerLabs/hexDSL@158a790, DoclerLabs/hexDSL@ad71f7a]
See some examples below:
//Constructor
test = new hex.mock.MockContextHolder( new hex.mock.MockApplicationContext( 'newRecursivity' ) );
//Constructor use for property assignment
r = new hex.mock.MockRectangle();
r.size = new hex.structures.Point( 10, 20 );
//Constructor use in anonymous structures
o2 = { p: new hex.mock.MockContextHolder( new hex.mock.MockApplicationContext( 'propertyRecursivity' ) ) };
//Array declaration in another Array with constructor use
test =
[
new hex.mock.MockClass(),
new hex.mock.AnotherMockClass(),
new hex.mock.MockClassWithIntGeneric( 3 ),
[ new hex.mock.MockClassWithIntGeneric( 4 ), 5 ]
];
- Prepare custom parsers support
0.22.0
Feature
IAnnotationReplace
is no longer necessary for the injector related metadata when usingIInjectorContainer
MacroUtil.append
MacroUtil.flatToExpr
MappingDefinition
typedef can be used to describe injector's mappings.IDependencyOwner
implementation on a class allows it to use metadata for describing needed dependencies.MappingChecker
does some mapping matching and can return missing mappings for any dependency owner.- DSL: injectInto is called after every object has been built, and injectorCreation has been removed.
- Static xml compiler checks mapping intergity passed to dependency owner's constructor
AsyncStatelessService
timeout duration set to 10000 instead of 100
0.21.1
0.21.0
Feature
- add
IAnnotationReplace
- documentation
@Inject(MyConstants.NAME_ONE)
public var injectedOne:String;
Bugs
- fixes an issue with the runtime DSL not being able to access properties correctly [FrancisBourre/hexIoC#80]
0.20.2
API change
Remove hex.di.mapping.MappingDefinition
- rd.addMappedDependencies( [ new MappingDefinition( IService ) ]);
+ rd.addMappedDependencies([ {type: IService } ]);
Changelog
Bugs
- Fix: ConsoleNotifier for haxe nightly build [DoclerLabs/hexUnit#26]
- Fix: TraceLogTarget for haxe nightly build [DoclerLabs/hexLog#12]
- ClassInstanceFactory sets value object type to Dynamic when it fails to figure out what is it [FrancisBourre/hexIoC@b3ef828]
- QuickFix for static compiler: Module Listening Service With 2 Passes [FrancisBourre/hexIoC@2c9e09d]
Enhancements
- map-name added to CommandTrigger for local injections [FrancisBourre/hexIoC@7422215]
0.20.1
0.20.0
API change
CommandExecutor
has now less restriction for themodule
parameter
--- public function new ( injector : IDependencyInjector, ?module : IModule )
+++ public function new ( injector : IDependencyInjector, ?module : IContextModule )
Changelog
Features
- DSL runtime parameters: Static compilers (Xml and Flow) can use runtime parameters to dynamize compiled code during its execution. Parameters are statically typed and double compile-checked, 1st time during DSL declaration, 2nd time during execution call. examples: #225
Enhancements:
Injector.getInstance
can take target type as parameterILogger
is now injected in all commands instead of relying on the owners logger
Bugfix:
- Fixed inconsistencies in the parameterized message output (#224)
MacroCommand
s owner is now propagated to child commands (FrancisBourre/hexMVC#74)
0.19.1
Bugs
- Fix LoggableBuilder build when IsLoggable object contains not typed property. DoclerLabs/hexAnnotation@d39f5df
- Fix expected returned type from static call can't be retrieved if arguments are defined by id references. DoclerLabs/hexDSL@7f967f0
0.19.0
API change
- Owner in
hex.control.command.ICommand
is now typed asIContextModule
instead ofIModule
hex.di.mapping.MappingConfiguration
configure doesn't needIDispatcher<{}>
.
--- public function configure( injector : IDependencyInjector, dispatcher : IDispatcher<{}>, module : IModule ) : Void
+++ public function configure( injector : IDependencyInjector, module : IContextModule ) : Void
- In DSL XML type should now be written
Xml
instead ofXML
--- <data id="fruits" type="XML" parser-class="hex.mock.MockXmlParser">
+++ <data id="fruits" type="Xml" parser-class="hex.mock.MockXmlParser">
Changelog
Features
BasicStaticFlowCompiler
andBasicStaticXmlCompiler
allows type checking and multiple compiler passes with dependency and controlled visibility by compilation inheritance.StaticXmlCompiler
added that supports full IoC features mixed with features listed above.- Flow DSL supports conditional compiling.
- Application context's name is optional inside DSL file.
- DSL compilers (xml and flow) can override application context name.
this
keyword added to both DSLs (xml and flow) to get application context reference.- Flow DSL parser accepts one to many metadata headers.
- Flow compilers use conditional variables as parameters.
IAnnotationReplace
utility which replaces expressions in annotations with their values (#182)
Enhancements
IContextModule
becomes core interface for any applicative module with injector, domain and logger.IModule
extendsIContextModule
.IApplicationContext extends IContextModule
, It means that an application context behaves like a super lightweight module.ApplicationContext
is mapped asIContextModule
in DSL compiled code.MacroUtil.getFQCNFromComplexType
added.MacroUtil.getFQCNFromExpression
added.MacroUtil.getFQCNFromString
added.ArrayUtil.indexOf
ensures to retrieve method closure on Neko target.- Any is used instead of Dynamic when it's possible.
CoreFactory
throws better exception messages when registering fails.- Assembler doesn't handle it's own expression anymore. Job is done with parsers.
- Void method trigger support -
ITrigger<Void->Void>
- Optionals in method triggers support -
ITrigger<?String->Void>
- IsLoggable produces better structured log messages leveraging the api of hexLog
- IsLoggable optional includeParams property to add method parameters into custom message
- IsLoggable searches for an existing logger before creating one
- hexUnit has new asserts:
arrayDeepContainsElement
andarrayDeepContainsElementsFrom
- Domain support in loggers created in modules (and in everything else that uses injected logger from the module context)
- Dedicated logger context (MacroContext) designed for using loggers in macros
- hexMachina is using hexLog everywhere instead of trace
Bugs
- State event handlers with method closures on Neko target fail.
- Dependency provider fix for getInstance call (target class is now null)