TYPEMAP
Apache          T_APACHEOBJ
HV *            T_HvRV

OUTPUT
T_APACHEOBJ
        sv_setref_pv($arg, \"${ntype}\", (void*)$var);
T_HvRV
        $arg = newRV((SV*)$var);


INPUT
T_HvRV
        if( SvROK($arg) && (SvTYPE(SvRV($arg)) == SVt_PVHV) )
                $var = (HV*)SvRV( $arg );
        else {
                warn( \"${Package}::$func_name() -- $var is not an HV reference\" );
                XSRETURN_UNDEF;
        }

T_APACHEOBJ
        r = sv2request_rec($arg, \"$ntype\", cv)

