Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Make a string's first character uppercase
<?php ucfirst(string $string): string
<?php return $this->callCustomCreator($name, $config);
}
$driverMethod = 'create'.ucfirst($config['driver']).'Driver';
if (method_exists($this, $driverMethod)) {
return $this->{$driverMethod}($name, $config);
<?php return $this->callCustomCreator($config);
}
$driverMethod = 'create'.ucfirst($config['driver']).'Driver';
if (! method_exists($this, $driverMethod)) {
throw new InvalidArgumentException("Driver [{$config['driver']}] is not supported.");
<?php return $this->callCustomCreator($config);
}
$driverMethod = 'create'.ucfirst($config['driver']).'Driver';
if (method_exists($this, $driverMethod)) {
return $this->{$driverMethod}($config);
<?php public function __call($method, $parameters)
{
$component = '\Illuminate\Console\View\Components\\'.ucfirst($method);
throw_unless(class_exists($component), new InvalidArgumentException(sprintf(
'Console component [%s] not found.', $method
<?php public function commandArguments(array $connection)
{
$driver = ucfirst($connection['driver']);
return $this->{"get{$driver}Arguments"}($connection);
}
<?php public function commandEnvironment(array $connection)
{
$driver = ucfirst($connection['driver']);
if (method_exists($this, "get{$driver}Environment")) {
return $this->{"get{$driver}Environment"}($connection);
<?php public function broadcastAs()
{
$default = class_basename($this->model).ucfirst($this->event);
return method_exists($this->model, 'broadcastAs')
? ($this->model->broadcastAs($this->event) ?: $default)
<?php public function hasNamedScope($scope)
{
return method_exists($this, 'scope'.ucfirst($scope));
}
<?php public function callNamedScope($scope, array $parameters = [])
{
return $this->{'scope'.ucfirst($scope)}(...$parameters);
}
<?php foreach ($this->selectComponents as $component) {
if (isset($query->$component)) {
$method = 'compile'.ucfirst($component);
$sql[$component] = $this->$method($query, $query->$component);
}
<?php continue;
}
$method = 'compile'.ucfirst($command->name);
if (method_exists($grammar, $method) || $grammar::hasMacro($method)) {
if (! is_null($sql = $grammar->$method($this, $command, $connection))) {
<?php elseif ($column->{$index} === false && $column->change) {
$this->{'drop'.ucfirst($index)}([$column->name]);
$column->{$index} = null;
continue 2;
<?php protected function getType(Fluent $column)
{
return $this->{'type'.ucfirst($column->type)}($column);
}
<?php ]))->partition(fn ($index) => $index->name === 'primary');
$indexes = collect($indexes)->reject(fn ($index) => str_starts_with('sqlite_', $index->index))->map(
fn ($index) => $this->{'compile'.ucfirst($index->name)}($blueprint, $index)
)->all();
$tempTable = $this->wrap('__temp__'.$blueprint->getPrefix().$table);
<?php return $this->callCustomCreator($config);
}
$driverMethod = 'create'.ucfirst($name).'Driver';
if (! method_exists($this, $driverMethod)) {
throw new InvalidArgumentException("Driver [{$name}] is not supported.");