From 3ae8fd2d12816cb84cde5b126091b007eb233695 Mon Sep 17 00:00:00 2001 From: nixo Date: Fri, 23 Oct 2020 15:28:54 +0200 Subject: [PATCH] Convert table to dict for easier access --- src/structure.jl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/structure.jl b/src/structure.jl index 3124d60..a4d2d7e 100644 --- a/src/structure.jl +++ b/src/structure.jl @@ -73,6 +73,8 @@ function Base.write(io::IOStream, object::Action; S = UInt32) wl end +Base.Dict(dbt::DataBaseTable) = dbt.memory.data + function Base.getindex(tbl::DataBaseTable, key::T) where T tbl.memory.data[key] end