Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rahulsom/muval
NIST's Meaningful Use Validator tweaked for programmatic usage
https://github.com/rahulsom/muval
ccd healthcare meaningful-use nist
Last synced: about 1 month ago
JSON representation
NIST's Meaningful Use Validator tweaked for programmatic usage
- Host: GitHub
- URL: https://github.com/rahulsom/muval
- Owner: rahulsom
- License: apache-2.0
- Created: 2016-03-06T05:55:16.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2024-10-02T06:25:37.000Z (3 months ago)
- Last Synced: 2024-10-08T08:46:28.374Z (3 months ago)
- Topics: ccd, healthcare, meaningful-use, nist
- Language: Java
- Homepage:
- Size: 1.55 MB
- Stars: 1
- Watchers: 3
- Forks: 2
- Open Issues: 3
-
Metadata Files:
- Readme: README.adoc
- Changelog: changelog.txt
- License: LICENSE
Awesome Lists containing this project
README
= muval
Meaningful Use Validator based on NIST's own.
== Introduction
NIST's Meaningful Use Validator is great to check if your CCDs are valid.
However it runs as as a Command Line Utility that outputs XML.
If you want to make validation part of your unit tests, you need it to be callable from code.
This project aims to do just that.
NIST made its code available http://cda-validation.nist.gov/cda-validation/downloads.html[here].
Also they consider their code to be public domain.
That makes it possible for this project to exist.
I am thankful for that.== Usage
This supports the legacy CLI usage as well as programmatic usage
=== CLI Usage
Download the jar from http://oss.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.github.rahulsom&a=muval&v=LATEST&c=all[here]
Then use it
[source,bash]
----
java -jar muval-all.jar -input sampleCCD.xml -output result.xml
----=== Programmatic usage
Import the dependency using maven, gradle, sbt, leingen or ivy.
Example below is for gradle.
Look up instructions for your build tool from this badge.image:https://maven-badges.herokuapp.com/maven-central/com.github.rahulsom/muval/badge.svg[link=https://maven-badges.herokuapp.com/maven-central/com.github.rahulsom/muval]
image:https://img.shields.io/github/commits-since/rahulsom/muval/latest[GitHub commits since latest release (by date) for a branch][source,gradle]
----
dependencies {
// ...
compile 'com.github.rahulsom:muval:'
}
----Then use it in your code. This example is a Spock Specification. You could use it in test or production code.
[source,groovy]
----
import spock.lang.Specificationimport static gov.nist.mu.validation.Rulesets.*
import static gov.nist.mu.validation.Validator.validateclass MyCcdSpec extends Specification {
private InputStream file(String resourceName) {
this.class.getClassLoader().getResourceAsStream(resourceName)
}def "sample ccd should validate"() {
when: "I validate a CCD"
def result = validate(Cdar2c32, file('SampleCCDDocument.xml'), Ccd, Cda4Cdt, C32_v_2_5_c83_2_0)then: "There are 50 errors and 98 issues"
result.allIssues.size() == 98
result.errors.size() == 50
result.otherIssues.isEmpty()
}}
----== Updating Schema and Schematron files
The `downloadResources` task will do the job. You need to delete the `nist` directory before that.
[source,bash]
----
./gradlew downloadResources
----If you run into network problems, you may rerun that command.
== Contributing
Please feel free to raise Issues with test cases or send Pull Requests. This uses the github issue tracker.