How to Create Organization Information [message #48687] |
Tue, 07 October 2008 05:51  |
Eclipse User |
|
|
|
<representedOrganization>
<id root="8a54f393-8015-460c-abd2-f29aad15481c"/>
<name>Good Health Disease Management</name>
<telecom value="tel:(999)555-1212" use="DIR"/>
<addr>
<streetAddressLine>21 North Ave</streetAddressLine>
<city>Burlington</city>
<state>MA</state>
<postalCode>01803</postalCode>
<country>USA</country>
</addr>
</representedOrganization>
What is the object type in the function
representedOrganization.getName().add(Object)? And the object type
representedOrganization.getTelecom().add£šObject£©?
In other words, how to write code to set the Organization Information.
This confused me for hours.
Thanks in advance!
|
|
|
|
|
|
Re: How to Create Organization Information [message #48933 is a reply to message #48869] |
Thu, 09 October 2008 10:46  |
Eclipse User |
|
|
|
Pretty much you can set it the same way ... there is a setUse method and
it will take an enumeration value from the TelecomAddressUse (or
something named simmilar -- I don't have access to the code at the
moment) enumeration.
- Sarah
RobertHua wrote:
> XML:<telecom value="tel:(999)555-1212" use="DIR"/>
> The telecom element have two attributes,vaule and use.Thank you for your
> code.The code that you give me can set the value's value,but how to set
> the use value?
>
>
|
|
|
|
Re: How to Create Organization Information [message #587859 is a reply to message #48751] |
Wed, 08 October 2008 13:56  |
Eclipse User |
|
|
|
Hi Robert,
Using the CDA schema and CDA examples as a guide will help you. telecom
is of type TEL and the actual telephone number/email/web
address/whatever will be set in the value attribute:
// create a TEL data type
TEL telecom = CDAR2Factory.eINSTANCE.createTEL();
// set the value
telecom.setValue("<telephone number>");
// add to the list of telecom for the organization
organization.getTelecom().add(telecom);
Again, EMF tutorials will be your best way to learn how to interact with
EMF.
- Sarah
RobertHua wrote:
> The addr was setted sucessful.But the use of telecom attributes value
> was not setted.
> How can set it?
> Thanks!
>
|
|
|
|
Re: How to Create Organization Information [message #587893 is a reply to message #48869] |
Thu, 09 October 2008 10:46  |
Eclipse User |
|
|
|
Pretty much you can set it the same way ... there is a setUse method and
it will take an enumeration value from the TelecomAddressUse (or
something named simmilar -- I don't have access to the code at the
moment) enumeration.
- Sarah
RobertHua wrote:
> XML:<telecom value="tel:(999)555-1212" use="DIR"/>
> The telecom element have two attributes,vaule and use.Thank you for your
> code.The code that you give me can set the value's value,but how to set
> the use value?
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.02835 seconds