updated: to the new EZC api (ezc functions can be methods of some special objects)

git-svn-id: svn://ttmath.org/publicrep/winix/trunk@1012 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
2015-06-14 18:24:08 +00:00
parent d8451ceaa0
commit f54df8d600
20 changed files with 948 additions and 836 deletions

View File

@@ -5,7 +5,7 @@
*/
/*
* Copyright (c) 2008-2014, Tomasz Sowa
* Copyright (c) 2008-2015, Tomasz Sowa
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -44,6 +44,7 @@ PatternCacher::PatternCacher()
how_many_delete = 3;
ezc_fun = 0;
ezc_blocks = 0;
ezc_obj = 0;
}
@@ -58,6 +59,13 @@ void PatternCacher::SetEzcBlocks(Ezc::Blocks * blocks)
ezc_blocks = blocks;
}
void PatternCacher::SetEzcObjects(Ezc::Objects<HtmlTextStream> * obj)
{
ezc_obj = obj;
}
void PatternCacher::SetEzcCommentary(const std::wstring & start, const std::wstring & end)
{
pattern_parser.SetCommentary(start, end);
@@ -211,6 +219,9 @@ void PatternCacher::RebuildCache(Ezc::Pattern & pattern)
{
pattern.ClearCache();
if( ezc_obj )
pattern.CacheObjects(*ezc_obj);
if( ezc_fun )
pattern.CacheFunctions(*ezc_fun);