Nwidart\Modules\Support\Migrations\NameParser::getPattern PHP Method

getPattern() public method

Get name pattern.
public getPattern ( ) : string
return string
    public function getPattern()
    {
        switch ($action = $this->getAction()) {
            case 'add':
            case 'append':
            case 'update':
            case 'insert':
                return "/{$action}_(.*)_to_(.*)_table/";
                break;
            case 'delete':
            case 'remove':
            case 'alter':
                return "/{$action}_(.*)_from_(.*)_table/";
                break;
            default:
                return "/{$action}_(.*)_table/";
                break;
        }
    }