Results of 1 - 10 of about 38 for Lazy (0.003 sec.)
- str_contains — 指定された部分文字列が、文字列に含まれるかを調べる | PHP 8.3 16730
- str_contains (PHP 8) str_contains — 指定された部分文字列が、文字列に含まれるかを調べる 説明 function str_contains ( string $haystack , string $needle ): bool needle が haystack に含まれるかを調べます。 大文字小文字は区別されます。 パラメータ
... となります。 Checking the existence of the empty string will always return true 例2 大文字小文字の区別 <?php $string = 'The lazy fox jumped over the fence' ; if ( str_contains ( $string , 'lazy' )) { echo "The string 'lazy' was found in the string\n" ... ; } if ( str_contains ( $string , 'Lazy' )) { echo 'The string "Lazy" was found in the string' ; } else { echo '"Lazy" was not found because the case does not mat ... ch' ; } ?> 上の例の出力は以下となります。 The string 'lazy' was found in the string "Lazy" was not found because the case does not match 注意 注意 : この関数はバイナリデータに対応し ...
-
https://man.mtool.work/php/8.3/function.str-contains.html
- preg_replace — 正規表現検索および置換を行う | PHP 8.3 9292
- preg_replace (PHP 4, PHP 5, PHP 7, PHP 8) preg_replace — 正規表現検索および置換を行う 説明 function preg_replace ( string | array $pattern , string | array $replacement , string | array $subject , int $limit = -1 , int &$count = null ): str
... 出力は以下となります。 April1,2003 例2 preg_replace() での添字配列の使用 <?php $string = 'The quick brown fox jumps over the lazy dog.' ; $patterns = array(); $patterns [ 0 ] = '/quick/' ; $patterns [ 1 ] = '/brown/' ; $patterns [ 2 ] = '/fox/' ; $repl ... preg_replace ( $patterns , $replacements , $string ); ?> 上の例の出力は以下となります。 The bear black slow jumps over the lazy dog. pattern と replacement を ksort すると、所望のものが得られます。 <?php $string = 'The quick brown fox jumps over the ... preg_replace ( $patterns , $replacements , $string ); ?> 上の例の出力は以下となります。 The slow black bear jumps over the lazy dog. 例3 複数値の置換 <?php $patterns = array ( '/(19|20)(\d{2})-(\d{1,2})-(\d{1,2})/' , '/^\s*{(\w+)}\s*=/' ); $replace = ...
-
https://man.mtool.work/php/8.3/function.preg-replace.html
- PDOStatement::fetch — 結果セットから次の行を取得する | PHP 8.3 9009
- PDOStatement::fetch (PHP 5 >= 5.1.0, PHP 7, PHP 8, PECL pdo >= 0.1.0) PDOStatement::fetch — 結果セットから次の行を取得する 説明 public function PDOStatement::fetch ( int $mode = PDO::FETCH_DEFAULT , int $cursorOrientation = PDO::FETCH_ORI_N
... トのカラムを、クラス内の対応する名前のプロパティにマップして、 要求されたクラスの既存のインスタンスを更新します。 PDO::FETCH_LAZY : PDO::FETCH_BOTH と PDO::FETCH_OBJ の 動作を組み合わせたもので、 PDORow オブジェクトを返します。 カラムの値は、プロパティ ... umn name and number\n" ; $result = $sth -> fetch ( PDO :: FETCH_BOTH ); var_dump ( $result ); echo "\n" ; echo "PDO::FETCH_LAZY: " ; echo "Return next row as a PDORow object with column names as properties\n" ; $result = $sth -> fetch ( PDO :: FETCH_ ... name"]=> string(6) "banana" [0]=> string(6) "banana" ["colour"]=> string(6) "yellow" [1]=> string(6) "yellow" } PDO::FETCH_LAZY: Return next row as a PDORow object with column names as properties object(PDORow)#3 (3) { ["queryString"]=> string(30) "S ...
-
https://man.mtool.work/php/8.3/pdostatement.fetch.html
- wordwrap — 指定した文字数で文字列を分割する | PHP 8.3 8868
- wordwrap (PHP 4 >= 4.0.2, PHP 5, PHP 7, PHP 8) wordwrap — 指定した文字数で文字列を分割する 説明 function wordwrap ( string $string , int $width = 75 , string $break = "\n" , bool $cut_long_words = false ): string 指定した文字数で、指定した文
... は、 E_WARNING が発生し、 false を返していました。 例 例1 wordwrap() の例 <?php $text = "The quick brown fox jumped over the lazy dog." ; $newtext = wordwrap ( $text , 20 , "<br />\n" ); echo $newtext ; ?> 上の例の出力は以下となります。 The quick brown ... fox<br /> jumped over the lazy<br /> dog. 例2 wordwrap() の例 <?php $text = "A very long woooooooooooord." ; $newtext = wordwrap ( $text , 8 , "\n" , tru ...
-
https://man.mtool.work/php/8.3/function.wordwrap.html
- hash_init — 段階的なハッシュコンテキストを初期化する | PHP 8.3 8443
- hash_init (PHP 5 >= 5.1.2, PHP 7, PHP 8, PECL hash >= 1.1) hash_init — 段階的なハッシュコンテキストを初期化する 説明 function hash_init ( string $algo , int $flags = 0 , #[ \SensitiveParameter ] string $key = "" , array $options = [] ): Has
... を返すようになりました。 例 例1 段階的なハッシュの例 <?php $hash = hash ( 'sha256' , 'The quick brown fox jumped over the lazy dog.' ); $ctx = hash_init ( 'sha256' ); hash_update ( $ctx , 'The quick brown fox ' ); hash_update ( $ctx , 'jumped over t ... he lazy dog.' ); $incremental_hash = hash_final ( $ctx ); echo $incremental_hash , PHP_EOL ; var_dump ( $hash === $incremental_has ...
-
https://man.mtool.work/php/8.3/function.hash-init.html
- ReflectionClass::newLazyProxy — 新しいレイジープロキシインスタンスを作成する | ... 8302
- ReflectionClass::newLazyProxy (PHP 8 >= 8.4.0) ReflectionClass::newLazyProxy — 新しいレイジープロキシインスタンスを作成する 説明 public function ReflectionClass::newLazyProxy ( callable $factory , int $options = 0 ): object クラスの新しいレ
... int $prop ) { echo __METHOD__ , "\n" ; } } $reflector = new ReflectionClass ( Example ::class); $object = $reflector -> newLazyProxy (function ( Example $object ) { $realInstance = new Example ( 1 ); return $realInstance ; }); var_dump ( $object ); v ... ティの取得を実インスタンスに転送します var_dump ( $object -> prop ); var_dump ( $object ); ?> 上の例の出力は以下となります。 lazy proxy object(Example)#3 (0) { ["prop"]=> uninitialized(int) } bool(true) Example::__construct int(1) lazy proxy object(Exa ... mple)#3 (1) { ["instance"]=> object(Example)#4 (1) { ["prop"]=> int(1) } } 参考 レイジーオブジェクト ReflectionClass::newLazyGhost() - 新しいレイジーゴーストインスタンスを作成する ReflectionClass::newInstanceWithoutConstructor() - コンストラクタを起 ...
-
https://man.mtool.work/php/8.3/reflectionclass.newlazyproxy.html
- hash_copy — ハッシュコンテキストをコピーする | PHP 8.3 8160
- hash_copy (PHP 5 >= 5.3.0, PHP 7, PHP 8) hash_copy — ハッシュコンテキストをコピーする 説明 function hash_copy ( HashContext $context ): HashContext パラメータ context hash_init() が返すハッシュコンテキスト。 戻り値 ハッシュコンテキストのコピ
... copy_context = hash_copy ( $context ); echo hash_final ( $context ), "\n" ; hash_update ( $copy_context , "jumped over the lazy dog." ); echo hash_final ( $copy_context ), "\n" ; ?> 上の例の出力は以下となります。 b29d66e56ed90cce9b0165c43fedec612b60a ...
-
https://man.mtool.work/php/8.3/function.hash-copy.html
- フェッチモード | PHP 8.3 8034
- フェッチモード PDO::FETCH_ORI_* カーソル定数については、 カーソル定数 を参照ください。 基本的なフェッチモード フェッチモード 概要 PDO::FETCH_DEFAULT 現在のデフォルトフェッチモードを使用するための特別な値。 PDO::FETCH_ASSOC カラム名のみでイン
... モード 概要 PDO::FETCH_BOUND 指定した変数に値をバインドします。 PDO::FETCH_INTO 既存のオブジェクトを更新します。 PDO::FETCH_LAZY 配列風およびオブジェクト風のアクセスのための PDORow による遅延フェッチ。 PDOStatement::fetchAll() 用の特殊な動作フラグ 以下 ... rid"]=> int(104) ["name"]=> string(5) "Chris" ["country"]=> string(7) "Ukraine" ["referred_by_userid"]=> NULL } PDO::FETCH_LAZY ( int ) このフェッチモードは PDOStatement::fetchAll() では使用できません。 このフェッチモードは PDORow オブジェクトを返し、 ... = $db -> query ( "SELECT userid, name, country, referred_by_userid FROM users" ); $result = $stmt -> fetch ( \PDO :: FETCH_LAZY ); print "ID: " . $result [ 0 ] . "\n" ; print "Name: { $result -> name } \n" ; print "Country: " . $result [ 'country' ] ...
-
https://man.mtool.work/php/8.3/pdo.constants.fetch-modes.html
- PDORow クラス | PHP 8.3 7893
- PDORow クラス (PHP 5 >= 5.1.0, PHP 7, PHP 8, PECL pdo >= 1.0.0) はじめに フェッチモード PDO::FETCH_LAZY を使って PDOStatement::fetch() をコールした場合に返される 結果セットの行を表します。 このクラスのオブジェクトは、インスタンス化できません
...
-
https://man.mtool.work/php/8.3/class.pdorow.html
- hash_update_stream — アクティブなハッシュコンテキストに、オープンしているストリ... 7893
- hash_update_stream (PHP 5 >= 5.1.2, PHP 7, PHP 8, PECL hash >= 1.1) hash_update_stream — アクティブなハッシュコンテキストに、オープンしているストリームから データを投入する 説明 function hash_update_stream ( HashContext $context , resource
... xt を受け入れるようになりました。 例 例1 hash_update_stream() の例 <?php $fp = tmpfile (); fwrite ( $fp , 'jumped over the lazy dog.' ); rewind ( $fp ); $ctx = hash_init ( 'sha256' ); hash_update ( $ctx , 'The quick brown fox ' ); hash_update_stream ...
-
https://man.mtool.work/php/8.3/function.hash-update-stream.html