Peter Gummer wrote:
> Thomas Beale wrote:
>
>> I also agree with Adam. A regex should be able to be used over a
>> population of strings (identifiers in this case) and have the effect of
>> filtering out what you want. ...
>>
>> Practically speaking this does not change the specifications, but I
>> suspect we should put some guidance in to the effect that regexes based
>> on full identifiers should be used in archetype slots.
>>
>>
>
>
> Surely the specifications should be stronger than just guidance.
>
I agree.
> Existing tools that are massaging the regex will cease to work if they
> are given a full regex. It would be a breaking change, so I think it
> should be spelled out in the specification. Otherwise, tools are going
> to have to try to do some clever guesswork to decide whether a given
> pattern is intended to match the full archetype id or just the domain
> concept part of it.
>
>
I agree in that it should state that the regex is the regex, that's it,
nothing else is required etc.
Wrt existing tools
A) We already know some tools break with the current system e.g. the
XSLT for rendering a choice i.e. ABC | DEF | GHI etc.
B) The string you are actually matching on is the Archetype ID. As such
that should be the basis of the regex. doing a pseudo-meta regex will
hurt in the long run.
Quick example:
NB: These are simply examples & are not intended as a source of
discussion in & of themselves.
Imagine English speaking people want to use archetypes whose names have
meaning to them e.g. "clinician".
Now imagine a variety of English speaking jurisdictions all wanting to
have their own definition of "clinician".
You could have
openEHR-EHR-CLUSTER.clinician-AUS.v1, openEHR-EHR-CLUSTER.clinician-NZ.v1,
openEHR-EHR-CLUSTER.clinician-UK.v1, openEHR-EHR-CLUSTER.clinician-US.v1 etc.
But then what happens if you then specialize one to show it's a surgeon
e.g. would it be
openEHR-EHR-CLUSTER.clinician-surgeon-AUS.v1 or
openEHR-EHR-CLUSTER.clinician-AUS-surgeon.v1, etc.
Or to avoid that sort of problem you could namespace it at the other
end e.g.:
openEHR-EHR-AUS-CLUSTER.clinician.v1, openEHR-EHR-NZ-CLUSTER.clinician.v1,
openEHR-EHR-UK-CLUSTER.clinician.v1, openEHR-EHR-US-CLUSTER.clinician.v1
or even
AUS-openEHR-EHR-CLUSTER.clinician.v1
Thus having {/clinician\.v1} and adding "openEHR-EHR-CLUSTER." would not work.
If the archetype is chosen then someone would have chosen
openEHR-EHR-CLUSTER.clinician.v1 if that is the archetype ID or
openEHR-EHR-AUS-CLUSTER.clinician.v1 if that was.
Fix it now & something like the above becomes a non-issue in the future.
Adam
> - Peter
>
> _______________________________________________
> openEHR-technical mailing list
> openEHR-technical at openehr.org
> http://lists.chime.ucl.ac.uk/mailman/listinfo/openehr-technical
>
***********************************************************************
This message may contain confidential and privileged information.
If you are not the intended recipient you should not disclose, copy
or distribute information in this e-mail or take any action in reliance
on its contents. To do so is strictly prohibited and may be unlawful.
Please inform the sender that this message has gone astray before
deleting it. Thank you.
2008 marks the 60th anniversary of the NHS. It's an opportunity to pay
tribute to the NHS staff and volunteers who help shape the service, and
celebrate their achievements.
If you work for the NHS and would like an NHSmail email account, go
to: www.connectingforhealth.nhs.uk/nhsmail
***********************************************************************