/**
  * @param string $id
  * @param string $name
  * @param string $type
  * @param int $period period in seconds
  * @param int $frequency
  *
  * @return Gpf_Recurrence_Preset
  */
 public function addRecurrencePreset($id, $name, $type = '', $period = '', $frequency = '')
 {
     $preset = new Gpf_Recurrence_Preset();
     $preset->setId($id);
     $preset->setName($name);
     $preset->setType(Gpf_Db_RecurrencePreset::SYSTEM_PRESET);
     $preset->insert();
     if ($type != '') {
         $presetSetting = new Gpf_Db_RecurrenceSetting();
         $presetSetting->setRecurrencePresetId($preset->getId());
         $presetSetting->setType($type);
         $presetSetting->setPeriod($period);
         $presetSetting->setFrequency($frequency);
         $presetSetting->insert();
     }
     return $preset;
 }