CDT.hpp   CDT.hpp 
skipping to change at line 94 skipping to change at line 94
STRING_VAL = 0x10, STRING_VAL = 0x10,
STRING_INT_VAL = 0x12, STRING_INT_VAL = 0x12,
STRING_REAL_VAL = 0x14, STRING_REAL_VAL = 0x14,
ARRAY_VAL = 0x20, ARRAY_VAL = 0x20,
HASH_VAL = 0x40 /*, HASH_VAL = 0x40 /*,
REFERENCE_VAL = 0x80 */ REFERENCE_VAL = 0x80 */
}; };
/**
@enum eMergeStrategy CDT.hpp <CDT.hpp>
@brief Describes merging strategy for HASH-es and ARRAY-s
*/
enum eMergeStrategy { FAST_MERGE, DEEP_MERGE };
// FWD // FWD
class SortingComparator; class SortingComparator;
/** /**
@brief Constructor @brief Constructor
@param oValue - type of value @param oValue - type of value
*/ */
CDT(const CDT::eValType & oValue = UNDEF); CDT(const CDT::eValType & oValue = UNDEF);
/** /**
skipping to change at line 240 skipping to change at line 246
@param sKey - The key of the element @param sKey - The key of the element
@return Object with data @return Object with data
*/ */
CDT & operator[](const STLW::string & sKey); CDT & operator[](const STLW::string & sKey);
/** /**
@brief Provides constant access to the data contained in CDT @brief Provides constant access to the data contained in CDT
@param iPos - The index of the element @param iPos - The index of the element
@return Object with data @return Object with data
*/ */
CDT GetCDT(const UINT_32 iPos) const; const CDT & GetCDT(const UINT_32 iPos) const;
/** /**
@brief Provides constant access to the data contained in CDT @brief Provides constant access to the data contained in CDT
@param sKey - The key of the hash @param sKey - The key of the hash
@return Object with data @return Object with data
*/ */
CDT GetCDT(const STLW::string & sKey) const; const CDT & GetCDT(const STLW::string & sKey) const;
/** /**
@brief Provides constant access to the data contained in CDT @brief Provides constant access to the data contained in CDT
@param sKey - The key of the hash [in] @param sKey - The key of the hash [in]
@param bCDTExist - Existence flag [out], is set to true if object exist or false otherwise @param bCDTExist - Existence flag [out], is set to true if object exist or false otherwise
@return Object with data @return Object with data
*/ */
CDT GetExistedCDT(const STLW::string & sKey, bool & bCDTExist) const ; const CDT & GetExistedCDT(const STLW::string & sKey, bool & bCDTExis t) const;
/** /**
@brief Erase element from HASH @brief Erase element from HASH
@param sKey - The key of the hash [in] @param sKey - The key of the hash [in]
@return true - if key found, false - otherwise @return true - if key found, false - otherwise
*/ */
bool Erase(const STLW::string & sKey); bool Erase(const STLW::string & sKey);
/** /**
@brief Check element in hash @brief Check element in hash
skipping to change at line 1679 skipping to change at line 1685
UINT_32 Size() const; UINT_32 Size() const;
/** /**
@brief Swap values @brief Swap values
@param oCDT - value to swap @param oCDT - value to swap
@return Reference to self @return Reference to self
*/ */
CDT & Swap(CDT & oCDT); CDT & Swap(CDT & oCDT);
/** /**
@brief Join array elements to string
@brief sDelimiter - delimiter between elements
@return string as result of join array values
*/
STLW::string JoinArrayElements(const STLW::string & sDelimiter = ""
) const;
/**
@brief Join hash keys
@brief sDelimiter - delimiter between keys
@return string as result of join hash keys
*/
STLW::string JoinHashKeys(const STLW::string & sDelimiter = "") con
st;
/**
@brief Join hash values
@brief sDelimiter - delimiter between keys
@return string as result of join hash values
*/
STLW::string JoinHashValues(const STLW::string & sDelimiter = "") c
onst;
/**
@brief Get hash keys
@return CDT with ARRAY type with hash keys
*/
CDT GetHashKeys() const;
/**
@brief Get hash values
@return CDT with ARRAY type with hash values
*/
CDT GetHashValues() const;
/**
@brief Merge two CDT's
@param oSource - source object
@param eStrategy - Merging strategy
*/
void MergeCDT(const CDT & oSource, const eMergeStrategy & eStrategy
= FAST_MERGE);
/**
@brief Quick sort ARRAY @brief Quick sort ARRAY
@param oSortingComparator - variables comparator @param oSortingComparator - variables comparator
*/ */
void SortArray(const SortingComparator & oSortingComparator); void SortArray(const SortingComparator & oSortingComparator);
/** /**
@class SortingComparator CDT.hpp <CDT.hpp> @class SortingComparator CDT.hpp <CDT.hpp>
@brief Sorting comparator @brief Sorting comparator
*/ */
class SortingComparator class SortingComparator
skipping to change at line 1937 skipping to change at line 1983
/** /**
@brief Dump CDT into string @brief Dump CDT into string
@param iLevel - level of recursion @param iLevel - level of recursion
@param oData - data to dump @param oData - data to dump
@param sResult - string to put result in @param sResult - string to put result in
*/ */
static void DumpData(UINT_32 iLevel, UINT_32 iOffset, const CDT & oD ata, STLW::string & sResult); static void DumpData(UINT_32 iLevel, UINT_32 iOffset, const CDT & oD ata, STLW::string & sResult);
/** /**
@brief Merge two CDT's
@param oDestination - destination object
@param oSource - source object
@param eStrategy - Merging strategy
*/
static void MergeCDT(CDT & oDestination, const CDT & oSource, const
eMergeStrategy & eStrategy);
/**
@brief Check complex data type and change value type, if need @brief Check complex data type and change value type, if need
*/ */
void CheckComplexDataType() const; void CheckComplexDataType() const;
}; };
// //////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////// ///////////////////// // //////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////// /////////////////////
// //
// Realization // Realization
// //
 End of changes. 6 change blocks. 
