<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Core\Util; class ReUtil { public static function group($sMElx, $McuDg, $p6Kpd) { try { if (preg_match($sMElx, $McuDg, $WpF0C)) { return $WpF0C[$p6Kpd]; } } catch (\Exception $WVwSN) { } return null; } public static function group0($sMElx, $McuDg) { try { return self::group($sMElx, $McuDg, 0); } catch (\Exception $WVwSN) { } return null; } public static function group1($sMElx, $McuDg) { try { return self::group($sMElx, $McuDg, 1); } catch (\Exception $WVwSN) { } return null; } public static function isWildMatch($FDZuI, $McuDg) { goto XGHv3; BhHpj: return preg_match($sMElx, $McuDg); goto t9q1K; pdu_R: $sMElx = str_replace('__x__star__', '.*', $sMElx); goto BhHpj; XAvoB: $sMElx = '/^' . preg_quote($FDZuI, '/') . '$/'; goto pdu_R; XGHv3: $FDZuI = str_replace('*', '__x__star__', $FDZuI); goto XAvoB; t9q1K: } public static function replace($Afv_G, $sMElx, $SO11l) { goto n5A34; n5A34: preg_match_all($sMElx, $Afv_G, $WpF0C); goto Egh9f; Tm5MH: return $Afv_G; goto k6iDj; Egh9f: foreach ($WpF0C[0] as $MqJHJ => $F6Fus) { goto NlwwZ; JuCVZ: $Afv_G = str_replace($F6Fus, $p_GXK, $Afv_G); goto uGpVw; NlwwZ: $tMM4T = array_map(function ($Etabp) use($MqJHJ, $WpF0C) { return $Etabp[$MqJHJ]; }, $WpF0C); goto UiZj3; UiZj3: $p_GXK = call_user_func_array($SO11l, array($tMM4T)); goto JuCVZ; uGpVw: } goto Tm5MH; k6iDj: } }