2017-06-08 19:09:51 -04:00
|
|
|
//
|
|
|
|
// ZX8081.hpp
|
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 08/06/2017.
|
2018-05-13 15:19:52 -04:00
|
|
|
// Copyright 2017 Thomas Harte. All rights reserved.
|
2017-06-08 19:09:51 -04:00
|
|
|
//
|
|
|
|
|
2017-06-11 16:41:15 -04:00
|
|
|
#ifndef Storage_Data_ZX8081_hpp
|
|
|
|
#define Storage_Data_ZX8081_hpp
|
2017-06-08 19:09:51 -04:00
|
|
|
|
2017-11-10 21:56:53 -05:00
|
|
|
#include <cstdint>
|
|
|
|
#include <memory>
|
2017-06-08 19:09:51 -04:00
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
namespace Storage {
|
|
|
|
namespace Data {
|
|
|
|
namespace ZX8081 {
|
|
|
|
|
|
|
|
struct File {
|
|
|
|
std::vector<uint8_t> data;
|
2017-07-17 19:52:54 -04:00
|
|
|
std::wstring name;
|
2017-06-08 19:09:51 -04:00
|
|
|
bool isZX81;
|
|
|
|
};
|
|
|
|
|
|
|
|
std::shared_ptr<File> FileFromData(const std::vector<uint8_t> &data);
|
|
|
|
|
2017-06-12 21:32:36 -04:00
|
|
|
std::wstring StringFromData(const std::vector<uint8_t> &data, bool is_zx81);
|
|
|
|
std::vector<uint8_t> DataFromString(const std::wstring &string, bool is_zx81);
|
|
|
|
|
|
|
|
|
2017-06-08 19:09:51 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* ZX8081_hpp */
|