-
Notifications
You must be signed in to change notification settings - Fork 21
Closed
Description
https://juliadata.github.io/StructTypes.jl/stable/#StructTypes.AbstractType uses read on a json string
car = StructTypes.read("""
{
"type": "car",
"make": "Mercedes-Benz",
"model": "S500",
"seatingCapacity": 5,
"topSpeed": 250.1
}""", Vehicle)
but I think read only works on filenames.
julia> # example from StructTypes deserialization
car = StructTypes.read("""
{
"type": "car",
"make": "Mercedes-Benz",
"model": "S500",
"seatingCapacity": 5,
"topSpeed": 250.1
}""", Vehicle)
ERROR: SystemError: opening file "{\n \"type\": \"car\",\n \"make\": \"Mercedes-Benz\",\n \"model\": \"S500\",\n \"seatingCapacity\": 5,\n \"topSpeed\": 250.1\n}": No such file or directoryMetadata
Metadata
Assignees
Labels
No labels