-
Notifications
You must be signed in to change notification settings - Fork 314
Expand file tree
/
Copy pathSystemRuntimeVersioning.cs
More file actions
54 lines (48 loc) · 2.03 KB
/
Copy pathSystemRuntimeVersioning.cs
File metadata and controls
54 lines (48 loc) · 2.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the Apache 2.0 license.
// See the LICENSE file in the project root for more information.
#nullable enable
namespace System.Runtime.Versioning {
#if !FEATURE_OSPLATFORMATTRIBUTE
internal abstract class OSPlatformAttribute : Attribute {
private protected OSPlatformAttribute(string platformName) {
PlatformName = platformName;
}
public string PlatformName { get; }
}
[AttributeUsage(AttributeTargets.Assembly |
AttributeTargets.Class |
AttributeTargets.Constructor |
AttributeTargets.Enum |
AttributeTargets.Event |
AttributeTargets.Field |
AttributeTargets.Method |
AttributeTargets.Module |
AttributeTargets.Property |
AttributeTargets.Struct,
AllowMultiple = true, Inherited = false)]
internal sealed class SupportedOSPlatformAttribute : OSPlatformAttribute {
public SupportedOSPlatformAttribute(string platformName) : base(platformName) {
}
}
[AttributeUsage(AttributeTargets.Assembly |
AttributeTargets.Class |
AttributeTargets.Constructor |
AttributeTargets.Enum |
AttributeTargets.Event |
AttributeTargets.Field |
AttributeTargets.Method |
AttributeTargets.Module |
AttributeTargets.Property |
AttributeTargets.Struct,
AllowMultiple = true, Inherited = false)]
internal sealed class UnsupportedOSPlatformAttribute : OSPlatformAttribute {
public UnsupportedOSPlatformAttribute(string platformName) : base(platformName) {
}
public UnsupportedOSPlatformAttribute (string platformName, string? message) : base(platformName) {
Message = message;
}
public string? Message { get; }
}
#endif
}