File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,47 +19,13 @@ namespace My.Awesome.App
1919 {
2020 public static void Main (string [] args )
2121 {
22- IUnityContainer container = UnityContainerBuilder . Build ();
22+ IUnityContainer container = UnityContainerPopulator . Populate ();
2323 }
2424 }
2525
26- [RegisterTypeAttribute ]
26+ [RegisterType ]
2727 public class MyService
2828 {
2929 }
3030}
3131```
32-
33- ## Details
34-
35- ### ` RegisterTypeAttribute(from, lifetimeManager) `
36- #### Description
37- Mark a type to be registered.
38- #### Parameters
39- - ` from `
40- - type: ` System.Type `
41- - optional: ` true `
42- - description: Type which will be requested, when using unity.
43- - ` lifetimeManager `
44- - type: ` UnityContainerAttributeRegistration.TypeLifetimeManager `
45- - optional: ` true `
46- - description: ` ITypeLifetimeManager ` which should be used.
47-
48- ### ` UnityContainerBuilder.Build() `
49- #### Description
50- Search for all types using ` RegisterTypeAttribute ` and register these types to a new ` IUnityContainer ` .
51- #### Return value
52- - type: ` Unity.IUnityContainer `
53- - description: New ` Unity.IUnityContainer ` instance, containing the registered types.
54-
55- ### ` UnityContainerBuilder.Build(container) `
56- #### Description
57- Search for all types using ` RegisterTypeAttribute ` and register these types to the passed ` IUnityContainer ` .
58- #### Parameters
59- - ` container `
60- - type: ` Unity.IUnityContainer `
61- - optional: ` false `
62- - description: ` IUnityContainer ` instance to register types
63- #### Return value
64- - type: ` Unity.IUnityContainer `
65- - description: The passed ` Unity.IUnityContainer ` , containing the registered types.
You can’t perform that action at this time.
0 commit comments