Skip to content
Snippets Groups Projects
Commit 1be37139 authored by florian's avatar florian
Browse files

DRAFT: Begin implementation of creators

parent e365f6e6
No related branches found
No related tags found
1 merge request!13ENH: Use new value and datatype structs
Pipeline #13819 failed
...@@ -475,6 +475,35 @@ function create_parent(; name::AbstractString = "", id::AbstractString = "") ...@@ -475,6 +475,35 @@ function create_parent(; name::AbstractString = "", id::AbstractString = "")
return parent return parent
end end
"""
function create_atomic_datatype(name::AbstractString)
Create and return a DataType object with an atomic datatype specified by the
`name`.
"""
function create_atomic_datatype(name::AbstractString)
datatype = Ref{_DataType}(_DataType(true))
err_code = ccall(
(:caosdb_entity_create_atomic_datatype, CaosDB.library_name),
Cint,
(Ref{_DataType}, Cstring),
datatype,
name
)
CaosDB.Exceptions.evaluate_return_code(err_code)
return datatype
end
function create_reference_datatype(name::AbstractString) end
function create_list_of_atomic_datatype(name::AbstractString) end
function create_list_of_reference_datatype(name::AbstractString) end
""" """
function get_id(entity::Ref{_Entity}) function get_id(entity::Ref{_Entity})
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment