当前位置: 首页>>代码示例>>Python>>正文


Python PurgePrincipalService._cancelEvent方法代码示例

本文整理汇总了Python中calendarserver.tools.purge.PurgePrincipalService._cancelEvent方法的典型用法代码示例。如果您正苦于以下问题:Python PurgePrincipalService._cancelEvent方法的具体用法?Python PurgePrincipalService._cancelEvent怎么用?Python PurgePrincipalService._cancelEvent使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在calendarserver.tools.purge.PurgePrincipalService的用法示例。


在下文中一共展示了PurgePrincipalService._cancelEvent方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_cancelAsAttendeeMultipleOccurrences

# 需要导入模块: from calendarserver.tools.purge import PurgePrincipalService [as 别名]
# 或者: from calendarserver.tools.purge.PurgePrincipalService import _cancelEvent [as 别名]
 def test_cancelAsAttendeeMultipleOccurrences(self):
     # Multiple meeting occurrences with no master, where purged CUA is
     # an attendee
     event = Component.fromString(INVITED_TO_MULTIPLE_OCCURRENCES_ICS)
     action = PurgePrincipalService._cancelEvent(event, PyCalendarDateTime(2010, 12, 6, 12, 0, 0, PyCalendarTimezone(utc=True)),
         "urn:uuid:9DC04A71-E6DD-11DF-9492-0800200C9A66")
     self.assertEquals(action, PurgePrincipalService.CANCELEVENT_SHOULD_DELETE)
开发者ID:azbarcea,项目名称:calendarserver,代码行数:9,代码来源:test_purge.py

示例2: test_cancelAllDayRepeating

# 需要导入模块: from calendarserver.tools.purge import PurgePrincipalService [as 别名]
# 或者: from calendarserver.tools.purge.PurgePrincipalService import _cancelEvent [as 别名]
 def test_cancelAllDayRepeating(self):
     # A repeating All Day event where purged CUA is organizer
     event = Component.fromString(REPEATING_2_ICS_BEFORE)
     action = PurgePrincipalService._cancelEvent(event, PyCalendarDateTime(2010, 12, 6, 12, 0, 0, PyCalendarTimezone(utc=True)),
         "urn:uuid:0F168477-CF3D-45D3-AE60-9875EA02C4D1")
     self.assertEquals(action, PurgePrincipalService.CANCELEVENT_MODIFIED)
     self.assertEquals(str(event), REPEATING_2_ICS_AFTER)
开发者ID:azbarcea,项目名称:calendarserver,代码行数:9,代码来源:test_purge.py

示例3: test_cancelAsAttendee

# 需要导入模块: from calendarserver.tools.purge import PurgePrincipalService [as 别名]
# 或者: from calendarserver.tools.purge.PurgePrincipalService import _cancelEvent [as 别名]
 def test_cancelAsAttendee(self):
     # A repeating meeting event where purged CUA is an attendee
     event = Component.fromString(REPEATING_ATTENDEE_MEETING_ICS)
     action = PurgePrincipalService._cancelEvent(event, PyCalendarDateTime(2010, 12, 6, 12, 0, 0, PyCalendarTimezone(utc=True)),
         "urn:uuid:0F168477-CF3D-45D3-AE60-9875EA02C4D1")
     self.assertEquals(action, PurgePrincipalService.CANCELEVENT_SHOULD_DELETE)
开发者ID:azbarcea,项目名称:calendarserver,代码行数:8,代码来源:test_purge.py

示例4: test_cancelFutureEvent

# 需要导入模块: from calendarserver.tools.purge import PurgePrincipalService [as 别名]
# 或者: from calendarserver.tools.purge.PurgePrincipalService import _cancelEvent [as 别名]
 def test_cancelFutureEvent(self):
     # A future event
     event = Component.fromString(FUTURE_EVENT_ICS)
     action = PurgePrincipalService._cancelEvent(event, PyCalendarDateTime(2010, 12, 6, 12, 0, 0, PyCalendarTimezone(utc=True)),
         "urn:uuid:0F168477-CF3D-45D3-AE60-9875EA02C4D1")
     self.assertEquals(action, PurgePrincipalService.CANCELEVENT_SHOULD_DELETE)
开发者ID:azbarcea,项目名称:calendarserver,代码行数:8,代码来源:test_purge.py

示例5: test_cancelNonMeeting

# 需要导入模块: from calendarserver.tools.purge import PurgePrincipalService [as 别名]
# 或者: from calendarserver.tools.purge.PurgePrincipalService import _cancelEvent [as 别名]
 def test_cancelNonMeeting(self):
     # A repeating non-meeting event
     event = Component.fromString(REPEATING_NON_MEETING_ICS)
     action = PurgePrincipalService._cancelEvent(event, DateTime(2010, 12, 6, 12, 0, 0, Timezone(utc=True)),
         "urn:uuid:0F168477-CF3D-45D3-AE60-9875EA02C4D1")
     self.assertEquals(action, PurgePrincipalService.CANCELEVENT_SHOULD_DELETE)
开发者ID:svn2github,项目名称:calendarserver-raw,代码行数:8,代码来源:test_purge.py


注:本文中的calendarserver.tools.purge.PurgePrincipalService._cancelEvent方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。