• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Java LDAPSearchConstraints类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: postSearchEntry

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchEntry(PostSearchEntryInterceptorChain chain,
		Entry entry, DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	chain.nextPostSearchEntry(entry, base, scope, filter, attributes, typesOnly, constraints);

	LDAPAttribute attr = entry.getEntry().getAttribute("objectClass");
	if (attr != null) {
		String[] vals = attr.getStringValueArray();
		for (String oc : vals) {
			if (oc.equalsIgnoreCase(this.objectClass)) {
				LDAPAttribute nattr = new LDAPAttribute(this.attributeName,this.attributeValue);
				entry.getEntry().getAttributeSet().add(nattr);
			}
		}
	}
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:19,代码来源:AddAttribute.java


示例2: postSearchEntry

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchEntry(PostSearchEntryInterceptorChain chain, Entry entry, DistinguishedName base, Int scope,
		Filter filter, ArrayList<Attribute> attributes, Bool typesOnly, LDAPSearchConstraints constraints)
				throws LDAPException {
	
	chain.nextPostSearchEntry(entry, base, scope, filter, attributes, typesOnly, constraints);
	
	LDAPAttribute attr = entry.getEntry().getAttribute(this.attributeName);
	if (attr != null) {
		LDAPAttribute nattr = new LDAPAttribute(this.attributeName);
		String[] vals = attr.getStringValueArray();
		for (String val : vals) {
			nattr.addValue(this.attr2dn(val,chain));
		}
		entry.getEntry().getAttributeSet().remove(this.attributeName);
		entry.getEntry().getAttributeSet().add(nattr);
	}

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:20,代码来源:Attribute2DN.java


示例3: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public Results  search(DistinguishedName base,Int scope,Filter filter,ArrayList<Attribute> attributes,Bool typesOnly,LDAPSearchConstraints constraints) throws LDAPException {
	this.initRequest();
	this.request = new HashMap<Object,Object>();
	
	SearchInterceptorChain searchChain;
	Results results;
	
	if (this.ns.isGlobal()) {
		searchChain = new SearchInterceptorChain(this.bindDN,this.pass,this.pos,this.ns.getChain(),this.session,this.request,this.ns.getRouter());
		results = new Results(this.ns.getChain(),this.pos);
	} else {
		searchChain = new SearchInterceptorChain(this.bindDN,this.pass,this.pos,this.ns.getChain(),this.session,this.request);
		results = new Results(null,this.pos);
	}
	
	searchChain.nextSearch(base, scope, filter, attributes, typesOnly, results, constraints);
	
	return results; 
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:20,代码来源:ConnectionUtil.java


示例4: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	chain.nextPostSearchComplete(base, scope, filter, attributes, typesOnly, constraints);
	
	long start = (Long) chain.getRequest().get(AccessLog.ACCESS_LOG_SRCH_BEGIN + this.name);
	Int op = (Int) chain.getRequest().get(AccessLog.ACCESS_LOG_SRCH_OP + this.name);
	Int con = (Int) chain.getRequest().get(AccessLog.ACCESS_LOG_SRCH_CON + this.name);
	Int nentries = (Int) chain.getRequest().get(AccessLog.ACCESS_LOG_SRCH_COUNT + this.name);
	long end = System.currentTimeMillis();

	StringBuffer buf = new StringBuffer();
	buf.append("SRCH-RESULT op=").append(op.getValue()).append(" con=").append(con.getValue()).append(" entries=").append(nentries.getValue()).append(" time=").append(end-start);

	logger.info(buf);
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:18,代码来源:AccessLog.java


示例5: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	
	log("Begin Post Search Complete - Filter=" + filter.getValue() + ";Base=" + base.toString() + ";Scope=" + scope.getValue() + ";Attributes=" + attributes);
	
	try {
	chain.nextPostSearchComplete(base,scope,filter,attributes,typesOnly,constraints);
	} catch (Throwable t) {
		log("Post Search Complete Error",t);
		if (t instanceof LDAPException) {
			throw ((LDAPException) t);
		} else {
			throw new RuntimeException(t);
		}
	} finally {
		log("Post Search Complete Complete");
	}

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:22,代码来源:DumpTransaction.java


示例6: postSearchEntry

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchEntry(PostSearchEntryInterceptorChain chain,
		Entry entry, DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	
	chain.nextPostSearchEntry(entry, base, scope, filter, attributes, typesOnly, constraints);
	
	boolean needUPN = (Boolean) chain.getRequest().get("CREATEUPN_NEEDUPN");
	
	
	
	if (needUPN) {
		LDAPAttribute upn = entry.getEntry().getAttribute("userprincipalname");
		if (upn == null) {
			LDAPAttribute prefixAttr = entry.getEntry().getAttribute(this.prefixAttrName);
			if (prefixAttr != null) {
				StringBuffer sb = new StringBuffer();
				sb.append(prefixAttr.getStringValue()).append('@').append(this.suffix);
				entry.getEntry().getAttributeSet().add(new LDAPAttribute("userPrincipalName",sb.toString()));
			}
		}
	}

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:26,代码来源:CreateUPN.java


示例7: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void search(SearchInterceptorChain chain, DistinguishedName base,
		Int scope, Filter filter, ArrayList<Attribute> attributes,
		Bool typesOnly, Results results, LDAPSearchConstraints constraints)
		throws LDAPException {
	
	Filter nfilter = null;
	
	try {
		FilterNode nroot = (FilterNode) filter.getRoot().clone();
		nfilter = new Filter(nroot);
	} catch (CloneNotSupportedException e) {
		throw new LDAPException("Could not clone filter",LDAPException.OPERATIONS_ERROR,"Could not clone filter",e);
	}

	this.toBin(nfilter.getRoot());
	
	
	
	chain.nextSearch(base, scope, nfilter, attributes, typesOnly, results, constraints);
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:22,代码来源:UUIDtoText.java


示例8: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void search(SearchInterceptorChain chain, DistinguishedName base,
		Int scope, Filter filter, ArrayList<Attribute> attributes,
		Bool typesOnly, Results results, LDAPSearchConstraints constraints)
		throws LDAPException {
	
	FilterNode newFilter = null;
	try {
		newFilter = (FilterNode) filter.getRoot().clone();
	} catch (CloneNotSupportedException e) {
		//Can't happen
	}
	
	this.mapFilter(newFilter);
	
	chain.nextSearch(base, scope, new Filter(newFilter), attributes, typesOnly, results, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:19,代码来源:RemoveDoubleQuotesFromDNFilter.java


示例9: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void search(SearchInterceptorChain chain, DistinguishedName base,
		Int scope, Filter filter, ArrayList<Attribute> attributes,
		Bool typesOnly, Results results, LDAPSearchConstraints constraints)
		throws LDAPException {
	
	StringBuffer buf = new StringBuffer();
	Iterator<Attribute> it = attributes.iterator();
	while (it.hasNext()) {
		buf.append(it.next().getAttribute().getName()).append(' ');
	}
	
	log("Begin Seach - Filter=" + filter.getValue() + ";Base=" + base.toString() + ";Scope=" + scope.getValue() + ";Attributes=" + buf.toString());
	
	try {
		chain.nextSearch(base,scope,filter,attributes,typesOnly,results,constraints);
	} catch (Throwable t) {
		log("Error Running Search",t);
		if (t instanceof LDAPException) {
			throw ((LDAPException) t);
		} else {
			throw new RuntimeException(t);
		}
	} finally {
		log("Seach submitted");
	}
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:27,代码来源:DumpTransaction.java


示例10: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	chain.nextPostSearchComplete(base, scope, filter, attributes, typesOnly, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:9,代码来源:AddAttribute.java


示例11: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	
	Stack<JoinData> joinStack = (Stack<JoinData>) chain.getRequest().get(this.stackKey);
	if (joinStack != null && joinStack.size() > 0 ) {
		joinStack.pop();
	}

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:12,代码来源:Joiner.java


示例12: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	// TODO Auto-generated method stub

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:8,代码来源:JoinAddFlatNS.java


示例13: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchComplete(PostSearchCompleteInterceptorChain chain, DistinguishedName base, Int scope,
		Filter filter, ArrayList<Attribute> attributes, Bool typesOnly, LDAPSearchConstraints constraints)
		throws LDAPException {
	chain.nextPostSearchComplete(base, scope, filter, attributes, typesOnly, constraints);
	
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:8,代码来源:AddActiveDirectoryEnabledFlag.java


示例14: postSearchEntry

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchEntry(PostSearchEntryInterceptorChain chain,
		Entry entry, DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	
	chain.nextPostSearchEntry(entry, base, scope, filter, attributes, typesOnly, constraints);
	entry.setEntry(this.mapEntry(entry.getEntry(), false));

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:10,代码来源:DNAttributeMapper.java


示例15: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void search(SearchInterceptorChain chain, DistinguishedName base, Int scope, Filter filter, ArrayList<Attribute> attributes, Bool typesOnly, Results results, LDAPSearchConstraints constraints) throws LDAPException {
	FilterNode newRoot;
	try {
		newRoot = (FilterNode) filter.getRoot().clone();
	} catch (CloneNotSupportedException e) {
		throw new LDAPException("Could not map filter " + e.toString(),LDAPException.OPERATIONS_ERROR,"");
	}
	this.renameFilter(newRoot);
	
	chain.nextSearch(base,scope,new Filter(newRoot),attributes,typesOnly,results,constraints);
	
}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:13,代码来源:AttributeValueMapper.java


示例16: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchComplete(PostSearchCompleteInterceptorChain chain,
		DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	chain.nextPostSearchComplete(base, scope, filter, attributes, typesOnly, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:8,代码来源:DNAttributeMapper.java


示例17: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void search(SearchInterceptorChain chain, DistinguishedName base,
		Int scope, Filter filter, ArrayList<Attribute> attributes,
		Bool typesOnly, Results results, LDAPSearchConstraints constraints)
		throws LDAPException {
	chain.nextSearch(base, scope, filter, attributes, typesOnly, results, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:9,代码来源:AddTlsParamInsert.java


示例18: postSearchEntry

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void postSearchEntry(PostSearchEntryInterceptorChain chain,
		Entry entry, DistinguishedName base, Int scope, Filter filter,
		ArrayList<Attribute> attributes, Bool typesOnly,
		LDAPSearchConstraints constraints) throws LDAPException {
	
	chain.nextPostSearchEntry(entry,base,scope,filter,attributes,typesOnly,constraints);
	
	ArrayList<Attribute> origAttributes = (ArrayList<Attribute>) chain.getRequest().get(key);
	
	attributes.clear();
	
	attributes.addAll(origAttributes);
	
	if (attributes.size() != 0 && ! attributes.contains(ALL_ATTRIBS)) {
		LDAPAttributeSet newAttribs = new LDAPAttributeSet();
		Iterator<Attribute> it = attributes.iterator();
		while (it.hasNext()) {
			LDAPAttribute attrib = entry.getEntry().getAttribute(it.next().getAttribute().getName()); 
			if (attrib != null) {
				newAttribs.add(attrib);
			}
		}
		
		entry.setEntry(new LDAPEntry(entry.getEntry().getDN(),newAttribs));
	}
	

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:29,代码来源:AttributeCleaner.java


示例19: postSearchComplete

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
@Override
public void postSearchComplete(PostSearchCompleteInterceptorChain chain, DistinguishedName base, Int scope,
		Filter filter, ArrayList<Attribute> attributes, Bool typesOnly, LDAPSearchConstraints constraints)
				throws LDAPException {
	chain.nextPostSearchComplete(base, scope, filter, attributes, typesOnly, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:8,代码来源:FormatDate.java


示例20: search

import com.novell.ldap.LDAPSearchConstraints; //导入依赖的package包/类
public void search(SearchInterceptorChain chain, DistinguishedName base,
		Int scope, Filter filter, ArrayList<Attribute> attributes,
		Bool typesOnly, Results results, LDAPSearchConstraints constraints)
		throws LDAPException {
	
	
	DN internalBase = this.getInternalDN(base.getDN(), chain);
	ArrayList<Attribute> attribs = this.createNewAttribs(attributes);
	chain.nextSearch(new DistinguishedName(internalBase), scope, filter, attribs, typesOnly, results, constraints);

}
 
开发者ID:TremoloSecurity,项目名称:MyVirtualDirectory,代码行数:12,代码来源:SetRDN.java



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java GeocodeParameters类代码示例发布时间:2022-05-23
下一篇:
Java Problem类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap