-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOverseacommodity.h
More file actions
25 lines (23 loc) · 827 Bytes
/
Overseacommodity.h
File metadata and controls
25 lines (23 loc) · 827 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
#ifndef OVERSEACOMMODITY_H
#define OVERSEACOMMODITY_H
#include <string>
#include "commodity.h"
class OverseaCommodity : public Commodity{
public:
OverseaCommodity(long id,std::string name,
double p=0,int n=0,double d=1.0,double t=0);
OverseaCommodity(std::string name,double p=0,
int n=0,double d=1.0,double t=0);
void setDiscount(double discount){this->discount=discount;}
void setTariff(double tariff){this->tariff=tariff;}
double getDiscount()const{return discount;}
double getTariff()const{return tariff;}
virtual double getNetPrice()const;
virtual void output()const;
virtual int getType()const;
virtual std::string getInfo()const;
private:
double discount;
double tariff;
};
#endif // OVERSEACOMMODITY_H