lib/lifen_fhir.rb in lifen_fhir-0.4.1 vs lib/lifen_fhir.rb in lifen_fhir-0.4.2
- old
+ new
@@ -3,20 +3,33 @@
require 'virtus'
require 'faraday'
require 'inflecto'
require 'base64'
+ class Recipient < Virtus::Attribute
+ def coerce(value)
+ (value.is_a?(Practitioner) or value.is_a?(Patient) or value.nil?) ? value : raise(Error)
+ end
+ end
+
+ class Sender < Virtus::Attribute
+ def coerce(value)
+ (value.is_a?(Practitioner) or value.nil?) ? value : raise(Error)
+ end
+ end
+
require "lifen_fhir/version"
require 'lifen_fhir/error'
require 'lifen_fhir/client'
require 'lifen_fhir/user_authenticated_client'
require 'lifen_fhir/app_authenticated_client'
require 'lifen_fhir/configuration'
require 'lifen_fhir/base'
+ require 'lifen_fhir/element'
- require 'lifen_fhir/reference'
require 'lifen_fhir/address'
+ require 'lifen_fhir/telecom'
require 'lifen_fhir/channel'
require 'lifen_fhir/practitioner'
require 'lifen_fhir/category'
require 'lifen_fhir/medium'
require 'lifen_fhir/attachment'