Search in sources :

Example 1 with Language

use of net.fortuna.ical4j.model.parameter.Language in project bw-calendar-engine by Bedework.

the class IcalUtil method setOrganizer.

/**
 * @param val
 * @return Organizer
 * @throws Throwable
 */
public static Organizer setOrganizer(final BwOrganizer val) throws Throwable {
    ParameterList pars = new ParameterList();
    String temp = val.getScheduleStatus();
    if (temp != null) {
        pars.add(new ScheduleStatus(temp));
    }
    temp = val.getCn();
    if (temp != null) {
        pars.add(new Cn(temp));
    }
    temp = val.getDir();
    if (temp != null) {
        pars.add(new Dir(temp));
    }
    temp = val.getLanguage();
    if (temp != null) {
        pars.add(new Language(temp));
    }
    temp = val.getSentBy();
    if (temp != null) {
        pars.add(new SentBy(temp));
    }
    Organizer prop = new Organizer(pars, val.getOrganizerUri());
    return prop;
}
Also used : Language(net.fortuna.ical4j.model.parameter.Language) BwOrganizer(org.bedework.calfacade.BwOrganizer) Organizer(net.fortuna.ical4j.model.property.Organizer) ParameterList(net.fortuna.ical4j.model.ParameterList) SentBy(net.fortuna.ical4j.model.parameter.SentBy) Cn(net.fortuna.ical4j.model.parameter.Cn) Dir(net.fortuna.ical4j.model.parameter.Dir) ScheduleStatus(net.fortuna.ical4j.model.parameter.ScheduleStatus)

Example 2 with Language

use of net.fortuna.ical4j.model.parameter.Language in project bw-calendar-engine by Bedework.

the class IcalUtil method setAttendeeVoter.

/**
 * make an attendee
 *
 * @param val
 * @return Attendee
 * @throws Throwable
 */
private static void setAttendeeVoter(final BwAttendee val, final ParameterList pars) throws Throwable {
    if (val.getRsvp()) {
        pars.add(Rsvp.TRUE);
    }
    String temp = val.getCn();
    if (temp != null) {
        pars.add(new Cn(temp));
    }
    temp = val.getScheduleStatus();
    if (temp != null) {
        pars.add(new ScheduleStatus(temp));
    }
    temp = val.getCuType();
    if (temp != null) {
        pars.add(new CuType(temp));
    }
    temp = val.getDelegatedFrom();
    if (temp != null) {
        pars.add(new DelegatedFrom(temp));
    }
    temp = val.getDelegatedTo();
    if (temp != null) {
        pars.add(new DelegatedTo(temp));
    }
    temp = val.getDir();
    if (temp != null) {
        pars.add(new Dir(temp));
    }
    temp = val.getLanguage();
    if (temp != null) {
        pars.add(new Language(temp));
    }
    temp = val.getMember();
    if (temp != null) {
        pars.add(new Member(temp));
    }
    temp = val.getRole();
    if (temp != null) {
        pars.add(new Role(temp));
    }
    temp = val.getSentBy();
    if (temp != null) {
        pars.add(new SentBy(temp));
    }
}
Also used : Role(net.fortuna.ical4j.model.parameter.Role) CuType(net.fortuna.ical4j.model.parameter.CuType) DelegatedTo(net.fortuna.ical4j.model.parameter.DelegatedTo) Language(net.fortuna.ical4j.model.parameter.Language) SentBy(net.fortuna.ical4j.model.parameter.SentBy) Cn(net.fortuna.ical4j.model.parameter.Cn) DelegatedFrom(net.fortuna.ical4j.model.parameter.DelegatedFrom) Dir(net.fortuna.ical4j.model.parameter.Dir) Member(net.fortuna.ical4j.model.parameter.Member) ScheduleStatus(net.fortuna.ical4j.model.parameter.ScheduleStatus)

Aggregations

Cn (net.fortuna.ical4j.model.parameter.Cn)2 Dir (net.fortuna.ical4j.model.parameter.Dir)2 Language (net.fortuna.ical4j.model.parameter.Language)2 ScheduleStatus (net.fortuna.ical4j.model.parameter.ScheduleStatus)2 SentBy (net.fortuna.ical4j.model.parameter.SentBy)2 ParameterList (net.fortuna.ical4j.model.ParameterList)1 CuType (net.fortuna.ical4j.model.parameter.CuType)1 DelegatedFrom (net.fortuna.ical4j.model.parameter.DelegatedFrom)1 DelegatedTo (net.fortuna.ical4j.model.parameter.DelegatedTo)1 Member (net.fortuna.ical4j.model.parameter.Member)1 Role (net.fortuna.ical4j.model.parameter.Role)1 Organizer (net.fortuna.ical4j.model.property.Organizer)1 BwOrganizer (org.bedework.calfacade.BwOrganizer)1