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


Java VEvent.addAttendee方法代码示例

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


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

示例1: ICalendar_constructor_storedRequiredAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedRequiredAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationLevel(ParticipationLevel.REQUIRED);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getRequired()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例2: ICalendar_constructor_storedOptionalAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedOptionalAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationLevel(ParticipationLevel.OPTIONAL);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getOptional()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例3: ICalendar_constructor_storedFyiAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedFyiAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationLevel(ParticipationLevel.FYI);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getFyi()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例4: ICalendar_constructor_storedAcceptedAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedAcceptedAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationStatus(ParticipationStatus.ACCEPTED);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getAccepted()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例5: ICalendar_constructor_storedTentativeAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedTentativeAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationStatus(ParticipationStatus.TENTATIVE);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getTentative()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例6: ICalendar_constructor_storedDeclinedAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedDeclinedAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationStatus(ParticipationStatus.DECLINED);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getDeclined()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例7: ICalendar_constructor_storedDelegatedAttendeesFromEvent

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void ICalendar_constructor_storedDelegatedAttendeesFromEvent() {
    List<ICalendar> iCalendars = new ArrayList<>();
    ICalendar iCalendar = new ICalendar();
    VEvent event = new VEvent();
    Attendee requiredAttendee = new Attendee("A", "[email protected]");
    requiredAttendee.setParticipationStatus(ParticipationStatus.DELEGATED);
    event.addAttendee(requiredAttendee);
    iCalendar.addEvent(event);
    iCalendars.add(iCalendar);
    ICalData data = new ICalData(iCalendars);

    assertEquals(requiredAttendee, data.getCalendarData().get(0).getDelegated()[0]);
}
 
开发者ID:philipwhiuk,项目名称:q-mail,代码行数:15,代码来源:ICalDataTest.java

示例8: example3

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void example3() throws Throwable {
	ICalendar ical = new ICalendar();
	ical.getProperties().clear();
	ical.setMethod("xyz");
	ical.setProductId("-//ABC Corporation//NONSGML My Product//EN");
	{
		VEvent event = new VEvent();
		event.getProperties().clear();
		event.setDateTimeStamp(utc("1997-03-24 12:00:00"));
		event.setSequence(0);
		event.setUid("[email protected]");
		event.setOrganizer("[email protected]");

		Attendee attendee = new Attendee(null, "[email protected]");
		attendee.setRsvp(true);
		event.addAttendee(attendee);

		event.setDateStart(utc("1997-03-24 12:30:00"));
		event.setDateEnd(utc("1997-03-24 21:00:00"));
		event.addCategories("MEETING", "PROJECT");
		event.setClassification(Classification.public_());
		event.setSummary("Calendaring Interoperability Planning Meeting");
		event.setDescription("Discuss how we can test c&s interoperability\nusing iCalendar and other IETF standards.");
		event.setLocation("LDB Lobby");

		Attachment attach = new Attachment("application/postscript", "ftp://example.com/pub/conf/bkgrnd.ps");
		event.addAttachment(attach);

		ical.addEvent(event);
	}

	assertValidate(ical).versions(V2_0_DEPRECATED, V2_0).run();
	assertExample(ical, "rfc5545-example3.ics", V2_0);
}
 
开发者ID:mangstadt,项目名称:biweekly,代码行数:36,代码来源:ICalWriterTest.java

示例9: example2

