PHP code example of friendsofhyperf / grpc-validation

1. Go to this page and download the library: Download friendsofhyperf/grpc-validation library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

friendsofhyperf / grpc-validation example snippets




use FriendsOfHyperf\GrpcValidation\Annotation;

#[Validation(rules: [
    'name' => '   $message = new HiReply();
    $message->setMessage("Hello World");
    $message->setUser($user);
    return $message;
}