PatientNoteStore - apache/ctakes GitHub Wiki
Cache for multi-document patient cas objects
- Author: SPF , chip-nlp
- Version: %I%
-
Since: 9/26/2017
private
-
Parameters:
-
engineNamename of engine that consumes patients
-
-
Parameters:
-
namedEngineengine that consumes patients
-
- Deprecated
-
Returns: identifiers for all stored patients
-
Parameters:
-
patientId-
-
-
Returns: identifiers for all stored documents for the given patient
synchronized public Collection<String> getStoredViewNames( final String patientId, final String docId )
-
Parameters:
-
patientId- -
docId-
-
-
Returns: names for all stored views for the given patient and document
-
Returns: all completed patient identifiers in the cache
-
Parameters:
-
patientId-
-
-
Returns: number of documents for the patient that have been completed and stored in the cache
-
Parameters:
-
patientId-
-
-
Returns: number of documents that exist for the patient or -1 if unknown
-
Parameters:
-
patientId- -
countnumber of documents that exist for the patient
-
-
Returns: the default identifier for a view of the document's patient.
If it has been set in the document metadata then that is used,
otherwise it will come from the document's parent directory.
-
See also:
- SourceMetadataUtil#getPatientIdentifier(JCas)
- DocIdUtil#getDocumentIdPrefix(JCas)
- Returns: the default identifier for a view of the document.
-
See also: DocIdUtil#getDocumentID(JCas)
Store all views in the source cas. Patient Id and Document Id will be determined from the source cas.
-
Parameters:
-
sourceCassource (document) cas
-
synchronized public void storeAllViews( final String patientId, final String docId, final JCas sourceCas )
Store all views in the source cas.
-
Parameters:
-
patientId- -
docId- -
sourceCassource (document) cas
-
Store the primary view under some different name. Patient Id and Document Id will be determined from the source cas.
-
Parameters:
-
storeViewNamethe name to use to store the primary view -
sourceCassource (document) cas
-
synchronized public void storePrimaryAsView( final String patientId, final String docId, final String storeViewName, final JCas sourceCas )
Store the primary view under some different name.
-
Parameters:
-
patientId- -
docId- -
storeViewNamethe name to use to store the primary view -
sourceCassource (document) cas
-
Store some single view with its own name. Patient Id and Document Id will be determined from the source cas.
-
Parameters:
-
sourceViewNamethe name of the view in the source cas -
sourceCassource (document) cas
-
synchronized public void storeView( final String patientId, final String docId, final String sourceViewName, final JCas sourceCas )
Explicitly store some single view with its own name.
-
Parameters:
-
patientId- -
docId- -
sourceViewNamethe name of the view in the source cas -
sourceCassource (document) cas
-
synchronized public void storeView( final String patientId, final String docId, final String storeViewName, final String sourceViewName, final JCas sourceCas )
Explicitly store some single view under a different name.
-
Parameters:
-
patientId- -
docId- -
storeViewNamethe name to use to store the view -
sourceViewNamethe name of the view in the source cas -
sourceCassource (document) cas
-
Make sure the patient cas contains its patient id
-
Parameters:
-
jCas- -
patientId-
-
synchronized public JCas getStoredView( final String patientId, final String docId, final String viewName )
-
Parameters:
-
patientId- -
docId- -
viewName-
-
-
Returns: Stored view for the parameters
-
Parameters:
-
patientId- -
docId-
-
-
Returns: Map of ViewNames to Views
-
Parameters:
-
patientId-
-
-
Returns: Map of docIds to Map of ViewNames to Views
static public String getInternalViewname( final String patientId, final String docId, final String viewName )
-
Parameters:
-
patientId- Stored patient ID -
docId- Stored document ID -
viewName- View name in original document CAS
-
-
Returns: String representing view name in patient CAS
Use popPatientCas instead to automate cleanup
-
Parameters:
-
patientId-
-
-
Parameters:
-
engineNameengine requesting a completed patient jcas
-
-
Returns: a patient jcas or null if none is available for the given engine
-
Parameters:
-
engineNameengine requesting a completed patient jcas
-
-
Returns: a patient jcas or null if none is available for the given engine
-
Parameters:
-
patientId- -
engineNameengine requesting a completed patient jcas
-
-
Returns: the patient jcas for the patient id or null if it isn't available for the given engine
-
Parameters:
-
patientIdidentifier of patient to remove from cache
-
-
Parameters:
-
patientId-
-
-
Returns: all encoded
Used to map pid, docId, view names to views for each patient.