You are here

class ICal in Opigno calendar event 8

Same name and namespace in other branches
  1. 3.x src/iCal/ICal.php \Drupal\opigno_calendar_event\iCal\ICal

Class ICal.

Hierarchy

  • class \Drupal\opigno_calendar_event\iCal\ICal

Expanded class hierarchy of ICal

1 string reference to 'ICal'
opigno_calendar_event.services.yml in ./opigno_calendar_event.services.yml
opigno_calendar_event.services.yml
1 service uses ICal
opigno_calendar_event.iCal in ./opigno_calendar_event.services.yml
Drupal\opigno_calendar_event\iCal\ICal

File

src/iCal/ICal.php, line 8

Namespace

Drupal\opigno_calendar_event\iCal
View source
class ICal {

  /**
   * Build iCal file for events.
   *
   * @param array $params
   *   Params.
   *
   * @return bool|string
   *   Calendar event.
   */
  public function buildICalEvent(array $params) {
    $event = new ICalendarEvent($params);
    $params['events'] = [
      $event,
    ];
    $calendar = new ICalendar($params);
    return $calendar
      ->generateString();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ICal::buildICalEvent public function Build iCal file for events.