Search in sources :

Example 51 with ZLdapFilter

use of com.zimbra.cs.ldap.ZLdapFilter in project zm-mailbox by Zimbra.

the class TestLdapZLdapFilter method signatureById.

@Test
public void signatureById() throws Exception {
    String ID = genUUID();
    String filter = LegacyLdapFilter.signatureById(ID);
    ZLdapFilter zLdapFilter = filterDactory.signatureById(ID);
    verify(FilterId.SIGNATURE_BY_ID, filter, zLdapFilter);
}
Also used : ZLdapFilter(com.zimbra.cs.ldap.ZLdapFilter)

Example 52 with ZLdapFilter

use of com.zimbra.cs.ldap.ZLdapFilter in project zm-mailbox by Zimbra.

the class TestLdapZLdapFilter method createdLaterOrEqual.

@Test
public void createdLaterOrEqual() throws Exception {
    String GENERALIZED_TIME = "20111005190522Z";
    String filter = LegacyLdapFilter.createdLaterOrEqual(GENERALIZED_TIME);
    ZLdapFilter zLdapFilter = filterDactory.createdLaterOrEqual(GENERALIZED_TIME);
    verify(FilterId.CREATED_LATEROREQUAL, filter, zLdapFilter);
}
Also used : ZLdapFilter(com.zimbra.cs.ldap.ZLdapFilter)

Example 53 with ZLdapFilter

use of com.zimbra.cs.ldap.ZLdapFilter in project zm-mailbox by Zimbra.

the class TestLdapZLdapFilter method memberOf.

@Test
public void memberOf() throws Exception {
    String DN = "dc=com";
    String filter = LegacyLdapFilter.memberOf(DN);
    ZLdapFilter zLdapFilter = filterDactory.memberOf(DN);
    verify(FilterId.MEMBER_OF, filter, zLdapFilter);
}
Also used : ZLdapFilter(com.zimbra.cs.ldap.ZLdapFilter)

Example 54 with ZLdapFilter

use of com.zimbra.cs.ldap.ZLdapFilter in project zm-mailbox by Zimbra.

the class TestLdapZLdapFilter method allAdminAccounts.

@Test
public void allAdminAccounts() throws Exception {
    String filter = LegacyLdapFilter.allAdminAccounts();
    ZLdapFilter zLdapFilter = filterDactory.allAdminAccounts();
    verify(FilterId.ALL_ADMIN_ACCOUNTS, filter, zLdapFilter);
}
Also used : ZLdapFilter(com.zimbra.cs.ldap.ZLdapFilter)

Example 55 with ZLdapFilter

use of com.zimbra.cs.ldap.ZLdapFilter in project zm-mailbox by Zimbra.

the class TestLdapZLdapFilter method accountByName.

@Test
public void accountByName() throws Exception {
    String NAME = getTestName();
    String filter = LegacyLdapFilter.accountByName(NAME);
    ZLdapFilter zLdapFilter = filterDactory.accountByName(NAME);
    verify(FilterId.ACCOUNT_BY_NAME, filter, zLdapFilter);
}
Also used : ZLdapFilter(com.zimbra.cs.ldap.ZLdapFilter)

Aggregations

ZLdapFilter (com.zimbra.cs.ldap.ZLdapFilter)123 ZSearchResultEntry (com.zimbra.cs.ldap.ZSearchResultEntry)15 ZSearchResultEnumeration (com.zimbra.cs.ldap.ZSearchResultEnumeration)13 ZLdapContext (com.zimbra.cs.ldap.ZLdapContext)10 ZSearchControls (com.zimbra.cs.ldap.ZSearchControls)10 ServiceException (com.zimbra.common.service.ServiceException)9 AccountServiceException (com.zimbra.cs.account.AccountServiceException)8 AuthFailedServiceException (com.zimbra.cs.account.AccountServiceException.AuthFailedServiceException)8 ArrayList (java.util.ArrayList)8 Server (com.zimbra.cs.account.Server)7 LdapDIT (com.zimbra.cs.account.ldap.LdapDIT)7 Account (com.zimbra.cs.account.Account)6 LdapSizeLimitExceededException (com.zimbra.cs.ldap.LdapException.LdapSizeLimitExceededException)6 NamedEntry (com.zimbra.cs.account.NamedEntry)5 SearchAccountsOptions (com.zimbra.cs.account.SearchAccountsOptions)5 BySearchResultEntrySearcher (com.zimbra.cs.account.ldap.BySearchResultEntrySearcher)5 SearchLdapOptions (com.zimbra.cs.ldap.SearchLdapOptions)5 ProvTest (com.zimbra.qa.unittest.prov.ProvTest)5 LDAPException (com.unboundid.ldap.sdk.LDAPException)3 SearchRequest (com.unboundid.ldap.sdk.SearchRequest)3