Пример #1
0
 /**
  * 初始化新的分流标签
  */
 protected function initialize()
 {
     $this->ipAddress = IpLocator::getClientIp();
     $this->timestamp = time();
     $this->salt = rand(1, 100);
 }
Пример #2
0
 /**
  * @param $ipAddress
  *
  * @return \Gram\SplitTest\IpAddress\IpAddress|null
  */
 protected function getIpAddress($ipAddress)
 {
     return IpLocator::find($ipAddress);
 }