org.apache.naming.resources.WARDirContext.listBindings()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(1.8k)|赞(0)|评价(0)|浏览(103)

本文整理了Java中org.apache.naming.resources.WARDirContext.listBindings()方法的一些代码示例,展示了WARDirContext.listBindings()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WARDirContext.listBindings()方法的具体详情如下:
包路径:org.apache.naming.resources.WARDirContext
类名称:WARDirContext
方法名:listBindings

WARDirContext.listBindings介绍

[英]Enumerates the names bound in the named context, along with the objects bound to them. The contents of any subcontexts are not included.

If a binding is added to or removed from this context, its effect on an enumeration previously returned is undefined.
[中]枚举在命名上下文中绑定的名称以及绑定到它们的对象。不包括任何分包文本的内容。
如果在该上下文中添加或删除绑定,则其对先前返回的枚举的影响未定义。

代码示例

代码示例来源:origin: jboss.web/jbossweb

/**
 * Enumerates the names bound in the named context, along with the 
 * objects bound to them. The contents of any subcontexts are not 
 * included.
 * <p>
 * If a binding is added to or removed from this context, its effect on 
 * an enumeration previously returned is undefined.
 * 
 * @param name the name of the context to list
 * @return an enumeration of the bindings in this context. 
 * Each element of the enumeration is of type Binding.
 * @exception NamingException if a naming exception is encountered
 */
public NamingEnumeration listBindings(String name)
  throws NamingException {
  return listBindings(new CompositeName(name));
}

代码示例来源:origin: org.jboss.web/jbossweb

/**
 * Enumerates the names bound in the named context, along with the 
 * objects bound to them. The contents of any subcontexts are not 
 * included.
 * <p>
 * If a binding is added to or removed from this context, its effect on 
 * an enumeration previously returned is undefined.
 * 
 * @param name the name of the context to list
 * @return an enumeration of the bindings in this context. 
 * Each element of the enumeration is of type Binding.
 * @exception NamingException if a naming exception is encountered
 */
public NamingEnumeration listBindings(String name)
  throws NamingException {
  return listBindings(new CompositeName(name));
}

相关文章