namespace Msp {
namespace DataFile {
-void BuiltinSource::add_object(const string &name, const char *content, unsigned size)
+void BuiltinSource::add_object(const string &name, const char *content, size_t size)
{
objects[name] = Object(content, size);
}
}
-BuiltinSource::Object::Object(const char *d, unsigned s):
+BuiltinSource::Object::Object(const char *d, size_t s):
data(d),
size(s)
{ }
struct Object
{
const char *data = nullptr;
- unsigned size = 0;
+ std::size_t size = 0;
Object() = default;
- Object(const char *, unsigned);
+ Object(const char *, std::size_t);
};
std::map<std::string, Object> objects;
public:
- void add_object(const std::string &, const char *, unsigned);
+ void add_object(const std::string &, const char *, std::size_t);
void add_object(const std::string &, const char *);
bool is_loadable(const CollectionItemTypeBase &, const std::string &) const override;
out = compressed;
}
-unsigned Output::put(char c)
+size_t Output::put(char c)
{
return out->put(c);
}
-unsigned Output::write(const string &s)
+size_t Output::write(const string &s)
{
return out->write(s);
}
void set_compressed();
- unsigned put(char);
- unsigned write(const std::string &);
+ std::size_t put(char);
+ std::size_t write(const std::string &);
};
} // namespace DataFile
struct StatementInfo
{
StatementKey key;
- unsigned args_size = 0;
- std::vector<unsigned> arg_offsets;
+ std::size_t args_size = 0;
+ std::vector<std::size_t> arg_offsets;
StatementInfo() = default;
StatementInfo(const std::string &, const std::string &);