## org.mortbay.jetty.plus.naming
Class NamingEntryUtil

    java.lang.Object
      org.mortbay.jetty.plus.naming.NamingEntryUtil

    public class NamingEntryUtil

extends Object

Constructor Summary
`NamingEntryUtil()`

Method Summary
`static boolean` `bindToENC(Object scope, String asName, String mappedName)` Link a name in a webapp's java:/comp/evn namespace to a pre-existing resource.
`static Context` `getContextForNamingEntries(Object scope)`
`static Context` `getContextForScope(Object scope)`
`static Name` `getNameForScope(Object scope)`
`static List` `lookupNamingEntries(Object scope, Class clazz)` Get all NameEntries of a certain type in the given naming environment scope (server-wide names or context-specific names)
`static NamingEntry` `lookupNamingEntry(Object scope, String jndiName)` Find a NamingEntry instance.
`static Name` `makeNamingEntryName(NameParser parser, NamingEntry namingEntry)`
`static Name` `makeNamingEntryName(NameParser parser, String jndiName)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### NamingEntryUtil

    public NamingEntryUtil()

Method Detail

### bindToENC

    public static boolean bindToENC(Object scope,
                                    String asName,
                                    String mappedName)
                             throws NamingException

  Link a name in a webapp's java:/comp/evn namespace to a pre-existing resource. The pre-existing resource can be either in the webapp's naming environment, or in the container's naming environment. Webapp's environment takes precedence over the server's namespace.

  Parameters:
    `asName` - the name to bind as
    `mappedName` - the name from the environment to link to asName
    `namingEntryType` -
  Throws:
    `NamingException`

### lookupNamingEntry

    public static NamingEntry lookupNamingEntry(Object scope,
                                                String jndiName)
                                         throws NamingException

  Find a NamingEntry instance. First the webapp's naming space is searched, and then the container's.

  Parameters:
    `jndiName` - name to lookup
  Returns:
  Throws:
    `NamingException`

### lookupNamingEntries

    public static List lookupNamingEntries(Object scope,
                                           Class clazz)
                                    throws NamingException

  Get all NameEntries of a certain type in the given naming environment scope (server-wide names or context-specific names)

  Parameters:
    `scope` -
    `clazz` - the type of the entry
  Returns:
  Throws:
    `NamingException`

### makeNamingEntryName

    public static Name makeNamingEntryName(NameParser parser,
                                           NamingEntry namingEntry)
                                    throws NamingException

  Throws:
    `NamingException`

### makeNamingEntryName

    public static Name makeNamingEntryName(NameParser parser,
                                           String jndiName)
                                    throws NamingException

  Throws:
    `NamingException`

### getNameForScope

    public static Name getNameForScope(Object scope)

### getContextForScope

    public static Context getContextForScope(Object scope)
                                      throws NamingException

  Throws:
    `NamingException`

### getContextForNamingEntries

    public static Context getContextForNamingEntries(Object scope)
                                              throws NamingException

  Throws:
    `NamingException`

Copyright © 1995-2008 Mort Bay Consulting. All Rights Reserved.