Logo: Department of HealthLogo: Pharmaceutical Benefits SchemeRendering Specification
PBS XML Schema Version 3.1.9

The PBS XML includes a structured representation of restriction text. In order to present a restriction to the user it is necessary to render the structured representation into a readable form. This document provides a specification on how to render a structured restriction into a human-readable form.

A reference implementation of this specification is provided in the PBS Software distribution in the file render.xsl. The software is available from the PBS Developers' website.

Restrictions are often displayed individually. However, in some situations a group of restrictions may be displayed together, for example in the PDF view of the Schedule. This rendering specification will provide instructions for both of these situations.

Introduction

A restriction is comprised of the following components:

  • administrative advice

  • foreword

  • caution

  • definition

  • prescriber instruction

  • indication

    • condition

    • episodicity

    • severity

  • treatment phase

  • criteria

    • population

    • clinical

    • treatment

  • parameter

    • location

    • care-type

    • prescriber

    • age

    • sex

    • other

    • condition-parameter

    • treatment-parameter

    • patient

administrative-advice, caution and foreword are all informational components. All of the other components are legal components.

Views

Three different views of a restriction are required. These are detailed below.

View

Description

Structural

Includes all components. Each component includes an indication of its type.

Schedule

Includes all components. Display of component type is not included.

Legal Instrument

Includes only legal components. Does not include informational components. Display of component type is not included.

Display

The restriction components are rendered as blocks (i.e. vertical down the page) in the following order:


indication
treatment phase
parameter
definition
prescriber instruction
foreword
administrative advice
caution
    

If the component contains formatted text then the formatted text is included as-is, otherwise the component is rendered as a paragraph.

The following components have sub-components that are rendered as phrases (i.e. horizontal across the page) separated by a space in the following order:

Component

Sub-components

indication

episodicity severity condition “.”

In addition, components administrative-advice, foreword, definition and prescriber-instruction are preceded by the title “Note”.

The caution component is preceded by the title “Caution”.

Grouping

If a group of restrictions are being rendered in a single display (e.g. in the PDF view of the Schedule) then the restriction components are rendered as blocks in the following order:

Repeat

Components

foreword

(distinct)

administrative-advice

(repeated)

definition

(distinct)

prescriber-instruction

(repeated)

caution

(repeated)

*

indication

*

treatment-phase

*

parameter

*

prescriber-instruction

(individual)

*

administrative-advice

(individual)

*

caution

(individual)

The components marked “*” are repeated for each restriction.

foreword and definition components from each restriction are displayed once, in the position indicated above. Duplicate components are only display once.

If more than one restriction includes the same administrative advice, prescriber instruction or caution then the component is displayed once in the position indicated with the qualifier “(repeated)”. If a component is included only once in a particular restriction then that component is displayed in the indicated position with that restriction.

Logical Operators

Where a restriction has two or more criteria or a criteria has two or more parameters then the logical operator determines the rendering of the contained components:

Operator

Rendering Instructions

all

Each sub-component is a block with spacing before and after.

Sub-components are indented on their left margin.

Every sub-component except the last has the suffix “; and” appended to the content. The last sub-component has the suffix “.” appended to the content.

any

If the sub-components are parameters then a block is inserted with the content “At least one of the following:”.

Each sub-component is a block with spacing before and after.

Sub-components are indented on their left margin.

If the sub-components are parameters, then every sub-component except the last has the suffix “; or” appended to the content. The last sub-component has the suffix “.” appended to the content.

one-of

A block is inserted with the content “Only one of the following:”.

After the above content each sub-component is a block with spacing before and after.

Sub-components are indented on their left margin.

Every sub-component except the last has the suffix “; or” appended to the content. The last sub-component has the suffix “.” appended to the content.

Case

The Legal Instrument view always uses lowercase for boilerplate text.

Boilerplate text used to separate criteria uses uppercase text.

Boilerplate text used to separate parameters uses lowercase text.

Punctuation

Restriction components should not contain punctuation at the end of their final paragraph. This is so that the appropriate punctuation can be added depending on the context in which the component appears.

Component Types

In the Structural View, each component that is displayed as a block is preceded by a title that contains the type of the component. Components that are displayed as a phrase MAY be have a background colour to assist in distinguishing the sub-components.

Formatted Text

A restriction component may either contain plain text or formatted text. Formatted text includes block-level sub-components such as paragraphs, bullet lists, numbered lists, tables and sections. These sub-components are rendered as follows:

Sub-component

Rendering Instructions

Paragraph

Block with spacing before and after.

Bullet list

Each list item is a block with spacing before and after. For the LI view, no bullet image is displayed at the start of the line. For the Schedule and Structural view a bullet image is displayed.

All list items except the last have the suffix “; or” appended to the content. The last list item has the suffix “.” appended to the content.

Numbered list

Each list item is a block with spacing before and after. The content of the list item is prefixed with a “(“, number and “)”. The prefixed text is in a hanging indent.

Numbered lists may be nested. Each nesting level uses a different numbering format as follows: 1 (Arabic), a (lowercase alphabetic), i (lowercase Roman).

All list items except the last have the suffix “; and” appended to the content. The last list item has the suffix “.” appended to the content.

Table

The table fills the available width of the block. Every cell has a border on all sides.