--- parser3/www/htdocs/Attic/index.html 2002/03/26 12:19:07 1.26 +++ parser3/www/htdocs/Attic/index.html 2002/03/29 10:26:01 1.30 @@ -7,8 +7,13 @@ $response:charset[windows-1251] $response:content-type[$.value[text/html]$.charset[$response:charset]] @main[] +^rolls2[] +#^cacheexpireschanging[] +#^cacheexpiresfixed[] +#^dateoffsets[] +#^exceptionTypes[] #^roll2[] -^rolls[] +#^rolls[] #^exceptions1[] #^locate_by_expr[] #^method_junction_params{...} @@ -111,9 +116,51 @@ $response:content-type[$.value[text/html
OK +@rolls2[] +$now[^date::now[]] +$d[^date::create($now.year;$now.month)] ^d.sql-string[]
+^for[i](1;12){ + ^d.roll[month](-1) ^d.sql-string[]
+} + +@cacheexpireschanging[] +^cache[$DB_HOME/keyключ][^date::now(+1)]{ ^rem{1 day} + ^cache[^date::now(+4/24/60/60)] +# ^cache(2) +# ^cache(0) + ^math:random(100) +} + + + +@cacheexpiresfixed[] +^cache[$DB_HOME/keyключ][^date::now(+2/24/60/60)]{ + ^math:random(100) +} + +@dateoffsets[] +$d[^date::create(^date::now[]+1/24/60)] +#$d[^date::now(+1/24/60)] +^d.sql-string[] +#$d + +@exceptionTypes[] +# parser.compile ^test[} компиляция (непарная скобка, ...) +# parser.runtime ^if(0). параметры (больше/меньше, чем нужно, не тех типов, ...) +# number.zerodivision ^eval(1/0) ^eval(1%0) +# number.format ^eval(abc*5) +# file.missing ^file:delete[delme] not found +# file.access ^table::load[.] no rights +# image.format ^image::measure[index.html] not gif/jpg +# sql.connect ^connect[mysql://baduser:pass@host/db]{} not found/timeout +# sql.execute ^connect[mysql://okuser:pass@host/db]{^void:sql{select bad}} syntax error +# xml ^xdoc::create{} any error in xml/xslt libs +# smtp.connect not found/timeout +# smtp.execute communication error + @roll2[] $d[^date::create(2002;4;2;2;2;3)] ^d.sql-string[]
-^d.roll[day](-2) ^d.sql-string[]
+^d.roll[day](+365*3+1) ^d.sql-string[]
@rolls[] @@ -156,8 +203,8 @@ $d[^date::create(2002;10;19)] ^throw[custom1;paf;is stupid] }{ ^if($exception.type eq custom1){ - $exception.handled(1) -# ^throw[$exception] +# $exception.handled(1) + ^throw[$exception] type=$exception.type
source=$exception.source
file=$exception.file