diff options
author | Marek Safar <marek.safar@gmail.com> | 2014-12-04 17:16:31 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2014-12-04 17:16:31 +0300 |
commit | a1aced8ab22c1dabd25542fe808459f332039ee9 (patch) | |
tree | edc815c58e3da7337a937cc454546af09b9530d7 /mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs | |
parent | 336755ca9edfbb0dd5c395f59a398c76449f7fdc (diff) |
Remove 4.0 profile
Diffstat (limited to 'mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs')
-rw-r--r-- | mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs b/mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs deleted file mode 100644 index 07783ffcd7b..00000000000 --- a/mcs/class/System.ComponentModel.Composition/src/ComponentModel/Microsoft/Internal/LazyServices.cs +++ /dev/null @@ -1,32 +0,0 @@ -using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Threading;
-using System.Text;
-using System.Globalization;
-
-namespace Microsoft.Internal
-{
- internal static class LazyServices
- {
- public static Lazy<T> AsLazy<T>(this T t)
- where T : class
- {
- return new Lazy<T>(() => t, false);
- }
-
- public static T GetNotNullValue<T>(this Lazy<T> lazy, string argument)
- where T : class
- {
- Assumes.NotNull(lazy);
- T value = lazy.Value;
- if (value == null)
- {
- throw new InvalidOperationException(
- string.Format(CultureInfo.CurrentCulture, Strings.LazyServices_LazyResolvesToNull, typeof(T), argument));
- }
-
- return value;
- }
- }
-}
|