dogs1.h
来自「VC++串口通信设。本书详细说明讲解了在VC++环境下编写串口通信得过程。值得一」· C头文件 代码 · 共 49 行
H
49 行
#ifndef DOGS_H
#define DOGS_H
#include <string>
class Animal
{
public:
// Public methods
string GetName() const;
void SetName(const string& strNewName);
... Other methods common to Animals ...
private:
// We assume that all Animals have a name
string strName;
... Other attributes common to Animals ...
};
class Dog : public Animal
{
public:
// Public methods
void Bark();
... Other methods and attributes common to Dogs ...
};
class Collie : public Dog
{
... Methods and attributes specific to Collies ...
};
class Terrier : public Dog
{
... Methods and attributes specific to Terriers ...
};
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?