private function __GetAPI($type) { $SID = 'notify.driver.api.'.$type; $api = moSpace($SID); if (!$api) { $api = driver('notify')->load($type, $this->notifys[$type]); moSpace($SID, $api); } return $api; }
public final function api($name) { $SID = 'driver.iaddress.api.'.$name; $obj = moSpace($SID); if ( ! $obj ) { require dirname(__FILE__).'/iaddress/'.$name.'.php'; $className = $name.'ImportAddressDriver'; $obj = moSpace($SID, (new $className())); } return $obj; }
public final function api($name) { $SID = 'driver.ulogin.api.'.$name; $obj = moSpace($SID); if ( ! $obj ) { require dirname(__FILE__).'/ulogin/'.$name.'.php'; $className = $name.'UnionLoginDriver'; $obj = moSpace($SID, (new $className())); } return $obj; }
public function user($uid = null) { if ($uid === null) { $uid = handler('member')->MemberFields['uid']; } $SID = 'logic.me.user.'.$uid; $obj = moSpace($SID); if ( ! $obj ) { $obj = moSpace($SID, (new MeLogic_User($uid))); } return $obj; }
function loadInstance($SID, $className) { $obj = moSpace($SID); if ( ! $obj ) { $obj = moSpace($SID, (new $className())); } return $obj; }
public function apiz($code) { if (is_numeric($code)) { $payment = $this->SrcOne($code); $code = $payment['code']; } $SID = 'payment.driver.api.'.$code; $api = moSpace($SID); if (!$api) { $api = moSpace($SID, driver('payment')->load($code)); } return $api; }