2 Star 5 Fork 1

子龙山人 / Lua-Tutorials

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
Student.cpp 557 Bytes
一键复制 编辑 原始数据 按行查看 历史
andyque 提交于 2014-09-15 10:41 . fix gc
//
// Student.cpp
// MyCppGame
//
// Created by guanghui on 8/11/14.
//
//
#include "Student.h"
Student::Student()
:name("default")
{
cout<<"Student Contructor called"<<endl;
}
Student::~Student()
{
cout<<"Student Destructor called"<<endl;
}
string Student::getName()
{
return name;
}
void Student::setName(string name)
{
this->name = name;
}
int Student::getAge()
{
return age;
}
void Student::setAge(int age)
{
this->age = age;
}
void Student::print()
{
cout<<"My name is: "<<name<<", and my age is "<<age<<endl;
}
C
1
https://gitee.com/zilongshanren/Lua-Tutorials.git
git@gitee.com:zilongshanren/Lua-Tutorials.git
zilongshanren
Lua-Tutorials
Lua-Tutorials
master

搜索帮助