object-spy/src/Example.php

38 lines
1 KiB
PHP
Raw Normal View History

<?php
/**
* This file is part of danjones000/object-spy
*
* danjones000/object-spy is open source software: you can distribute
* it and/or modify it under the terms of the MIT License
* (the "License"). You may not use this file except in
* compliance with the License.
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
* implied. See the License for the specific language governing
* permissions and limitations under the License.
*
* @copyright Copyright (c) Dan Jones <danjones@goodevilgenius.org>
* @license https://opensource.org/licenses/MIT MIT License
*/
declare(strict_types=1);
namespace Danjones000\Spy;
/**
* An example class to act as a starting point for developing your library
*/
class Example
{
/**
* Returns a greeting statement using the provided name
*/
public function greet(string $name = 'World'): string
{
return "Hello, {$name}!";
}
}