On Oct 21, 2012, at 4:13 AM, Jan Algermissen wrote:
>
> On Oct 21, 2012, at 12:29 AM, Jan Algermissen wrote:
>
>> Hi,
>>
>> AFAIK there can be more than one Link header value for any given rel. E.g. one could have
>>
>> Link: </a>; rel="describedBy"
>> Link: </b>; rel="describedBy"
>>
>> given that
>>
>> Link getLink(String relation)
>>
>> Should (unfortunately) be something like
>>
>> Collection<Link> getLinks(String relation)
>>
>> Agreed?
>>
>> I'll check back on apps-discuss.
>
> Seems correct - there can be more than one link for any given rel:
>
> http://www.ietf.org/mail-archive/web/apps-discuss/current/msg07612.html
>
> Issue opened here:
> http://java.net/jira/browse/JAX_RS_SPEC-276
We had some discussions about this in the past (I'd need to look them up). I recall people thought this case was much less common and could be handled by Set<Links> getLinks() and some filtering, already in the API. I'm not strongly opposed to this addition, but there something to be said about keeping the number of methods to a minimum.
-- Santiago