import biweekly.component.VEvent; //导入方法依赖的package包/类
@Test
public void example2() throws Throwable {
	TimeZone eastern = TimeZone.getTimeZone("America/New_York");
	ICalendar ical = new ICalendar();
	ical.getProperties().clear();
	ical.setProductId("-//RDU Software//NONSGML HandCal//EN");
	{
		VEvent event = new VEvent();
		event.setDateTimeStamp(utc("1998-03-09 23:10:00"));
		event.setUid("guid-1.example.com");
		event.setOrganizer("[email protected]");

		Attendee attendee = new Attendee(null, "[email protected]");
		attendee.setRsvp(true);
		attendee.setParticipationLevel(ParticipationLevel.REQUIRED);
		attendee.setCalendarUserType(CalendarUserType.GROUP);
		event.addAttendee(attendee);

		event.setDescription("Project XYZ Review Meeting");
		event.addCategories("MEETING");
		event.setClassification(Classification.public_());
		event.setCreated(utc("1998-03-09 13:00:00"));
		event.setSummary("XYZ Project Review");
		event.setDateStart(date("1998-03-12 08:30:00", eastern));
		event.setDateEnd(date("1998-03-12 09:30:00", eastern));
		event.setLocation("1CP Conference Room 4350");
		ical.addEvent(event);
	}

	assertValidate(ical).versions(V2_0_DEPRECATED, V2_0).run();

	TimezoneInfo tzinfo = ical.getTimezoneInfo();
	VTimezone usEasternTz;
	{
		usEasternTz = new VTimezone("America/New_York");
		{
			StandardTime standard = new StandardTime();
			standard.setDateStart(new DateTimeComponents(1998, 10, 25, 2, 0, 0, false));
			standard.setTimezoneOffsetFrom(new UtcOffset(false, 4, 0));
			standard.setTimezoneOffsetTo(new UtcOffset(false, 5, 0));
			standard.addTimezoneName("EST");
			usEasternTz.addStandardTime(standard);
		}
		{
			DaylightSavingsTime daylight = new DaylightSavingsTime();
			daylight.setDateStart(new DateTimeComponents(1999, 4, 4, 2, 0, 0, false));
			daylight.setTimezoneOffsetFrom(new UtcOffset(false, 5, 0));
			daylight.setTimezoneOffsetTo(new UtcOffset(false, 4, 0));
			daylight.addTimezoneName("EDT");
			usEasternTz.addDaylightSavingsTime(daylight);
		}
	}

	tzinfo.setDefaultTimezone(new TimezoneAssignment(eastern, usEasternTz));
	assertExample(ical, "rfc5545-example2.ics", V2_0);
}
 
开发者ID:mangstadt,项目名称:biweekly,代码行数:57,代码来源:ICalWriterTest.java

示例10: toVEventObject

import biweekly.component.VEvent; //导入方法依赖的package包/类
@SuppressWarnings("unchecked")
public VEvent toVEventObject() {

	VEvent event = new VEvent();

	if (uid != null)
           event.setUid(uid);

	event.setDateStart(dtStart);
	if (dtEnd != null)
		event.setDateEnd(dtEnd);
	if (duration != null)
		event.setDuration(duration);
	
	if (rrule != null)
		event.setRecurrenceRule(rrule);
	if (rdate != null && !rdate.isEmpty()) {
           for (RecurrenceDates rd : rdate) {
               event.addRecurrenceDates(rd);
           }
       }
	if (exrule != null && !exrule.isEmpty()) {
           for (ExceptionRule exr : exrule) {
               event.addExceptionRule(exr);
           }
       }
	if (exdate != null && !exdate.isEmpty()) {
           for (ExceptionDates exd: exdate) {
               event.addExceptionDates(exd);
           }
       }
	
	if (summary != null && !summary.isEmpty())
		event.setSummary(summary);
	if (location != null && !location.isEmpty())
           event.setLocation(location);
	if (description != null && !description.isEmpty())
		event.setDescription(description);
	
	if (status != null)
		event.setStatus(status);
	if (!opaque)
		event.setTransparency(true);
	
	if (organizer != null)
		event.setOrganizer(organizer);

       for (Attendee attendee: attendees) {
           event.addAttendee(attendee);
       }

	if (forPublic != null)
		event.setClassification(forPublic ? "public" : "private");
	
	for (VAlarm alarm: alarms) {
           event.addAlarm(alarm);
       }

	event.setLastModified(new Date());

       return event;
}
 
开发者ID:eXfio,项目名称:CucumberSync,代码行数:63,代码来源:Event.java


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