The formula interface for layer functions

Once we support spatials we may have to do a little more reflection, we need to retrieve the `@data` slot.