Objects Initial

This commit is contained in:
IlushaShurupov 2023-07-24 21:55:19 +03:00 committed by Ilya Shurupov
parent 0f639ba3b1
commit 94057d2a66
76 changed files with 7895 additions and 17 deletions

View file

@ -0,0 +1,31 @@
#pragma once
#include "core/object.h"
namespace obj {
struct DictObject : Object {
static ObjectType TypeData;
static void copy(Object* self, const Object* in);
static void destructor(Object* self);
static void constructor(Object* self);
static tp::alni save_size(DictObject* self);
static void save(DictObject* self, Archiver& file_self);
static void load(Archiver& file_self, DictObject* self);
static tp::Buffer<Object*> childs_retrival(DictObject* self);
static tp::alni allocated_size(DictObject* self);
static tp::alni allocated_size_recursive(DictObject* self);
void put(tp::String, Object*);
void remove(tp::String);
Object* get(tp::String);
tp::Map<tp::String, Object*>::Idx presents(tp::String);
Object* getSlotVal(tp::alni);
const tp::Map<tp::String, Object*>& getItems() const;
private:
tp::Map<tp::String, Object*> items;
};
};