Skip to content

Commit

Permalink
Signed-off-by: Katsuki Shuto <stk2k@sazysoft.com>
Browse files Browse the repository at this point in the history
  • Loading branch information
stk2k committed Jun 5, 2021
1 parent 3774674 commit 879c350
Show file tree
Hide file tree
Showing 26 changed files with 111 additions and 52 deletions.
7 changes: 6 additions & 1 deletion composer.json
Expand Up @@ -20,7 +20,12 @@
},
"autoload": {
"psr-4": {
"Stk2k\\Util\\": "src/"
"stk2k\\Util\\": "src/"
}
},
"autoload-dev": {
"psr-4": {
"stk2k\\Util\\Test\\": "test/"
}
}
}
4 changes: 3 additions & 1 deletion src/EqualableInterface.php
@@ -1,5 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

interface EqualableInterface
{
Expand Down
2 changes: 1 addition & 1 deletion src/Exception/MacroHandlerException.php
@@ -1,7 +1,7 @@
<?php
declare(strict_types=1);

namespace Stk2k\Util\Exception;
namespace stk2k\Util\Exception;

use Throwable;
use Exception;
Expand Down
4 changes: 2 additions & 2 deletions src/Exception/UtilExceptionInterface.php
@@ -1,7 +1,7 @@
<?php
namespace Stk2k\Util\Exception;
declare(strict_types=1);

use Calgamo\Exception\CalgamoExceptionInterface;
namespace stk2k\Util\Exception;

interface UtilExceptionInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/CombinedMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

final class CombinedMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/CookieMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class CookieMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/DateMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class DateMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/EnvMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class EnvMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/GetMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class GetMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/PostMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class PostMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/RequestMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class RequestMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/ServerMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class ServerMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/SessionMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class SessionMacroHandler implements MacroHandlerInterface
{
Expand Down
6 changes: 4 additions & 2 deletions src/Handler/SystemMacroHandler.php
@@ -1,7 +1,9 @@
<?php
namespace Stk2k\Util\Handler;
declare(strict_types=1);

use Stk2k\Util\MacroHandlerInterface;
namespace stk2k\Util\Handler;

use stk2k\Util\MacroHandlerInterface;

class SystemMacroHandler implements MacroHandlerInterface
{
Expand Down
4 changes: 3 additions & 1 deletion src/HashableInterface.php
@@ -1,5 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

interface HashableInterface
{
Expand Down
3 changes: 2 additions & 1 deletion src/MacroHandlerInterface.php
@@ -1,6 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

interface MacroHandlerInterface
{
Expand Down
26 changes: 14 additions & 12 deletions src/MacroProcessor.php
@@ -1,17 +1,19 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

use Stk2k\Util\Exception\MacroHandlerException;
use Stk2k\Util\Handler\SystemMacroHandler;
use Stk2k\Util\Handler\DateMacroHandler;
use Stk2k\Util\Handler\ServerMacroHandler;
use Stk2k\Util\Handler\EnvMacroHandler;
use Stk2k\Util\Handler\CookieMacroHandler;
use Stk2k\Util\Handler\SessionMacroHandler;
use Stk2k\Util\Handler\GetMacroHandler;
use Stk2k\Util\Handler\PostMacroHandler;
use Stk2k\Util\Handler\RequestMacroHandler;
use Stk2k\Util\Enum\EnumMacroHandler;
namespace stk2k\Util;

use stk2k\Util\Exception\MacroHandlerException;
use stk2k\Util\Handler\SystemMacroHandler;
use stk2k\Util\Handler\DateMacroHandler;
use stk2k\Util\Handler\ServerMacroHandler;
use stk2k\Util\Handler\EnvMacroHandler;
use stk2k\Util\Handler\CookieMacroHandler;
use stk2k\Util\Handler\SessionMacroHandler;
use stk2k\Util\Handler\GetMacroHandler;
use stk2k\Util\Handler\PostMacroHandler;
use stk2k\Util\Handler\RequestMacroHandler;
use stk2k\Util\Enum\EnumMacroHandler;

class MacroProcessor
{
Expand Down
6 changes: 4 additions & 2 deletions src/MemoryUtil.php
@@ -1,9 +1,11 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

use InvalidArgumentException;

use Stk2k\Util\Enum\EnumMemoryUnit as EnumMemoryUnit;
use stk2k\Util\Enum\EnumMemoryUnit as EnumMemoryUnit;

/**
* Utility class of memory calculations
Expand Down
4 changes: 3 additions & 1 deletion src/StringUtil.php
@@ -1,5 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

final class StringUtil
{
Expand Down
4 changes: 3 additions & 1 deletion src/Util.php
@@ -1,5 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util;

use Throwable;
use Traversable;
Expand Down
8 changes: 6 additions & 2 deletions test/DateMacroHandlerTest.php
@@ -1,8 +1,12 @@
<?php
declare(strict_types=1);

namespace stk2k\Util\Test;


use PHPUnit\Framework\TestCase;
use Stk2k\Util\MacroProcessor;
use Stk2k\Util\Enum\EnumMacroHandler;
use stk2k\Util\MacroProcessor;
use stk2k\Util\Enum\EnumMacroHandler;

class DateMacroHandlerTest extends TestCase
{
Expand Down
6 changes: 5 additions & 1 deletion test/MacroProcessorTest.php
@@ -1,7 +1,11 @@
<?php
declare(strict_types=1);

namespace stk2k\Util\Test;


use PHPUnit\Framework\TestCase;
use Stk2k\Util\MacroProcessor;
use stk2k\Util\MacroProcessor;

class MacroProcessorTest extends TestCase
{
Expand Down
8 changes: 6 additions & 2 deletions test/ServerMacroHandlerTest.php
@@ -1,8 +1,12 @@
<?php
declare(strict_types=1);

namespace stk2k\Util\Test;


use PHPUnit\Framework\TestCase;
use Stk2k\Util\MacroProcessor;
use Stk2k\Util\Enum\EnumMacroHandler;
use stk2k\Util\MacroProcessor;
use stk2k\Util\Enum\EnumMacroHandler;

class ServerMacroHandlerTest extends TestCase
{
Expand Down
5 changes: 4 additions & 1 deletion test/StringUtilTest.php
@@ -1,7 +1,10 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util\Test;

use PHPUnit\Framework\TestCase;
use stk2k\Util\StringUtil;

class StringUtilTest extends TestCase
{
Expand Down
8 changes: 6 additions & 2 deletions test/SystemMacroHandlerTest.php
@@ -1,8 +1,12 @@
<?php
declare(strict_types=1);

namespace stk2k\Util\Test;


use PHPUnit\Framework\TestCase;
use Stk2k\Util\MacroProcessor;
use Stk2k\Util\Enum\EnumMacroHandler;
use stk2k\Util\MacroProcessor;
use stk2k\Util\Enum\EnumMacroHandler;

class SystemMacroHandlerTest extends TestCase
{
Expand Down
4 changes: 3 additions & 1 deletion test/UtilTest.php
@@ -1,5 +1,7 @@
<?php
namespace Stk2k\Util;
declare(strict_types=1);

namespace stk2k\Util\Test;

use Exception;
use Throwable;
Expand Down

0 comments on commit 879c350

Please sign in to comment.