PHP mappings for Redox Engine
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bin
generator
samples/patientadmin
src
tests
.gitignore
.travis.yml
CHANGELOG.md
LICENSE
README.md
composer.json
phpunit.xml.dist

README.md

Redox for PHP

Latest Stable Version License Build Status Code Coverage Scrutinizer Code Quality

PHP mappings for Redox Engine. Attempts to be PSR-1, PSR-2, and PSR-4 compliant.

DEPRECATED AND WILL EVENTUALLY BE DELETED. We have decided to take a Tolerant Reader approach instead of using code generation.

Installation

composer require rwos/redox

Usage

use RoundingWell\Redox\PushMessage;

// Using a file path
$push = PushMessage::fromFile($path);

// Using a JSON string
$push = PushMessage::fromString($json);

// Using decoded JSON data
$push = PushMessage::fromObject($data);

Once created, the entire Redox document structure will be available:

$patientFirstName = $push->Header->Patient->Demographics->FirstName;

foreach ($push->Allergies as $allergy) {
    echo "$patientFirstName is allergic to ", $allergy->Substance->Name, "\n";
}

Refer the Redox data models for a complete reference of available fields.