org.sakaiproject.service.legacy.calendar
Interface CalendarImporterService

All Known Implementing Classes:
GenericCalendarImporter

public interface CalendarImporterService

Interface for importing various calendar exports into Sakai.


Field Summary
static String CSV_IMPORT
          Comma separated value import type
static String MEETINGMAKER_IMPORT
          MeetingMaker import type
static String OUTLOOK_IMPORT
          Outlook import type
 
Method Summary
 List doImport(String importType, InputStream importStream, Map columnMapping, String[] customFieldPropertyNames)
          Perform an import given the import type.
 Map getDefaultColumnMap(String importType)
          Get the default column mapping (keys are column headers, values are property names).
 

Field Detail

CSV_IMPORT

public static final String CSV_IMPORT
Comma separated value import type

See Also:
Constant Field Values

MEETINGMAKER_IMPORT

public static final String MEETINGMAKER_IMPORT
MeetingMaker import type

See Also:
Constant Field Values

OUTLOOK_IMPORT

public static final String OUTLOOK_IMPORT
Outlook import type

See Also:
Constant Field Values
Method Detail

getDefaultColumnMap

public Map getDefaultColumnMap(String importType)
                        throws ImportException
Get the default column mapping (keys are column headers, values are property names).

Parameters:
importType - Type such as Outlook, MeetingMaker, etc. defined in the CalendarImporterService interface.
Throws:
ImportException

doImport

public List doImport(String importType,
                     InputStream importStream,
                     Map columnMapping,
                     String[] customFieldPropertyNames)
              throws ImportException
Perform an import given the import type.

Parameters:
importType - Type such as Outlook, MeetingMaker, etc. defined in the CalendarImporterService interface.
importStream - Stream of data to be imported
columnMapping - Map of column headers (keys) to property names (values)
customFieldPropertyNames - Array of custom properties that we want to import. null if there are no custom properties.
Returns:
A list of CalendarEvent objects. These objects are not "real", so their copies must be copied into CalendarEvents created by the Calendar service.
Throws:
ImportException