Search
 
SCRIPT & CODE EXAMPLE
 

PHP

php multi type parameter php multi type parameter

#Union types have finally been implemented in PHP 8.0
class Number {
    private int|float $number;

    public function setNumber(int|float $number): void {
        $this->number = $number;
    }

    public function getNumber(): int|float {
        return $this->number;
    }
}
Comment

PREVIOUS NEXT
Code Example
Php :: mysql get the last id php 
Php :: Auth::routes(); why display error in route laravel 8 
Php :: laravel storage save file folder on disk 
Php :: mt_rand 
Php :: laravel hasfile 
Php :: php base64img to file 
Php :: ucfirst meaning in php 
Php :: php trim string to length 
Php :: laravel serve in another post 
Php :: what is directory_separator in php 
Php :: php hash password using bcrypt 
Php :: is users logged in laravel blade 
Php :: convert to int php 
Php :: laravel run a specific migration 
Php :: laravel RuntimeException Session store not set on request. 
Php :: php insert character into string 
Php :: php contains substring 
Php :: php sqrt 
Php :: php closecursor 
Php :: php 2d empty array remove 
Php :: check if session is set 
Php :: laravel route view 
Php :: php number to color 
Php :: laravel php artisan tinker test email 
Php :: laravel restore soft delete 
Php :: laravel-socialite-invalidstateexception 
Php :: php get highest key value 
Php :: concat function using laravel update query 
Php :: php array merge skip diplicate 
Php :: php add 1 day to current date 
ADD CONTENT
Topic
Content
Source link
Name
4+5 =