Commit 13cbebbe authored by Elen.Subbotina's avatar Elen.Subbotina Committed by Alexander Trofimov

переводелка xml с микрософт на libxml2

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@61961 954022d7-b5bf-4e40-9824-e11837661b57
parent c4f63837
...@@ -11,13 +11,16 @@ ...@@ -11,13 +11,16 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
<Configurations> <Configurations>
<Configuration <Configuration
Name="Debug|Win32" Name="Debug|Win32"
OutputDirectory="$(SolutionDir)bin/Debug" OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(SolutionDir)output/$(ConfigurationName)/$(ProjectName)" IntermediateDirectory="$(SolutionDir)output/$(ConfigurationName)/$(ProjectName)"
ConfigurationType="2" ConfigurationType="2"
UseOfATL="1" UseOfATL="1"
...@@ -52,7 +55,7 @@ ...@@ -52,7 +55,7 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="$(SolutionDir)include" AdditionalIncludeDirectories="$(SolutionDir)include"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES;STANDALONE_USE=1" PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES;STANDALONE_USE=1;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
...@@ -114,10 +117,109 @@ ...@@ -114,10 +117,109 @@
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;" CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="2"
UseOfATL="1"
ATLMinimizesCRunTimeLibraryUsage="false"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="_DEBUG"
MkTypLibCompatible="false"
TargetEnvironment="3"
GenerateStublessProxies="true"
TypeLibraryName="$(IntDir)/ASCOfficeOdfFile.tlb"
HeaderFileName="ASCOfficeOdfFile.h"
DLLDataFileName=""
InterfaceIdentifierFileName="ASCOfficeOdfFile_i.c"
ProxyFileName="ASCOfficeOdfFile_p.c"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="$(SolutionDir)include"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG;_USRDLL;_ATL_ATTRIBUTES;STANDALONE_USE=1"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="_DEBUG"
Culture="1049"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
IgnoreImportLibrary="true"
AdditionalDependencies="XmlLite.lib Msimg32.lib"
OutputFile="$(OutDir)/ASCOfficeOdfFile.dll"
LinkIncremental="2"
AdditionalLibraryDirectories="&quot;$(SolutionDir)bin&quot;;..\..\ASCOfficeUtils\ZLIB\zlib123dll\static32"
IgnoreDefaultLibraryNames="libcmt.lib"
MergedIDLBaseFileName="_ASCOfficeOdfFile.idl"
GenerateDebugInformation="true"
SubSystem="2"
ImportLibrary="$(OutDir)/ASCOfficeOdfFile.lib"
TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
Description="Performing registration"
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;"
/>
</Configuration>
<Configuration <Configuration
Name="Release|Win32" Name="Release|Win32"
OutputDirectory="$(SolutionDir)bin/Release" OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(SolutionDir)output/$(ConfigurationName)/$(ProjectName)" IntermediateDirectory="$(SolutionDir)$(ConfigurationName)/$(ProjectName)"
ConfigurationType="2" ConfigurationType="2"
UseOfATL="1" UseOfATL="1"
ATLMinimizesCRunTimeLibraryUsage="false" ATLMinimizesCRunTimeLibraryUsage="false"
...@@ -218,6 +320,110 @@ ...@@ -218,6 +320,110 @@
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; &quot;../../Redist&quot;&#x0D;&#x0A;" CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; &quot;../../Redist&quot;&#x0D;&#x0A;"
/> />
</Configuration> </Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="2"
UseOfATL="1"
ATLMinimizesCRunTimeLibraryUsage="false"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
CommandLine=""
ExcludedFromBuild="false"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="NDEBUG"
MkTypLibCompatible="false"
TargetEnvironment="3"
GenerateStublessProxies="true"
TypeLibraryName="$(IntDir)/ASCOfficeOdfFile.tlb"
HeaderFileName="ASCOfficeOdfFile.h"
DLLDataFileName=""
InterfaceIdentifierFileName="ASCOfficeOdfFile_i.c"
ProxyFileName="ASCOfficeOdfFile_p.c"
/>
<Tool
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="$(SolutionDir)include"
PreprocessorDefinitions="WIN32;_WINDOWS;_USRDLL;_ATL_ATTRIBUTES;STANDALONE_USE=0"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="NDEBUG"
Culture="1049"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
CommandLine=""
/>
<Tool
Name="VCLinkerTool"
IgnoreImportLibrary="true"
AdditionalDependencies="XmlLite.lib Msimg32.lib"
OutputFile="$(OutDir)/ASCOfficeOdfFile.dll"
LinkIncremental="1"
AdditionalLibraryDirectories="$(SolutionDir)bin"
IgnoreDefaultLibraryNames="libcmt.lib"
MergedIDLBaseFileName="_ASCOfficeOdfFile.idl"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ImportLibrary="$(OutDir)/ASCOfficeOdfFile.lib"
TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
Description="Performing registration"
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; &quot;../../Redist&quot;&#x0D;&#x0A;"
/>
</Configuration>
<Configuration <Configuration
Name="Release ASC|Win32" Name="Release ASC|Win32"
OutputDirectory="$(SolutionDir)bin" OutputDirectory="$(SolutionDir)bin"
...@@ -319,6 +525,107 @@ ...@@ -319,6 +525,107 @@
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;" CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;"
/> />
</Configuration> </Configuration>
<Configuration
Name="Release ASC|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="2"
UseOfATL="1"
ATLMinimizesCRunTimeLibraryUsage="false"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
CommandLine="../../Redist/VersionControl.exe $(ProjectDir)\version.h"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="NDEBUG"
MkTypLibCompatible="false"
TargetEnvironment="3"
GenerateStublessProxies="true"
TypeLibraryName="$(IntDir)/ASCOfficeOdfFile.tlb"
HeaderFileName="ASCOfficeOdfFile.h"
DLLDataFileName=""
InterfaceIdentifierFileName="ASCOfficeOdfFile_i.c"
ProxyFileName="ASCOfficeOdfFile_p.c"
/>
<Tool
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
WholeProgramOptimization="true"
AdditionalIncludeDirectories="$(SolutionDir)include"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG;_USRDLL;_ATL_ATTRIBUTES"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="NDEBUG;ASCBUILD"
Culture="1049"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
IgnoreImportLibrary="true"
AdditionalDependencies="XmlLite.lib"
OutputFile="$(OutDir)/ASCOfficeOdfFile.dll"
LinkIncremental="1"
AdditionalLibraryDirectories="$(SolutionDir)bin"
MergedIDLBaseFileName="_ASCOfficeOdfFile.idl"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
ImportLibrary="$(OutDir)/ASCOfficeOdfFile.lib"
TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
Description="Performing registration"
CommandLine="regsvr32 /s /c &quot;$(TargetPath)&quot;"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
...@@ -375,6 +682,14 @@ ...@@ -375,6 +682,14 @@
Culture="1033" Culture="1033"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCResourceCompilerTool"
Culture="1033"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -383,6 +698,14 @@ ...@@ -383,6 +698,14 @@
Culture="1033" Culture="1033"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCResourceCompilerTool"
Culture="1033"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release ASC|Win32" Name="Release ASC|Win32"
> >
...@@ -391,6 +714,14 @@ ...@@ -391,6 +714,14 @@
Culture="1033" Culture="1033"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release ASC|x64"
>
<Tool
Name="VCResourceCompilerTool"
Culture="1033"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\ASCOfficeOdfFile.rgs" RelativePath=".\ASCOfficeOdfFile.rgs"
...@@ -416,6 +747,14 @@ ...@@ -416,6 +747,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -424,6 +763,14 @@ ...@@ -424,6 +763,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release ASC|Win32" Name="Release ASC|Win32"
> >
...@@ -432,6 +779,14 @@ ...@@ -432,6 +779,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release ASC|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File> </File>
</Files> </Files>
<Globals> <Globals>
......
...@@ -24,11 +24,6 @@ ...@@ -24,11 +24,6 @@
#include "..\..\Common\ASCATLError.h" #include "..\..\Common\ASCATLError.h"
#pragma comment(lib, "cpformulasconvert-static.lib")
#pragma comment(lib, "cpxml-static.lib")
#pragma comment(lib, "cpodf-static.lib")
#pragma comment(lib, "cpcommon-static.lib")
#ifdef _DEBUG #ifdef _DEBUG
#pragma comment(lib, "../../ASCImageStudio3/ASCGraphics/OfficeSvmFile/Debug/OfficeSvmFile.lib") #pragma comment(lib, "../../ASCImageStudio3/ASCGraphics/OfficeSvmFile/Debug/OfficeSvmFile.lib")
#else #else
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8,00" Version="8,00"
Name="cpcommon" Name="Common"
ProjectGUID="{609ED938-3CA8-4BED-B363-25096D4C4812}" ProjectGUID="{609ED938-3CA8-4BED-B363-25096D4C4812}"
RootNamespace="cpcommon" RootNamespace="cpcommon"
Keyword="Win32Proj" Keyword="Win32Proj"
...@@ -11,6 +11,9 @@ ...@@ -11,6 +11,9 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
...@@ -81,6 +84,73 @@ ...@@ -81,6 +84,73 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;&quot;$(SolutionDir)include&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="precompiled_cpcommon.h"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration <Configuration
Name="Release|Win32" Name="Release|Win32"
OutputDirectory="$(SolutionDir)bin/Release" OutputDirectory="$(SolutionDir)bin/Release"
...@@ -146,6 +216,72 @@ ...@@ -146,6 +216,72 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;&quot;$(SolutionDir)include&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="precompiled_cpcommon.h"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
...@@ -221,6 +357,14 @@ ...@@ -221,6 +357,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -229,6 +373,14 @@ ...@@ -229,6 +373,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\common\precompiled_cpcommon.h" RelativePath=".\src\common\precompiled_cpcommon.h"
......
...@@ -32,46 +32,59 @@ EndProject ...@@ -32,46 +32,59 @@ EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32 Debug|Win32 = Debug|Win32
Release ASC|Win32 = Release ASC|Win32 Debug|x64 = Debug|x64
Release|Win32 = Release|Win32 Release|Win32 = Release|Win32
Release|x64 = Release|x64
EndGlobalSection EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution GlobalSection(ProjectConfigurationPlatforms) = postSolution
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|Win32.ActiveCfg = Debug|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|Win32.ActiveCfg = Debug|Win32
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|Win32.Build.0 = Debug|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|Win32.Build.0 = Debug|Win32
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release ASC|Win32.ActiveCfg = Release|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|x64.ActiveCfg = Debug|x64
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release ASC|Win32.Build.0 = Release|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Debug|x64.Build.0 = Debug|x64
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|Win32.ActiveCfg = Release|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|Win32.ActiveCfg = Release|Win32
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|Win32.Build.0 = Release|Win32 {41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|Win32.Build.0 = Release|Win32
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|x64.ActiveCfg = Release|Win32
{41BED424-4EAF-4053-8A5F-1E2A387D53D1}.Release|x64.Build.0 = Release|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Debug|Win32.ActiveCfg = Debug|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Debug|Win32.ActiveCfg = Debug|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Debug|Win32.Build.0 = Debug|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Debug|Win32.Build.0 = Debug|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Release ASC|Win32.ActiveCfg = Release|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Debug|x64.ActiveCfg = Debug|x64
{50E20601-4A8D-4AFB-8870-63828D328429}.Release ASC|Win32.Build.0 = Release|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Debug|x64.Build.0 = Debug|x64
{50E20601-4A8D-4AFB-8870-63828D328429}.Release|Win32.ActiveCfg = Release|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Release|Win32.ActiveCfg = Release|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Release|Win32.Build.0 = Release|Win32 {50E20601-4A8D-4AFB-8870-63828D328429}.Release|Win32.Build.0 = Release|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Release|x64.ActiveCfg = Release|Win32
{50E20601-4A8D-4AFB-8870-63828D328429}.Release|x64.Build.0 = Release|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.ActiveCfg = Debug|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.ActiveCfg = Debug|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.Build.0 = Debug|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|Win32.Build.0 = Debug|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release ASC|Win32.ActiveCfg = Release|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|x64.ActiveCfg = Debug|x64
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release ASC|Win32.Build.0 = Release|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Debug|x64.Build.0 = Debug|x64
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.ActiveCfg = Release|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.ActiveCfg = Release|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.Build.0 = Release|Win32 {609ED938-3CA8-4BED-B363-25096D4C4812}.Release|Win32.Build.0 = Release|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|x64.ActiveCfg = Release|Win32
{609ED938-3CA8-4BED-B363-25096D4C4812}.Release|x64.Build.0 = Release|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|Win32.ActiveCfg = Debug|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|Win32.ActiveCfg = Debug|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|Win32.Build.0 = Debug|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|Win32.Build.0 = Debug|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release ASC|Win32.ActiveCfg = Release ASC|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|x64.ActiveCfg = Debug|x64
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release ASC|Win32.Build.0 = Release ASC|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Debug|x64.Build.0 = Debug|x64
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|Win32.ActiveCfg = Release|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|Win32.ActiveCfg = Release|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|Win32.Build.0 = Release|Win32 {64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|Win32.Build.0 = Release|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|x64.ActiveCfg = Release|Win32
{64B09C98-22DC-494E-A882-9E2D7D18557C}.Release|x64.Build.0 = Release|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|Win32.ActiveCfg = Debug|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|Win32.ActiveCfg = Debug|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|Win32.Build.0 = Debug|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|Win32.Build.0 = Debug|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release ASC|Win32.ActiveCfg = Release|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|x64.ActiveCfg = Debug|x64
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release ASC|Win32.Build.0 = Release|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Debug|x64.Build.0 = Debug|x64
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|Win32.ActiveCfg = Release|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|Win32.ActiveCfg = Release|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|Win32.Build.0 = Release|Win32 {C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|Win32.Build.0 = Release|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|x64.ActiveCfg = Release|Win32
{C2882DDD-07E6-4314-AD4B-48F43F38D722}.Release|x64.Build.0 = Release|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|Win32.ActiveCfg = Debug|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|Win32.ActiveCfg = Debug|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|Win32.Build.0 = Debug|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|Win32.Build.0 = Debug|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release ASC|Win32.ActiveCfg = Release|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|x64.ActiveCfg = Debug|x64
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release ASC|Win32.Build.0 = Release|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Debug|x64.Build.0 = Debug|x64
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.ActiveCfg = Release|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.ActiveCfg = Release|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.Build.0 = Release|Win32 {94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|Win32.Build.0 = Release|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|x64.ActiveCfg = Release|Win32
{94954A67-A853-43B1-A727-6EF2774C5A6A}.Release|x64.Build.0 = Release|Win32
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8,00" Version="8,00"
Name="cpodf" Name="OdfFormat"
ProjectGUID="{50E20601-4A8D-4AFB-8870-63828D328429}" ProjectGUID="{50E20601-4A8D-4AFB-8870-63828D328429}"
RootNamespace="cpodf" RootNamespace="cpodf"
Keyword="Win32Proj" Keyword="Win32Proj"
...@@ -11,6 +11,9 @@ ...@@ -11,6 +11,9 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
...@@ -37,6 +40,73 @@ ...@@ -37,6 +40,73 @@
<Tool <Tool
Name="VCMIDLTool" Name="VCMIDLTool"
/> />
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;&quot;$(SolutionDir)include&quot;;&quot;$(SolutionDir)3dparty\gtest\include\&quot;;&quot;$(SolutionDir)3dparty\utf8cpp\include&quot;;&quot;$(SolutionDir)formulasconvert\include\&quot;;.\src\odf\datatypes;.\src\odf\"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
PrecompiledHeaderThrough=""
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName).lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
...@@ -49,7 +119,7 @@ ...@@ -49,7 +119,7 @@
PrecompiledHeaderThrough="precompiled_cpodf.h" PrecompiledHeaderThrough="precompiled_cpodf.h"
WarningLevel="3" WarningLevel="3"
Detect64BitPortabilityProblems="true" Detect64BitPortabilityProblems="true"
DebugInformationFormat="4" DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172" DisableSpecificWarnings="4311;4267;4996;4172"
/> />
<Tool <Tool
...@@ -63,7 +133,7 @@ ...@@ -63,7 +133,7 @@
/> />
<Tool <Tool
Name="VCLibrarianTool" Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib" OutputFile="$(OutDir)\$(ProjectName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -128,7 +198,74 @@ ...@@ -128,7 +198,74 @@
/> />
<Tool <Tool
Name="VCLibrarianTool" Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib" OutputFile="$(OutDir)\$(ProjectName).lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
CommandLine="D:\WORK\VersionControl.exe $(ProjectDir)\ASCOfficeOdfFile\version.h"
/>
</Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;&quot;$(SolutionDir)include&quot;;&quot;$(SolutionDir)3dparty\gtest\include\&quot;;&quot;$(SolutionDir)3dparty\utf8cpp\include&quot;;&quot;$(SolutionDir)formulasconvert\include\&quot;;.\src\odf\datatypes;.\src\odf\"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="precompiled_cpodf.h"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -217,6 +354,14 @@ ...@@ -217,6 +354,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -225,6 +370,14 @@ ...@@ -225,6 +370,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\odf\precompiled_cpodf.h" RelativePath=".\src\odf\precompiled_cpodf.h"
...@@ -510,6 +663,15 @@ ...@@ -510,6 +663,15 @@
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc" XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -519,6 +681,15 @@ ...@@ -519,6 +681,15 @@
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc" XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\odf\datatypes\common_attlists.h" RelativePath=".\src\odf\datatypes\common_attlists.h"
...@@ -1187,6 +1358,15 @@ ...@@ -1187,6 +1358,15 @@
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc" XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
<FileConfiguration <FileConfiguration
Name="Release|Win32" Name="Release|Win32"
> >
...@@ -1196,6 +1376,15 @@ ...@@ -1196,6 +1376,15 @@
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc" XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
ObjectFile="$(IntDir)\$(InputName)1.obj"
XMLDocumentationFileName="$(IntDir)\$(InputName)1.xdc"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\docx\namespaces.h" RelativePath=".\src\docx\namespaces.h"
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8,00" Version="8,00"
Name="cpxml" Name="xml_wrapper"
ProjectGUID="{41BED424-4EAF-4053-8A5F-1E2A387D53D1}" ProjectGUID="{41BED424-4EAF-4053-8A5F-1E2A387D53D1}"
RootNamespace="cpxml" RootNamespace="cpxml"
Keyword="Win32Proj" Keyword="Win32Proj"
...@@ -11,6 +11,9 @@ ...@@ -11,6 +11,9 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
...@@ -41,7 +44,74 @@ ...@@ -41,7 +44,74 @@
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;" AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE" PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="0"
PrecompiledHeaderThrough=""
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName).lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;USE_LITE_READER;_USE_XMLLITE_READER_;_USE_LIBXML2_READER_;LIBXML_READER_ENABLED"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
RuntimeLibrary="3" RuntimeLibrary="3"
...@@ -49,7 +119,7 @@ ...@@ -49,7 +119,7 @@
PrecompiledHeaderThrough="precompiled_cpxml.h" PrecompiledHeaderThrough="precompiled_cpxml.h"
WarningLevel="3" WarningLevel="3"
Detect64BitPortabilityProblems="true" Detect64BitPortabilityProblems="true"
DebugInformationFormat="4" DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172" DisableSpecificWarnings="4311;4267;4996;4172"
/> />
<Tool <Tool
...@@ -63,7 +133,7 @@ ...@@ -63,7 +133,7 @@
/> />
<Tool <Tool
Name="VCLibrarianTool" Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib" OutputFile="$(OutDir)\$(ProjectName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -146,6 +216,72 @@ ...@@ -146,6 +216,72 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
FavorSizeOrSpeed="1"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="precompiled_cpxml.h"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
...@@ -156,6 +292,14 @@ ...@@ -156,6 +292,14 @@
<File <File
RelativePath=".\src\xml\sax_win32_xmllite.cpp" RelativePath=".\src\xml\sax_win32_xmllite.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\xml\sax_win32_xmllite.h" RelativePath=".\src\xml\sax_win32_xmllite.h"
...@@ -202,20 +346,20 @@ ...@@ -202,20 +346,20 @@
RelativePath=".\src\xml\attributes.cpp" RelativePath=".\src\xml\attributes.cpp"
> >
</File> </File>
<File
RelativePath=".\src\xml\istream2Win32Stream.cpp"
>
</File>
<File
RelativePath=".\src\xml\istream2Win32Stream.h"
>
</File>
<File <File
RelativePath=".\src\xml\precompiled_cpxml.cpp" RelativePath=".\src\xml\precompiled_cpxml.cpp"
> >
<FileConfiguration <FileConfiguration
Name="Debug|Win32" Name="Debug|Win32"
> >
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
...@@ -229,6 +373,14 @@ ...@@ -229,6 +373,14 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\xml\precompiled_cpxml.h" RelativePath=".\src\xml\precompiled_cpxml.h"
...@@ -237,30 +389,66 @@ ...@@ -237,30 +389,66 @@
<File <File
RelativePath=".\src\xml\sax.cpp" RelativePath=".\src\xml\sax.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\xml\serialize_attributes.cpp" RelativePath=".\src\xml\serialize_attributes.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\xml\utils.cpp" RelativePath=".\src\xml\utils.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\include\cpdoccore\xml\utils.h" RelativePath=".\include\cpdoccore\xml\utils.h"
> >
</File> </File>
<File
RelativePath=".\src\xml\win32ver.h"
>
</File>
<File <File
RelativePath=".\src\xml\xmlchar.cpp" RelativePath=".\src\xml\xmlchar.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
<File <File
RelativePath=".\src\xml\xmlelement.cpp" RelativePath=".\src\xml\xmlelement.cpp"
> >
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="0"
/>
</FileConfiguration>
</File> </File>
</Files> </Files>
<Globals> <Globals>
......
...@@ -11,6 +11,9 @@ ...@@ -11,6 +11,9 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
...@@ -167,6 +170,160 @@ ...@@ -167,6 +170,160 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="1"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="kernel32.lib $(NoInherit)"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="1"
TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="1"
CharacterSet="1"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
RuntimeLibrary="2"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
AdditionalDependencies="kernel32.lib $(NoInherit)"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="17"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
...@@ -199,6 +356,22 @@ ...@@ -199,6 +356,22 @@
UsePrecompiledHeader="1" UsePrecompiledHeader="1"
/> />
</FileConfiguration> </FileConfiguration>
<FileConfiguration
Name="Debug|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|x64"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File> </File>
</Filter> </Filter>
<Filter <Filter
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8,00" Version="8,00"
Name="cpformulasconvert" Name="FormulasConvert"
ProjectGUID="{94954A67-A853-43B1-A727-6EF2774C5A6A}" ProjectGUID="{94954A67-A853-43B1-A727-6EF2774C5A6A}"
RootNamespace="formulasconvert" RootNamespace="formulasconvert"
> >
...@@ -10,6 +10,9 @@ ...@@ -10,6 +10,9 @@
<Platform <Platform
Name="Win32" Name="Win32"
/> />
<Platform
Name="x64"
/>
</Platforms> </Platforms>
<ToolFiles> <ToolFiles>
</ToolFiles> </ToolFiles>
...@@ -77,6 +80,70 @@ ...@@ -77,6 +80,70 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Debug|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;..\include;..\3dparty\gtest\include\;..\dparty\utf8cpp\include"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration <Configuration
Name="Release|Win32" Name="Release|Win32"
OutputDirectory="$(SolutionDir)bin/Release" OutputDirectory="$(SolutionDir)bin/Release"
...@@ -138,6 +205,68 @@ ...@@ -138,6 +205,68 @@
Name="VCPostBuildEventTool" Name="VCPostBuildEventTool"
/> />
</Configuration> </Configuration>
<Configuration
Name="Release|x64"
OutputDirectory="$(SolutionDir)$(PlatformName)\$(ConfigurationName)"
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
ConfigurationType="4"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
TargetEnvironment="3"
/>
<Tool
Name="VCCLCompilerTool"
AdditionalIncludeDirectories="&quot;$(ProjectDir)include&quot;;..\include;..\3dparty\gtest\include\;..\3dparty\utf8cpp\include"
RuntimeLibrary="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
DisableSpecificWarnings="4311;4267;4996;4172"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
OutputFile="$(OutDir)\$(ProjectName)-static.lib"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations> </Configurations>
<References> <References>
</References> </References>
......
/// \brief Simple API XML /// \brief Simple API XML
#ifndef _CPDOCCORE_XML_SAX_H_
#define _CPDOCCORE_XML_SAX_H_
#ifdef _MSC_VER
#pragma once #pragma once
#endif
#include <string> #include <string>
#include <exception> #include <exception>
...@@ -43,7 +39,7 @@ public: ...@@ -43,7 +39,7 @@ public:
public: public:
virtual unsigned int attrCount() = 0; virtual unsigned int attrCount() = 0;
virtual std::wstring baseURI() = 0; //virtual std::wstring baseURI() = 0;
virtual unsigned int depth() = 0; virtual unsigned int depth() = 0;
// <p:abc/>, returns "abc". // <p:abc/>, returns "abc".
...@@ -55,8 +51,8 @@ public: ...@@ -55,8 +51,8 @@ public:
// <xyz:abc xmlns:xyz="u://1" />, it returns "xyz". // <xyz:abc xmlns:xyz="u://1" />, it returns "xyz".
virtual std::wstring namespacePrefix() = 0; virtual std::wstring namespacePrefix() = 0;
// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />. //// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />.
virtual std::wstring namespaceUri() = 0; //virtual std::wstring namespaceUri() = 0;
virtual NodeType nodeType() = 0; virtual NodeType nodeType() = 0;
virtual std::wstring value() = 0; virtual std::wstring value() = 0;
...@@ -67,7 +63,6 @@ public: ...@@ -67,7 +63,6 @@ public:
virtual bool isEof() = 0; virtual bool isEof() = 0;
virtual bool moveToAttrByName(const wchar_t * Name, const wchar_t * nsURI) = 0;
virtual bool moveToAttrFirst() = 0; virtual bool moveToAttrFirst() = 0;
virtual bool moveToAttrNext() = 0; virtual bool moveToAttrNext() = 0;
virtual void moveToAttrOwner() = 0; virtual void moveToAttrOwner() = 0;
...@@ -75,10 +70,7 @@ public: ...@@ -75,10 +70,7 @@ public:
virtual NodeType next() = 0; virtual NodeType next() = 0;
virtual unsigned int lineNumber() = 0; //virtual unsigned int readChunk(wchar_t * Buffer, unsigned int Size) = 0;
virtual unsigned int linePosition() = 0;
virtual unsigned int readChunk(wchar_t * Buffer, unsigned int Size) = 0;
virtual ~sax() = 0; virtual ~sax() = 0;
...@@ -88,13 +80,11 @@ public: ...@@ -88,13 +80,11 @@ public:
inline sax::~sax() {}; inline sax::~sax() {};
sax_ptr create_sax(const wchar_t * FileName); sax_ptr create_sax(const wchar_t * FileName);
sax_ptr create_sax(shared_ptr< std::istream >::Type istreamPtr); //sax_ptr create_sax(shared_ptr< std::istream >::Type istreamPtr);
sax_ptr create_sax(std::istream & istreamVal); //sax_ptr create_sax(std::istream & istreamVal);
//sax_ptr create_sax(const std::string & String); //sax_ptr create_sax(const std::string & String);
} // namespace xml } // namespace xml
} // namespace cpdoccore } // namespace cpdoccore
#endif // #ifndef _CPDOCCORE_XML_SAX_H_
...@@ -59,19 +59,19 @@ namespace fs = ::boost::filesystem; ...@@ -59,19 +59,19 @@ namespace fs = ::boost::filesystem;
namespace { namespace {
content_xml_t_ptr read_file_content(const fs::wpath & Path) content_xml_t_ptr read_file_content(const fs::wpath & Path)
{ {
fs::ifstream content_file; //fs::ifstream content_file;
content_file.open(Path); //content_file.open(Path);
if (content_file) // if (content_file)
{ {
xml::sax_ptr sax = xml::create_sax( content_file ); xml::sax_ptr sax = xml::create_sax( /*content_file*/ Path);
content_xml_t_ptr result( new content_xml_t() ); content_xml_t_ptr result( new content_xml_t() );
result->read_sax(sax.get()); result->read_sax(sax.get());
return result; return result;
} }
else //else
{ //{
_CP_LOG(info) << L"[warning] open file error (" << BOOST_STRING_PATH(Path) << L")\n"; // _CP_LOG(info) << L"[warning] open file error (" << BOOST_STRING_PATH(Path) << L")\n";
} //}
return content_xml_t_ptr(); return content_xml_t_ptr();
} }
} }
......
#ifndef _PRECOMPILED_CPXML_
#define _PRECOMPILED_CPXML_
#ifdef _MSC_VER
#pragma once #pragma once
#ifdef __cplusplus
#include <string> #include <string>
#include <map> #include <map>
#include <boost/optional.hpp> #include <boost/optional.hpp>
#include <lexical_cast.h> #include <lexical_cast.h>
#endif
#endif
#endif
...@@ -14,15 +14,15 @@ sax_ptr create_sax(const wchar_t * FileName) ...@@ -14,15 +14,15 @@ sax_ptr create_sax(const wchar_t * FileName)
return create_sax_win32_xmllite(FileName); return create_sax_win32_xmllite(FileName);
} }
sax_ptr create_sax(shared_ptr< std::istream >::Type istreamPtr) //sax_ptr create_sax(shared_ptr< std::istream >::Type istreamPtr)
{ //{
return create_sax_win32_xmllite(istreamPtr); // return create_sax_win32_xmllite(istreamPtr);
} //}
//
sax_ptr create_sax(std::istream & istreamVal) //sax_ptr create_sax(std::istream & istreamVal)
{ //{
return create_sax_win32_xmllite(istreamVal); // return create_sax_win32_xmllite(istreamVal);
} //}
/* /*
sax_ptr create_sax(const std::string & String) sax_ptr create_sax(const std::string & String)
......
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
#include <string> #include <string>
#include "win32ver.h"
#define _ATL_APARTMENT_THREADED #define _ATL_APARTMENT_THREADED
#define _ATL_NO_AUTOMATIC_NAMESPACE #define _ATL_NO_AUTOMATIC_NAMESPACE
...@@ -15,22 +14,22 @@ ...@@ -15,22 +14,22 @@
// turns off ATL's hiding of some common and often safely ignored warning messages // turns off ATL's hiding of some common and often safely ignored warning messages
#define _ATL_ALL_WARNINGS #define _ATL_ALL_WARNINGS
#include <atlbase.h> //#include <atlbase.h>
#include <atlcom.h> //#include <atlcom.h>
#include <atlwin.h> //#include <atlwin.h>
#include <atltypes.h> //#include <atltypes.h>
#include <atlctl.h> //#include <atlctl.h>
#include <atlhost.h> //#include <atlhost.h>
using namespace ATL; //using namespace ATL;
#include <windows.h> #include "../../../Common/DocxFormat/Source/Base/Nullable.h"
#include <xmllite.h> #include "../../../common/docxformat/source/xml/libxml2/libxml2.h"
#include <cpdoccore/xml/sax.h> #include <cpdoccore/xml/sax.h>
#include "sax_win32_xmllite.h" #include "sax_win32_xmllite.h"
#include "istream2Win32Stream.h" //#include "istream2Win32Stream.h"
namespace cpdoccore { namespace cpdoccore {
namespace xml { namespace xml {
...@@ -39,13 +38,13 @@ class SaxWin32XmlLite : public sax ...@@ -39,13 +38,13 @@ class SaxWin32XmlLite : public sax
{ {
public: public:
SaxWin32XmlLite(const wchar_t * FileName); SaxWin32XmlLite(const wchar_t * FileName);
SaxWin32XmlLite(shared_ptr< std::istream >::Type istreamPtr); //SaxWin32XmlLite(shared_ptr< std::istream >::Type istreamPtr);
SaxWin32XmlLite(std::istream & istreamVal); //SaxWin32XmlLite(std::istream & istreamVal);
SaxWin32XmlLite(); SaxWin32XmlLite();
public: public:
virtual unsigned int attrCount(); virtual unsigned int attrCount();
virtual std::wstring baseURI(); //virtual std::wstring baseURI();
virtual unsigned int depth(); virtual unsigned int depth();
// <p:abc/>, returns "abc". // <p:abc/>, returns "abc".
...@@ -57,8 +56,8 @@ public: ...@@ -57,8 +56,8 @@ public:
// <xyz:abc xmlns:xyz="u://1" />, it returns "xyz". // <xyz:abc xmlns:xyz="u://1" />, it returns "xyz".
virtual std::wstring namespacePrefix(); virtual std::wstring namespacePrefix();
// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />. //// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />.
virtual std::wstring namespaceUri(); //virtual std::wstring namespaceUri();
virtual NodeType nodeType(); virtual NodeType nodeType();
virtual std::wstring value(); virtual std::wstring value();
...@@ -77,43 +76,40 @@ public: ...@@ -77,43 +76,40 @@ public:
virtual NodeType next(); virtual NodeType next();
virtual unsigned int lineNumber(); //virtual unsigned int readChunk(wchar_t * Buffer, unsigned int Size);
virtual unsigned int linePosition();
virtual unsigned int readChunk(wchar_t * Buffer, unsigned int Size);
private: private:
::ATL::CComPtr< IXmlReader > xml_; smart_ptr< XmlUtils::CXmlLiteReader > xml_;
}; };
namespace namespace
{ {
NodeType NodeTypeConvert(XmlNodeType Type) NodeType NodeTypeConvert(XmlUtils::XmlNodeType Type)
{ {
switch(Type) switch(Type)
{ {
case XmlNodeType_None: case XmlUtils::XmlNodeType_None:
return typeNone; return typeNone;
case XmlNodeType_Element: case XmlUtils::XmlNodeType_Element:
return typeElement; return typeElement;
case XmlNodeType_Attribute: case XmlUtils::XmlNodeType_Attribute:
return typeAttribute; return typeAttribute;
case XmlNodeType_Text: case XmlUtils::XmlNodeType_Text:
return typeText; return typeText;
case XmlNodeType_CDATA: case XmlUtils::XmlNodeType_CDATA:
return typeCDATA; return typeCDATA;
case XmlNodeType_ProcessingInstruction: case XmlUtils::XmlNodeType_ProcessingInstruction:
return typeProcessingInstruction; return typeProcessingInstruction;
case XmlNodeType_Comment: case XmlUtils::XmlNodeType_Comment:
return typeComment; return typeComment;
case XmlNodeType_DocumentType: case XmlUtils::XmlNodeType_DocumentType:
return typeDocumentType; return typeDocumentType;
case XmlNodeType_Whitespace: case XmlUtils::XmlNodeType_Whitespace:
return typeWhitespace; return typeWhitespace;
case XmlNodeType_EndElement: case XmlUtils::XmlNodeType_EndElement:
return typeEndElement; return typeEndElement;
case XmlNodeType_XmlDeclaration: case XmlUtils::XmlNodeType_XmlDeclaration:
return typeXmlDeclaration; return typeXmlDeclaration;
default: default:
return typeNone; return typeNone;
...@@ -123,191 +119,135 @@ namespace ...@@ -123,191 +119,135 @@ namespace
SaxWin32XmlLite::SaxWin32XmlLite(const wchar_t * FileName) SaxWin32XmlLite::SaxWin32XmlLite(const wchar_t * FileName)
{ {
::ATL::CComPtr< IStream > pFileStream; xml_ = new XmlUtils::CXmlLiteReader();
HRESULT hr;
if (FAILED(hr = ::SHCreateStreamOnFileW(FileName, STGM_READ, &pFileStream))) xml_->FromFile(FileName);
{
//wprintf(L"Error creating file reader, error is %08.8lx", hr);
throw error( error::openFile );
}
if (FAILED(hr = ::CreateXmlReader(__uuidof(IXmlReader), (void**)&xml_, NULL)))
{
//wprintf(L"Error creating xml reader, error is %08.8lx", hr);
throw error( error::createReader );
}
if FAILED(xml_->SetInput(pFileStream))
{
throw error( error::createReader );
};
}
SaxWin32XmlLite::SaxWin32XmlLite(shared_ptr< std::istream >::Type istreamPtr)
{
HRESULT hr;
::ATL::CComPtr< IStream > stream = istreamToWin32IStream(istreamPtr);
if (FAILED(hr = ::CreateXmlReader(__uuidof(IXmlReader), (void**)&xml_, NULL)))
{
//wprintf(L"Error creating xml reader, error is %08.8lx", hr);
throw error( error::createReader );
}
if FAILED(xml_->SetInput(stream))
{
throw error( error::createReader );
};
}
SaxWin32XmlLite::SaxWin32XmlLite(std::istream & istreamVal)
{
HRESULT hr;
::ATL::CComPtr< IStream > stream = istreamToWin32IStream(istreamVal);
if (FAILED(hr = ::CreateXmlReader(__uuidof(IXmlReader), (void**)&xml_, NULL)))
{
//wprintf(L"Error creating xml reader, error is %08.8lx", hr);
throw error( error::createReader );
}
if FAILED(xml_->SetInput(stream))
{
throw error( error::createReader );
};
} }
//SaxWin32XmlLite::SaxWin32XmlLite(shared_ptr< std::istream >::Type istreamPtr)
//{
// HRESULT hr;
// ::ATL::CComPtr< IStream > stream = istreamToWin32IStream(istreamPtr);
//
// if (FAILED(hr = ::CreateXmlReader(__uuidof(IXmlReader), (void**)&xml_, NULL)))
// {
// //wprintf(L"Error creating xml reader, error is %08.8lx", hr);
// throw error( error::createReader );
// }
//
// if FAILED(xml_->SetInput(stream))
// {
// throw error( error::createReader );
// };
//
//}
//
//SaxWin32XmlLite::SaxWin32XmlLite(std::istream & istreamVal)
//{
// HRESULT hr;
// ::ATL::CComPtr< IStream > stream = istreamToWin32IStream(istreamVal);
//
// if (FAILED(hr = ::CreateXmlReader(__uuidof(IXmlReader), (void**)&xml_, NULL)))
// {
// //wprintf(L"Error creating xml reader, error is %08.8lx", hr);
// throw error( error::createReader );
// }
//
// if FAILED(xml_->SetInput(stream))
// {
// throw error( error::createReader );
// };
//}
//
unsigned int SaxWin32XmlLite::attrCount() unsigned int SaxWin32XmlLite::attrCount()
{ {
HRESULT hr; if (xml_.IsInit() == false) return 0;
UINT count = 0;
if FAILED(hr = xml_->GetAttributeCount(&count))
{
throw error(error::internalErr);
}
return count;
}
std::wstring SaxWin32XmlLite::baseURI()
{
HRESULT hr;
UINT size = 0;
const wchar_t * val;
if FAILED(hr = xml_->GetBaseUri(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
return xml_->GetAttributesCount();
} }
//std::wstring SaxWin32XmlLite::baseURI()
//{
// HRESULT hr;
// UINT size = 0;
// const wchar_t * val;
// if FAILED(hr = xml_->GetBaseUri(&val, &size))
// {
// throw error(error::internalErr);
// }
// if (size)
// return std::wstring(&val[0], &val[size]);
// else
// return L"";
//
//}
unsigned int SaxWin32XmlLite::depth() unsigned int SaxWin32XmlLite::depth()
{ {
HRESULT hr; if (xml_.IsInit() == false) return 0;
UINT depth = 0;
if FAILED(hr = xml_->GetDepth(&depth)) return xml_->GetDepth();
{
throw error(error::internalErr);
}
return depth;
} }
// <p:abc/>, returns "abc". // <p:abc/>, returns "abc".
std::wstring SaxWin32XmlLite::nodeLocalName() std::wstring SaxWin32XmlLite::nodeLocalName()
{ {
HRESULT hr; if (xml_.IsInit() == false) return _T("");
UINT size = 0;
const wchar_t * val; return XmlUtils::GetNameNoNS(xml_->GetName()).GetBuffer();
if FAILED(hr = xml_->GetLocalName(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
} }
// <p:abc />, returns "p:abc". // <p:abc />, returns "p:abc".
std::wstring SaxWin32XmlLite::nodeQualifiedName() std::wstring SaxWin32XmlLite::nodeQualifiedName()
{ {
HRESULT hr; if (xml_.IsInit() == false) return _T("");
UINT size = 0; return xml_->GetName();
const wchar_t * val;
if FAILED(hr = xml_->GetQualifiedName(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
} }
// <xyz:abc xmlns:xyz="u://1" />, it returns "xyz". // <xyz:abc xmlns:xyz="u://1" />, it returns "xyz".
std::wstring SaxWin32XmlLite::namespacePrefix() std::wstring SaxWin32XmlLite::namespacePrefix()
{ {
HRESULT hr; if (xml_.IsInit() == false) return _T("");
UINT size = 0;
const wchar_t * val;
if FAILED(hr = xml_->GetPrefix(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
} xmlChar* pName = xmlTextReaderPrefix(xml_->getNativeReader());
if (NULL == pName)
// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />. return L"";
std::wstring SaxWin32XmlLite::namespaceUri()
{
HRESULT hr;
UINT size = 0;
const wchar_t * val;
if FAILED(hr = xml_->GetNamespaceUri(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
std::wstring sTemp = NSFile::CUtf8Converter::GetUnicodeStringFromUTF8((BYTE*)pName, (LONG)strlen((const char*)pName));
free(pName);
return sTemp;
} }
//
//// Returns "u://1" for the element <xyz:abc xmlns:xyz="u://1" />.
//std::wstring SaxWin32XmlLite::namespaceUri()
//{
// HRESULT hr;
// UINT size = 0;
// const wchar_t * val;
// if FAILED(hr = xml_->GetNamespaceUri(&val, &size))
// {
// throw error(error::internalErr);
// }
// if (size)
// return std::wstring(&val[0], &val[size]);
// else
// return L"";
//
//}
NodeType SaxWin32XmlLite::nodeType() NodeType SaxWin32XmlLite::nodeType()
{ {
HRESULT hr; if (xml_.IsInit() == false) return typeNone;
XmlNodeType nodeType;
if FAILED(hr = xml_->GetNodeType(&nodeType)) XmlUtils::XmlNodeType nTempType = (XmlUtils::XmlNodeType)xmlTextReaderNodeType(xml_->getNativeReader());
{ return NodeTypeConvert(nTempType);
throw error(error::internalErr);
}
return NodeTypeConvert(nodeType);
} }
std::wstring SaxWin32XmlLite::value() std::wstring SaxWin32XmlLite::value()
{ {
HRESULT hr; if (xml_.IsInit() == false) return _T("");
UINT size = 0;
const wchar_t * val; return xml_->GetText3();
if FAILED(hr = xml_->GetValue(&val, &size))
{
throw error(error::internalErr);
}
if (size)
return std::wstring(&val[0], &val[size]);
else
return L"";
} }
...@@ -315,28 +255,23 @@ std::wstring SaxWin32XmlLite::value() ...@@ -315,28 +255,23 @@ std::wstring SaxWin32XmlLite::value()
// <element attribute="123"/> - true // <element attribute="123"/> - true
bool SaxWin32XmlLite::isEmptyElement() bool SaxWin32XmlLite::isEmptyElement()
{ {
return (xml_->IsEmptyElement() == TRUE); if (xml_.IsInit() == false) return false;
return (xml_->IsEmptyNode() == TRUE);
} }
bool SaxWin32XmlLite::isEof() bool SaxWin32XmlLite::isEof()
{ {
return (xml_->IsEOF() == TRUE); if (xml_.IsInit() == false) return true;
}
return false;
bool SaxWin32XmlLite::moveToAttrByName(const wchar_t * Name, const wchar_t * nsURI)
{
HRESULT hr;
if FAILED(hr = xml_->MoveToAttributeByName(Name, nsURI))
{
throw error(error::internalErr);
}
return (S_FALSE != hr);
} }
bool SaxWin32XmlLite::moveToAttrFirst() bool SaxWin32XmlLite::moveToAttrFirst()
{ {
HRESULT hr; if (xml_.IsInit() == false) return false;
HRESULT hr;
if FAILED(hr = xml_->MoveToFirstAttribute()) if FAILED(hr = xml_->MoveToFirstAttribute())
{ {
throw error(error::internalErr); throw error(error::internalErr);
...@@ -347,7 +282,9 @@ bool SaxWin32XmlLite::moveToAttrFirst() ...@@ -347,7 +282,9 @@ bool SaxWin32XmlLite::moveToAttrFirst()
bool SaxWin32XmlLite::moveToAttrNext() bool SaxWin32XmlLite::moveToAttrNext()
{ {
HRESULT hr; if (xml_.IsInit() == false) return false;
HRESULT hr;
if FAILED(hr = xml_->MoveToNextAttribute()) if FAILED(hr = xml_->MoveToNextAttribute())
{ {
throw error(error::internalErr); throw error(error::internalErr);
...@@ -358,6 +295,7 @@ bool SaxWin32XmlLite::moveToAttrNext() ...@@ -358,6 +295,7 @@ bool SaxWin32XmlLite::moveToAttrNext()
void SaxWin32XmlLite::moveToAttrOwner() void SaxWin32XmlLite::moveToAttrOwner()
{ {
if (xml_.IsInit() == false) return;
HRESULT hr; HRESULT hr;
if FAILED(hr = xml_->MoveToElement()) if FAILED(hr = xml_->MoveToElement())
{ {
...@@ -367,57 +305,42 @@ void SaxWin32XmlLite::moveToAttrOwner() ...@@ -367,57 +305,42 @@ void SaxWin32XmlLite::moveToAttrOwner()
bool SaxWin32XmlLite::attrDefault() bool SaxWin32XmlLite::attrDefault()
{ {
return (FALSE != xml_->IsDefault()); if (xml_.IsInit() == false) return false;
return (FALSE != xmlTextReaderIsDefault(xml_->getNativeReader()));
} }
NodeType SaxWin32XmlLite::next() NodeType SaxWin32XmlLite::next()
{ {
HRESULT hr; HRESULT hr;
XmlNodeType nodeType; NodeType nodeType;
if FAILED(hr = xml_->Read(&nodeType))
{ int nCurDepth = xml_->GetDepth();
return typeEOF; if (xml_->ReadNextSiblingNode(nCurDepth))
} {
if (S_FALSE == hr) XmlUtils::XmlNodeType nTempType = (XmlUtils::XmlNodeType)xmlTextReaderNodeType(xml_->getNativeReader());
return typeEOF; return NodeTypeConvert(nTempType);
else }
return NodeTypeConvert(nodeType); else
return typeNone;
} }
//unsigned int SaxWin32XmlLite::readChunk(wchar_t * const Buffer, unsigned int Size)
unsigned int SaxWin32XmlLite::lineNumber() //{
{ // if (xml_.IsInit() == false) return 0;
HRESULT hr; //
UINT val = 0; //
if FAILED(hr = xml_->GetLineNumber(&val)) // XmlUtils::XmlNodeType nTempType = (XmlUtils::XmlNodeType)xmlTextReaderNodeType(xml_->getNativeReader());
{ //
throw error(error::internalErr); // if FAILED(hr = xml_->ReadValueChunk(Buffer, Size, &readed))
} // {
return val; // throw error(error::internalErr);
} // }
// return readed;
unsigned int SaxWin32XmlLite::linePosition() //}
{ //
HRESULT hr; //
UINT val = 0;
if FAILED(hr = xml_->GetLinePosition(&val))
{
throw error(error::internalErr);
}
return val;
}
unsigned int SaxWin32XmlLite::readChunk(wchar_t * const Buffer, unsigned int Size)
{
UINT readed = 0;
HRESULT hr;
if FAILED(hr = xml_->ReadValueChunk(Buffer, Size, &readed))
{
throw error(error::internalErr);
}
return readed;
}
//////////////// ////////////////
sax_ptr create_sax_win32_xmllite(const wchar_t * FileName) sax_ptr create_sax_win32_xmllite(const wchar_t * FileName)
...@@ -425,15 +348,15 @@ sax_ptr create_sax_win32_xmllite(const wchar_t * FileName) ...@@ -425,15 +348,15 @@ sax_ptr create_sax_win32_xmllite(const wchar_t * FileName)
return sax_ptr( new SaxWin32XmlLite(FileName) ); return sax_ptr( new SaxWin32XmlLite(FileName) );
} }
sax_ptr create_sax_win32_xmllite( shared_ptr< std::istream >::Type istreamPtr) //sax_ptr create_sax_win32_xmllite( shared_ptr< std::istream >::Type istreamPtr)
{ //{
return sax_ptr( new SaxWin32XmlLite(istreamPtr) ); // return sax_ptr( new SaxWin32XmlLite(istreamPtr) );
} //}
//
sax_ptr create_sax_win32_xmllite( std::istream & istreamVal ) //sax_ptr create_sax_win32_xmllite( std::istream & istreamVal )
{ //{
return sax_ptr( new SaxWin32XmlLite(istreamVal) ); // return sax_ptr( new SaxWin32XmlLite(istreamVal) );
} //}
} }
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment