CDAKCodedEntries
public struct CDAKCodedEntries: CustomStringConvertible, SequenceType, CollectionType, Equatable, Hashable
                Represents a collection of vocabulary concepts for an entry.
- Spans multiple vocabularies
 - For a single vocabulary, can have multiple vocabulary codes
 
Example:
- LOINC
- LOINC | 2.16.840.1.113883.6.1 | 8302-2 | Patient Body Height
 
 - SNOMED-CT
- SNOMED | 2.16.840.1.113883.6.96 | 50373000 | Body Height
 
 
- 
                  
                  
Subscript to return all coded entries based on vocabulary key/tag
Declaration
Swift
public subscript(codeSystem: String) -> [CDAKCodedEntry]? - 
                  
                  
provides access to coded entries by vocabulary key/tag
Declaration
Swift
public subscript(_i: Index) -> _Element {get { return entries[_i] }} - 
                  
                  
Undocumented
Declaration
Swift
public struct CDAKCodedEntries: CustomStringConvertible, SequenceType, CollectionType, Equatable, Hashable - 
                  
                  
Undocumented
Declaration
Swift
public struct CDAKCodedEntries: CustomStringConvertible, SequenceType, CollectionType, Equatable, Hashable - 
                  
                  
Undocumented
Declaration
Swift
public struct CDAKCodedEntries: CustomStringConvertible, SequenceType, CollectionType, Equatable, Hashable - 
                  
                  
first entry
Declaration
Swift
public var first: _Element? { get {return entries.first} } - 
                  
                  
number of entries
Declaration
Swift
public var count: Int { get {return entries.count} } - 
                  
                  
vocabulary system keys/tags
Declaration
Swift
public var keys: [String] { return codeSystems } - 
                  
                  
All vocabulary code system keys/tags used in current entries
Declaration
Swift
public var codeSystems: [String] - 
                  
                  
Returns all entries across all vocabularies
Declaration
Swift
public var codes: [CDAKCodedEntry] - 
                  
                  
If you need to manage the notion of preferred codes or translation codes at the code level (as opposed to the entry level), then you can do so by supplying a list of code system keys/tags as Strings. EX:
LOINC
,SNOMED-CT
. These will then bepreferred
code systems.Declaration
Swift
public var preferred_code_sets: [String] = [] - 
                  
                  
If you have supplied preferred code sets, you can then export the first matching preferred term for that set of code sets
Declaration
Swift
public var preferred_code: CDAKCodedEntry? - 
                  
                  
If you have supplied preferred code sets, you can emit the list of translation codes for the entry
Declaration
Swift
public var translation_codes: [CDAKCodedEntry] 
- 
                  
                  
Basic initializer
Declaration
Swift
public init(){} - 
                  
                  
Basic initializer
Declaration
Swift
public init(codeSystem:String, code: String, codeSystemOid: String? = nil, displayName: String? = nil)Parameters
codeSystemthe vocabulary key/tag. EX:
SNOMED-CT
codethe vocabulary concept code
codeSystemOidthe OID associated with the vocabulary. If it is not supplied, the OID will be looked up based on the supplied vocabulary codeSystem
displayNamethe human-readable concept description
 - 
                  
                  
Basic initializer
Declaration
Swift
public init(entries: [CDAKCodedEntry])Parameters
entriesAccepts an array of coded entries
 - 
                  
                  
Basic initializer
Declaration
Swift
public init(entry: CDAKCodedEntry?)Parameters
entryAccepts an optional coded entry
 - 
                  
                  
Add a code to the vocabulary collection - parameter entries: an array of coded entries
Declaration
Swift
mutating public func addCodes(entries: [CDAKCodedEntry])Parameters
entriesan array of coded entries
 - 
                  
                  
Add a code to the vocabulary collection - parameter entries: an optional coded entry
Declaration
Swift
mutating public func addCodes(entry: CDAKCodedEntry?)Parameters
entriesan optional coded entry
 - 
                  
                  
