コード例 #1
0
ファイル: cInventory.cpp プロジェクト: dnulho/School
// Wrapper for cInventory SaveToFile function
void SaveInvToFile(cInventory & inv, const char * filename)
{
	ofstream file(filename);
	if (file.is_open())
	{
		inv.SaveToFile(file);
		file.close();
	}
	else
		cout << "Error: Unable to open " << filename << endl;
}