Index index = ( Index ) getUserIndex( attr );
Index index = getUserIndex( attr );
    public void delete( BigInteger id ) throws  NamingException    {        Attributes entry = lookup( id );        BigInteger parentId = getParentId( id );        NamingEnumeration attrs = entry.getIDs();                if ( entry.get( "objectClass" ).contains( ALIAS_OBJECT ) )        {            dropAliasIndices( id );        }        ndnIdx.drop( id );        updnIdx.drop( id );        heirarchyIdx.drop( id );                // Remove parent's reference to entry only if entry is not the upSuffix        if ( ! parentId.equals( BigInteger.ZERO ) )        {            heirarchyIdx.drop( parentId, id );        }                while ( attrs.hasMore() )         {            String attr = ( ( String ) attrs.next() );            if ( hasUserIndexOn( attr ) )            {                Index index = ( Index ) getUserIndex( attr );                NamingEnumeration values = entry.get( attr ).getAll();                                while ( values.hasMore() )                {                    index.drop( values.next(), id );                }                existanceIdx.drop( attr.toLowerCase(), id );            }        }        master.delete( id );    }