richter 02/02/16 15:31:34
Modified: . Tag: Embperl2c Makefile.PL ep2.h epcache.c epcfg.h
epcgiinit.c epdat2.h epeval.c epinit.c epmain.c
epprovider.c test.pl
Embperl Tag: Embperl2c Object.pm Run.pm
Embperl/Recipe Tag: Embperl2c Embperl.pm
driver Tag: Embperl2c eplibxslt.c
test/cmp Tag: Embperl2c input.htm
test/cmp2 Tag: Embperl2c input.htm
xsbuilder/maps Tag: Embperl2c ep_structure.map
Log:
provider
Revision Changes Path
No revision
No revision
1.31.4.49 +3 -2 embperl/Makefile.PL
Index: Makefile.PL
===================================================================
RCS file: /home/cvs/embperl/Makefile.PL,v
retrieving revision 1.31.4.48
retrieving revision 1.31.4.49
diff -u -r1.31.4.48 -r1.31.4.49
--- Makefile.PL 12 Feb 2002 09:11:44 -0000 1.31.4.48
+++ Makefile.PL 16 Feb 2002 23:31:32 -0000 1.31.4.49
@@ -3,7 +3,7 @@
#
# (C) 1997-2001 G.Richter ([EMAIL PROTECTED]) / ECOS
#
-# $Id: Makefile.PL,v 1.31.4.48 2002/02/12 09:11:44 richter Exp $
+# $Id: Makefile.PL,v 1.31.4.49 2002/02/16 23:31:32 richter Exp $
#
@@ -190,8 +190,9 @@
my $self = shift ;
my $txt = $self -> MM::c_o (@_) ;
+ my $opt = $win32?'Fo':'o ' ;
- $txt =~ s/\$\*/-o \$*\$(OBJ_EXT) \$*/g ;
+ $txt =~ s/\$\*/-$opt\$*\$(OBJ_EXT) \$*/g ;
my @txt = split (/\n/, $txt) ;
my $cpp = 0 ;
foreach (@txt)
1.1.2.28 +16 -8 embperl/Attic/ep2.h
Index: ep2.h
===================================================================
RCS file: /home/cvs/embperl/Attic/ep2.h,v
retrieving revision 1.1.2.27
retrieving revision 1.1.2.28
diff -u -r1.1.2.27 -r1.1.2.28
--- ep2.h 23 Jan 2002 15:09:00 -0000 1.1.2.27
+++ ep2.h 16 Feb 2002 23:31:32 -0000 1.1.2.28
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: ep2.h,v 1.1.2.27 2002/01/23 15:09:00 richter Exp $
+# $Id: ep2.h,v 1.1.2.28 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -161,9 +161,9 @@
typedef struct tProviderClass
{
const char * sOutputType ;
/**< MIME type of output format (maybe override by object) */
- int (*fNew)(req * r, tCacheItem * pOutputCache, struct tProviderClass *
pProviderClass, HV * pParam) ; /**< called to initialize the provider */
- int (*fAppendKey)(req * r, struct tProviderClass * pProviderClass, HV * pParam,
SV * pKey) ; /**< append the key for the cache of the provider and it's dependencies
*/
- int (*fUpdateParam)(req * r, struct tProvider * pProvider, HV * pParam) ;
/**< update the parameter of the provider */
+ int (*fNew)(req * r, tCacheItem * pOutputCache, struct tProviderClass *
pProviderClass, HV * pProviderParam, SV * pParam, IV nParamIndex) ; /**< called to
initialize the provider */
+ int (*fAppendKey)(req * r, struct tProviderClass * pProviderClass, HV *
pProviderParam, SV * pParam, IV nParamIndex, SV * pKey) ; /**< append the key for
the cache of the provider and it's dependencies */
+ int (*fUpdateParam)(req * r, struct tProvider * pProvider, HV * pProviderParam)
; /**< update the parameter of the provider */
int (*fGetContentSV)(req * r, struct tProvider * pProvider, SV ** pData, bool
bUseCache) ; /**< Get the content from that provider */
int (*fGetContentPtr)(req * r, struct tProvider * pProvider, void ** pData,
bool bUseCache) ; /**< Get the content from that provider */
int (*fGetContentIndex)(req * r, struct tProvider * pProvider, tIndex * pData,
bool bUseCache) ;/**< Get the content from that provider */
@@ -190,12 +190,16 @@
int Cache_CleanupRequest (req * r) ;
int Cache_New (/*in*/ req * r,
- /*in*/ HV * pParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamNdx,
+ /*in*/ bool bTopLevel,
/*in*/ tCacheItem * * pItem) ;
int Cache_AppendKey (/*in*/ req * r,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
/*in*/ const char * sSubProvider,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey) ;
tCacheItem * Cache_GetByKey (/*in*/ req * r,
@@ -260,14 +264,18 @@
/*in*/ const char * sSourceName,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam) ;
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex) ;
int Provider_AddDependOne (/*in*/ req * r,
/*in*/ tProvider * pProvider,
/*in*/ const char * sSourceName,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam) ;
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex) ;
/* --- from epinit.c --- */
1.1.2.21 +192 -128 embperl/Attic/epcache.c
Index: epcache.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epcache.c,v
retrieving revision 1.1.2.20
retrieving revision 1.1.2.21
diff -u -r1.1.2.20 -r1.1.2.21
--- epcache.c 23 Jan 2002 10:11:35 -0000 1.1.2.20
+++ epcache.c 16 Feb 2002 23:31:32 -0000 1.1.2.21
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epcache.c,v 1.1.2.20 2002/01/23 10:11:35 richter Exp $
+# $Id: epcache.c,v 1.1.2.21 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -127,6 +127,57 @@
/* ------------------------------------------------------------------------ */
/* */
+/* Cache_ParamUpdate */
+/* */
+
+
+
+int Cache_ParamUpdate (/*in*/ req * r,
+ /*in*/ HV * pProviderParam,
+ /*in*/ bool bTopLevel,
+ /*in*/ char * sLogText,
+ /*in*/ tCacheItem * pNew)
+
+
+ {
+ epTHX_
+ char * exfn ;
+ int rc ;
+
+ pNew -> nExpiresInTime = GetHashValueInt (aTHX_ pProviderParam,
"expires_in", bTopLevel?r -> Component.Config.nExpiresIn:0) ;
+ if (pNew -> pExpiresCV)
+ SvREFCNT_dec (pNew -> pExpiresCV) ;
+ if ((rc = GetHashValueCREF (r, pProviderParam, "expires_func", &pNew ->
pExpiresCV)) != ok)
+ return rc ;
+ if (!pNew -> pExpiresCV && bTopLevel)
+ pNew -> pExpiresCV = (CV *)SvREFCNT_inc((SV *)r ->
Component.Config.pExpiredFunc) ;
+
+ exfn = GetHashValueStrDupA (aTHX_ pProviderParam, "expires_filename",
bTopLevel?r -> Component.Config.sExpiresFilename:NULL) ;
+ if (pNew -> sExpiresFilename)
+ {
+ if (exfn)
+ {
+ /* lprintf (r -> pApp, "exfn=%s\n", exfn) ; */
+ free ((void *)pNew -> sExpiresFilename) ;
+ pNew -> sExpiresFilename = exfn ;
+ }
+ }
+ else
+ pNew -> sExpiresFilename = exfn ;
+
+ pNew -> bCache = (bool)GetHashValueInt (aTHX_ pProviderParam,
"cache", pNew -> sExpiresFilename || pNew -> pExpiresCV || pNew -> nExpiresInTime?1:0)
;
+
+ if (sLogText && (r -> Component.Config.bDebug & dbgCache))
+ lprintf (r -> pApp, "[%d]CACHE: %s CacheItem %s; expires_in=%d
expires_func=%s expires_filename=%s cache=%s\n",
+ r -> pThread -> nPid, sLogText, pNew -> sKey, pNew ->
nExpiresInTime,
+ pNew -> pExpiresCV?"yes":"no", pNew ->
sExpiresFilename?pNew -> sExpiresFilename:"",
+ pNew -> bCache?"yes":"no") ;
+
+ return ok ;
+ }
+
+/* ------------------------------------------------------------------------ */
+/* */
/* Cache_New */
/* */
/*!
@@ -136,7 +187,7 @@
* pParam
*
* @param r Embperl request record
-* @param pParam Parameter
+* @param pParam Parameter (PV,HV,AV)
* expires_in number of seconds when the item
* expires, 0 = expires never
* expires_func Perl Function (coderef) that
@@ -146,6 +197,9 @@
* time of file changes
* cache set to zero to not cache the
content
* provider parameter for the provider
+* @param nParamNdx If pParam is a AV, this parameter gives the index into
the Array
+* @param bTopLevel True if last elemet before output. In this case the
cache parameters
+* defaults to the ones from Componet.Config
* @param pItem Return of the new Items
* @return error code
* \endif
@@ -156,7 +210,7 @@
* pParam
*
* @param r Embperl request record
-* @param pParam Parameter
+* @param pParam Parameter (PV,HV,AV)
* expires_in anzahl der Sekunden wenn Item
* abl�uft; 0 = nie
* expires_func Perl Funktion (coderef) die
@@ -167,6 +221,9 @@
* cache Auf Null setzen damit Inhalt
* nicht gecacht wird
* provider parameter f�r Provider
+* @param nParamNdx Wenn pParam ein AV ist, gibt dieser Parameter den Index
an
+* @param bTopLevel Wahr wenn letztes Element vor der Ausgabe, dann werden
+* die Cache Parameter aus Componet.Config herangezogen
* @param pItem R�ckgabe des neuen Items
* @return Fehlercode
* \endif
@@ -174,7 +231,9 @@
* ------------------------------------------------------------------------ */
int Cache_New (/*in*/ req * r,
- /*in*/ HV * pParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamNdx,
+ /*in*/ bool bTopLevel,
/*in*/ tCacheItem * * pItem)
@@ -187,69 +246,75 @@
tCacheItem * pNew = NULL ;
SV * pKey = NULL ;
const char * sKey = "" ;
+ STRLEN len ;
+ if (SvTYPE(pParam) == SVt_RV)
+ pParam = SvRV (pParam) ;
- if ((rc = GetHashValueHREF (r, pParam, "provider", &pProviderParam)) != ok)
+ if (SvTYPE(pParam) == SVt_PV)
{
- return rc ;
+ /* change this to auto match later on ... */
+ pProviderParam = (HV *)SvRV(sv_2mortal (CreateHashRef (r,
+ "type", hashtstr, "file",
+ "filename", hashtsv, pParam,
+ NULL) ,
+ )) ;
}
- if (pProviderParam)
+ else if (SvTYPE(pParam) == SVt_PVAV)
{
- STRLEN len ;
-
- sProvider = GetHashValueStr (aTHX_ pProviderParam, "type", "") ;
- pProviderClass = (tProviderClass *)GetHashValuePtr (r, pProviders,
sProvider, NULL) ;
- if (!pProviderClass)
+ SV * * ppRV = av_fetch ((AV *)pParam, nParamNdx, 0) ;
+ if (!ppRV || !*ppRV)
{
- if (*sProvider)
- strncpy (r -> errdat1, sProvider, sizeof(r -> errdat1) - 1) ;
- else
- strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1)
;
+ strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1) ;
return rcUnknownProvider ;
}
- pKey = newSVpv ("", 0) ;
- if (pProviderClass -> fAppendKey)
- if ((rc = (*pProviderClass -> fAppendKey)(r, pProviderClass,
pProviderParam, pKey)) != ok)
- return rc ;
-
- sKey = SvPV(pKey, len) ;
- if (pNew = Cache_GetByKey (r, sKey))
+ if (!SvROK (*ppRV) || SvTYPE(pProviderParam = (HV *)SvRV (*ppRV)) !=
SVt_PVHV)
{
- char * exfn ;
+ strncpy (r -> errdat1, "<provider missing, element is no hashref>",
sizeof(r -> errdat1) - 1) ;
- pNew -> nExpiresInTime = GetHashValueInt (aTHX_ pParam,
"expires_in", 0) ;
- if (pNew -> pExpiresCV)
- SvREFCNT_dec (pNew -> pExpiresCV) ;
- if ((rc = GetHashValueCREF (r, pParam, "expires_func", &pNew ->
pExpiresCV)) != ok)
- return rc ;
- exfn = GetHashValueStrDupA (aTHX_ pParam, "expires_filename", NULL) ;
- if (pNew -> sExpiresFilename)
- {
- if (exfn)
- {
- /* lprintf (r -> pApp, "exfn=%s\n", exfn) ; */
- free ((void *)pNew -> sExpiresFilename) ;
- pNew -> sExpiresFilename = exfn ;
- }
- }
- else
- pNew -> sExpiresFilename = exfn ;
-
- pNew -> bCache = (bool)GetHashValueInt (aTHX_ pParam,
"cache", 1) ;
-
- if (r -> Component.Config.bDebug & dbgCache)
- lprintf (r -> pApp, "[%d]CACHE: Update CacheItem %s; expires_in=%d
expires_func=%s expires_filename=%s cache=%s\n",
- r -> pThread -> nPid, pNew -> sKey, pNew ->
nExpiresInTime,
- pNew -> pExpiresCV?"yes":"no", pNew ->
sExpiresFilename?pNew -> sExpiresFilename:"",
- pNew -> bCache?"yes":"no") ;
+ return rcUnknownProvider ;
+ }
+ nParamNdx++ ;
+ }
+ else if (SvTYPE(pParam) == SVt_PVHV)
+ {
+ pProviderParam = (HV *)pParam ;
+ }
+ else
+ {
+ strncpy (r -> errdat1, "<provider missing, no description found>", sizeof(r
-> errdat1) - 1) ;
- if (pProviderClass -> fUpdateParam)
- if ((rc = (*pProviderClass -> fUpdateParam)(r, pNew -> pProvider,
pProviderParam)) != ok)
- return rc ;
- }
+ return rcUnknownProvider ;
+ }
+
+
+ sProvider = GetHashValueStr (aTHX_ pProviderParam, "type", "") ;
+ pProviderClass = (tProviderClass *)GetHashValuePtr (r, pProviders, sProvider,
NULL) ;
+ if (!pProviderClass)
+ {
+ if (*sProvider)
+ strncpy (r -> errdat1, sProvider, sizeof(r -> errdat1) - 1) ;
+ else
+ strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1) ;
+ return rcUnknownProvider ;
}
+ pKey = newSVpv ("", 0) ;
+ if (pProviderClass -> fAppendKey)
+ if ((rc = (*pProviderClass -> fAppendKey)(r, pProviderClass,
pProviderParam, pParam, nParamNdx, pKey)) != ok)
+ return rc ;
+
+ sKey = SvPV(pKey, len) ;
+ if (pNew = Cache_GetByKey (r, sKey))
+ {
+ Cache_ParamUpdate (r, pProviderParam, bTopLevel, "Update", pNew) ;
+
+
+ if (pProviderClass -> fUpdateParam)
+ if ((rc = (*pProviderClass -> fUpdateParam)(r, pNew -> pProvider,
pProviderParam)) != ok)
+ return rc ;
+ }
if (!pNew)
{
@@ -264,16 +329,12 @@
*pItem = NULL ;
memset (pNew, 0, sizeof (tCacheItem)) ;
- pNew -> nExpiresInTime = GetHashValueInt (aTHX_ pParam, "expires_in",
0) ;
- if ((rc = GetHashValueCREF (r, pParam, "expires_func", &pNew ->
pExpiresCV)) != ok)
- return rc ;
- pNew -> sExpiresFilename = GetHashValueStrDupA (aTHX_ pParam,
"expires_filename", NULL) ;
- pNew -> bCache = (bool)GetHashValueInt (aTHX_ pParam, "cache",
1) ;
+ Cache_ParamUpdate (r, pProviderParam, bTopLevel, NULL, pNew) ;
pNew -> sKey = strdup (sKey) ;
if (pProviderParam)
{
- if ((rc = (*pProviderClass -> fNew)(r, pNew, pProviderClass,
pProviderParam)) != ok)
+ if ((rc = (*pProviderClass -> fNew)(r, pNew, pProviderClass,
pProviderParam, pParam, nParamNdx)) != ok)
{
if (pKey)
SvREFCNT_dec (pKey) ;
@@ -333,94 +394,97 @@
* ------------------------------------------------------------------------ */
int Cache_AppendKey (/*in*/ req * r,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
/*in*/ const char * sSubProvider,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- HV * pSubProvider ;
- HV * pProviderParam ;
char * sProvider ;
tProviderClass * pProviderClass ;
+ STRLEN len ;
+ tCacheItem * pItem ;
+ SV * pSubParam = GetHashValueSV (r, pProviderParam, sSubProvider) ;
- if ((rc = GetHashValueHREF (r, pParam, sSubProvider, &pSubProvider)) != ok)
- {
- STRLEN l ;
- if (!r->errdat1[0])
- strncpy (r -> errdat1, SvPV(pKey, l), sizeof (r -> errdat1) -1 ) ;
- return rc ;
- }
- if ((rc = GetHashValueHREF (r, pSubProvider, "provider", &pProviderParam)) !=
ok)
+ if (pSubParam)
+ pParam = pSubParam ;
+
+ if (SvTYPE(pParam) == SVt_RV)
+ pParam = SvRV (pParam) ;
+
+ if (SvTYPE(pParam) == SVt_PV)
{
- STRLEN l ;
- if (!r->errdat1[0])
- strncpy (r -> errdat1, SvPV(pKey, l), sizeof (r -> errdat1) -1 ) ;
- return rc ;
+ /* change this to auto match later on ... */
+ pProviderParam = (HV *)SvRV(sv_2mortal (CreateHashRef (r,
+ "type", hashtstr, "file",
+ "filename", hashtsv, pParam,
+ NULL) ,
+ )) ;
}
- if (pProviderParam)
+ else if (SvTYPE(pParam) == SVt_PVAV)
{
- STRLEN len ;
- tCacheItem * pItem ;
-
- sProvider = GetHashValueStr (aTHX_ pProviderParam, "type", "") ;
- pProviderClass = (tProviderClass *)GetHashValuePtr (r, pProviders,
sProvider, NULL) ;
- if (!pProviderClass)
+ SV * * ppRV = av_fetch ((AV *)pParam, nParamIndex, 0) ;
+ if (!ppRV || !*ppRV)
{
- if (*sProvider)
- strncpy (r -> errdat1, sProvider, sizeof(r -> errdat1) - 1) ;
- else
- strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1)
;
+ strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1) ;
+
return rcUnknownProvider ;
}
- if (pProviderClass -> fAppendKey)
- if ((rc = (*pProviderClass -> fAppendKey)(r, pProviderClass,
pProviderParam, pKey)) != ok)
- {
- if (r -> Component.Config.bDebug & dbgCache)
- lprintf (r -> pApp, "[%d]CACHE: Error in Update CacheItem
provider=%s\n",
- r -> pThread -> nPid, sProvider) ;
- return rc ;
- }
- if (pItem = Cache_GetByKey (r, SvPV(pKey, len)))
+ if (!SvROK (*ppRV) || SvTYPE(pProviderParam = (HV *)SvRV (*ppRV)) !=
SVt_PVHV)
{
- int bCache = pItem -> bCache ;
- char * exfn ;
+ strncpy (r -> errdat1, "<provider missing, element is no hashref>",
sizeof(r -> errdat1) - 1) ;
- pItem -> nExpiresInTime = GetHashValueInt (aTHX_ pSubProvider,
"expires_in", 0) ;
- if (pItem -> pExpiresCV)
- SvREFCNT_dec (pItem -> pExpiresCV) ;
- if ((rc = GetHashValueCREF (r, pSubProvider, "expires_func", &pItem ->
pExpiresCV)) != ok)
- return rc ;
- exfn = GetHashValueStrDupA (aTHX_ pSubProvider, "expires_filename",
NULL) ;
- if (pItem -> sExpiresFilename)
- {
- if (exfn)
- {
- free ((void *)pItem -> sExpiresFilename) ;
- pItem -> sExpiresFilename = exfn ;
- }
- }
- else
- pItem -> sExpiresFilename = exfn ;
-
- pItem -> bCache = (bool)GetHashValueInt (aTHX_
pSubProvider, "cache", 1) ;
- if (!pItem -> bCache && bCache)
- Cache_FreeContent (r, pItem) ;
-
- if (r -> Component.Config.bDebug & dbgCache)
- lprintf (r -> pApp, "[%d]CACHE: Update CacheItem %s; expires_in=%d
expires_func=%s expires_filename=%s cache=%s\n",
- r -> pThread -> nPid, pItem -> sKey, pItem ->
nExpiresInTime,
- pItem -> pExpiresCV?"yes":"no", pItem ->
sExpiresFilename?pItem -> sExpiresFilename:"",
- pItem -> bCache?"yes":"no") ;
-
- if (pProviderClass -> fUpdateParam)
- if ((rc = (*pProviderClass -> fUpdateParam)(r, pItem -> pProvider,
pProviderParam)) != ok)
- return rc ;
- }
+ return rcUnknownProvider ;
+ }
+ nParamIndex++ ;
+ }
+ else if (SvTYPE(pParam) == SVt_PVHV)
+ {
+ pProviderParam = (HV *)pParam ;
}
else
- sv_catpv (pKey, "-?") ;
+ {
+ strncpy (r -> errdat1, "<provider missing, no description found>", sizeof(r
-> errdat1) - 1) ;
+
+ return rcUnknownProvider ;
+ }
+
+
+ sProvider = GetHashValueStr (aTHX_ pProviderParam, "type", "") ;
+ pProviderClass = (tProviderClass *)GetHashValuePtr (r, pProviders, sProvider,
NULL) ;
+ if (!pProviderClass)
+ {
+ if (*sProvider)
+ strncpy (r -> errdat1, sProvider, sizeof(r -> errdat1) - 1) ;
+ else
+ strncpy (r -> errdat1, "<provider missing>", sizeof(r -> errdat1) - 1) ;
+ return rcUnknownProvider ;
+ }
+ if (pProviderClass -> fAppendKey)
+ if ((rc = (*pProviderClass -> fAppendKey)(r, pProviderClass,
pProviderParam, pParam, nParamIndex, pKey)) != ok)
+ {
+ if (r -> Component.Config.bDebug & dbgCache)
+ lprintf (r -> pApp, "[%d]CACHE: Error in Update CacheItem
provider=%s\n",
+ r -> pThread -> nPid, sProvider) ;
+ return rc ;
+ }
+ if (pItem = Cache_GetByKey (r, SvPV(pKey, len)))
+ {
+ int bCache = pItem -> bCache ;
+
+ Cache_ParamUpdate (r, pProviderParam, 0, "Update", pItem) ;
+
+ if (!pItem -> bCache && bCache)
+ Cache_FreeContent (r, pItem) ;
+
+
+ if (pProviderClass -> fUpdateParam)
+ if ((rc = (*pProviderClass -> fUpdateParam)(r, pItem -> pProvider,
pProviderParam)) != ok)
+ return rc ;
+ }
return ok ;
}
1.1.2.8 +2 -0 embperl/Attic/epcfg.h
Index: epcfg.h
===================================================================
RCS file: /home/cvs/embperl/Attic/epcfg.h,v
retrieving revision 1.1.2.7
retrieving revision 1.1.2.8
diff -u -r1.1.2.7 -r1.1.2.8
--- epcfg.h 7 Feb 2002 06:56:20 -0000 1.1.2.7
+++ epcfg.h 16 Feb 2002 23:31:32 -0000 1.1.2.8
@@ -31,6 +31,8 @@
EPCFG_REGEX(ReqConfig, CV *, pUriMatch, URIMATCH)
EPCFG_CHAR(ReqConfig, char , cMultFieldSep, MULTFIELDSEP )
EPCFG_AV (ReqConfig, AV *, pPathAV, PATH, SEPARATOR)
+EPCFG_INT (ReqConfig, unsigned, bDebug, DEBUG)
+EPCFG_INT (ReqConfig, unsigned, bOptions, OPTIONS)
#endif
1.1.2.9 +2 -2 embperl/Attic/epcgiinit.c
Index: epcgiinit.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epcgiinit.c,v
retrieving revision 1.1.2.8
retrieving revision 1.1.2.9
diff -u -r1.1.2.8 -r1.1.2.9
--- epcgiinit.c 11 Feb 2002 17:01:05 -0000 1.1.2.8
+++ epcgiinit.c 16 Feb 2002 23:31:32 -0000 1.1.2.9
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epcgiinit.c,v 1.1.2.8 2002/02/11 17:01:05 richter Exp $
+# $Id: epcgiinit.c,v 1.1.2.9 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -61,7 +61,7 @@
{ \
int rc ;\
char * arg = GetHashValueStr (aTHX_ pThread -> pEnvHash, "EMBPERL_"#CFGNAME,
NULL) ; \
- if (0) \
+ if (arg) \
if ((rc = EvalRegEx (pApp, arg, "Configuration: EMBPERL_"#CFGNAME, &pConfig
-> NAME)) != ok) \
return rc ; \
}
1.1.2.25 +4 -1 embperl/Attic/epdat2.h
Index: epdat2.h
===================================================================
RCS file: /home/cvs/embperl/Attic/epdat2.h,v
retrieving revision 1.1.2.24
retrieving revision 1.1.2.25
diff -u -r1.1.2.24 -r1.1.2.25
--- epdat2.h 10 Feb 2002 21:26:14 -0000 1.1.2.24
+++ epdat2.h 16 Feb 2002 23:31:32 -0000 1.1.2.25
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epdat2.h,v 1.1.2.24 2002/02/10 21:26:14 richter Exp $
+# $Id: epdat2.h,v 1.1.2.25 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -82,6 +82,7 @@
CV * pExpiredFunc ;
CV * pCacheKeyFunc ;
int nExpiresIn ;
+ char * sExpiresFilename ;
char * sSyntax ;
char * sRecipe ;
char * sXsltstylesheet ;
@@ -99,6 +100,8 @@
CV * pUriMatch ;
char cMultFieldSep ;
AV * pPathAV ;
+ unsigned bDebug ;
+ unsigned bOptions ;
} tReqConfig ;
typedef struct tReqParam
1.23.4.20 +2 -1 embperl/epeval.c
Index: epeval.c
===================================================================
RCS file: /home/cvs/embperl/epeval.c,v
retrieving revision 1.23.4.19
retrieving revision 1.23.4.20
diff -u -r1.23.4.19 -r1.23.4.20
--- epeval.c 5 Feb 2002 09:04:03 -0000 1.23.4.19
+++ epeval.c 16 Feb 2002 23:31:32 -0000 1.23.4.20
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epeval.c,v 1.23.4.19 2002/02/05 09:04:03 richter Exp $
+# $Id: epeval.c,v 1.23.4.20 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -262,6 +262,7 @@
SvREFCNT_inc (*ppCV) ;
}
+ SvREFCNT_dec (pSV) ;
return ok ;
}
1.1.2.27 +19 -14 embperl/Attic/epinit.c
Index: epinit.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epinit.c,v
retrieving revision 1.1.2.26
retrieving revision 1.1.2.27
diff -u -r1.1.2.26 -r1.1.2.27
--- epinit.c 10 Feb 2002 21:26:14 -0000 1.1.2.26
+++ epinit.c 16 Feb 2002 23:31:32 -0000 1.1.2.27
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epinit.c,v 1.1.2.26 2002/02/10 21:26:14 richter Exp $
+# $Id: epinit.c,v 1.1.2.27 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -135,6 +135,7 @@
perl_get_hv (EMBPERL_HDR_NAME, TRUE) ;
perl_get_hv (EMBPERL_IDAT_NAME, TRUE) ;
perl_get_hv (EMBPERL_ENV_NAME, TRUE) ;
+ perl_get_hv (EMBPERL_PARAM_NAME, TRUE) ;
*ppSV = pThreadRV ;
}
else
@@ -636,15 +637,10 @@
HV * pFormHash = r -> pThread -> pFormHash ;
HV * pFormSplitHash = r -> pThread -> pFormSplitHash ;
HV * pInputHash = r -> pThread -> pInputHash ;
- bool bAll = r -> Component.Config.bOptions & optAllFormData ;
- bool bDebug = r -> Component.Config.bDebug & dbgForm ;
+ bool bAll = (r -> Config.bOptions & optAllFormData) != 0 ;
+ bool bDebug = (r -> Config.bDebug & dbgForm) != 0 ;
epTHX ;
- hv_clear (pFormHash) ;
- hv_clear (pFormSplitHash) ;
- av_clear (pFormArray) ;
- hv_clear (pInputHash) ;
-
if (nLen == 0)
return ok ;
@@ -792,6 +788,15 @@
char sLen [20] ;
epTHX ;
+
+ hv_clear (r -> pThread -> pFormHash) ;
+ hv_clear (r -> pThread -> pFormSplitHash) ;
+ av_clear (r -> pThread -> pFormArray) ;
+ hv_clear (r -> pThread -> pInputHash) ;
+
+ if (r -> Config.bOptions & optDisableFormData)
+ return ok ;
+
/* print out of env set tainted, so reset it now */
tainted = 0 ;
@@ -832,7 +837,7 @@
f = p ;
}
- if (r -> Component.Config.bDebug)
+ if (r -> Config.bDebug & dbgForm)
lprintf (r -> pApp, "[%d]Formdata... length = %d\n", r -> pThread ->
nPid, len) ;
rc = embperl_GetFormData (r, p, len) ;
@@ -1130,7 +1135,7 @@
while ((pEntry = hv_iternext (r -> pCleanupPackagesHV)))
{
char * sPackage = hv_iterkey (pEntry, &l) ;
- ClearSymtab (r, sPackage, r -> Component.Config.bDebug & dbgShowCleanup) ;
+ ClearSymtab (r, sPackage, r -> Config.bDebug & dbgShowCleanup) ;
}
SvREFCNT_dec (r -> pCleanupPackagesHV) ;
@@ -1164,7 +1169,7 @@
dmalloc_message ( "[%d]%sRequest freed. Entry-SVs: %d -OBJs: %d Exit-SVs: %d
-OBJs: %d\n", r -> pThread -> nPid,
(r -> Component.pPrev?"Sub-":""), r -> stsv_count, r -> stsv_objcount,
sv_count, sv_objcount) ;
#endif
- if (r -> Component.Config.bDebug)
+ if (r -> Config.bDebug)
DomStats (r -> pApp) ;
return ok ;
@@ -1452,7 +1457,7 @@
{
epTHX ;
- if (r -> pApp -> Config.bDebug)
+ if (r -> Config.bDebug)
{
time_t t = time(NULL) ;
lprintf (r -> pApp, "[%d]REQ: Start Request at %s\n", r -> pThread ->
nPid, ctime (&t)) ;
@@ -1464,7 +1469,7 @@
#ifdef APACHE
- if (r -> pApacheReq && (r -> pApp -> Config.bDebug & dbgHeadersIn))
+ if (r -> pApacheReq && (r -> Config.bDebug & dbgHeadersIn))
{
int i;
array_header *hdrs_arr;
@@ -1479,7 +1484,7 @@
lprintf (r -> pApp, "[%d]HDR: %s=%s\n", r -> pThread -> nPid,
hdrs[i].key, hdrs[i].val) ;
}
#endif
- if (r -> pApp -> Config.bDebug & dbgEnv)
+ if (r -> Config.bDebug & dbgEnv)
{
SV * psv ;
HE * pEntry ;
1.75.4.99 +2 -2 embperl/epmain.c
Index: epmain.c
===================================================================
RCS file: /home/cvs/embperl/epmain.c,v
retrieving revision 1.75.4.98
retrieving revision 1.75.4.99
diff -u -r1.75.4.98 -r1.75.4.99
--- epmain.c 11 Feb 2002 17:01:05 -0000 1.75.4.98
+++ epmain.c 16 Feb 2002 23:31:32 -0000 1.75.4.99
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epmain.c,v 1.75.4.98 2002/02/11 17:01:05 richter Exp $
+# $Id: epmain.c,v 1.75.4.99 2002/02/16 23:31:32 richter Exp $
#
###################################################################################*/
@@ -1256,7 +1256,7 @@
return rcNotHashRef ;
}
- if ((rc = Cache_New (r, pParam, &r -> Component.pOutputCache)) != ok)
+ if ((rc = Cache_New (r, pParam, 0, 1, &r -> Component.pOutputCache)) != ok)
return rc ;
1.1.2.31 +181 -124 embperl/Attic/epprovider.c
Index: epprovider.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epprovider.c,v
retrieving revision 1.1.2.30
retrieving revision 1.1.2.31
diff -u -r1.1.2.30 -r1.1.2.31
--- epprovider.c 12 Feb 2002 09:11:44 -0000 1.1.2.30
+++ epprovider.c 16 Feb 2002 23:31:33 -0000 1.1.2.31
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epprovider.c,v 1.1.2.30 2002/02/12 09:11:44 richter Exp $
+# $Id: epprovider.c,v 1.1.2.31 2002/02/16 23:31:33 richter Exp $
#
###################################################################################*/
@@ -102,8 +102,9 @@
* @param sSourceName Name of the element in pParam that holds the source
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -122,8 +123,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -134,46 +136,41 @@
/*in*/ const char * sSourceName,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
epTHX_
int rc ;
- HV * pSourceParam ;
- char * sSource ;
+ SV * pSourceParam ;
tCacheItem * pSubCache ;
- GetHashValueStrOrHash (r, pParam, sSourceName, &sSource, &pSourceParam) ;
-
- if (sSource)
- {
- pSourceParam = (HV *)SvRV(sv_2mortal (CreateHashRef (r,
- "provider", hashtsv, CreateHashRef (r,
- "type", hashtstr, "file",
- "filename", hashtstr, sSource,
- NULL),
- "cache", hashtint, 0,
- NULL))) ;
- }
+ pSourceParam = GetHashValueSV (r, pProviderParam, sSourceName) ;
if (pSourceParam)
{
- if ((rc = Cache_New (r, pSourceParam, &pSubCache)) != ok)
- return rc ;
-
- if ((rc = Cache_AddDependency (r, pItem, pSubCache)) != ok)
+ if ((rc = Cache_New (r, pSourceParam, 0, 0, &pSubCache)) != ok)
+ {
+ strcpy (r -> errdat2, sSourceName) ;
return rc ;
-
+ }
}
else
{
- strcpy (r -> errdat1, pItem -> sKey) ;
- strcpy (r -> errdat2, sSourceName) ;
- return rcMissingParam ;
+ if ((rc = Cache_New (r, pParam, nParamIndex, 0, &pSubCache)) != ok)
+ {
+ strcpy (r -> errdat2, sSourceName) ;
+ return rc ;
+ }
}
+ if ((rc = Cache_AddDependency (r, pItem, pSubCache)) != ok)
+ return rc ;
+
+
return ok ;
}
@@ -195,8 +192,9 @@
* @param sSourceName Name of the element in pParam that holds the source
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is a AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -215,8 +213,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -227,16 +226,18 @@
/*in*/ const char * sSourceName,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_New (r, nSize, pItem, pProviderClass, pParam)) != ok)
+ if ((rc = Provider_New (r, nSize, pItem, pProviderClass, pProviderParam)) != ok)
return rc ;
- if ((rc = Provider_AddDependOne (r, pItem -> pProvider, sSourceName, pItem,
pProviderClass, pParam)) != ok)
+ if ((rc = Provider_AddDependOne (r, pItem -> pProvider, sSourceName, pItem,
pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -269,8 +270,10 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename name of file
+* @param pProviderParam Parameter Hash of this Providers
+* filename filename
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -282,8 +285,10 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash dieses Providers
* filename Dateiname
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -292,7 +297,9 @@
static int ProviderFile_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
@@ -301,12 +308,12 @@
tProviderFile * pNew ;
char * sFilename ;
- if ((rc = Provider_New (r, sizeof(tProviderFile), pItem, pProviderClass,
pParam)) != ok)
+ if ((rc = Provider_New (r, sizeof(tProviderFile), pItem, pProviderClass,
pProviderParam)) != ok)
return rc ;
pNew = (tProviderFile *)pItem -> pProvider ;
- sFilename = GetHashValueStr (aTHX_ pParam, "filename", r ->
Component.Param.sInputfile) ;
+ sFilename = GetHashValueStr (aTHX_ pProviderParam, "filename", r ->
Component.Param.sInputfile) ;
pNew -> sFilename = embperl_PathSearch(r, NULL, sFilename) ;
if (!pNew -> sFilename)
{
@@ -334,8 +341,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename name of file
+* @param pProviderParam Parameter Hash of this Providers
+* filename filename
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -348,8 +357,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash dieses Providers
* filename Dateiname
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -358,14 +369,16 @@
static int ProviderFile_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
const char * sFilename ;
const char * sAbsFilename ;
- sFilename = GetHashValueStr (aTHX_ pParam, "filename", r ->
Component.Param.sInputfile) ;
+ sFilename = GetHashValueStr (aTHX_ pProviderParam, "filename", r ->
Component.Param.sInputfile) ;
sAbsFilename = embperl_PathSearch(r, NULL, (char *)sFilename) ;
if (!sAbsFilename)
{
@@ -483,10 +496,12 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
* name name (used to compare mtime)
* source source text
* mtime last modification time
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -498,10 +513,12 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash dieses Providers
* name Name (wird benutzt um mtime zu
vergelichen)
* source Quellentext
* mtime Zeitpunkt der letzten �nderung
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -510,7 +527,9 @@
static int ProviderMem_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
@@ -518,12 +537,12 @@
int rc ;
tProviderMem * pNew ;
- if ((rc = Provider_New (r, sizeof(tProviderMem), pItem, pProviderClass,
pParam)) != ok)
+ if ((rc = Provider_New (r, sizeof(tProviderMem), pItem, pProviderClass,
pProviderParam)) != ok)
return rc ;
pNew = (tProviderMem *)pItem -> pProvider ;
- pNew -> sName = GetHashValueStrDupA (aTHX_ pParam, "name", r
-> Component.Param.sInputfile) ;
+ pNew -> sName = GetHashValueStrDupA (aTHX_ pProviderParam,
"name", r -> Component.Param.sInputfile) ;
/*
pNew -> nLastModified = GetHashValueUInt (pParam, "mtime", 0) ;
@@ -552,8 +571,12 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* name name
+* @param pProviderParam Parameter Hash of this Providers
+* name name (used to compare mtime)
+* source source text
+* mtime last modification time
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -566,8 +589,12 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* name name
+* @param pProviderParam Parameter Hash dieses Providers
+* name Name (wird benutzt um mtime zu
vergelichen)
+* source Quellentext
+* mtime Zeitpunkt der letzten �nderung
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -575,12 +602,14 @@
* ------------------------------------------------------------------------ */
static int ProviderMem_AppendKey (/*in*/ req * r,
- /*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
- /*i/o*/ SV * pKey)
+ /*in*/ tProviderClass * pProviderClass,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
+ /*i/o*/ SV * pKey)
{
epTHX_
- const char * sName = GetHashValueStr (aTHX_ pParam, "name", r ->
Component.Param.sInputfile) ;
+ const char * sName = GetHashValueStr (aTHX_ pProviderParam, "name", r ->
Component.Param.sInputfile) ;
sv_catpvf (pKey, "*memory:%s", sName) ;
return ok ;
@@ -804,8 +833,9 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -817,8 +847,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -827,7 +858,9 @@
static int ProviderEpParse_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
@@ -839,9 +872,9 @@
SV * pSyntaxRV ;
SV * pSyntaxPV ;
tTokenTable * pSyntax ;
- const char * sSyntax = GetHashValueStr (aTHX_ pParam, "syntax", r ->
Component.Config.sSyntax) ;
+ const char * sSyntax = GetHashValueStr (aTHX_ pProviderParam, "syntax", r ->
Component.Config.sSyntax) ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpParse), "source", pItem,
pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpParse), "source", pItem,
pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
pSyntaxPV = sv_2mortal(newSVpv ((char *)sSyntax, 0)) ;
@@ -882,9 +915,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Sourcetext
+* @param pProviderParam Parameter Hash of this Providers
* syntax Syntax
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -896,9 +930,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext
+* @param pProviderParam Parameter Hash dieses Providers
* syntax Syntax
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -906,15 +941,17 @@
* ------------------------------------------------------------------------ */
static int ProviderEpParse_AppendKey (/*in*/ req * r,
- /*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
- /*i/o*/ SV * pKey)
+ /*in*/ tProviderClass * pProviderClass,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
+ /*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- const char * sSyntax = GetHashValueStr (aTHX_ pParam, "syntax", r ->
Component.Config.sSyntax) ;
+ const char * sSyntax = GetHashValueStr (aTHX_ pProviderParam, "syntax", r ->
Component.Config.sSyntax) ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
sv_catpvf (pKey, "*epparse:%s", sSyntax) ;
@@ -1064,8 +1101,10 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* package Packagename
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -1077,8 +1116,10 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* package Packagename
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -1087,7 +1128,9 @@
static int ProviderEpCompile_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
@@ -1096,10 +1139,10 @@
char * sPackage ;
char * sMainSub ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpCompile), "source",
pItem, pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpCompile), "source",
pItem, pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
- if (sPackage = GetHashValueStrDupA (aTHX_ pParam, "package", r ->
Component.Config.sPackage))
+ if (sPackage = GetHashValueStrDupA (aTHX_ pProviderParam, "package", r ->
Component.Config.sPackage))
{
int n ;
ep_acquire_mutex(PackageCountMutex) ;
@@ -1136,9 +1179,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Sourcetext
+* @param pProviderParam Parameter Hash of this Providers
* package Packagename
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -1150,9 +1194,10 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext
+* @param pProviderParam Parameter Hash dieses Providers
* package Packagename
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -1160,17 +1205,19 @@
* ------------------------------------------------------------------------ */
static int ProviderEpCompile_AppendKey (/*in*/ req * r,
- /*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
- /*i/o*/ SV * pKey)
+ /*in*/ tProviderClass * pProviderClass,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
+ /*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
- sv_catpvf (pKey, "*epcompile:%s", GetHashValueStr (aTHX_ pParam, "package", r
-> Component.Config.sPackage?r -> Component.Config.sPackage:"")) ;
+ sv_catpvf (pKey, "*epcompile:%s", GetHashValueStr (aTHX_ pProviderParam,
"package", r -> Component.Config.sPackage?r -> Component.Config.sPackage:"")) ;
return ok ;
}
@@ -1375,8 +1422,9 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -1388,8 +1436,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -1398,13 +1447,15 @@
static int ProviderEpRun_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpRun), "source", pItem,
pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpRun), "source", pItem,
pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -1422,11 +1473,12 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Sourcetext
+* @param pProviderParam Parameter Hash of this Providers
* cache_key
* cache_key_options
* cache_key_func
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -1438,11 +1490,12 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext
+* @param pProviderParam Parameter Hash dieses Providers
* cache_key
* cache_key_options
* cache_key_func
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -1451,21 +1504,23 @@
static int ProviderEpRun_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- const char * sKey = GetHashValueStr (aTHX_ pParam, "cache_key", r ->
Component.Config.sCacheKey) ;
- int bKeyOptions = GetHashValueInt (aTHX_ pParam, "cache_key_options",
r -> Component.Config.bCacheKeyOptions) ;
+ const char * sKey = GetHashValueStr (aTHX_ pProviderParam, "cache_key",
r -> Component.Config.sCacheKey) ;
+ int bKeyOptions = GetHashValueInt (aTHX_ pProviderParam,
"cache_key_options", r -> Component.Config.bCacheKeyOptions) ;
CV * pKeyCV ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
sv_catpv (pKey, "*eprun:") ;
- if ((rc = GetHashValueCREF (r, pParam, "cache_key_func", &pKeyCV)) != ok)
+ if ((rc = GetHashValueCREF (r, pProviderParam, "cache_key_func", &pKeyCV)) !=
ok)
return rc ;
if (!pKeyCV)
@@ -1676,8 +1731,9 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* source Sourcetext provider
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -1689,8 +1745,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext provider
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -1699,13 +1756,15 @@
static int ProviderEpToString_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpToString), "source",
pItem, pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderEpToString), "source",
pItem, pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -1723,11 +1782,9 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Sourcetext
-* cache_key
-* cache_key_options
-* cache_key_func
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -1739,11 +1796,9 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* source Quellentext
-* cache_key
-* cache_key_options
-* cache_key_func
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -1752,14 +1807,16 @@
static int ProviderEpToString_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
sv_catpv (pKey, "*eptostring") ;
1.70.4.114 +3 -3 embperl/test.pl
Index: test.pl
===================================================================
RCS file: /home/cvs/embperl/test.pl,v
retrieving revision 1.70.4.113
retrieving revision 1.70.4.114
diff -u -r1.70.4.113 -r1.70.4.114
--- test.pl 10 Feb 2002 21:26:15 -0000 1.70.4.113
+++ test.pl 16 Feb 2002 23:31:33 -0000 1.70.4.114
@@ -11,7 +11,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: test.pl,v 1.70.4.113 2002/02/10 21:26:15 richter Exp $
+# $Id: test.pl,v 1.70.4.114 2002/02/16 23:31:33 richter Exp $
#
###################################################################################
@@ -1724,7 +1724,7 @@
@testargs = ( '-o', $outfile ,
'-l', $logfile,
'-d', $debug,
- ($test->{param}?(ref ($test->{param}) eq 'ARRAY'?map {
('-p', $_) } @{$test->{param}}:('-p', $test->{param})):()),
+ ##($test->{param}?(ref ($test->{param}) eq 'ARRAY'?map {
('-p', $_) } @{$test->{param}}:('-p', $test->{param})):()),
$page, $test -> {query_info} || '') ;
unshift (@testargs, 'dbgbreak') if ($opt_dbgbreak) ;
@@ -1737,7 +1737,7 @@
$n_offline++ ;
$t1 = 0 ; # Embperl::Clock () ;
- $err = Embperl::Run::run (@testargs) ;
+ $err = Embperl::Run::run (@testargs, ref $test->{param} eq
'HASH'?[$test->{param}]:$test->{param}) ;
$t_offline += 0 ; # Embperl::Clock () - $t1 ;
if ($opt_memcheck)
No revision
No revision
1.1.2.7 +1 -3 embperl/Embperl/Attic/Object.pm
Index: Object.pm
===================================================================
RCS file: /home/cvs/embperl/Embperl/Attic/Object.pm,v
retrieving revision 1.1.2.6
retrieving revision 1.1.2.7
diff -u -r1.1.2.6 -r1.1.2.7
--- Object.pm 10 Feb 2002 21:26:16 -0000 1.1.2.6
+++ Object.pm 16 Feb 2002 23:31:34 -0000 1.1.2.7
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: Object.pm,v 1.1.2.6 2002/02/10 21:26:16 richter Exp $
+# $Id: Object.pm,v 1.1.2.7 2002/02/16 23:31:34 richter Exp $
#
###################################################################################
@@ -157,8 +157,6 @@
my ($rc, $r) = Embperl::Req::InitRequest ($req -> {req_rec}, $req) ;
return $rc if ($rc) ;
- use Data::Dumper ;
- warn Dumper ($rc, $r) ;
my $cwd ;
my $filename = norm_path ($r -> param -> filename, $cwd) ;
1.1.2.4 +3 -3 embperl/Embperl/Attic/Run.pm
Index: Run.pm
===================================================================
RCS file: /home/cvs/embperl/Embperl/Attic/Run.pm,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -u -r1.1.2.3 -r1.1.2.4
--- Run.pm 28 Jan 2002 20:28:35 -0000 1.1.2.3
+++ Run.pm 16 Feb 2002 23:31:34 -0000 1.1.2.4
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: Run.pm,v 1.1.2.3 2002/01/28 20:28:35 richter Exp $
+# $Id: Run.pm,v 1.1.2.4 2002/02/16 23:31:34 richter Exp $
#
###################################################################################
@@ -25,7 +25,7 @@
-sub run (;\@)
+sub run (;\@$)
{
@ARGV = @{$_[0]} if (ref $_[0] eq 'ARRAY') ;
@@ -52,7 +52,7 @@
}
- $param{'param'} = \@param ;
+ $param{'param'} = $_[1] if (defined ($_[1])) ;
$rc = Embperl::Execute (\%param) ;
No revision
No revision
1.1.2.15 +11 -20 embperl/Embperl/Recipe/Attic/Embperl.pm
Index: Embperl.pm
===================================================================
RCS file: /home/cvs/embperl/Embperl/Recipe/Attic/Embperl.pm,v
retrieving revision 1.1.2.14
retrieving revision 1.1.2.15
diff -u -r1.1.2.14 -r1.1.2.15
--- Embperl.pm 11 Feb 2002 17:01:07 -0000 1.1.2.14
+++ Embperl.pm 16 Feb 2002 23:31:34 -0000 1.1.2.15
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: Embperl.pm,v 1.1.2.14 2002/02/11 17:01:07 richter Exp $
+# $Id: Embperl.pm,v 1.1.2.15 2002/02/16 23:31:34 richter Exp $
#
###################################################################################
@@ -67,23 +67,17 @@
my $import =
{
- 'provider' =>
+ 'type' => 'epcompile',
+ ($config -> package?('package' => $config -> package):()),
+ 'source' =>
{
- 'type' => 'epcompile',
- ($config -> package?('package' => $config -> package):()),
+ 'cache', => 0,
+ 'type' => 'epparse',
+ $syntax?('syntax' => $syntax):(),
'source' =>
{
- 'cache', => 0,
- 'provider' =>
- {
- 'type' => 'epparse',
- $syntax?('syntax' => $syntax):(),
- 'source' =>
- {
- 'cache' => 0,
- 'provider' => $src,
- }
- }
+ 'cache' => 0,
+ %$src,
}
}
} ;
@@ -92,11 +86,8 @@
{
my $run =
{
- 'provider' =>
- {
- 'type' => 'eprun',
- 'source' => $import
- }
+ 'type' => 'eprun',
+ 'source' => $import
} ;
No revision
No revision
1.1.2.16 +72 -38 embperl/driver/Attic/eplibxslt.c
Index: eplibxslt.c
===================================================================
RCS file: /home/cvs/embperl/driver/Attic/eplibxslt.c,v
retrieving revision 1.1.2.15
retrieving revision 1.1.2.16
diff -u -r1.1.2.15 -r1.1.2.16
--- eplibxslt.c 12 Feb 2002 09:11:44 -0000 1.1.2.15
+++ eplibxslt.c 16 Feb 2002 23:31:34 -0000 1.1.2.16
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: eplibxslt.c,v 1.1.2.15 2002/02/12 09:11:44 richter Exp $
+# $Id: eplibxslt.c,v 1.1.2.16 2002/02/16 23:31:34 richter Exp $
#
###################################################################################*/
@@ -183,9 +183,11 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
* stylesheet filename or provider for the
* stylesheet
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -197,9 +199,11 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash dieses Providers
* stylesheet dateiname oder provider f�r das
* stylesheet
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -208,13 +212,15 @@
static int ProviderLibXSLTXSL_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLTXSL), "stylesheet",
pItem, pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLTXSL), "stylesheet",
pItem, pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -222,7 +228,7 @@
/* ------------------------------------------------------------------------ */
/* */
-/* ProviderFile_AppendKey */
+/* ProviderLibXSLTXSL_AppendKey */
/* */
/*!
* \_en
@@ -231,8 +237,11 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename name of file
+* @param pProviderParam Parameter Hash of this Providers
+* stylesheet filename or provider for the
+* stylesheet
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -244,8 +253,11 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename Dateiname
+* @param pProviderParam Parameter Hash dieses Providers
+* stylesheet dateiname oder provider f�r das
+* stylesheet
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -254,13 +266,15 @@
static int ProviderLibXSLTXSL_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- if ((rc = Cache_AppendKey (r, pParam, "stylesheet", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "stylesheet", pParam,
nParamIndex, pKey)) != ok)
return rc;
sv_catpv (pKey, "*libxslt-compile-xsl") ;
@@ -426,9 +440,9 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* stylesheet filename or provider for the
-* stylesheet
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -440,9 +454,9 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* stylesheet dateiname oder provider f�r das
-* stylesheet
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -451,13 +465,15 @@
static int ProviderLibXSLTXML_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLTXML), "source",
pItem, pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLTXML), "source",
pItem, pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -474,8 +490,9 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename name of file
+* @param pProviderParam Parameter Hash of this Providers
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -487,8 +504,9 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename Dateiname
+* @param pProviderParam Parameter Hash dieses Providers
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -497,13 +515,15 @@
static int ProviderLibXSLTXML_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
sv_catpv (pKey, "*libxslt-parse-xml") ;
@@ -684,9 +704,11 @@
* @param r Embperl request record
* @param pItem CacheItem which holds the output of the provider
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash of this Providers
* stylesheet filename or provider for the
* stylesheet
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @return error code
* \endif
*
@@ -698,9 +720,11 @@
* @param pItem CacheItem welches die Ausgabe des Providers
* speichert
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
+* @param pProviderParam Parameter Hash dieses Providers
* stylesheet dateiname oder provider f�r das
* stylesheet
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @return Fehlercode
* \endif
*
@@ -709,16 +733,18 @@
int ProviderLibXSLT_New (/*in*/ req * r,
/*in*/ tCacheItem * pItem,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam)
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex)
{
int rc ;
- if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLT), "source", pItem,
pProviderClass, pParam)) != ok)
+ if ((rc = Provider_NewDependOne (r, sizeof(tProviderLibXSLT), "source", pItem,
pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
- if ((rc = Provider_AddDependOne (r, pItem -> pProvider, "stylesheet", pItem,
pProviderClass, pParam)) != ok)
+ if ((rc = Provider_AddDependOne (r, pItem -> pProvider, "stylesheet", pItem,
pProviderClass, pProviderParam, pParam, nParamIndex)) != ok)
return rc ;
return ok ;
@@ -735,8 +761,11 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename name of file
+* @param pProviderParam Parameter Hash of this Providers
+* stylesheet filename or provider for the
+* stylesheet
+* @param pParam All Parameters
+* @param nParamIndex If pParam is an AV, this parameter gives the index
into the Array
* @param pKey Key to which string should be appended
* @return error code
* \endif
@@ -748,8 +777,11 @@
*
* @param r Embperl request record
* @param pProviderClass Provider class record
-* @param pParam Parameter Hash
-* filename Dateiname
+* @param pProviderParam Parameter Hash dieses Providers
+* stylesheet dateiname oder provider f�r das
+* stylesheet
+* @param pParam Parameter insgesamt
+* @param nParamIndex Wenn pParam ein AV ist, gibt dieser Parameter den
Index an
* @param pKey Schl�ssel zu welchem hinzugef�gt wird
* @return Fehlercode
* \endif
@@ -758,16 +790,18 @@
static int ProviderLibXSLT_AppendKey (/*in*/ req * r,
/*in*/ tProviderClass * pProviderClass,
- /*in*/ HV * pParam,
+ /*in*/ HV * pProviderParam,
+ /*in*/ SV * pParam,
+ /*in*/ IV nParamIndex,
/*i/o*/ SV * pKey)
{
epTHX_
int rc ;
- if ((rc = Cache_AppendKey (r, pParam, "source", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "source", pParam, nParamIndex,
pKey)) != ok)
return rc;
- if ((rc = Cache_AppendKey (r, pParam, "stylesheet", pKey)) != ok)
+ if ((rc = Cache_AppendKey (r, pProviderParam, "stylesheet", pParam,
nParamIndex, pKey)) != ok)
return rc;
sv_catpv (pKey, "*libxslt") ;
No revision
No revision
1.12.4.6 +12 -0 embperl/test/cmp/input.htm
Index: input.htm
===================================================================
RCS file: /home/cvs/embperl/test/cmp/input.htm,v
retrieving revision 1.12.4.5
retrieving revision 1.12.4.6
diff -u -r1.12.4.5 -r1.12.4.6
--- input.htm 2 May 2001 11:54:52 -0000 1.12.4.5
+++ input.htm 16 Feb 2002 23:31:34 -0000 1.12.4.6
@@ -407,6 +407,18 @@
<input type="text" name="feld6" value="feld6">
<input type="text" name="feld6" value="Wert6">
+ <textarea name="feld1"></textarea>
+ <textarea name="feld1"></textarea>
+
+ <textarea name="feld5">feld5</textarea>
+ <textarea name="feld5">Wert5</textarea>
+
+ <textarea name="feld2"></textarea>
+ <textarea name="feld2"></textarea>
+
+ <textarea name="feld6">feld6</textarea>
+ <textarea name="feld6">Wert6</textarea>
+
<p>
i = 5 fdat{feld5} Wert5<br>
<input type="checkbox" value="cbv5" name="cb5" checked>
No revision
No revision
1.1.2.8 +12 -0 embperl/test/cmp2/Attic/input.htm
Index: input.htm
===================================================================
RCS file: /home/cvs/embperl/test/cmp2/Attic/input.htm,v
retrieving revision 1.1.2.7
retrieving revision 1.1.2.8
diff -u -r1.1.2.7 -r1.1.2.8
--- input.htm 2 May 2001 12:14:15 -0000 1.1.2.7
+++ input.htm 16 Feb 2002 23:31:34 -0000 1.1.2.8
@@ -371,6 +371,18 @@
<input type="text" name="feld6" value="feld6">
<input type="text" name="feld6" value="Wert6">
+ <textarea name="feld1"></textarea>
+ <textarea name="feld1"></textarea>
+
+ <textarea name="feld5">feld5</textarea>
+ <textarea name="feld5">Wert5</textarea>
+
+ <textarea name="feld2"></textarea>
+ <textarea name="feld2"></textarea>
+
+ <textarea name="feld6">feld6</textarea>
+ <textarea name="feld6">Wert6</textarea>
+
<p>
i = 5 fdat{feld5} Wert5<br>
<input type="checkbox" value="cbv5" name="cb5" checked>
No revision
No revision
1.1.2.16 +25 -24 embperl/xsbuilder/maps/Attic/ep_structure.map
Index: ep_structure.map
===================================================================
RCS file: /home/cvs/embperl/xsbuilder/maps/Attic/ep_structure.map,v
retrieving revision 1.1.2.15
retrieving revision 1.1.2.16
diff -u -r1.1.2.15 -r1.1.2.16
--- ep_structure.map 10 Feb 2002 21:26:16 -0000 1.1.2.15
+++ ep_structure.map 16 Feb 2002 23:31:34 -0000 1.1.2.16
@@ -1,23 +1,22 @@
- MALLOC=svinc:$dest = ($type)SvREFCNT_inc($src)
-
- <tTokenTable>
-! pCompilerInfo | compiler_info
- sName | name
-! sRootNode | root_node
-! cStartChars | start_chars
-! cAllChars | all_chars
-! pTokens | tokens
-! numTokens | tokens
-! bLSearch | lsearch
-! nDefNodeType | def_node_type
-! pContainsToken | contains_token
-! new
-! private
- </tTokenTable>
-
-
-
- MALLOC=strdup:$dest = ($type)ep_pstrdup(obj->pPool,$src)
+ MALLOC=svinc:$dest = ($type)SvREFCNT_inc($src)
+
+ <tTokenTable>
+! pCompilerInfo | compiler_info
+ sName | name
+! sRootNode | root_node
+! cStartChars | start_chars
+! cAllChars | all_chars
+! pTokens | tokens
+! numTokens | tokens
+! bLSearch | lsearch
+! nDefNodeType | def_node_type
+! pContainsToken | contains_token
+! new
+! private
+ </tTokenTable>
+
+
+ MALLOC=strdup:$dest = ($type)ep_pstrdup(obj->pPool,$src)
<tReq>
! _perlsv
@@ -46,8 +45,8 @@
pCleanupAV | cleanup_vars
pCleanupPackagesHV | cleanup_packages
sInitialCWD | initial_cwd
- pMessages | messages
- pDefaultMessages | default_messages
+ pMessages | messages
+ pDefaultMessages | default_messages
startclock
stsv_count
! MemCheckpoint | mem_checkpoint
@@ -199,7 +198,7 @@
sObject | object
sISA | isa
pErrArray | errors
- pXsltParam | xsltparam
+ pXsltParam | xsltparam
new
! private
</tComponentParam>
@@ -212,6 +211,8 @@
sDecline | decline
cMultFieldSep | mult_field_sep
pPathAV | path
+ bDebug | debug
+ bOptions | options
new
! private
</tReqConfig>
@@ -224,7 +225,7 @@
sUri | uri
sPathInfo | path_info
sQueryInfo | query_info
- sLanguage | language
+ sLanguage | language
new
! private
</tReqParam>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]