class Exchange \ CurrencyOrder


In openclerk/exchanges, we want to return all exchange pairs according to a particular currency order. For example, we want all exchanges to return "USD/BTC" (USD for one BTC), rather than "BTC/USD" - this keeps business logic consistent in applications that use this component.

This class defines the intended order, and some helper methods for asserting that this order is used.

Currencies that are not defined in this class can appear in any order.


Method Summary

Name Description
hasOrder($c)
isOrdered($c1, $c2)

static function hasOrder($c)


static function isOrdered($c1, $c2)