Ancient-Spider/蜘蛛纸牌/Card.h
筱傑 a6666bcd52
提交源码
编译环境 VS2017
2018-09-24 12:54:34 +08:00

38 lines
498 B
C++

#pragma once
#include "CardType.h"
class Card
{
private:
CardValue _Value;
CardType _Type;
public:
Card() {}
Card(CardValue value, CardType type)
:_Value(value), _Type(type) {}
~Card() {}
CardValue GetValue() const
{
return _Value;
}
CardType GetType() const
{
return _Type;
}
bool operator<(const Card & card) const
{
return _Value < card._Value;
}
bool operator<(const CardValue & value) const
{
return _Value < value;
}
};