Refactor the `properties`, `methods` and `events` accessors, part 1.

In the accessor functions, accept `this` as either the
`node.{properties,methods,events}` collection object or the `node`.

References #3078.
Refactor the `properties`, `methods` and `events` accessors, part 2.

Extract the now-identical accessor creation code into functions (one
each for properties, methods and events).

References #3078.
Refactor the `properties`, `methods` and `events` accessors, part 3.

Formatting and comments.

References #3078.
Prepare for managing event listeners through the kernel.
Support namespaced events to be used for node meta events.

Namespaced events will allow the kernel to use the normal event
listening/firing mechanism for meta events that are distinct from a
node's regular events.

Meta events will announce changes to a node, such as adding and removing
children, creating and deleting properties, methods and events, etc.
Attach meta events to the node collection objects.

References #3079.
Pass context node references as IDs to pass through the kernel properly.