-
Notifications
You must be signed in to change notification settings - Fork 14
/
DeprecatedAttribute.cs
32 lines (29 loc) · 1.11 KB
/
DeprecatedAttribute.cs
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
using System;
using System.Collections.Generic;
using System.Text;
namespace QBittorrent.Client
{
/// <summary>
/// Annotates the method/property that is not longer supported in the API.
/// </summary>
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Class, Inherited = true, AllowMultiple = false)]
public class DeprecatedAttribute : Attribute
{
/// <summary>
/// Initializes a new instance of the <see cref="DeprecatedAttribute"/> class.
/// </summary>
/// <param name="fromVersion">The version from which the support for annotated method/property was dropped.</param>
public DeprecatedAttribute(string fromVersion)
{
FromVersion = fromVersion;
}
/// <summary>
/// Gets the version from which the support for annotated method/property was dropped.
/// </summary>
public string FromVersion { get; }
/// <summary>
/// Describes the reason for deprecation and alternative API.
/// </summary>
public string Description { get; set; }
}
}