diff options
Diffstat (limited to 'vendor/gipfl/openrpc/src/License.php')
-rw-r--r-- | vendor/gipfl/openrpc/src/License.php | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/vendor/gipfl/openrpc/src/License.php b/vendor/gipfl/openrpc/src/License.php new file mode 100644 index 0000000..3bb8904 --- /dev/null +++ b/vendor/gipfl/openrpc/src/License.php @@ -0,0 +1,37 @@ +<?php + +namespace gipfl\OpenRpc; + +use JsonSerializable; + +/** + * License information for the exposed API. + */ +class License implements JsonSerializable +{ + use SimpleJsonSerializer; + + /** + * REQUIRED. The license name used for the API. + * + * @var string + */ + public $name; + + /** + * A URL to the license used for the API. MUST be in the format of a URL. + * + * @var string|null + */ + public $url; + + /** + * @param string $name + * @param string|null $url + */ + public function __construct($name, $url = null) + { + $this->name = $name; + $this->url = $url; + } +} |