public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Fred Schaettgen <bluez-devel@schaettgen.de>
To: bluez-devel@lists.sourceforge.net
Subject: Re: [Bluez-devel] Bluetooth MIME types and URIs
Date: Fri, 8 Jul 2005 17:54:54 +0200	[thread overview]
Message-ID: <200507081754.55107.bluez-devel@schaettgen.de> (raw)
In-Reply-To: <1120833804.18553.117.camel@pegasus>

[-- Attachment #1: Type: text/plain, Size: 2393 bytes --]

On Friday, 8. July 2005 16:43, Marcel Holtmann wrote:
...
> > But I wonder if this isn´t actually an abuse of mimetypes. Aren´t
> > mimetypes supposed to declare the format of a file? Yet we are not
> > talking about file contents at all here. Instead we associate a mimetype
> > with a certain URL format.
>
> In general yes, but they always have been misused.



> > At the moment, an item with the mimetype ¨bluetooth/obex-push-profile¨
> > can only live inside the sdp kioslave.
> > Maybe a more correct way would in fact be to have a helper application
> > associated with the type application/x-bt.service, which gets the
> > information what device to connect to not from the URL, but from the URL
> > contents. application/x-bt.service could simply be a file that contains
> > the whole service record as xml, similar to the service record files for
> > the metaserver. The applications would have to parse this xml file, which
> > isn´t very lightweight, but it gives all available information and we
> > don´t have to worry how to squezze everything into an URL.
>
> I am not really happy with adding somekind of XML overhead.

But it´s the most natural format for a hierarchical data structure like the 
service records. The computational overhead would be neglectable and it only 
has to be implemented in the service dispatcher, not in each application 
started by it. We can put everything we know in the xml structure without 
much effort. Extending the url format might become more troublesome at some 
point. 
We could also go without the service dispatcher and still use distinct 
mimetypes for each service, but let the application read the needed 
information from the data the url points to and not from the URL itself.
We didn´t have to standardize on a URL format then, but just on the mimetypes 
and the service description format, be it xml or anything else. 
In KDE it would allow for a kfile plugin which displays additional properties 
of services in konqueror besides the name. 
Or we could do both - putting just the most relevant information into the URL 
(bdaddr+channel) and the complete service record, device adress + name and 
everything else we know about a service into the file contents as xml similar 
to sdp registration files we use (see attachment).

Fred

-- 
Fred Schaettgen
bluez-devel@schaettgen.de

[-- Attachment #2: kbluetoothd_kbtobexsrv.sdp.xml --]
[-- Type: text/xml, Size: 1284 bytes --]

<sdprecord>
<attributes>

<!-- Service name -->
<attribute id='0x0100'>
<str>Obex Push Server</str>
</attribute>

<!-- Service description -->
<attribute id='0x0101'>
<str>KDE OBEX Object Push Service</str>
</attribute>

<!-- Supported formats list -->
<attribute id='0x0303'>
<seq>
<uint val='0xFF' size='8'/><!-- anything  -->
<uint val='0x01' size='8'/><!-- vCard 2.1 -->
<uint val='0x02' size='8'/><!-- vCard 3.0 -->
<uint val='0x03' size='8'/><!-- vCal  1.0 -->
<uint val='0x04' size='8'/><!-- iCal  2.0 -->
<uint val='0x05' size='8'/><!-- vNotes    -->
<uint val='0x06' size='8'/><!-- vMessage  -->
</seq>
</attribute>

<!-- Service class ID list -->
<attribute id='0x0001'>
<seq>
<uuid val='0x1105' size='16'/>
</seq>
</attribute>

<!-- Protocol descriptor list -->
<attribute id='0x0004'>
<seq>
<seq><uuid val='256' size='16'/></seq>
<seq><uuid val='3' size='16'/>
<uint valref='rfcommchannel' size='8'/></seq>
<seq><uuid val='0x0008' size='16'/></seq>
</seq>
</attribute>

<!-- Browse group list-->
<attribute id='0x0005'>
<seq>
<uuid val='0x1002' size='16'/>
</seq>
</attribute>

<!-- Bluetooth profile descriptor list -->
<attribute id='0x0009'>
<seq>
<seq><uuid val='0x1105' size='16'/>
<uint val='0x0100' size='16'/></seq>
</seq>
</attribute>

</attributes>
</sdprecord>

  reply	other threads:[~2005-07-08 15:54 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-07 14:42 [Bluez-devel] Bluetooth MIME types and URIs Marcel Holtmann
2005-07-07 17:00 ` Fred Schaettgen
2005-07-07 18:13   ` Marcel Holtmann
2005-07-08  1:15     ` Fred Schaettgen
2005-07-08  6:38       ` Marcel Holtmann
2005-07-08 12:45         ` Claudio Takahasi
2005-07-08 14:47           ` Marcel Holtmann
2005-07-08 16:23             ` Claudio Takahasi
2005-07-08 19:10               ` Marcel Holtmann
2005-07-08 20:04                 ` Claudio Takahasi
2005-07-08 20:11                   ` Marcel Holtmann
2005-07-08 12:51         ` Fred Schaettgen
2005-07-08 14:43           ` Marcel Holtmann
2005-07-08 15:54             ` Fred Schaettgen [this message]
2005-07-08 19:17               ` Marcel Holtmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200507081754.55107.bluez-devel@schaettgen.de \
    --to=bluez-devel@schaettgen.de \
    --cc=bluez-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox