Re: [thredds] alias and name in catalogRef not working as expected

Yep. "ID" did it. I should be able to work with that.

Thanks,
Doug

On 10/10/11 11:14 AM, Ethan Davis wrote:
Hi Doug,

Try "ID" instead of "id". Dataset IDs must be unique in a catalog.

Ethan

On 10/10/2011 10:36 AM, Doug Lindholm wrote:
Hi Ethan,

I tried using "id" in my catalogRef, but it is also null in the
InvCatalogRef object. Is there a way I can specify and use a short name
for a catalogRef so I don't have to use the title? For example, consider:

catalog.xml:
<catalogRef name="doug" xlink:title="Doug's Catalog"
xlink:href="doug_cat.xml"/>

doug_cat.xml:
<catalog name="My Catalog">
   <dataset name="foo">
   ...

I'd like to reference the dataset as "doug/foo" and not "Doug's
Catalog/foo" (and certainly not "Doug's Catalog/My Catalog/foo").

I could always parse the XML myself, but I like the idea of being able
to use the THREDDS Java API.

Thanks,
Doug

On 10/7/11 12:07 PM, Ethan Davis wrote:
Hi Doug,

We generally use the dataset ID for more URL friendly names.

Ethan

On 10/7/2011 11:57 AM, Doug Lindholm wrote:
Hi Ethan,

It essentially comes down to a long name vs a short name issue. I want
to use the title for a human readable long name, but I'd like to be able
to address the catalogs (and the datasets within them) with more
concise, URL friendly names.

Thanks,
Doug

On 10/7/11 11:40 AM, Ethan Davis wrote:
Hi Doug,

In a catalogRef element, the 'xlink:title' attribute is used to name
the
catalogRef, the 'name' attribute is ignored. In an InvCatalogRef object
you still access the name with getName()/setName().

The 'alias' attribute is not an alternate name for the dataset (if that
is why you're trying to set it). Rather, an 'alias' value references
another dataset in the catalog (by ID). The intent is to allow the same
dataset to appear in multiple places in the same catalog without having
to duplicate all the metadata and such. All properties and metadata
in a
dataset with an 'alias' attribute is ignored in favor of that from the
referenced dataset.

http://www.unidata.ucar.edu/projects/THREDDS/tech/catalog/v1.0.2/InvCatalogSpec.html#alias



If you want to explain the reason you are trying to set both
'xlink:title' and 'name', we can try to come up with another solution.

Cheers,

Ethan

On 10/5/2011 9:21 AM, Doug Lindholm wrote:
Hi,

I am trying to set a "name" or "alias" attribute in a catalogRef
element, but InvCatalogRef.getName() returns the xlink:title and
getAlias() returns null. The spec (and API) implies that the
catalog ref
should behave as a dataset in this regard. Any suggestions short of
parsing the catalog xml myself?

Thanks,
Doug

_______________________________________________
thredds mailing list
thredds@xxxxxxxxxxxxxxxx
For list information or to unsubscribe,  visit:
http://www.unidata.ucar.edu/mailing_lists/

_______________________________________________
thredds mailing list
thredds@xxxxxxxxxxxxxxxx
For list information or to unsubscribe,  visit:
http://www.unidata.ucar.edu/mailing_lists/


_______________________________________________
thredds mailing list
thredds@xxxxxxxxxxxxxxxx
For list information or to unsubscribe,  visit:
http://www.unidata.ucar.edu/mailing_lists/




  • 2011 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the thredds archives: