common/src/main/java/HTTPClient/RedirectionModule.java
/**
     * Update the permanent redirection list.
     *
     * @param the original request
     * @param the new location
     */
Update the permanent redirection list.
@param the original request
@param the new location
Update the permanent redirection list . @param the original request @param the new location
@SuppressWarnings("unchecked")
    private static void update_perm_redir_list(RoRequest req, URI new_loc)
    {
	HTTPConnection con = req.getConnection();
	URI cur_loc = null;
	try
	{
	    cur_loc = new URI(new URI(con.getProtocol(), con.getHost(), con.getPort(), null),
			      req.getRequestURI());
	}
	catch (ParseException pe)
	    { }
	if (!cur_loc.equals(new_loc))
	{
	    Hashtable perm_redir_list =
			Util.getList(perm_redir_cntxt_list, con.getContext());
	    perm_redir_list.put(cur_loc, new_loc);
	}
    }
@ SuppressWarnings ( "unchecked" ) private static void update_perm_redir_list ( RoRequest req , URI new_loc ) { HTTPConnection con = req . getConnection ( ) ; URI cur_loc = null ; try { cur_loc = new URI ( new URI ( con . getProtocol ( ) , con . getHost ( ) , con . getPort ( ) , null ) , req . getRequestURI ( ) ) ; } catch ( ParseException pe ) { } if ( ! cur_loc . equals ( new_loc ) ) { Hashtable perm_redir_list = Util . getList ( perm_redir_cntxt_list , con . getContext ( ) ) ; perm_redir_list . put ( cur_loc , new_loc ) ; } }
Update the permanent redirection list.
Update the permanent redirection list .