示例#1
0
/*
  construct a MprVar from a string, using NULL if needed
*/
struct MprVar mprString(const char *s)
{
	if (s == NULL) {
		return mprCreatePtrVar(NULL);
	}
	return mprCreateStringVar(s, True);
}
示例#2
0
文件: esp.c 项目: embedthis/appweb-2
void espSetStringVar(EspRequest *ep, EspEnvType oType, char *var, char *value)
{
	/*
 	 *	Will create or update if already existing
 	 */
	mprSetPropertyValue(&ep->variables[oType], var, 
		mprCreateStringVar(value, 0));
}
示例#3
0
文件: esp.c 项目: embedthis/appweb-2
void espSetReturnString(EspRequest *ep, char *str)
{
	mprAssert(ep);

	ejsSetReturnValue(ep->eid, mprCreateStringVar(str, 0));
}