<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Vendor\Provider\SiteUrl; use ModStart\Core\Exception\BizException; class SiteUrlProvider { private static $list = array(); private static $init = false; public static function register($ugwYT) { self::$list[] = $ugwYT; } public static function get() { if (!self::$init) { self::$init = true; foreach (self::$list as $QBy8K => $cG5OI) { if (is_string($cG5OI)) { self::$list[$QBy8K] = app($cG5OI); } } } return self::$list; } public static function update($JPXsz, $n_9y_ = '', $f_HcG = array()) { BizException::throwsIfEmpty('SiteUrlProvider.Error -> url empty', $JPXsz); foreach (self::get() as $vFZTy) { $vFZTy->update($JPXsz, $n_9y_, $f_HcG); } } public static function delete($JPXsz) { BizException::throwsIfEmpty('SiteUrlProvider.Error -> url empty', $JPXsz); foreach (self::get() as $vFZTy) { $vFZTy->delete($JPXsz); } } }