typedb / typeql

TypeQL: the power of programming, in your database
https://typedb.com
Mozilla Public License 2.0
221 stars 46 forks source link

Make Variables be independent Statements #65

Closed haikalpribadi closed 1 year ago

haikalpribadi commented 5 years ago

At the moment, whenever we want to provide a variable into a Statement builder, we must construct a full Statement object that only contains that one Variable. For example:

type("marriage").relates(var("x"))

In the case above, Graql.var("x") returns a Statement object, in which StatementTypeBuilder.relates() accepts.

This is problematic for various reasons:

flyingsilverfin commented 1 year ago

The "tightness" of the APIs was resolved in the refactor for version 2.x