当前位置: 首页>>代码示例>>Java>>正文


Java LdapInvalidSearchFilterException类代码示例

本文整理汇总了Java中org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException的典型用法代码示例。如果您正苦于以下问题:Java LdapInvalidSearchFilterException类的具体用法?Java LdapInvalidSearchFilterException怎么用?Java LdapInvalidSearchFilterException使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


LdapInvalidSearchFilterException类属于org.apache.directory.api.ldap.model.exception包,在下文中一共展示了LdapInvalidSearchFilterException类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: search

import org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
public EntryFilteringCursor search( Dn dn, String filter, boolean ignoreReferrals ) throws LdapException
{
    OperationManager operationManager = directoryService.getOperationManager();
    ExprNode filterNode = null;

    try
    {
        filterNode = FilterParser.parse( directoryService.getSchemaManager(), filter );
    }
    catch ( ParseException pe )
    {
        throw new LdapInvalidSearchFilterException( pe.getMessage() );
    }

    SearchOperationContext searchContext = new SearchOperationContext( this, dn, SearchScope.OBJECT, filterNode,
        ( String ) null );
    searchContext.setAliasDerefMode( AliasDerefMode.DEREF_ALWAYS );
    setReferralHandling( searchContext, ignoreReferrals );

    return operationManager.search( searchContext );
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:25,代码来源:DefaultCoreSession.java

示例2: search

import org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException; //导入依赖的package包/类
/**
 * {@inheritDoc}
 */
public Cursor<Entry> search( Dn dn, String filter, boolean ignoreReferrals ) throws LdapException
{
    OperationManager operationManager = directoryService.getOperationManager();
    ExprNode filterNode = null;

    try
    {
        filterNode = FilterParser.parse( directoryService.getSchemaManager(), filter );
    }
    catch ( ParseException pe )
    {
        throw new LdapInvalidSearchFilterException( pe.getMessage() );
    }

    SearchOperationContext searchContext = new SearchOperationContext( this, dn, SearchScope.OBJECT, filterNode,
        ( String ) null );
    searchContext.setAliasDerefMode( AliasDerefMode.DEREF_ALWAYS );
    setReferralHandling( searchContext, ignoreReferrals );

    return operationManager.search( searchContext );
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:25,代码来源:DefaultCoreSession.java

示例3: generateException

import org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException; //导入依赖的package包/类
public static LdapException generateException(LDAPException e) {
	LdapException ex;
	
	switch (e.getResultCode()) {
	
		
		case 1 : ex = new org.apache.directory.api.ldap.model.exception.LdapOperationErrorException(e.getMessage(), e); break;
		case 2 : ex = new org.apache.directory.api.ldap.model.exception.LdapProtocolErrorException(e.getMessage(), e); break;
		case 3 : ex = new org.apache.directory.api.ldap.model.exception.LdapTimeLimitExceededException(e.getMessage()); break;
		case 4 : ex = new org.apache.directory.api.ldap.model.exception.LdapSizeLimitExceededException(e.getMessage()); break;
		case 48:
		case 7 : ex = new org.apache.directory.api.ldap.model.exception.LdapAuthenticationNotSupportedException(ResultCodeEnum.AUTH_METHOD_NOT_SUPPORTED); break;
		case 8 : ex = new org.apache.directory.api.ldap.model.exception.LdapStrongAuthenticationRequiredException(e.getMessage()); break;
		case 11 : ex = new org.apache.directory.api.ldap.model.exception.LdapAdminLimitExceededException(e.getMessage()); break;
		case 53 :
		case 12 : ex = new org.apache.directory.api.ldap.model.exception.LdapUnwillingToPerformException(e.getMessage()); break;
		case 13 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoPermissionException(e.getMessage()); break;
		case 16 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoSuchAttributeException(e.getMessage()); break;
		case 17 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoSuchAttributeException(e.getMessage()); break;
		case 18 : ex = new org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException(e.getMessage()); break;
		case 21:
		case 19 : ex = new org.apache.directory.api.ldap.model.exception.LdapInvalidAttributeValueException(ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX, e.getMessage());
		case 20 : ex = new org.apache.directory.api.ldap.model.exception.LdapAttributeInUseException(e.getMessage()); break;
		case 32 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoSuchObjectException(e.getMessage()); break;
		case 34 : ex = new org.apache.directory.api.ldap.model.exception.LdapInvalidDnException(e.getMessage()); break;
		case 49 : ex = new org.apache.directory.api.ldap.model.exception.LdapAuthenticationException(e.getMessage()); break;
		case 50 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoPermissionException(e.getMessage()); break;
		case 52 :
		case 51 : ex = new org.apache.directory.api.ldap.model.exception.LdapServiceUnavailableException(ResultCodeEnum.UNAVAILABLE); break;
		case 54 : ex = new org.apache.directory.api.ldap.model.exception.LdapLoopDetectedException(e.getMessage());
		case 64 : ex = new org.apache.directory.api.ldap.model.exception.LdapInvalidDnException(e.getMessage()); break;
		case 65 : ex = new org.apache.directory.api.ldap.model.exception.LdapNoSuchAttributeException(e.getMessage()); break;
		case 66 : ex = new org.apache.directory.api.ldap.model.exception.LdapContextNotEmptyException(e.getMessage()); break;
		case 69 :
		case 67 : ex = new org.apache.directory.api.ldap.model.exception.LdapSchemaException(e.getMessage()); break;
		case 68 : ex = new org.apache.directory.api.ldap.model.exception.LdapEntryAlreadyExistsException(e.getMessage()); break;
		case 71 : ex = new org.apache.directory.api.ldap.model.exception.LdapAffectMultipleDsaException(e.getMessage()); break;
		case 80 : ex = new org.apache.directory.api.ldap.model.exception.LdapOtherException(e.getMessage()); break;
	    		
		default : ex = new org.apache.directory.api.ldap.model.exception.LdapOperationErrorException(e.getMessage(), e); break;
	}
	
	ex.setStackTrace(e.getStackTrace());
	return ex;
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:46,代码来源:MyVDInterceptor.java


注:本文中的org.apache.directory.api.ldap.model.exception.LdapInvalidSearchFilterException类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。