Exemplo n.º 1
0
 /**
  * change Wi-Fi object to associative array
  *
  * @param Wifi $wifi
  * @return array
  */
 private function prepareArrayForDB(Wifi $wifi)
 {
     $wifi->synchronizeSecurity();
     $array = array("id_source" => $wifi->getSource(), "date_added" => date("Y-m-d"), "mac" => MyUtils::macSeparator2Colon($wifi->getMac()), "ssid" => $wifi->getSsid(), "sec" => $wifi->getSec(), "latitude" => $wifi->getLatitude(), "longitude" => $wifi->getLongitude(), "altitude" => $wifi->getAltitude(), "comment" => $wifi->getComment(), "name" => $wifi->getName(), "type" => $wifi->getType(), "freenet" => $wifi->getFreenet(), "paynet" => $wifi->getPaynet(), "firsttime" => $wifi->getFirsttime(), "lasttime" => $wifi->getLasttime(), "flags" => $wifi->getFlags(), "wep" => $wifi->getWep(), "lastupdt" => $wifi->getLastupdt(), "channel" => $wifi->getChannel(), "bcninterval" => $wifi->getBcninterval(), "qos" => $wifi->getQos(), "accuracy" => $wifi->getAccuracy(), "calculated" => $wifi->getCalculated());
     return $array;
 }