Beispiel #1
0
        private static Type?GetType(ExportLaunchProfileExtensionValueProviderScope scope)
        {
            return(scope switch
            {
                ExportLaunchProfileExtensionValueProviderScope.LaunchProfile => typeof(ILaunchProfileExtensionValueProvider),
                ExportLaunchProfileExtensionValueProviderScope.GlobalSettings => typeof(IGlobalSettingExtensionValueProvider),

                _ => null
            });
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ExportLaunchProfileExtensionValueProviderAttribute"/>
 /// class for multiple intercepted properties.
 /// </summary>
 public ExportLaunchProfileExtensionValueProviderAttribute(string[] propertyNames, ExportLaunchProfileExtensionValueProviderScope scope)
     : base(GetType(scope))
 {
     PropertyNames = propertyNames;
 }
Beispiel #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ExportLaunchProfileExtensionValueProviderAttribute"/>
 /// class for a single intercepted property.
 /// </summary>
 public ExportLaunchProfileExtensionValueProviderAttribute(string propertyName, ExportLaunchProfileExtensionValueProviderScope scope)
     : this(new[] { propertyName }, scope)
 {
 }