/* * This file was generated automatically by ExtUtils::ParseXS version 2.21 from the * contents of CmdParms.xs. Do not edit this file, edit CmdParms.xs instead. * * ANY CHANGES MADE HERE WILL BE LOST! * */ #line 1 "CmdParms.xs" /* * *********** WARNING ************** * This file generated by ModPerl::WrapXS/0.01 * Any changes made here will be lost * *********************************** * 01: lib/ModPerl/WrapXS.pm:540 * 02: lib/ModPerl/WrapXS.pm:1174 * 03: Makefile.PL:423 * 04: Makefile.PL:325 * 05: Makefile.PL:56 */ #define MP_IN_XS #include "mod_perl.h" #include "modperl_xs_sv_convert.h" #include "modperl_xs_util.h" #include "modperl_xs_typedefs.h" #include "Apache2/CmdParms/Apache2__CmdParms.h" #line 38 "CmdParms.c" #ifndef PERL_UNUSED_VAR # define PERL_UNUSED_VAR(var) if (0) var = var #endif #ifndef PERL_ARGS_ASSERT_CROAK_XS_USAGE #define PERL_ARGS_ASSERT_CROAK_XS_USAGE assert(cv); assert(params) /* prototype to pass -Wmissing-prototypes */ STATIC void S_croak_xs_usage(pTHX_ const CV *const cv, const char *const params); STATIC void S_croak_xs_usage(pTHX_ const CV *const cv, const char *const params) { const GV *const gv = CvGV(cv); PERL_ARGS_ASSERT_CROAK_XS_USAGE; if (gv) { const char *const gvname = GvNAME(gv); const HV *const stash = GvSTASH(gv); const char *const hvname = stash ? HvNAME(stash) : NULL; if (hvname) Perl_croak(aTHX_ "Usage: %s::%s(%s)", hvname, gvname, params); else Perl_croak(aTHX_ "Usage: %s(%s)", gvname, params); } else { /* Pants. I don't think that it should be possible to get here. */ Perl_croak(aTHX_ "Usage: CODE(0x%"UVxf")(%s)", PTR2UV(cv), params); } } #undef PERL_ARGS_ASSERT_CROAK_XS_USAGE #ifdef PERL_IMPLICIT_CONTEXT #define croak_xs_usage(a,b) S_croak_xs_usage(aTHX_ a,b) #else #define croak_xs_usage S_croak_xs_usage #endif #endif /* NOTE: the prototype of newXSproto() is different in versions of perls, * so we define a portable version of newXSproto() */ #ifdef newXS_flags #define newXSproto_portable(name, c_impl, file, proto) newXS_flags(name, c_impl, file, proto, 0) #else #define newXSproto_portable(name, c_impl, file, proto) (PL_Sv=(SV*)newXS(name, c_impl, file), sv_setpv(PL_Sv, proto), (CV*)PL_Sv) #endif /* !defined(newXS_flags) */ #line 90 "CmdParms.c" XS(XS_Apache2__CmdParms_check_cmd_context); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_check_cmd_context) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 2) croak_xs_usage(cv, "cmd, forbidden"); { Apache2__CmdParms cmd; unsigned forbidden = (unsigned)SvUV(ST(1)); const char * RETVAL; dXSTARG; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); cmd = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::check_cmd_context", "cmd", "Apache2::CmdParms"); RETVAL = ap_check_cmd_context(cmd, forbidden); sv_setpv(TARG, RETVAL); XSprePUSH; PUSHTARG; } XSRETURN(1); } XS(XS_Apache2__CmdParms_method_is_limited); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_method_is_limited) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 2) croak_xs_usage(cv, "cmd, method"); { Apache2__CmdParms cmd; const char * method = (const char *)SvPV_nolen(ST(1)); int RETVAL; dXSTARG; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); cmd = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::method_is_limited", "cmd", "Apache2::CmdParms"); RETVAL = ap_method_is_limited(cmd, method); XSprePUSH; PUSHi((IV)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_add_config); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_add_config) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 2) croak_xs_usage(cv, "parms, lines"); { Apache2__CmdParms parms; SV * lines = ST(1); if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); parms = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::add_config", "parms", "Apache2::CmdParms"); #line 53 "CmdParms.xs" mpxs_Apache2__CmdParms_add_config(aTHX_ parms, lines); #line 180 "CmdParms.c" } XSRETURN_EMPTY; } XS(XS_Apache2__CmdParms_info); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_info) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "parms"); { Apache2__CmdParms parms; SV * RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); parms = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::info", "parms", "Apache2::CmdParms"); #line 64 "CmdParms.xs" RETVAL = mpxs_Apache2__CmdParms_info(aTHX_ parms); #line 211 "CmdParms.c" ST(0) = RETVAL; sv_2mortal(ST(0)); } XSRETURN(1); } XS(XS_Apache2__CmdParms_override_opts); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_override_opts) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "parms"); { Apache2__CmdParms parms; int RETVAL; dXSTARG; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); parms = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::override_opts", "parms", "Apache2::CmdParms"); #line 77 "CmdParms.xs" RETVAL = mpxs_Apache2__CmdParms_override_opts(aTHX_ parms); #line 245 "CmdParms.c" XSprePUSH; PUSHi((IV)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_override); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_override) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; int RETVAL; dXSTARG; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::override", "obj", "Apache2::CmdParms"); #line 91 "CmdParms.xs" RETVAL = (int) obj->override; #line 278 "CmdParms.c" XSprePUSH; PUSHi((IV)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_directive); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_directive) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; Apache2__Directive RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::directive", "obj", "Apache2::CmdParms"); #line 105 "CmdParms.xs" RETVAL = (Apache2__Directive) obj->directive; #line 310 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "Apache2::Directive", (void*)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_pool); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_pool) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; APR__Pool RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::pool", "obj", "Apache2::CmdParms"); #line 119 "CmdParms.xs" RETVAL = (APR__Pool) obj->pool; #line 343 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "APR::Pool", (void*)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_temp_pool); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_temp_pool) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; APR__Pool RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::temp_pool", "obj", "Apache2::CmdParms"); #line 133 "CmdParms.xs" RETVAL = (APR__Pool) obj->temp_pool; #line 377 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "APR::Pool", (void*)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_server); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_server) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; Apache2__ServerRec RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::server", "obj", "Apache2::CmdParms"); #line 147 "CmdParms.xs" RETVAL = (Apache2__ServerRec) obj->server; #line 411 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "Apache2::ServerRec", (void*)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_path); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_path) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; char * RETVAL; dXSTARG; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::path", "obj", "Apache2::CmdParms"); #line 161 "CmdParms.xs" RETVAL = (char *) obj->path; #line 445 "CmdParms.c" sv_setpv(TARG, RETVAL); XSprePUSH; PUSHTARG; } XSRETURN(1); } XS(XS_Apache2__CmdParms_cmd); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_cmd) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; Apache2__Command RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::cmd", "obj", "Apache2::CmdParms"); #line 175 "CmdParms.xs" RETVAL = (Apache2__Command) obj->cmd; #line 477 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "Apache2::Command", (void*)RETVAL); } XSRETURN(1); } XS(XS_Apache2__CmdParms_context); /* prototype to pass -Wmissing-prototypes */ XS(XS_Apache2__CmdParms_context) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif if (items != 1) croak_xs_usage(cv, "obj"); { Apache2__CmdParms obj; Apache2__ConfVector RETVAL; if (sv_derived_from(ST(0), "Apache2::CmdParms")) { IV tmp = SvIV((SV*)SvRV(ST(0))); obj = INT2PTR(Apache2__CmdParms,tmp); } else Perl_croak(aTHX_ "%s: %s is not of type %s", "Apache2::CmdParms::context", "obj", "Apache2::CmdParms"); #line 189 "CmdParms.xs" RETVAL = (Apache2__ConfVector) obj->context; #line 510 "CmdParms.c" ST(0) = sv_newmortal(); sv_setref_pv(ST(0), "Apache2::ConfVector", (void*)RETVAL); } XSRETURN(1); } #ifdef __cplusplus extern "C" #endif XS(boot_Apache2__CmdParms); /* prototype to pass -Wmissing-prototypes */ XS(boot_Apache2__CmdParms) { #ifdef dVAR dVAR; dXSARGS; #else dXSARGS; #endif #if (PERL_REVISION == 5 && PERL_VERSION < 9) char* file = __FILE__; #else const char* file = __FILE__; #endif PERL_UNUSED_VAR(cv); /* -W */ PERL_UNUSED_VAR(items); /* -W */ XS_VERSION_BOOTCHECK ; (void)newXS("Apache2::CmdParms::check_cmd_context", XS_Apache2__CmdParms_check_cmd_context, file); (void)newXS("Apache2::CmdParms::method_is_limited", XS_Apache2__CmdParms_method_is_limited, file); (void)newXS("Apache2::CmdParms::add_config", XS_Apache2__CmdParms_add_config, file); (void)newXS("Apache2::CmdParms::info", XS_Apache2__CmdParms_info, file); (void)newXS("Apache2::CmdParms::override_opts", XS_Apache2__CmdParms_override_opts, file); (void)newXS("Apache2::CmdParms::override", XS_Apache2__CmdParms_override, file); (void)newXS("Apache2::CmdParms::directive", XS_Apache2__CmdParms_directive, file); (void)newXS("Apache2::CmdParms::pool", XS_Apache2__CmdParms_pool, file); (void)newXS("Apache2::CmdParms::temp_pool", XS_Apache2__CmdParms_temp_pool, file); (void)newXS("Apache2::CmdParms::server", XS_Apache2__CmdParms_server, file); (void)newXS("Apache2::CmdParms::path", XS_Apache2__CmdParms_path, file); (void)newXS("Apache2::CmdParms::cmd", XS_Apache2__CmdParms_cmd, file); (void)newXS("Apache2::CmdParms::context", XS_Apache2__CmdParms_context, file); /* Initialisation Section */ #line 198 "CmdParms.xs" items = items; /* -Wall */ #line 557 "CmdParms.c" /* End of Initialisation Section */ #if (PERL_REVISION == 5 && PERL_VERSION >= 9) if (PL_unitcheckav) call_list(PL_scopestack_ix, PL_unitcheckav); #endif XSRETURN_YES; }