Elexis API documentation
Version 2.1.6 as of December 11 2011

ch.elexis.exchange
Class XChangeExporter

java.lang.Object
  extended by ch.elexis.exchange.XChangeExporter
All Implemented Interfaces:
IDataSender
Direct Known Subclasses:
BlockExporter

public abstract class XChangeExporter
extends java.lang.Object
implements IDataSender


Constructor Summary
XChangeExporter()
           
 
Method Summary
 void addBinary(java.lang.String id, byte[] contents)
          Add a binary content to the Container
 ContactElement addContact(Kontakt k)
          Add a new Contact to the file.
 ContactElement addPatient(Patient pat)
          Add a Patient to the Container.This will as well export the medical history of the patient and ist thus the starting point for exporting the EMR.
 boolean canHandle(java.lang.Class<? extends PersistentObject> clazz)
          Ask if this IDataSender can handle a certain type
 XChangeContainer getContainer()
           
 Document getDocument()
           
 Element getRoot()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ch.elexis.exchange.IDataSender
finalizeExport, store
 

Constructor Detail

XChangeExporter

public XChangeExporter()
Method Detail

canHandle

public boolean canHandle(java.lang.Class<? extends PersistentObject> clazz)
Description copied from interface: IDataSender
Ask if this IDataSender can handle a certain type

Specified by:
canHandle in interface IDataSender
Parameters:
clazz - the class in question
Returns:
true if it can handle objects of that class.

getRoot

public Element getRoot()

getDocument

public Document getDocument()

getContainer

public XChangeContainer getContainer()

addContact

public ContactElement addContact(Kontakt k)
Add a new Contact to the file. It will only be added, if it does not yet exist. Rule for the created ID: If a Contact has a really unique ID (EAN, Unique Patient Identifier) then this shold be used. Otherwise a unique id should be generated (here we take the existing id from Elexis which is by definition already a UUID)

Parameters:
k - the contact to insert
Returns:
the Element node of the newly inserted (or earlier inserted) contact

addPatient

public ContactElement addPatient(Patient pat)
Add a Patient to the Container.This will as well export the medical history of the patient and ist thus the starting point for exporting the EMR.

Parameters:
pat - the Patient to export
Returns:
the ContactElement that was created from the Patient (containing the Medical-Element)

addBinary

public void addBinary(java.lang.String id,
                      byte[] contents)
Add a binary content to the Container

Parameters:
id - a unique identifier for the content
contents - the content

Elexis API documentation
Version 2.1.6 as of December 11 2011

Copyright 2005-2011 by Gerry Weirich, Elexis