--- parser3/operators.ru.txt 2002/06/14 11:59:12 1.45 +++ parser3/operators.ru.txt 2002/06/25 14:28:57 1.54 @@ -272,6 +272,9 @@ odbc c:\drives\y\parser3project\odbc\ <0 = не найдено !^строка.replace[$таблица_подстановок_строка_на_строку] !^строка.save[[append;]путь] + !^строка.normalize[] выдает другую строку, в которой фрагменты на одном языке объединены + полезно делать перед сложными match операциями, если вы знаете, что входная строка + состоит из большого числа фрагментов !table в выражении @@ -414,16 +417,78 @@ Xhashfile ^code.cache[заголовки новостей](35){....} !mail + !$mail.received=MESSAGE: + .from + .reply-to + .subject + .date класса date + .message-id + .raw[ + .СЫРОЕ_ПОЛЬЗОВАТЕЛЬСКОЕ-ПОЛЕ-ЗАГОЛОВКА + ] + $.{text|html|file#}[ << нумеруется как и в mail:send (text, text2, ...) (file, file2, ...) + $.content-type[ + $.value[{text|...|x-unknown}/{plain|html|...|x-unknown}] + [$.charset[windows-1251]] << в каком пришло, сейчас уже перекодировано + $.ПОЛЬЗОВАТЕЛЬСКИЙ-ПАРАМЕТР-ЗАГОЛОВКА + ] + $.description + $.content-id + $.content-md5 + $.content-location + .raw[ + .СЫРОЕ_ПОЛЬЗОВАТЕЛЬСКОЕ-ПОЛЕ-ЗАГОЛОВКА + ] + $.value[строка|FILE] + ] + $.message#[MESSAGE] (message, message2, ...) + + !^mail:send[ + $.charset[кодировка заголовка и текстовых блоков] + $.any-header-field + $.text[string] + $.text[ + $.any-header-field + $.value[string] + ] + $.html{string} + $.html[ + $.any-header-field + $.value{string} + ] + $.file#[FILE] + $.file#[ + $.any-header-field + $value[FILE] + ] + ] + !если charset указан, письмо перекодируется в этот charset + !content-type.charset не влияет на перекодирование + !после имени части может идти # число + ^mail:send[ +# по-умолчанию, совпадает с source encoding. +# задаёт кодировку body + $.charset[windows-1251] +# нет умолчания + $.content-type[$.value[text/plain] $.charset[windows-1251]] + $.from["вася" ] + $.to["петя" ] + $.subject[пойдём пивка] + $.body[ + слова + ] + ] !:send[$.header-field[] $.charset[кодировка письма] $.body[когда body не строка, а hash, отсылается multipart письмо]] !если charset указан, письмо перекодируется в этот charset !content-type.charset не влияет на перекодирование + !после имени части может идти целое число, части пойдут в порядке чисел. !если body указан строкой, то это текст письма, никаких вложений. !если body указан hash, то это части, будут собраны текстовые блоки, затем вложения + !это старый формат, поддерживается для обратной совместимости !если имя части начинается со слова text, то это текстовый блок. !если имя части начинается со слова attach, то это вложение, формат задания:: !$attach[$.format[!uue|Xbase64] $.value[DATA] $.file-name[user-file-name]] - !после имени части может идти целое число, части пойдут в порядке чисел. !важно: при multipart не указывать content-type ^mail:send[ # по-умолчанию, совпадает с source encoding. @@ -537,6 +602,11 @@ Xhashfile выполняется код разблокируется Xchmod[...] НЕТ И НЕ БУДЕТ, ЧТОБЫ НЕ МОГЛИ СДЕЛАТЬ executable и запустить, даже если ftp запрещает chmod. + !^file:dirname[/a/some.tar.gz]=/a + !^file:dirname[/a/b/]=/a + !^file:basename[/a/some.tar.gz]=some.tar.gz + !^file:justname[/a/some.tar.gz]=some.tar + !^file:justext[/a/some.tar.gz]=gz math !$math:PI @@ -548,8 +618,12 @@ math !^math:degrees radians !^math:pow sqrt !^math:random(ширина диапазона) - ^math:{C2C0983C-E26E-4169-BD07-77ECE9405BA5} - + ^math:GUID {C2C0983C-E26E-4169-BD07-77ECE9405BA5} + !^math:crypt[password;salt] + salt prefix $apr1$ вызывает встроенный MD5 алгоритм, + если нет тела salt, оно создаётся случайным + $1$ вызывает MD5 алгоритм функции OS 'crypt', если поддерживается [заведомо нет на solaris]. + другие salt читайте документацию по функции OS 'crypt'. !date !время типа time можно использовать в выражениях, подставляет @@ -602,7 +676,7 @@ xdoc(xnode) !равно текущей кодировке выходной страницы, $response:charset ::sql{...} - !::create{} старое имя 'set' + !::create{} старое имя 'set' !::create[qualifiedName] !::load[file.xml] !.transform[rules.xsl][[params hash]] выдаёт dom @@ -623,9 +697,9 @@ xdoc(xnode) !media-type = string /> !параметры передаются как есть, не xpath выражения - !.string[output options] - !.save[file.xml;output options] с шапкой - !.file[output options] = file + !.string[[output options]] + !.save[file.xml[;output options]] с шапкой + !.file[[output options]] = file output options идентичны атрибутам xsl:output [исключение: игнорируется cdata-section-elements, нужно будет, сделаю] выдаёт media-type при подстановке $response:body[сюда] @@ -662,10 +736,15 @@ xdoc(xnode) true if the attribute received its value explicitly in the XML document, or if a value was assigned programatically with the setValue function. false if the attribute value came from the default value declared in the document's DTD. + !$attribute_node.name + !$attribute_node.value $text_node/cdata_node/comment_node.substringData !$pi_node.target = target of this processing instruction XML defines this as being the first token following the markup that begins the processing instruction. + !$pi_node.data = The content of this processing instruction + This is from the first non white space character after the target + to the character immediately preceding the ?>. document_node. readonly attribute DocumentType doctype readonly attribute DOMImplementation implementation @@ -705,9 +784,9 @@ xdoc(xnode) !^node.select[xpath/query/expression] = array of nodes, empty array if nothing found !^node.selectSingle[xpath/query/expression] = first node if any - !^node.selectBool[xpath/query/expression] = bool if any - !^node.selectNumber[xpath/query/expression] = double if any - !^node.selectString[xpath/query/expression] = string if any + !^node.selectBool[xpath/query/expression] = bool if any or die + !^node.selectNumber[xpath/query/expression] = double if any or die + !^node.selectString[xpath/query/expression] = string if any or die !error codes(пока придут как текст в случае соответствующих ошибок): INDEX_SIZE_ERR