-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathInputItem.cs
More file actions
38 lines (33 loc) · 943 Bytes
/
InputItem.cs
File metadata and controls
38 lines (33 loc) · 943 Bytes
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
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace CramOMatic
{
class InputItem
{
public string Name { get; set; }
public int Value { get; set; }
[System.ComponentModel.DisplayName("Type")]
public PokemonType PokemonType { get; set; }
public InputItem(PokemonType pokemonType, int value, string name)
{
PokemonType = pokemonType;
Value = value;
Name = name;
}
public override string ToString()
{
return Name;
}
public static int CompareName(InputItem value1, InputItem value2)
{
return value1.Name.CompareTo(value2.Name);
}
public static int CompareValueDesc(InputItem value1, InputItem value2)
{
return value2.Value.CompareTo(value1.Value);
}
}
}