Re: [sensors] granularity of Permission name for concrete/ fusion sensors

> let s = new HeadTrackerSensor();
> permissions.query(s).then(/.../);

Yes, this could be thought of as something like:

```js
HeadTrackerSensor.prototype.getPermission = function() {
    return ["gyroscope", "magnetometer"];
};

Permissions.prototype.query = function(...args) {
    args.map(function(arg) {
        if (typeof arg.getPermission === "function") {
            return arg.getPermission();
        } else {
            return arg;
        } 
    });
    // do stuff
};
```

-- 
GitHub Notification of comment by tobie
Please view or discuss this issue at 
https://github.com/w3c/sensors/issues/132#issuecomment-260376376 using
 your GitHub account

Received on Monday, 14 November 2016 16:01:42 UTC