3 lines changed or deleted 62 lines changed or added


 CTPP2SimpleCompiler.hpp   CTPP2SimpleCompiler.hpp 
/*- /*-
* Copyright (c) 2004 - 2011 CTPP Team * Copyright (c) 2004 - 2010 CTPP Team
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions * modification, are permitted provided that the following conditions
* are met: * are met:
* 1. Redistributions of source code must retain the above copyright * 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer. * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright * 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the * notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution. * documentation and/or other materials provided with the distribution.
* 4. Neither the name of the CTPP Team nor the names of its contributors * 4. Neither the name of the CTPP Team nor the names of its contributors
skipping to change at line 28 skipping to change at line 28
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPO SE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPO SE
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTI AL * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTI AL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRI CT * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRI CT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WA Y * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WA Y
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE. * SUCH DAMAGE.
* *
* CTPP2SimpleCompiler.hpp * SimpleCompiler.hpp
* *
* $CTPP$ * $CTPP$
*/ */
#ifndef _CTPP2_SIMPLE_COMPILER_HPP__ #ifndef _SIMPLE_COMPILER_HPP__
#define _CTPP2_SIMPLE_COMPILER_HPP__ 1 #define _SIMPLE_COMPILER_HPP__ 1
/** /**
@file CTPP2SimpleCompiler.hpp @file SimpleVM.hpp
@brief Compiler, simple API @brief Virtual Machine, simple use case
*/ */
#include "CTPP2Types.h" #include "CTPP2Types.h"
#include "STLString.hpp"
#include <string> #include <string>
#include <stdio.h> #include <stdio.h>
namespace CTPP // C++ Template Engine namespace CTPP // C++ Template Engine
{ {
// FWD // FWD
class CDT; class CDT;
class OutputCollector; class OutputCollector;
class VMLoader; class VMLoader;
struct VMMemoryCore; struct VMMemoryCore;
/** /**
@class SimpleCompiler CTPP2SimpleCompiler.hpp <CTPP2SimpleCompiler.hpp> @class SimpleCompiler SimpleCompiler.hpp <SimpleCompiler.hpp>
@brief Simple CTPP2 template compiler @brief Simple CTPP2 template compiler
*/ */
class CTPP2DECL SimpleCompiler class CTPP2DECL SimpleCompiler
{ {
public: public:
/** /**
@brief Constructor @brief Constructor
@param sSourceFile - source file @param sSourceFile - source file
*/ */
SimpleCompiler(const STLW::string & sSourceFile); SimpleCompiler(const std::string & sSourceFile);
/** /**
@brief Save compiled data to file @brief Save compiled data to file
@param sCompiledFile - compiled file @param sCompiledFile - compiled file
@return 0 - if success, -1 - if any error occured @return 0 - if success, -1 - if any error occured
*/ */
UINT_32 Save(const STLW::string & sCompiledFile) const; UINT_32 Save(const std::string & sCompiledFile) const;
/** /**
@brief Get memory core @brief Get memory core
@return ready to run memory core @return ready to run memory core
*/ */
const VMMemoryCore * GetCore() const; const VMMemoryCore * GetCore() const;
/** /**
@brief A destructor @brief A destructor
*/ */
skipping to change at line 98 skipping to change at line 97
/** Pompl for Simple VM internal data */ /** Pompl for Simple VM internal data */
_SimpleCompiler * pSimpleCompiler; _SimpleCompiler * pSimpleCompiler;
// Prevent object copying // Prevent object copying
SimpleCompiler(const SimpleCompiler & oRhs); SimpleCompiler(const SimpleCompiler & oRhs);
SimpleCompiler & operator=(const SimpleCompiler & oRhs); SimpleCompiler & operator=(const SimpleCompiler & oRhs);
}; };
} // namespace CTPP } // namespace CTPP
#endif // _CTPP2_SIMPLE_COMPILER_HPP__ #endif // _SIMPLE_COMPILER_HPP__
// End. // End.
 End of changes. 9 change blocks. 
11 lines changed or deleted 10 lines changed or added


