This website works better with JavaScript.
Home
Issues
Pull Requests
Milestones
AI流水线
Repositories
Datasets
Forum
实训
竞赛
大数据
Register
Sign In
youys
/
Discord.Net
Not watched
Unwatch
Watch all
Watch but not notify
1
Star
0
Fork
0
Code
Releases
34
Wiki
Activity
Issues
0
Pull Requests
0
Datasets
Model
Cloudbrain
Browse Source
Merge pull request
#234
from Joe4evr/IEquatable
Constrain IEntity's TId to IEquatable<TId>
tags/1.0-rc
RogueException
GitHub
9 years ago
parent
7f7fe6b3c9
a326824cdb
commit
92e86525e0
2 changed files
with
6 additions
and
1 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+3
-0
src/Discord.Net/Entities/IEntity.cs
+3
-1
src/Discord.Net/Rest/Entities/Entity.cs
+ 3
- 0
src/Discord.Net/Entities/IEntity.cs
View File
@@ -1,6 +1,9 @@
using System;
namespace Discord
{
public interface IEntity<TId>
where TId : IEquatable<TId>
{
/// <summary> Gets the unique identifier for this object. </summary>
TId Id { get; }
+ 3
- 1
src/Discord.Net/Rest/Entities/Entity.cs
View File
@@ -1,8 +1,10 @@
using Discord.Rest;
using System;
using Discord.Rest;
namespace Discord.Rest
{
internal abstract class Entity<T> : IEntity<T>
where T : IEquatable<T>
{
public T Id { get; }
Write
Preview
Loading…
Cancel
Save