org.eclipse.ohf.ihe.xds.source
Class Source

java.lang.Object
  extended by org.eclipse.ohf.ihe.xds.source.Source

public class Source
extends java.lang.Object

OHF Source Actor implementation of the IHE XDS Source Actor provides a utility class for composing and submitting IHE XDS Provide and Register Document Set transactions to the IHE XDS Repository. This is described in the IHE ITI-15 transaction.

Externally (and initially) this actor interacts with two services:

  1. The IHE XDS Repository is used to submit submissions to
  2. The IHE ATNA Auditor service is used to write IHE ATNA audit records to.
The ultimate purpose of this class is to submit a Provide and Register Document Set transaction to the repository. This is done by encoding the transaction as an ebXML document, with the following sets of data (see SubmitTransactionData for more information):

  1. A set of metdadata about the transaction - referred to as the SubmissionSet
  2. A set of metadata about each document in the transction. This a collection of the data from DocumentEntryType objects - one for each document.
  3. The documents to be submitted imbedded as MIME entities
  4. A set of metadata about XDS Folders. This is a collection of the data from FolderType objects - one for each folder

Classes using this class, should interact with it as follows:

  1. Create a new transaction data instance (see SubmitTransactionData) (note: per IHE XDS - a transaction can hold 0 or more documents, and ALL documents must belong to the same patient)
  2. Invoke submit() to perform the submission to the XDS Repository Actor.

Since:
OHF v0.0
Author:
Glenn Deen , Sarah Knoop
See Also:
IHE Technical Framework

Constructor Summary
Source(java.lang.String repositoryURL)
          Constructor
Source(java.lang.String repositoryURL, boolean doAudit)
          Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors
Source(java.net.URI uri)
          Constructor
Source(java.net.URI uri, boolean doAudit)
          Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors
 
Method Summary
 java.net.URI getRepositoryURI()
           
 java.lang.String getRepositoryURL()
           
 boolean isDoAudit()
           
 void setDoAudit(boolean doAudit)
          Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors
 void setRepositoryURI(java.net.URI repositoryURI)
          Sets the the URI of the repository
 void setRepositoryURL(java.lang.String repositoryURL)
          Sets the string url to be the URI of the repository
 void submit(SubmitTransactionData txnData, java.lang.String initiatingUser)
          Submits the Provide and Register Document Set transaction to the XDS Repository Actor.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Source

public Source(java.lang.String repositoryURL,
              boolean doAudit)
Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors

Constructor

Parameters:
repositoryURL - the string URL for the repository to submit to.
doAudit - whether to enable or disable auditing for the source actor

Source

public Source(java.lang.String repositoryURL)
Constructor

Parameters:
repositoryURL - the string URL for the repository to submit to.

Source

public Source(java.net.URI uri,
              boolean doAudit)
Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors

Constructor

Parameters:
repositoryURI - the URI for the repository to submit to.
doAudit - whether to enable or disable auditing for the source actor

Source

public Source(java.net.URI uri)
Constructor

Parameters:
repositoryURI - the URI for the repository to submit to.
Method Detail

isDoAudit

public boolean isDoAudit()
Returns:
the doAudit

setDoAudit

public void setDoAudit(boolean doAudit)
Deprecated. use AtnaAgentFactory.getAtnaAgent().setDoAudit(doAudit) to turn auditing on and off for all your actors

Parameters:
doAudit - the doAudit to set

getRepositoryURL

public java.lang.String getRepositoryURL()
Returns:
Returns the repositoryURI as a url string

setRepositoryURL

public void setRepositoryURL(java.lang.String repositoryURL)
Sets the string url to be the URI of the repository

Parameters:
repositoryURL - The repositoryURL to set.

getRepositoryURI

public java.net.URI getRepositoryURI()
Returns:
Returns the repositoryURI

setRepositoryURI

public void setRepositoryURI(java.net.URI repositoryURI)
Sets the the URI of the repository

Parameters:
repositoryURL - The URI to set.

submit

public void submit(SubmitTransactionData txnData,
                   java.lang.String initiatingUser)
            throws java.lang.Exception
Submits the Provide and Register Document Set transaction to the XDS Repository Actor.
Errors from the Repository are returned in a thrown exception.

Notes:

    Parameters:
    txnData - transaction payload data: XDS metadata and corresponding documents
    initiatingUser - initiating user for auditing purposes
    Throws:
    java.lang.Exception - If the transaction failed to complete