Primary method to add a code to the vocabulary collection
If a code with the same vocabulary key/tag and code already exists and the new description is non-nil, this will overwrite the existing description with the new one.
Declaration
Swift
mutating public func addCodes(codeSystem: String, code: String, codeSystemOid: String? = nil, displayName: String? = nil)Parameters
codeSystemthe vocabulary key/tag. EX:
SNOMED-CT
codethe vocabulary concept code
codeSystemOidthe OID associated with the vocabulary. If it is not supplied, the OID will be looked up based on the supplied vocabulary codeSystem
displayNamethe human-readable concept description
 - 
                  
                  
Evaluates existing entries to determine if the supplied concept key/tag and code already exist in the entry collection
Declaration
Swift
public func containsCode(withCodeSystem codeSystem: String, andCode code: String) -> BoolParameters
withCodeSystem (codeSystem)the vocabulary key/tag. EX:
SNOMED-CT
andCode (code)the vocabulary concept code
 - 
                  
                  
Evaluates existing entries to determine if the supplied concept already exists in the entry collection
Declaration
Swift
public func containsCode(codedEntry: CDAKCodedEntry) -> BoolParameters
codedEntrythe concept you wish to compare against the existing entry collection
 - 
                  
                  
Searches all codeded entries for a match of the specified vocabulary and codes - parameter forCodeSystem: (String) key for code system. EX:
LOINC
- parameter matchingCodes: [String] array of strings for code values - returns: an array of CDAKCodedEntry containing the specified codeSystem:code(s)Declaration
Swift
public func findIntersectingCodedEntries(forCodeSystem codeSystem: String, matchingCodes codes:[String]) -> [CDAKCodedEntry]?Parameters
forCodeSystem(String) key for code system. EX:
LOINC
matchingCodes[String] array of strings for code values
Return Value
an array of CDAKCodedEntry containing the specified codeSystem:code(s)
 - 
                  
                  
Searches all codeded entries for a match of the specified vocabulary and codes - parameter forCodedEntries: Array of [CDAKCodedEntry] - returns: an array of CDAKCodedEntry containing the specified codeSystem:code(s)
Declaration
Swift
public func findIntersectingCodedEntries(forCodedEntries matching:[CDAKCodedEntry]?) -> [CDAKCodedEntry]?Parameters
forCodedEntriesArray of [CDAKCodedEntry]
Return Value
an array of CDAKCodedEntry containing the specified codeSystem:code(s)
 - 
                  
                  
Searches all codeded entries for a match of the specified vocabulary and codes - parameter forCodedEntries: CDAKCodedEntries - returns: an array of CDAKCodedEntry containing the specified codeSystem:code(s)
Declaration
Swift
public func findIntersectingCodedEntries(forCodedEntries ces:CDAKCodedEntries?) -> [CDAKCodedEntry]?Parameters
forCodedEntriesCDAKCodedEntries
Return Value
an array of CDAKCodedEntry containing the specified codeSystem:code(s)
 - 
                  
                  
Counts all distinct entries across all vocabularies. Where
countwould return the number of vocabulary keys/tags,numberOfDistinctCodesreturns the number of distinct codes.Declaration
Swift
public var numberOfDistinctCodes: Int 
- 
                  
                  
Debugging description
Declaration
Swift
public var description: String - 
                  
                  
hash value
Declaration
Swift
public var hashValue: Int 
- 
                  
                  
Undocumented
Declaration
Swift
public struct CDAKCodedEntries: CustomStringConvertible, SequenceType, CollectionType, Equatable, Hashable 
- 
                  
                  
Marshalles preferred_code and translation_codes so we can more easily reuse them in Mustache templates
Declaration
Swift
public var boxedPreferredAndTranslatedCodes: MustacheBox 
- 
                  
                  
Dictionary for JSON data
Declaration
Swift
public var jsonDict: [String: AnyObject] 
        CDAKCodedEntries Struct Reference