[uf-new] Namespace anti-pattern and hAudio TITLE (was: hAudio FN or Title)

Manu Sporny msporny at digitalbazaar.com
Mon Feb 4 19:46:28 PST 2008


Brian Suda wrote:
>> If we have this (EX2):
>>
>> organization/name
>> organization/unit
>>
>> We have a root, a separator and a suffix. The root is 'organization',
>> the separator is '/' and the suffixes are 'name' and unit'.
> 
> --- but your argument falls down with your other citation of
> country-name. This is NOT:
> 
> country/name

Does it? If 'country-name' isn't namespaced, then we could get rid of
country and 'name' by itself would have an unambiguous meaning. However,
if we were to do that in practice, 'name' wouldn't mean 'country name'
anymore... it would be more ambiguous. By being more ambiguous, we're
stating that the prefix that we removed, 'country', actually does have
semantic meaning. 'country' is a namespace that gives scope to the
following 'name' by specifying that we are talking about a 'country
name' and not a 'person name'.

But even with that argument, let's get rid of country-name - we're still
left with:

entry-title
entry-summary
entry-description
organization-name
organization-unit

My argument still stands - we're providing a specific scope to 'title',
'summary' and 'description' - that scope is 'entry'.

We are also providing a specific scope to 'name', and 'unit' - that
scope is 'organization'.

>> Regardless of what those that put hCard together meant to do, a side
>> effect of choosing to use '-' to separate elements and using the same
>> root creates an "emulated namespace".
> 
> --- this was never the intent of hCard, and i still no do not believe
> having a hyphen denotes namespaces of any kind. People who hypenate
> their surnames, jones-smith is NOT a namespace of jones/smith.

We're not talking about people who hyphenate their surnames - we are
talking about the use of TITLE in hAudio and the inconsistency in the
Microformat community's definition of 'namespace'.

>> To create an "emulated namespace" and then to claim that it isn't one
>> creates an inconsistency in the Microformat community's stance against
>> namespaces.
> 
> Agreed, and this is why i do not consider  this any sort of "emulated
> namespace" had it his been CamelCase would you still argue Namespace?

Yes! You don't need a separator for namespaces to occur, you just need
the root to be the same.

> getUser() is not namespaced, nor is smith-jones or country-name or
> e-mail.

I agree that smith-jones is not namespaced, it is hyphenated. However,
every other one of your examples is a form of scoping/namespacing:

getUser() implies that there are other getters on the object - the
implied namespace/scope is "the set of getter methods for the
object/module".

country-name is namespaced/scoped - the named scope is 'country'. This
differentiates it from 'audio-name', which implies a named scope of
'audio'. If we were to remove 'country' and 'audio' from these two
examples, we would be left with 'name' and 'name' - which are
indistinguishable from each other. The prefixes define a scope - a scope
that is named is called a "namespace".

> We must be talking past one another with our definitions

Just to be clear - this isn't /my/ definition - it is the definition
that is widely accepted in Computer Science. The definition on the
Microformats page is, at best, vague, at worst, inconsistent with the
definition that is widely accepted in Computer Science.

> it is
> probably best to start a wiki page and the discussion will not get
> lose between posts and threads. It will also make it easier for anyone
> to reference later.

Sure thing - the page is up:

http://microformats.org/wiki/namespaces-inconsistency

-- manu



More information about the microformats-new mailing list