Adds support for the ZEF segment to ruby-hl7
Add this line to your application's Gemfile:
gem 'ruby-hl7-zef'
And then execute:
$ bundle
Or install it yourself as:
$ gem install ruby-hl7-zef
require 'base64'
msg = HL7::Message.parse(hl7_with_zef)
Array(msg[:ZEF]).each_with_index do |zef, i|
File.write("zef-#{i}.pdf", Base64.decode64(zef.embedded_pdf))
end
- Fork it ( https://github.com/[my-github-username]/ruby-hl7-zef/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request