You are here

function cmfcCalendarV1::factory in Calendar Systems 6.3

Same name and namespace in other branches
  1. 8 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  2. 8.2 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  3. 5 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  4. 6 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  5. 7.3 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  6. 7 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
  7. 7.2 calendar/v1/calendarV1.class.inc.php \cmfcCalendarV1::factory()
2 calls to cmfcCalendarV1::factory()
cmfcCalendar::factory in calendar/calendar.class.inc.php
cmfcCalendarV1::getYmdwMonthAsNavigationalArray in calendar/v1/calendarV1.class.inc.php

File

calendar/v1/calendarV1.class.inc.php, line 37

Class

cmfcCalendarV1

Code

function factory($options) {
  if ($options['name'] == 'iranian') {
    require_once dirname(__FILE__) . '/calendarSystems/iranian.class.inc.php';
    return new cmfcCalendarV1Iranian($options);
  }
  if ($options['name'] == 'gregorian') {
    require_once dirname(__FILE__) . '/calendarSystems/gregorian.class.inc.php';
    return new cmfcCalendarV1Gregorian($options);
  }
  if ($options['name'] == 'arabic') {
    require_once dirname(__FILE__) . '/calendarSystems/arabic.class.inc.php';
    return new cmfcCalendarV1Arabic($options);
  }
}