kdl icon indicating copy to clipboard operation
kdl copied to clipboard

Terminology requests

Open Lucretiel opened this issue 2 years ago • 3 comments

For the assistance of implementers, I'd like to propose we add a set of terminology to help group related concepts in KDL. Specifically, I'm interested in a unifying term for:

  • The properties and arguments associated with a node.
  • The properties, arguments, and the set of children associated with a node.

In kaydle I've been using "Entity" interchangeably for both of these, but I don't love that. I was thinking something like a "Component" (for all things belonging to a node) and "Primitive Component" (for everything except the set of children). Of course, I'm happy to hear bikeshedding for this. Under this model, a single component would be any individual value, an individual property (the key-value pair collectively), or the set of children as a whole.

This terminology shouldn't really be needed by actual KDL users, but it'll be convenient for implementors to be able to have a common term to refer to all of the things belonging to a single node, because often these are iterated / grouped collectively in the course of parsing.

Lucretiel avatar Sep 20 '21 21:09 Lucretiel

entity sounds fine by me. Everything else I can think of has a lot of overlap with other languages that would prove confusing?

zkat avatar Sep 21 '21 01:09 zkat

I also can't think of anything better than entity.

hkolbeck avatar Sep 21 '21 23:09 hkolbeck

I'm using entity now for the props/values object, and yeah, it works fine for me.

tabatkins avatar Oct 05 '21 18:10 tabatkins