Examples of OmTimeZone


Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

    // if user has not time zone get one from the server configuration

    String defaultTzName = configurationDao.getConfValue("default.timezone", String.class, "Europe/Berlin");

    OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(defaultTzName);

    TimeZone timeZoneByOmTimeZone = TimeZone.getTimeZone(omTimeZone
        .getIcal());

    if (timeZoneByOmTimeZone != null) {
      return timeZoneByOmTimeZone;
    }
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

   * @param jName
   * @return
   */
  public TimeZone getTimezoneByInternalJName(String jName) {

    OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(jName);
   
    if (omTimeZone == null) {
      log.error("There is not omTimeZone for this jName: "+jName);
      throw new RuntimeException("There is not omTimeZone for this jName: "+jName);
    }

    TimeZone timeZone = TimeZone.getTimeZone(omTimeZone.getIcal());

    if (timeZone != null) {
      return timeZone;
    }

    // if user has not time zone get one from the server configuration

    String defaultTzName = configurationDao.getConfValue("default.timezone", String.class, "Europe/Berlin");

    OmTimeZone omTimeZoneDefault = omTimeZoneDaoImpl.getOmTimeZone(defaultTzName);

    TimeZone timeZoneByOmTimeZone = TimeZone
        .getTimeZone(omTimeZoneDefault.getIcal());

    if (timeZoneByOmTimeZone != null) {
      return timeZoneByOmTimeZone;
    }

View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

    if (userdata.containsKey(ldapAttrs.get("timezoneAttr"))
        && userdata.get(ldapAttrs.get("timezoneAttr")) != null)
      jName_timeZone = userdata.get(ldapAttrs.get("timezoneAttr"));
   
    //only change the timezone if there can be found some in the OpenMeetings database
    OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(jName_timeZone);
    if (omTimeZone != null) {
      user.setOmTimeZone(omTimeZone);
    }
 
  }
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

     * ##################### Import Users
     */
    {
      List<User> list = readUserList(f, "users.xml", "users");
      for (User u : list) {
        OmTimeZone tz = u.getOmTimeZone();
        if (tz == null || tz.getJname() == null) {
          String jNameTimeZone = configurationDao.getConfValue(
              "default.timezone", String.class, "Europe/Berlin");
          OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(jNameTimeZone);
          u.setOmTimeZone(omTimeZone);
          u.setForceTimeZoneCheck(true);
        } else {
          u.setForceTimeZoneCheck(false);
        }
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

      String timeZoneName = item.attributeValue("name");
      String timeZoneLabel = item.attributeValue("label");
      Integer orderId = Integer.valueOf(item.attributeValue("orderId"));
      String iCal = item.attributeValue("iCal");

      OmTimeZone omTimeZone = new OmTimeZone();
      omTimeZone.setIcal(iCal);
      omTimeZone.setJname(timeZoneName);
      omTimeZone.setLabel(timeZoneLabel);
      omTimeZone.setOrderId(orderId);

      omTimeZones.add(omTimeZone);
    }

    return omTimeZones;
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

    if (userdata.containsKey(ldapAttrs.get("timezoneAttr"))
        && userdata.get(ldapAttrs.get("timezoneAttr")) != null)
      jName_timeZone = userdata.get(ldapAttrs.get("timezoneAttr"));
   
    //only change the timezone if there can be found some in the OpenMeetings database
    OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(jName_timeZone);
    if (omTimeZone != null) {
      user.setOmTimeZone(omTimeZone);
    }
 
  }
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

            // the UI
            // only has around 24 timezones
            // and Java around 600++
            Long sendToUserId = 0L;
            TimeZone timezoneMember = null;
            OmTimeZone omTimeZone = null;
            if (clientMember.get("userId") != null) {
              sendToUserId = Long.valueOf(
                  clientMember.get("userId").toString())
                  .longValue();
            }
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

            invitation.setAllowEntry(true);
            return invitation;
          }

        } else if (invitation.getIsValidByTime()) {
          OmTimeZone tz = invitation.getOmTimeZone() == null
              ? omTimeZoneDaoImpl.getOmTimeZone(configurationDao.getConfValue("default.timezone", String.class, "Europe/Berlin"))
              : invitation.getOmTimeZone();
          Calendar now = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
          Calendar start = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
          start.setTime(invitation.getValidFrom());

          Calendar end = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
          end.setTime(invitation.getValidTo());
          if (now.after(start) && now.before(end)) {
            this.updateInvitation(invitation);
            // invitation.setInvitationpass(null);
            invitation.setAllowEntry(true);
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

      String timeZoneName = item.attributeValue("name");
      String timeZoneLabel = item.attributeValue("label");
      Integer orderId = Integer.valueOf(item.attributeValue("orderId"));
      String iCal = item.attributeValue("iCal");

      OmTimeZone omTimeZone = new OmTimeZone();
      omTimeZone.setIcal(iCal);
      omTimeZone.setJname(timeZoneName);
      omTimeZone.setLabel(timeZoneLabel);
      omTimeZone.setOrderId(orderId);

      omTimeZones.add(omTimeZone);
    }

    return omTimeZones;
View Full Code Here

Examples of org.apache.openmeetings.persistence.beans.basic.OmTimeZone

     * ##################### Import Users
     */
    {
      List<User> list = readUserList(f, "users.xml", "users");
      for (User u : list) {
        OmTimeZone tz = u.getOmTimeZone();
        if (tz == null || tz.getJname() == null) {
          String jNameTimeZone = configurationDao.getConfValue(
              "default.timezone", String.class, "Europe/Berlin");
          OmTimeZone omTimeZone = omTimeZoneDaoImpl.getOmTimeZone(jNameTimeZone);
          u.setOmTimeZone(omTimeZone);
          u.setForceTimeZoneCheck(true);
        } else {
          u.setForceTimeZoneCheck(false);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.