 CTPP2SimpleVM.hpp   CTPP2SimpleVM.hpp 
/*- /*-
* Copyright (c) 2004 - 2011 CTPP Team * Copyright (c) 2004 - 2010 CTPP Team
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions * modification, are permitted provided that the following conditions
* are met: * are met:
* 1. Redistributions of source code must retain the above copyright * 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer. * notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright * 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the * notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution. * documentation and/or other materials provided with the distribution.
* 4. Neither the name of the CTPP Team nor the names of its contributors * 4. Neither the name of the CTPP Team nor the names of its contributors
skipping to change at line 28 skipping to change at line 28
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPO SE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPO SE
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTI AL * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTI AL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRI CT * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRI CT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WA Y * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WA Y
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE. * SUCH DAMAGE.
* *
* CTPP2SimpleVM.hpp * SimpleVM.hpp
* *
* $CTPP$ * $CTPP$
*/ */
#ifndef _CTPP2_SIMPLE_VM_HPP__ #ifndef _SIMPLE_VM_HPP__
#define _CTPP2_SIMPLE_VM_HPP__ 1 #define _SIMPLE_VM_HPP__ 1
/** /**
@file CTPP2SimpleVM.hpp @file SimpleVM.hpp
@brief Virtual Machine, simple API @brief Virtual Machine, simple use case
*/ */
#include "CTPP2Types.h" #include "CTPP2Types.h"
#include "STLString.hpp"
#include <string> #include <string>
#include <stdio.h> #include <stdio.h>
namespace CTPP // C++ Template Engine namespace CTPP // C++ Template Engine
{ {
// FWD // FWD
class CDT; class CDT;
class OutputCollector; class OutputCollector;
class Logger; class Logger;
class VMLoader; class VMLoader;
struct VMMemoryCore; struct VMMemoryCore;
/** /**
@class SimpleVM CTPP2SimpleVM.hpp <CTPP2SimpleVM.hpp> @class SimpleVM SimpleVM.hpp <SimpleVM.hpp>
@brief Simple CTPP2 Virtual machine @brief Simple CTPP2 Virtual machine
*/ */
class CTPP2DECL SimpleVM class CTPP2DECL SimpleVM
{ {
public: public:
/** /**
@brief Constructor @brief Constructor
@param iIMaxFunctions - max. number of functions in syscall factor y @param iIMaxFunctions - max. number of functions in syscall factor y
@param iIMaxArgStackSize - max. size of arguments stack @param iIMaxArgStackSize - max. size of arguments stack
@param iIMaxCodeStackSize - max. size of code stack @param iIMaxCodeStackSize - max. size of code stack
skipping to change at line 84 skipping to change at line 83
const UINT_32 & iIDebugLevel = 0); const UINT_32 & iIDebugLevel = 0);
/** /**
@brief Run program @brief Run program
@param oData - initial data @param oData - initial data
@param oLoader - template loader @param oLoader - template loader
@param sResult - result collector, STL string @param sResult - result collector, STL string
@param oLogger - logger object @param oLogger - logger object
@return instruction pointer @return instruction pointer
*/ */
UINT_32 Run(CDT & oData, const VMLoader & oLoader, STLW::string & sR esult, Logger & oLogger); UINT_32 Run(CDT & oData, const VMLoader & oLoader, std::string & sRe sult, Logger & oLogger);
/** /**
@brief Run program @brief Run program
@param oData - initial data @param oData - initial data
@param oLoader - template loader @param oLoader - template loader
@param F - result collector, file handle @param F - result collector, file handle
@param oLogger - logger object @param oLogger - logger object
@return instruction pointer @return instruction pointer
*/ */
UINT_32 Run(CDT & oData, const VMLoader & oLoader, FILE * F, Logger & oLogger); UINT_32 Run(CDT & oData, const VMLoader & oLoader, FILE * F, Logger & oLogger);
skipping to change at line 114 skipping to change at line 113
UINT_32 Run(CDT & oData, const VMLoader & oLoader, OutputCollector & oCollector, Logger & oLogger); UINT_32 Run(CDT & oData, const VMLoader & oLoader, OutputCollector & oCollector, Logger & oLogger);
/** /**
@brief Run program @brief Run program
@param oData - initial data @param oData - initial data
@param pCore - memory core @param pCore - memory core
@param sResult - result collector, STL string @param sResult - result collector, STL string
@param oLogger - logger object @param oLogger - logger object
@return instruction pointer @return instruction pointer
*/ */
UINT_32 Run(CDT & oData, const VMMemoryCore * pCore, STLW::string & sResult, Logger & oLogger); UINT_32 Run(CDT & oData, const VMMemoryCore * pCore, std::string & s Result, Logger & oLogger);
/** /**
@brief Run program @brief Run program
@param oData - initial data @param oData - initial data
@param pCore - memory core @param pCore - memory core
@param F - result collector, file handle @param F - result collector, file handle
@param oLogger - logger object @param oLogger - logger object
@return instruction pointer @return instruction pointer
*/ */
UINT_32 Run(CDT & oData, const VMMemoryCore * pCore, FILE * F, Logge r & oLogger); UINT_32 Run(CDT & oData, const VMMemoryCore * pCore, FILE * F, Logge r & oLogger);
 End of changes. 8 change blocks. 
10 lines changed or deleted 9 lines changed or added


 CTPP2SysHeaders.h   CTPP2SysHeaders.h 
skipping to change at line 81 skipping to change at line 81
#define CTPP_ESCAPE_BUFFER_LEN 1024 #define CTPP_ESCAPE_BUFFER_LEN 1024
#define CTPP_MAX_TEMPLATE_RECURSION_DEPTH 1024 #define CTPP_MAX_TEMPLATE_RECURSION_DEPTH 1024
#define ICONV_SUPPORT 1 #define ICONV_SUPPORT 1
#define ICONV_DISCARD_ILSEQ 1 #define ICONV_DISCARD_ILSEQ 1
#define ICONV_TRANSLITERATE 1 #define ICONV_TRANSLITERATE 1
#define CTPP_VERSION "2.6.12" #define CTPP_VERSION "2.6.13"
#define CTPP_IDENT "Dzoraget" #define CTPP_IDENT "Dzoraget"
#define CTPP_MASTER_SITE_URL "http://ctpp.havoc.ru/" #define CTPP_MASTER_SITE_URL "http://ctpp.havoc.ru/"
/* #undef THROW_EXCEPTION_IN_COMPARATORS */ /* #undef THROW_EXCEPTION_IN_COMPARATORS */
#endif /* _CTPP2_SYS_HEADERS_H__ */ #endif /* _CTPP2_SYS_HEADERS_H__ */
/* End. */ /* End. */
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/