DataType instead of Data


#1

Hello,

In the Resources paragraph of Graph API Overview, the example shows how to create resource types:

ResourceType<String> title = mindmapsGraph.putResourceType("title", Data.STRING);
ResourceType<String> epithet = mindmapsGraph.putResourceType("epithet", Data.STRING);`

But, as properly reported by API docs, the second parameter of putResourceType method is a DataType:

type - The data type of the resource type. Supported types include: DataType.STRING, DataType.LONG, DataType.DOUBLE, and DataType.BOOLEAN

Antonio


#2

Hi Antonio,

There is an error in our Graph Overview API documentation, thanks for pointing it out. It should actually be:

ResourceType<String> title = mindmapsGraph.putResourceType("title", ResourceType.DataType.STRING);
ResourceType<String> epithet = mindmapsGraph.putResourceType("epithet", ResourceType.DataType.STRING);

We will rectify that immediately.

Regards,

Filipe


#3

Now fixed on the site https://mindmaps.io/pages/documentation/core-api/overview.html#resources