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