Parse the migration name into something we can use.

@param  string $name
@return array
188230
public function parse($name)
    {
        $segments = array_reverse(explode('_', $name));

        if ($segments[0] == 'table') {
            array_shift($segments);
        }

        return [
            'action' => $this->getAction($segments),
            'table' => $this->getTableName($segments)
        ];
    }
525549
private function parse_name($name) {
        $bits = explode('/', $name);
        $name = array_pop($bits);
        $plugin = '';
        if ($bits) {
            $plugin = array_pop($bits);
            if ($plugin === 'moodle') {
                $plugin = '';
            }
        }
        return 's_'.$plugin.'_'.$name;
    }
1230244
public function getTableFieldMigrationName($name, $tableName)
    {
        return sprintf(
            MigrationBuilder::PATTERN_FIELD,
            ucfirst($name),
            ucfirst($tableName)
        );
    }
714739
public function parseName($name)
    {
        if(null !== $this->config->prefix)
        {
            return str_replace('@', $this->config->prefix, $name);
        }
        else
        {
            return $name;
        }
    }
978437
public function getFieldsByName( $name )
	{
		$name	= strtolower( $name );
		if( isset( $this->fields[$name] ) )
			return $this->fields[$name];
		return array();
	}
984382
protected function loadTypeExtensions($name)
    {
        $typeExtensions = [];

        $extensions = $this->getExtensions();
        foreach ($extensions as $extension) {
            if ($extension->hasTypeExtensions($name)) {
                $typeExtensions = array_merge($typeExtensions, $extension->getTypeExtensions($name));
            }
        }
        $this->typeExtensions[$name] = $typeExtensions;

        return $typeExtensions;
    }
1348680
public function getRowsMetadata($name)
    {
        $metadataValues = array();
        foreach ($this->getRows() as $row) {
            $metadataValues[] = $row->getMetadata($name);
        }
        return $metadataValues;
    }
395430
public function parseTable($name): array
    {
        if ($name instanceof Model) {
            return [$name->alias(), $name->name()];
        }

        if (is_array($name)) {
            return [key($name), current($name)];
        }

        if (is_scalar($name)) {
            return static::parseName($name);
        }

        return [null, $name];
    }
918589
public function name($name)
    {
        $prefix = !is_null($this->associatedEntity) && $this->associatedEntity->isSupportedAttribute($name) ?
            $this->keys['POST_WRAP'] . '[' . $this->associatedEntity->getInputName() . ']' :
            $this->keys['POST_WRAP'];

        // Transforms user[name] to data[user][name];
        if (preg_match('/^(.+?)\[(.+)?/', $name, $matches)) {
            return $prefix . '[' . $matches[1].'][' . $matches[2];
        }

        // Transforms user to data[user]
        return $prefix . '[' . $name . ']';
    }
1117985
protected function getConfig(string $name): array
    {
        if (isset($this->app['config']['self-update']['repository_types'][$name])) {
            return $this->app['config']['self-update']['repository_types'][$name];
        }

        return [];
    }
642024
protected function parseName($name = null)
    {
        if (!$name) {
            $name = $this->name;
        }

        return [
            '{{pluralCamel}}'   => str_plural(camel_case($name)),
            '{{pluralSlug}}'    => str_plural(str_slug($name)),
            '{{pluralSnake}}'   => str_plural(snake_case($name)),
            '{{pluralClass}}'   => str_plural(studly_case($name)),
            '{{singularCamel}}' => str_singular(camel_case($name)),
            '{{singularSlug}}'  => str_singular(str_slug($name)),
            '{{singularSnake}}' => str_singular(snake_case($name)),
            '{{singularClass}}' => str_singular(studly_case($name)),
            '{{namespace}}'     => $this->getNamespace(),
        ];
    }
244878
protected function getGroup(string $name): array
    {
        if (!$this->container->has('config_'.$name)) {
            $this->loadGroup($name);
        }

        return $this->container->get('config_'.$name);
    }
1028128
protected function getPath($name)
    {
        $name = str_replace($this->laravel->getNamespace(), '', $name);
        $datePrefix = date('Y_m_d_His');

        return database_path('/migrations/') . $datePrefix . '_create_' . $name . '_table.php';
    }
135481
protected function parseName($name)
    {
        if (str_contains($name, '\\')) {
            $name = str_replace('\\', '/', $name);
        }

        if (str_contains($name, '/')) {
            $formats = collect(explode('/', $name))->map(function ($name)
            {
                return Str::studly($name);
            });

            $name = $formats->implode('/');
        } else {
            $name = Str::studly($name);
        }

        return $name;
    }
442652
public function getArray($name)
    {
        return isset($this->arguments[$name]) ? $this->arguments[$name]->values() : [];
    }
939882
protected function parseName($name)
    {
        $this->checkNamespace();

        $rootNamespace = $this->getPackageNamespace();

        if (Str::startsWith($name, $rootNamespace)) {
            return $name;
        }

        if (Str::contains($name, '/')) {
            $name = str_replace('/', '\\', $name);
        }

        return $this->parseName($this->getDefaultNamespace(trim($rootNamespace, '\\')).'\\'.$name);
    }
1155589
private function parseReferences($name): string
    {
        if (preg_match_all('/\$\{(.*[a-z\.0-9])\}/si', $name, $results, PREG_SET_ORDER)) {
            foreach ($results as $match) {
                $replace = $match[0];
                $key = $match[1];

                // Handle using relative placement like get('db.${.default}.host');
                if (strpos($key, '.') === 0) {
                    // using relative placement
                    $key = substr($name, 0, strpos($name, $replace) - 1) . $key;
                }

                // get the value
                $value = $this->get($key);
                if ($value === null || $value === '' || $value === false) {
                    throw new InvalidArgumentException(
                        $key . ' replacement for ' . $name . ' must not be null or empty'
                    );
                }

                $name = str_replace($replace, $value, $name);
            }
        }

        return $name;
    }