Package com.anthonyeden.lib.config

Examples of com.anthonyeden.lib.config.MutableConfiguration.addAttribute()


    BGAreaManager am = BGAreaManagerImpl.getInstance();
    List areas = am.findBGAreasOfBGContext(context);
    for (Iterator iter = areas.iterator(); iter.hasNext();) {
      BGArea area = (BGArea) iter.next();
      MutableConfiguration newArea = confAreas.addChild(EXPORT_KEY_AREA);
      newArea.addAttribute(EXPORT_ATTR_NAME, area.getName());
      newArea.addChild(EXPORT_KEY_DESCRIPTION, area.getDescription());
    }

    // TODO fg: export group rights
View Full Code Here


    saveGroupConfiguration(fExportFile, root);
  }

  private void exportGroup(File fExportFile, MutableConfiguration confGroups, BusinessGroup group) {
    MutableConfiguration newGroup = confGroups.addChild(EXPORT_KEY_GROUP);
    newGroup.addAttribute(EXPORT_ATTR_NAME, group.getName());
    if (group.getMinParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MIN_PARTICIPATS, group.getMinParticipants());
    if (group.getMaxParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MAX_PARTICIPATS, group.getMaxParticipants());     
    if (group.getWaitingListEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_WAITING_LIST, group.getWaitingListEnabled());
    if (group.getAutoCloseRanksEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_AUTO_CLOSE_RANKS, group.getAutoCloseRanksEnabled());
    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
View Full Code Here

  }

  private void exportGroup(File fExportFile, MutableConfiguration confGroups, BusinessGroup group) {
    MutableConfiguration newGroup = confGroups.addChild(EXPORT_KEY_GROUP);
    newGroup.addAttribute(EXPORT_ATTR_NAME, group.getName());
    if (group.getMinParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MIN_PARTICIPATS, group.getMinParticipants());
    if (group.getMaxParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MAX_PARTICIPATS, group.getMaxParticipants());     
    if (group.getWaitingListEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_WAITING_LIST, group.getWaitingListEnabled());
    if (group.getAutoCloseRanksEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_AUTO_CLOSE_RANKS, group.getAutoCloseRanksEnabled());
    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
    // collab tools
View Full Code Here

  private void exportGroup(File fExportFile, MutableConfiguration confGroups, BusinessGroup group) {
    MutableConfiguration newGroup = confGroups.addChild(EXPORT_KEY_GROUP);
    newGroup.addAttribute(EXPORT_ATTR_NAME, group.getName());
    if (group.getMinParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MIN_PARTICIPATS, group.getMinParticipants());
    if (group.getMaxParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MAX_PARTICIPATS, group.getMaxParticipants());     
    if (group.getWaitingListEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_WAITING_LIST, group.getWaitingListEnabled());
    if (group.getAutoCloseRanksEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_AUTO_CLOSE_RANKS, group.getAutoCloseRanksEnabled());
    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
    // collab tools
    MutableConfiguration toolsConfig = newGroup.addChild(EXPORT_KEY_COLLABTOOLS);
View Full Code Here

  private void exportGroup(File fExportFile, MutableConfiguration confGroups, BusinessGroup group) {
    MutableConfiguration newGroup = confGroups.addChild(EXPORT_KEY_GROUP);
    newGroup.addAttribute(EXPORT_ATTR_NAME, group.getName());
    if (group.getMinParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MIN_PARTICIPATS, group.getMinParticipants());
    if (group.getMaxParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MAX_PARTICIPATS, group.getMaxParticipants());     
    if (group.getWaitingListEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_WAITING_LIST, group.getWaitingListEnabled());
    if (group.getAutoCloseRanksEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_AUTO_CLOSE_RANKS, group.getAutoCloseRanksEnabled());
    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
    // collab tools
    MutableConfiguration toolsConfig = newGroup.addChild(EXPORT_KEY_COLLABTOOLS);
    CollaborationTools ct = CollaborationToolsFactory.getInstance().getOrCreateCollaborationTools(group);
View Full Code Here

    MutableConfiguration newGroup = confGroups.addChild(EXPORT_KEY_GROUP);
    newGroup.addAttribute(EXPORT_ATTR_NAME, group.getName());
    if (group.getMinParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MIN_PARTICIPATS, group.getMinParticipants());
    if (group.getMaxParticipants() != null) newGroup.addAttribute(EXPORT_ATTR_MAX_PARTICIPATS, group.getMaxParticipants());     
    if (group.getWaitingListEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_WAITING_LIST, group.getWaitingListEnabled());
    if (group.getAutoCloseRanksEnabled() != null) newGroup.addAttribute(EXPORT_ATTR_AUTO_CLOSE_RANKS, group.getAutoCloseRanksEnabled());
    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
    // collab tools
    MutableConfiguration toolsConfig = newGroup.addChild(EXPORT_KEY_COLLABTOOLS);
    CollaborationTools ct = CollaborationToolsFactory.getInstance().getOrCreateCollaborationTools(group);
    for (int i = 0; i < CollaborationTools.TOOLS.length; i++) {
View Full Code Here

    newGroup.addChild(EXPORT_KEY_DESCRIPTION, group.getDescription());
    // collab tools
    MutableConfiguration toolsConfig = newGroup.addChild(EXPORT_KEY_COLLABTOOLS);
    CollaborationTools ct = CollaborationToolsFactory.getInstance().getOrCreateCollaborationTools(group);
    for (int i = 0; i < CollaborationTools.TOOLS.length; i++) {
      toolsConfig.addAttribute(CollaborationTools.TOOLS[i], ct.isToolEnabled(CollaborationTools.TOOLS[i]) ? "true" : "false");
    }
    Long calendarAccess = ct.lookupCalendarAccess();
    if (calendarAccess != null) {
      newGroup.addAttribute(EXPORT_KEY_CALENDAR_ACCESS,calendarAccess);     
    }
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.