Search in sources :

Example 16 with Config

use of com.zimbra.cs.account.Config in project zm-mailbox by Zimbra.

the class BUG_57205 method doGlobalConfig.

private void doGlobalConfig(ZLdapContext zlc) throws ServiceException {
    Config config = prov.getConfig();
    doEntry(zlc, config);
}
Also used : Config(com.zimbra.cs.account.Config)

Example 17 with Config

use of com.zimbra.cs.account.Config in project zm-mailbox by Zimbra.

the class BUG_63475 method doGlobalConfig.

private void doGlobalConfig(ZLdapContext zlc) throws ServiceException {
    Config config = prov.getConfig();
    doEntry(zlc, config, "global config");
}
Also used : Config(com.zimbra.cs.account.Config)

Example 18 with Config

use of com.zimbra.cs.account.Config in project zm-mailbox by Zimbra.

the class BUG_32719 method doGlobalConfig.

private void doGlobalConfig(ZLdapContext zlc) throws ServiceException {
    Config config = prov.getConfig();
    doEntry(zlc, config, "global config");
}
Also used : Config(com.zimbra.cs.account.Config)

Example 19 with Config

use of com.zimbra.cs.account.Config in project zm-mailbox by Zimbra.

the class BUG_58481 method upgradeZimbraGalLdapAttrMap.

private void upgradeZimbraGalLdapAttrMap() throws ServiceException {
    final String attrName = Provisioning.A_zimbraGalLdapAttrMap;
    final String[] valuesToAdd = new String[] { "objectClass=objectClass", "zimbraId=zimbraId", "zimbraMailForwardingAddress=member" };
    Config config = prov.getConfig();
    Map<String, Object> attrs = new HashMap<String, Object>();
    Set<String> curValues = config.getMultiAttrSet(attrName);
    for (String valueToAdd : valuesToAdd) {
        if (!curValues.contains(valueToAdd)) {
            StringUtil.addToMultiMap(attrs, "+" + attrName, valueToAdd);
        }
    }
    modifyAttrs(config, attrs);
}
Also used : HashMap(java.util.HashMap) Config(com.zimbra.cs.account.Config)

Example 20 with Config

use of com.zimbra.cs.account.Config in project zm-mailbox by Zimbra.

the class GetAllConfig method handle.

public Element handle(Element request, Map<String, Object> context) throws ServiceException {
    ZimbraSoapContext zsc = getZimbraSoapContext(context);
    Provisioning prov = Provisioning.getInstance();
    Config config = prov.getConfig();
    AdminAccessControl aac = checkRight(zsc, context, config, AdminRight.PR_ALWAYS_ALLOW);
    Element response = zsc.createElement(AdminConstants.GET_ALL_CONFIG_RESPONSE);
    encodeConfig(response, config, null, aac.getAttrRightChecker(config));
    return response;
}
Also used : ZimbraSoapContext(com.zimbra.soap.ZimbraSoapContext) Config(com.zimbra.cs.account.Config) Element(com.zimbra.common.soap.Element) Provisioning(com.zimbra.cs.account.Provisioning)

Aggregations

Config (com.zimbra.cs.account.Config)73 HashMap (java.util.HashMap)24 Provisioning (com.zimbra.cs.account.Provisioning)10 Test (org.junit.Test)8 ServiceException (com.zimbra.common.service.ServiceException)7 Account (com.zimbra.cs.account.Account)7 RetentionPolicy (com.zimbra.soap.mail.type.RetentionPolicy)7 Element (com.zimbra.common.soap.Element)6 Policy (com.zimbra.soap.mail.type.Policy)6 Cos (com.zimbra.cs.account.Cos)5 Server (com.zimbra.cs.account.Server)5 Domain (com.zimbra.cs.account.Domain)4 ZimbraSoapContext (com.zimbra.soap.ZimbraSoapContext)4 Pair (com.zimbra.common.util.Pair)3 HashSet (java.util.HashSet)3 SMTPMessage (com.sun.mail.smtp.SMTPMessage)2 ZFilterAction (com.zimbra.client.ZFilterAction)2 ZFileIntoAction (com.zimbra.client.ZFilterAction.ZFileIntoAction)2 ZFilterCondition (com.zimbra.client.ZFilterCondition)2 ZHeaderCondition (com.zimbra.client.ZFilterCondition.ZHeaderCondition)2