@Override
    public boolean hasObjectWithPrefix(JavaColonNamespace namespace, String name) throws NamingException {
        final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
        if (isTraceOn && tc.isEntryEnabled())
            Tr.entry(tc, "hasObjectWithPrefix (" + namespace + ", " + name + ")");

        if (name == null) {
            throw new InvalidNameException();
        }

        boolean result = false;
        // This helper only provides support for java:comp/env
        if (namespace == JavaColonNamespace.COMP && name.isEmpty()) {
            result = true;
        }

        if (isTraceOn && tc.isEntryEnabled())
            Tr.exit(tc, "hasObjectWithPrefix", result);
        return result;
    }
@ Override public boolean hasObjectWithPrefix ( JavaColonNamespace namespace , String name ) throws NamingException { final boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "hasObjectWithPrefix (" + namespace + ", " + name + ")" ) ; if ( name == null ) { throw new InvalidNameException ( ) ; } boolean result = false ; if ( namespace == JavaColonNamespace . COMP && name . isEmpty ( ) ) { result = true ; } if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . exit ( tc , "hasObjectWithPrefix" , result ) ; return result ; }
{@inheritDoc}

@throws NameException