You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// <c>On</c> or <c>Off</c>. Determines whether to use a static partial <c>OnNewRoot<T>(...)</c> method to handle the new Composition root registration event. <c>Off</c> by default.
663
+
/// <c>On</c> or <c>Off</c>. Determines whether to use a static partial <c>OnNewRoot<T>(...)</c> method to handle the new composition root registration event. <c>Off</c> by default.
664
664
/// <example>
665
665
/// <code>
666
666
/// // OnNewRoot = On
@@ -680,7 +680,7 @@ internal enum Hint
680
680
OnNewRoot,
681
681
682
682
/// <summary>
683
-
/// <c>On</c> or <c>Off</c>. Determines whether to generate a static partial <c>OnNewRoot<T>(...)</c> method when the <c>OnNewRoot</c> hint is <c>On</c> to handle the new Composition root registration event. <c>On</c> by default.
683
+
/// <c>On</c> or <c>Off</c>. Determines whether to generate a static partial <c>OnNewRoot<T>(...)</c> method when the <c>OnNewRoot</c> hint is <c>On</c> to handle the new composition root registration event. <c>On</c> by default.
684
684
/// <example>
685
685
/// <code>
686
686
/// // OnNewRootPartial = On
@@ -720,7 +720,7 @@ internal enum Hint
720
720
ToString,
721
721
722
722
/// <summary>
723
-
/// <c>On</c> or <c>Off</c>. This hint determines whether object Composition will be created in a thread-safe manner. <c>On</c> by default.
723
+
/// <c>On</c> or <c>Off</c>. This hint determines whether object composition will be created in a thread-safe manner. <c>On</c> by default.
/// <typeparam name="T">The type of dependency to be bound.</typeparam>
1882
-
/// <param name="name">Specifies the name template of the root of the composition. If the value is empty, a private root will be created, which can be used when calling <c>Resolve</c> methods.</param>
1883
-
/// <param name="kind">The Optional argument specifying the kind for the root of the Composition.</param>
1882
+
/// <param name="name">
1883
+
/// Specifies the name of the root of the composition. If the value is empty, a private root will be created, which can be used when calling <c>Resolve</c> methods.
1884
+
/// <para>
1885
+
/// The name supports templating:
1886
+
/// <list type="table">
1887
+
/// <listheader>
1888
+
/// <term>Template</term>
1889
+
/// <description>Description</description>
1890
+
/// </listheader>
1891
+
/// <item>
1892
+
/// <term>{type}</term>
1893
+
/// <description>Will be replaced by the short name of the root type without its namespaces.</description>
1894
+
/// </item>
1895
+
/// <item>
1896
+
/// <term>{TYPE}</term>
1897
+
/// <description>Will be replaced with the full name of the root type.</description>
1898
+
/// </item>
1899
+
/// <item>
1900
+
/// <term>{tag}</term>
1901
+
/// <description>Will be replaced with the first tag name.</description>
1902
+
/// </item>
1903
+
/// </list>
1904
+
/// </para>
1905
+
/// </param>
1906
+
/// <param name="kind">The optional argument specifying the kind for the root of the composition.</param>
1884
1907
/// <param name="tags">The optional argument that specifies tags for a particular type of dependency binding. If is is not empty, the first tag is used for the root.</param>
1885
1908
/// <returns>Reference to the setup continuation chain.</returns>
/// <param name="tags">Optional argument specifying the binding tags for which it will set the default lifetime. If not specified, the default lifetime will be set for any tags.</param>
2026
+
/// <param name="tags">The optional argument specifying the binding tags for which it will set the default lifetime. If not specified, the default lifetime will be set for any tags.</param>
2004
2027
/// <typeparam name="T">The default lifetime will be applied to bindings if the implementation class can be cast to type <typeparamref name="T"/>.</typeparam>
2005
2028
/// <returns>Reference to the setup continuation chain.</returns>
/// <param name="name">Specifies the name template of the root of the composition. If the value is empty, a private root will be created, which can be used when calling <c>Resolve</c> methods.</param>
2050
-
/// <param name="tag">Optional argument specifying the tag for the root of the Composition.</param>
2051
-
/// <param name="kind">The Optional argument specifying the kind for the root of the Composition.</param>
/// Specifies the name of the root of the composition. If the value is empty, a private root will be created, which can be used when calling <c>Resolve</c> methods.
2126
+
/// <para>
2127
+
/// The name supports templating:
2128
+
/// <list type="table">
2129
+
/// <listheader>
2130
+
/// <term>Template</term>
2131
+
/// <description>Description</description>
2132
+
/// </listheader>
2133
+
/// <item>
2134
+
/// <term>{type}</term>
2135
+
/// <description>Will be replaced by the short name of the root type without its namespaces.</description>
2136
+
/// </item>
2137
+
/// <item>
2138
+
/// <term>{TYPE}</term>
2139
+
/// <description>Will be replaced with the full name of the root type.</description>
2140
+
/// </item>
2141
+
/// <item>
2142
+
/// <term>{tag}</term>
2143
+
/// <description>Will be replaced with the root tag name.</description>
2144
+
/// </item>
2145
+
/// </list>
2146
+
/// </para>
2147
+
/// </param>
2148
+
/// <param name="tag">The optional argument specifying the tag for the root of the composition.</param>
2149
+
/// <param name="kind">The optional argument specifying the kind for the root of the composition.</param>
/// Specifies to define composition roots for all types inherited from <see cref="T"/> available at compile time at the time this method is called.
2058
2156
/// <example>
2059
2157
/// <code>
2060
2158
/// DI.Setup("Composition")
2061
2159
/// .Roots<IService>();
2062
2160
/// </code>
2063
2161
/// </example>
2162
+
/// <example>
2163
+
/// <code>
2164
+
/// DI.Setup("Composition")
2165
+
/// .Roots<IService>("Root{type}");
2166
+
/// </code>
2167
+
/// </example>
2064
2168
/// </summary>
2065
-
/// <param name="name">Specifies the name template of the roots of the composition. If the value is empty, private roots will be created, which can be used when calling <c>Resolve</c> methods.</param>
2066
-
/// <param name="kind">The Optional argument specifying the kind for the root of the Composition.</param>
2067
-
/// <typeparam name="T">The Composition root base type.</typeparam>
2169
+
/// <param name="name">
2170
+
/// Specifies the name of the roots of the composition. If the value is empty, private roots will be created, which can be used when calling <c>Resolve</c> methods.
2171
+
/// <para>
2172
+
/// The name supports templating:
2173
+
/// <list type="table">
2174
+
/// <listheader>
2175
+
/// <term>Template</term>
2176
+
/// <description>Description</description>
2177
+
/// </listheader>
2178
+
/// <item>
2179
+
/// <term>{type}</term>
2180
+
/// <description>Will be replaced by the short name of the type without its namespaces.</description>
2181
+
/// </item>
2182
+
/// <item>
2183
+
/// <term>{TYPE}</term>
2184
+
/// <description>Will be replaced with the full name of the type.</description>
2185
+
/// </item>
2186
+
/// </list>
2187
+
/// </para>
2188
+
/// </param>
2189
+
/// <param name="kind">The optional argument specifying the kind for the root of the composition.</param>
2190
+
/// <typeparam name="T">The composition root base type.</typeparam>
2068
2191
/// <returns>Reference to the setup continuation chain.</returns>
/// Specifies the methods of the composition builders. The first argument to the method will always be the instance to be built. The remaining arguments to this method will be listed in the order in which they are defined in the setup.Specifies to create a composition builder method. The first argument to the method will always be the instance to be built. The remaining arguments to this method will be listed in the order in which they are defined in the setup.
2229
+
/// Specifies to define builders for all types inherited from <see cref="T"/> available at compile time at the time this method is called.
2088
2230
/// <example>
2089
2231
/// <code>
2090
2232
/// DI.Setup("Composition")
2091
-
/// .Builder<Service>("BuildUpMyService");
2233
+
/// .Builders<Service>();
2234
+
/// </code>
2235
+
/// </example>
2236
+
/// <example>
2237
+
/// <code>
2238
+
/// DI.Setup("Composition")
2239
+
/// .Builder<Service>("BuildUp");
2240
+
/// </code>
2241
+
/// </example>
2242
+
/// <example>
2243
+
/// <code>
2244
+
/// DI.Setup("Composition")
2245
+
/// .Builder<Service>("BuildUp{type}");
2092
2246
/// </code>
2093
2247
/// </example>
2094
2248
/// </summary>
2095
-
/// <param name="name">Specifies the name template of the builders. The default name tamplate is "BuildUp".</param>
2096
-
/// <param name="kind">The Optional argument specifying the kind for the root of the Composition.</param>
2097
-
/// <typeparam name="T">The Composition root base type.</typeparam>
2249
+
/// <param name="name">
2250
+
/// Specifies the name of the builders. The default name is "BuildUp".
2251
+
/// <para>
2252
+
/// The name supports templating:
2253
+
/// <list type="table">
2254
+
/// <listheader>
2255
+
/// <term>Template</term>
2256
+
/// <description>Description</description>
2257
+
/// </listheader>
2258
+
/// <item>
2259
+
/// <term>{type}</term>
2260
+
/// <description>Will be replaced by the short name of the type without its namespaces.</description>
2261
+
/// </item>
2262
+
/// <item>
2263
+
/// <term>{TYPE}</term>
2264
+
/// <description>Will be replaced with the full name of the type.</description>
2265
+
/// </item>
2266
+
/// </list>
2267
+
/// </para>
2268
+
/// </param>
2269
+
/// <param name="kind">The optional argument specifying the kind for the root of the composition.</param>
2270
+
/// <typeparam name="T">The composition root base type.</typeparam>
2098
2271
/// <returns>Reference to the setup continuation chain.</returns>
0 commit comments