W3C home > Mailing lists > Public > public-device-apis@w3.org > December 2009

Hanging the APIs off navigator.device

From: <richard.tibbett@orange-ftgroup.com>
Date: Tue, 15 Dec 2009 10:58:55 +0100
Message-ID: <355A518BC0575547B2A3D6773AAF8EEF73A1A0@ftrdmel1>
To: <public-device-apis@w3.org>
Hi,

Just wondering whether we should settle on a specific approach to
hanging certain APIs off the navigator.device object.

At the moment I spy three different approaches:

In Contacts [1]: 

navigator.device.contacts.create(...)
navigator.device.contacts.find(...)

In File Writer [2]:

navigator.device.textWriter(...)
navigator.device.fileWriter(...)

In System Info & Events [3]:

navigator.device.get(...)
navigator.device.watch(...)
navigator.device.set(...)


So just wondering whether we should take a unified approach to this
stuff. I'd prefer [1] but, well, I'm biased as editor. Maybe [2] works
well (with [1] becoming navigator.device.createContact and
navigator.device.findContacts)?

What do people think?

Kind Regards,

Richard


[1] http://dev.w3.org/2009/dap/contacts/

[2] http://dev.w3.org/2009/dap/file-system/file-writer.html

[3] http://dev.w3.org/2009/dap/system-info/
Received on Tuesday, 15 December 2009 09:59:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:14:03 GMT