-
Notifications
You must be signed in to change notification settings - Fork 4
/
meal.h
42 lines (28 loc) · 887 Bytes
/
meal.h
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
39
40
41
42
#ifndef _MEAL_H_
#define _MEAL_H_
#include <string>
#include <node.h>
#include <nan.h>
#define DISALOW_COPY_ASSIGN(x)
class Meal {
DISALOW_COPY_ASSIGN(Meal);
public:
explicit Meal();
explicit Meal(const std::string& type);
explicit Meal(const std::string& type, const double& size);
~Meal();
const std::string get_type () const { return type_; }
void set_type (const std::string& new_value) { type_ = new_value; }
double get_size () const { return size_; }
void set_size (double new_value) { size_ = new_value; }
bool get_isRawMeal() const { return raw_meal_; }
void prepare(std::string type, double size);
void prepare(std::string type);
// void cook(std::string chefName);
v8::Handle<v8::Promise> cook(const std::string& chefName, v8::Isolate* isolate);
private:
std::string type_;
double size_;
bool raw_meal_;
};
#endif // _MEAL_H_