📄 storage.h
字号:
// Storage.h: interface for the Storage class.
//
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_STORAGE_H__A0CE3BC1_6AB0_44B0_8A37_78125093F1E4__INCLUDED_)
#define AFX_STORAGE_H__A0CE3BC1_6AB0_44B0_8A37_78125093F1E4__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "fstream.h"
struct BookData
{
char isbn[14];
char bookTitle[51];
char author[31];
char publisher[31];
char dateAdded[11];
int qtyOnHand;
float wholesale;
float retail;
int showed;//标记是否已经打印
};
class Storage
{
public:
//int Max=100;//最多存储的书的本数
BookData book[100];
static int num;//已经存储的书的本数
public:
Storage();
void setTitle(char *,int);
void setISBN(char *,int);
void setAuthor(char *,int);
void setPub(char *,int);
void setDateAdded(char *,int);
void setQty(int,int);
void setWholesale(float,int);
void setRetail(float,int);
bool isEmpty(int);
void addBook();
void removeBook(int);
int lookBook(char *);
void BookInfo(int);
void lookUpBook(char *);
void editBook(char *);
void deleteBook(char *);
~Storage();
};
#endif // !defined(AFX_STORAGE_H__A0CE3BC1_6AB0_44B0_8A37_78125093F1E4__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -