def encodeInternal(self, value, instance): __VEventSerDer__().encodeInternal(value, instance) from netbluemind.core.api.date.BmDateTime import BmDateTime from netbluemind.core.api.date.BmDateTime import __BmDateTimeSerDer__ recuridValue = value.recurid instance["recurid"] = __BmDateTimeSerDer__().encode(recuridValue) return instance
def parse(self, value): if (value == None): return None instance = VEventOccurrence() __VEventSerDer__().parseInternal(value, instance) self.parseInternal(value, instance) return instance
def parseInternal(self, value, instance): from netbluemind.calendar.api.VEvent import VEvent from netbluemind.calendar.api.VEvent import __VEventSerDer__ from netbluemind.core.container.model.ItemValue import ItemValue from netbluemind.core.container.model.ItemValue import __ItemValueSerDer__ veventValue = value['vevent'] instance.vevent = __ItemValueSerDer__( __VEventSerDer__()).parse(veventValue) from netbluemind.icalendar.api.ICalendarElementVAlarm import ICalendarElementVAlarm from netbluemind.icalendar.api.ICalendarElementVAlarm import __ICalendarElementVAlarmSerDer__ valarmValue = value['valarm'] instance.valarm = __ICalendarElementVAlarmSerDer__().parse(valarmValue) return instance
def encodeInternal(self, value, instance): from netbluemind.calendar.api.VEvent import VEvent from netbluemind.calendar.api.VEvent import __VEventSerDer__ from netbluemind.core.container.model.ItemValue import ItemValue from netbluemind.core.container.model.ItemValue import __ItemValueSerDer__ veventValue = value.vevent instance["vevent"] = __ItemValueSerDer__( __VEventSerDer__()).encode(veventValue) from netbluemind.icalendar.api.ICalendarElementVAlarm import ICalendarElementVAlarm from netbluemind.icalendar.api.ICalendarElementVAlarm import __ICalendarElementVAlarmSerDer__ valarmValue = value.valarm instance["valarm"] = __ICalendarElementVAlarmSerDer__().encode( valarmValue) return instance
def parseInternal(self, value, instance): from netbluemind.calendar.api.VEvent import VEvent from netbluemind.calendar.api.VEvent import __VEventSerDer__ mainValue = value['main'] instance.main = __VEventSerDer__().parse(mainValue) from netbluemind.calendar.api.VEventOccurrence import VEventOccurrence from netbluemind.calendar.api.VEventOccurrence import __VEventOccurrenceSerDer__ occurrencesValue = value['occurrences'] instance.occurrences = serder.ListSerDer( __VEventOccurrenceSerDer__()).parse(occurrencesValue) propertiesValue = value['properties'] instance.properties = serder.MapSerDer( serder.STRING).parse(propertiesValue) icsUidValue = value['icsUid'] instance.icsUid = serder.STRING.parse(icsUidValue) return instance
def encodeInternal(self, value, instance): from netbluemind.calendar.api.VEvent import VEvent from netbluemind.calendar.api.VEvent import __VEventSerDer__ mainValue = value.main instance["main"] = __VEventSerDer__().encode(mainValue) from netbluemind.calendar.api.VEventOccurrence import VEventOccurrence from netbluemind.calendar.api.VEventOccurrence import __VEventOccurrenceSerDer__ occurrencesValue = value.occurrences instance["occurrences"] = serder.ListSerDer( __VEventOccurrenceSerDer__()).encode(occurrencesValue) propertiesValue = value.properties instance["properties"] = serder.MapSerDer( serder.STRING).encode(propertiesValue) icsUidValue = value.icsUid instance["icsUid"] = serder.STRING.encode(icsUidValue) return instance