mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-13 23:55:50 +00:00
Compare commits
144 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d9a0181189 | ||
|
|
09570996a9 | ||
|
|
adc4c855ca | ||
|
|
8b1df06a94 | ||
|
|
7c81eec30c | ||
|
|
faa999d6d0 | ||
|
|
370bfb7a22 | ||
|
|
ae649ec917 | ||
|
|
93b44fcdc1 | ||
|
|
1fe57720c4 | ||
|
|
fca8fa1b1b | ||
|
|
81082ad10f | ||
|
|
2c515636cb | ||
|
|
2f7ac98e34 | ||
|
|
37b39ed1a1 | ||
|
|
73485d5a23 | ||
|
|
28c7827f14 | ||
|
|
e055dc1513 | ||
|
|
c173f14fc0 | ||
|
|
cd30e552a7 | ||
|
|
9bf1a76e91 | ||
|
|
2957b688fd | ||
|
|
add40d524f | ||
|
|
04a55e35b6 | ||
|
|
955ce45448 | ||
|
|
995e64a205 | ||
|
|
bf085f0ef3 | ||
|
|
1374b37882 | ||
|
|
e275f4eb9d | ||
|
|
652d809129 | ||
|
|
c186519bcf | ||
|
|
870fb4f291 | ||
|
|
7cd63489f4 | ||
|
|
616a53888e | ||
|
|
a336cc26f9 | ||
|
|
382088c456 | ||
|
|
ff80531db4 | ||
|
|
105cf3cd1e | ||
|
|
38ba7e695a | ||
|
|
996326a00e | ||
|
|
f2beb82b97 | ||
|
|
41c0702408 | ||
|
|
66b5f75142 | ||
|
|
c2a16ddbab | ||
|
|
5bb194cf89 | ||
|
|
645b9a01c7 | ||
|
|
3a1a5d12de | ||
|
|
12748e7539 | ||
|
|
2f69d4c8ee | ||
|
|
8dbf8b9038 | ||
|
|
fdfe047f3e | ||
|
|
38c3f84c9f | ||
|
|
9c5b071556 | ||
|
|
46dc52e449 | ||
|
|
f469e3853d | ||
|
|
a681a4fcd4 | ||
|
|
575b0bb7b0 | ||
|
|
588cf4bfca | ||
|
|
9cc8c341e7 | ||
|
|
9b657ba224 | ||
|
|
9bc6e83f8a | ||
|
|
572aae320d | ||
|
|
2906899811 | ||
|
|
1a6bf88900 | ||
|
|
e60b28980a | ||
|
|
a253b2ef4b | ||
|
|
0c2e35edc9 | ||
|
|
d0970397a6 | ||
|
|
0afbda0351 | ||
|
|
2009f8b1ca | ||
|
|
35715a0146 | ||
|
|
20e27ceb04 | ||
|
|
7fb614f7af | ||
|
|
83442825e5 | ||
|
|
123c482a69 | ||
|
|
3f091fce59 | ||
|
|
6c5f88aa25 | ||
|
|
23eccebf5b | ||
|
|
15112c1a27 | ||
|
|
d0ca81ff36 | ||
|
|
3e218c494d | ||
|
|
88bd5b12a4 | ||
|
|
5df5983f88 | ||
|
|
aa5ca7cea5 | ||
|
|
02483b2e0b | ||
|
|
f7817866ba | ||
|
|
d62287d54b | ||
|
|
aad074cd8e | ||
|
|
580d179dd0 | ||
|
|
616a514c4d | ||
|
|
bac8d41954 | ||
|
|
f295bb20a1 | ||
|
|
b5ffa2351a | ||
|
|
1b37b52071 | ||
|
|
b1ffd10079 | ||
|
|
39235f5b91 | ||
|
|
8825d94636 | ||
|
|
c8a7b2af56 | ||
|
|
d22b25c030 | ||
|
|
d475994e02 | ||
|
|
f0bb3dfdfb | ||
|
|
e7f0b8eca6 | ||
|
|
0bab6a9fec | ||
|
|
9486fc416c | ||
|
|
fb63aa737a | ||
|
|
58a6ca1d3d | ||
|
|
505f029edb | ||
|
|
815659b898 | ||
|
|
07d16f280c | ||
|
|
f88ddc947c | ||
|
|
65ffdff40c | ||
|
|
c95dccfec6 | ||
|
|
fe83f471f5 | ||
|
|
d2953f602e | ||
|
|
9d07ddeae1 | ||
|
|
ef7810bc95 | ||
|
|
486539b3d3 | ||
|
|
990fb20a2a | ||
|
|
9b61a83721 | ||
|
|
f753519976 | ||
|
|
663e38dcdd | ||
|
|
7570b6489d | ||
|
|
c341d1a71e | ||
|
|
fa10e90c9d | ||
|
|
68501763dd | ||
|
|
cac1d555be | ||
|
|
25ff77c2fd | ||
|
|
2870c7f457 | ||
|
|
ab8d7a86ae | ||
|
|
809359e81e | ||
|
|
6e4cd5bc9c | ||
|
|
de018bd582 | ||
|
|
544642a6ea | ||
|
|
06737bb36f | ||
|
|
7efbfa2d20 | ||
|
|
4d5df92cbc | ||
|
|
1fcb2872b9 | ||
|
|
00c87ca2dd | ||
|
|
d474d68566 | ||
|
|
93e03804d0 | ||
|
|
4591658160 | ||
|
|
a2109b4bda | ||
|
|
deafea9c88 | ||
|
|
93f1a05f5c |
44
.travis.yml
44
.travis.yml
@@ -1,10 +1,50 @@
|
||||
language: cpp
|
||||
compiler:
|
||||
- clang
|
||||
- gcc
|
||||
before_install:
|
||||
- sudo apt-get update -qq
|
||||
- sudo apt-get install -qq libboost1.48-all-dev protobuf-compiler libprotobuf-dev libssl-dev exuberant-ctags
|
||||
script: scons && npm install && npm test
|
||||
- sudo apt-get install -qq python-software-properties
|
||||
- sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
|
||||
- sudo add-apt-repository -y ppa:boost-latest/ppa
|
||||
- sudo apt-get update -qq
|
||||
- sudo apt-get install -qq g++-4.8
|
||||
- sudo apt-get install -qq libboost1.55-all-dev
|
||||
# We want debug symbols for boost as we install gdb later
|
||||
- sudo apt-get install -qq libboost1.55-dbg
|
||||
- sudo apt-get install -qq mlocate
|
||||
- sudo updatedb
|
||||
- sudo locate libboost | grep /lib | grep -e ".a$"
|
||||
- sudo apt-get install -qq protobuf-compiler libprotobuf-dev libssl-dev exuberant-ctags
|
||||
# We need gcc >= 4.8 for some c++11 features
|
||||
- sudo apt-get install -qq gcc-4.8
|
||||
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 40 --slave /usr/bin/g++ g++ /usr/bin/g++-4.8
|
||||
- sudo update-alternatives --set gcc /usr/bin/gcc-4.8
|
||||
# Stuff is gold. Nuff said ;)
|
||||
- sudo apt-get -y install binutils-gold
|
||||
# We can get a backtrace if the guy crashes
|
||||
- sudo apt-get -y install gdb
|
||||
# What versions are we ACTUALLY running?
|
||||
- g++ -v
|
||||
- clang -v
|
||||
|
||||
script:
|
||||
# Set so any failing command will abort the build
|
||||
- set -e
|
||||
# If only we could do -j12 ;)
|
||||
- scons
|
||||
# See what we've actually built
|
||||
- ldd ./build/rippled
|
||||
# Run unittests (under gdb)
|
||||
- | # create gdb script
|
||||
echo "set env MALLOC_CHECK_=3" > script.gdb
|
||||
echo "run" >> script.gdb
|
||||
echo "backtrace full" >> script.gdb
|
||||
# gdb --help
|
||||
- cat script.gdb | gdb --return-child-result --args ./build/rippled --unittest
|
||||
# Run integration tests
|
||||
- npm install
|
||||
- npm test
|
||||
notifications:
|
||||
email:
|
||||
false
|
||||
|
||||
@@ -69,8 +69,8 @@ SOURCES += \
|
||||
../../src/ripple/http/ripple_http.cpp \
|
||||
../../src/ripple/json/ripple_json.cpp \
|
||||
../../src/ripple/peerfinder/ripple_peerfinder.cpp \
|
||||
../../src/ripple/radmap/ripple_radmap.cpp \
|
||||
../../src/ripple/resource/ripple_resource.cpp \
|
||||
../../src/ripple/rpc/ripple_rpc.cpp \
|
||||
../../src/ripple/sitefiles/ripple_sitefiles.cpp \
|
||||
../../src/ripple/sslutil/ripple_sslutil.cpp \
|
||||
../../src/ripple/testoverlay/ripple_testoverlay.cpp \
|
||||
@@ -96,6 +96,8 @@ SOURCES += \
|
||||
../../src/ripple_hyperleveldb/ripple_hyperleveldb.cpp \
|
||||
../../src/ripple_leveldb/ripple_leveldb.cpp \
|
||||
../../src/ripple_net/ripple_net.cpp \
|
||||
../../src/ripple_overlay/ripple_overlay.cpp \
|
||||
../../src/ripple_rpc/ripple_rpc.cpp \
|
||||
../../src/ripple_websocket/ripple_websocket.cpp
|
||||
|
||||
LIBS += \
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ImportGroup Label="PropertySheets" />
|
||||
<PropertyGroup Label="UserMacros">
|
||||
<RepoDir>..\..</RepoDir>
|
||||
<SrcDir>$(RepoDir)\src\cpp\ripple</SrcDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<OutDir>$(RepoDir)\build\VisualStudio2010\$(Configuration).$(Platform)\</OutDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<IntDir>$(RepoDir)\build\obj\VisualStudio2010\$(Configuration).$(Platform)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>$(RepoDir);$(RepoDir)\src\cpp\leveldb;$(RepoDir)\src\cpp\leveldb\include;$(RepoDir)\src\cpp\protobuf\src;$(RepoDir)\src\cpp\protobuf\vsprojects;$(RepoDir)\build\proto;$(RepoDir)\Subtrees\beast;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>USE_LEVELDB;BOOST_TEST_ALTERNATIVE_INIT_API;BOOST_TEST_NO_MAIN;_WIN32_WINNT=0x0600;_SCL_SECURE_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<BuildMacro Include="RepoDir">
|
||||
<Value>$(RepoDir)</Value>
|
||||
</BuildMacro>
|
||||
<BuildMacro Include="SrcDir">
|
||||
<Value>$(SrcDir)</Value>
|
||||
</BuildMacro>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -1,20 +0,0 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 11.00
|
||||
# Visual Studio 2010
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "RippleD", "RippleD.vcxproj", "{EE95954F-3D34-4FB1-ADBD-FE8395233026}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
Release|Win32 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{EE95954F-3D34-4FB1-ADBD-FE8395233026}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{EE95954F-3D34-4FB1-ADBD-FE8395233026}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{EE95954F-3D34-4FB1-ADBD-FE8395233026}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{EE95954F-3D34-4FB1-ADBD-FE8395233026}.Release|Win32.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
@@ -1,98 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{EE95954F-3D34-4FB1-ADBD-FE8395233026}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>RippleD</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="RippleD.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<MinimalRebuild>false</MinimalRebuild>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<MinimalRebuild>false</MinimalRebuild>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt1.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt2.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt3.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt4.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_basics\ripple_basics.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_data\ripple_data.cpp" />
|
||||
<ClCompile Include="..\..\src\cpp\database\sqlite3.c" />
|
||||
<ClCompile Include="..\..\src\cpp\leveldb_core.cpp" />
|
||||
<ClCompile Include="..\..\src\cpp\protobuf_core.cpp" />
|
||||
<ClCompile Include="..\..\src\cpp\websocket_core.cpp" />
|
||||
<ClCompile Include="..\..\Subtrees\beast\modules\beast_basics\beast_basics.cpp" />
|
||||
<ClCompile Include="..\..\Subtrees\beast\modules\beast_core\beast_core.cpp" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
@@ -1,37 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt1.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt2.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt3.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_app\ripple_app_pt4.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_basics\ripple_basics.cpp" />
|
||||
<ClCompile Include="..\..\modules\ripple_data\ripple_data.cpp" />
|
||||
<ClCompile Include="..\..\Subtrees\beast\modules\beast_basics\beast_basics.cpp">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\Subtrees\beast\modules\beast_core\beast_core.cpp">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\cpp\leveldb_core.cpp">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\cpp\protobuf_core.cpp">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\cpp\websocket_core.cpp">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\cpp\database\sqlite3.c">
|
||||
<Filter>Subtrees</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Filter Include="Ripple">
|
||||
<UniqueIdentifier>{63db902e-0e7a-42d1-b5f5-663e4b48786c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Subtrees">
|
||||
<UniqueIdentifier>{469e8a0a-64bf-4fa1-8b6f-81207db68577}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -5,8 +5,8 @@
|
||||
<RepoDir>..\..</RepoDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<OutDir>$(RepoDir)\build\VisualStudio2012\$(Configuration).$(Platform)\</OutDir>
|
||||
<IntDir>$(RepoDir)\build\obj\VisualStudio2012\$(Configuration).$(Platform)\</IntDir>
|
||||
<OutDir>$(RepoDir)\build\VisualStudio2013\$(Configuration).$(Platform)\</OutDir>
|
||||
<IntDir>$(RepoDir)\build\obj\VisualStudio2013\$(Configuration).$(Platform)\</IntDir>
|
||||
<TargetName>rippled</TargetName>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup>
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
@@ -22,7 +22,25 @@
|
||||
<ClCompile Include="..\..\build\proto\ripple.pb.cc" />
|
||||
<ClCompile Include="..\..\src\ripple\beast\ripple_beast.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\beast\ripple_beastc.c" />
|
||||
<ClCompile Include="..\..\src\ripple\common\functional\impl\counted_bind.cpp">
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\counted_bind.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\KeyCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\ResolverAsio.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\TaggedCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
@@ -54,6 +72,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\http\ripple_http.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\json\impl\JsonPropertyStream.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\json\impl\json_reader.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -79,6 +103,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\json\ripple_json.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Bootcache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Checker.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -91,13 +121,19 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\ConnectHandouts.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Endpoint.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Cache.cpp">
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Livecache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
@@ -109,13 +145,25 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Resolver.cpp">
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\RedirectHandouts.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Slots.cpp">
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotHandouts.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotImp.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotImp.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
@@ -127,13 +175,20 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Tests.cpp">
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\ripple_peerfinder.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\sim\Tests.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\ripple_peerfinder.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\radmap\impl\BasicFullBelowCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\radmap\ripple_radmap.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\resource\impl\Charge.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -604,25 +659,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Handler.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Manager.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Service.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\ripple_rpc.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple\sitefiles\impl\Manager.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -680,12 +716,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\types\impl\JsonPropertyStream.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\types\impl\RandomNumbers.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -838,6 +868,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\DirectoryEntryIterator.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\Ledger.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -910,6 +946,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\OrderBookIterator.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\SerializedValidation.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1090,6 +1132,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\paths\PathRequests.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\paths\PathState.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1114,33 +1162,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\NameResolver.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PackedMessage.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PeerDoor.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\Peer.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\Peers.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PeerSet.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1400,12 +1421,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_basics\containers\TaggedCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_basics\log\Log.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1539,12 +1554,24 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Backend.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\BatchWriter.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Database.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\DecodedBlob.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1563,12 +1590,36 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Factory.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Manager.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\NodeObject.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Scheduler.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Task.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\NodeStore.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1690,6 +1741,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_data\protocol\STParsedJSON.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_data\protocol\TER.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1774,6 +1831,44 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\PackedMessage.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\PeerDoor.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\Peers.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\ripple_overlay.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\DoPrint.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\ErrorCodes.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\Manager.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\ripple_rpc.cpp" />
|
||||
<ClCompile Include="..\..\src\ripple_websocket\autosocket\AutoSocket.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -2134,8 +2229,12 @@
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\src\ripple\algorithm\api\CycledSet.h" />
|
||||
<ClInclude Include="..\..\src\ripple\algorithm\api\DecayingSample.h" />
|
||||
<ClInclude Include="..\..\src\ripple\algorithm\api\DiscreteClock.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\functional\counted_bind.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\counted_bind.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\KeyCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\Resolver.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\ResolverAsio.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\seconds_clock.h" />
|
||||
<ClInclude Include="..\..\src\ripple\common\TaggedCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\http\api\Handler.h" />
|
||||
<ClInclude Include="..\..\src\ripple\http\api\Server.h" />
|
||||
<ClInclude Include="..\..\src\ripple\http\api\Port.h" />
|
||||
@@ -2146,6 +2245,7 @@
|
||||
<ClInclude Include="..\..\src\ripple\http\impl\ServerImpl.h" />
|
||||
<ClInclude Include="..\..\src\ripple\http\impl\Types.h" />
|
||||
<ClInclude Include="..\..\src\ripple\http\ripple_http.h" />
|
||||
<ClInclude Include="..\..\src\ripple\json\api\JsonPropertyStream.h" />
|
||||
<ClInclude Include="..\..\src\ripple\json\api\json_config.h" />
|
||||
<ClInclude Include="..\..\src\ripple\json\api\json_features.h" />
|
||||
<ClInclude Include="..\..\src\ripple\json\api\json_forwards.h" />
|
||||
@@ -2159,26 +2259,39 @@
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Config.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Endpoint.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Manager.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Slot.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Types.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\CachedEndpoint.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Bootcache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Checker.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\CheckerAdapter.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Cache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Giveaways.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\GiveawaysAtHop.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LegacyEndpoint.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LegacyEndpointCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\ConnectHandouts.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Fixed.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\handout.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\iosformat.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Livecache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Logic.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LogicType.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\PeerInfo.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Resolver.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Slots.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\PrivateTypes.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\RedirectHandouts.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Reporting.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Counts.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\SlotHandouts.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Source.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\SourceStrings.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Store.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\StoreSqdb.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Tuning.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\ripple_peerfinder.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\FunctionQueue.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\GraphAlgorithms.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Message.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\NodeSnapshot.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Params.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Predicates.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\sync_timer.h" />
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\WrappedSink.h" />
|
||||
<ClInclude Include="..\..\src\ripple\radmap\api\BasicFullBelowCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple\radmap\api\Tuning.h" />
|
||||
<ClInclude Include="..\..\src\ripple\radmap\ripple_radmap.h" />
|
||||
<ClInclude Include="..\..\src\ripple\resource\api\Charge.h" />
|
||||
<ClInclude Include="..\..\src\ripple\resource\api\Consumer.h" />
|
||||
<ClInclude Include="..\..\src\ripple\resource\api\Disposition.h" />
|
||||
@@ -2284,11 +2397,6 @@
|
||||
<ClInclude Include="..\..\src\ripple\rocksdb\rocksdb\util\string_util.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rocksdb\rocksdb\util\testharness.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rocksdb\rocksdb\util\testutil.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Handler.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Manager.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Service.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rpc\impl\ManagerImpl.h" />
|
||||
<ClInclude Include="..\..\src\ripple\rpc\ripple_rpc.h" />
|
||||
<ClInclude Include="..\..\src\ripple\sitefiles\api\Listener.h" />
|
||||
<ClInclude Include="..\..\src\ripple\sitefiles\api\Manager.h" />
|
||||
<ClInclude Include="..\..\src\ripple\sitefiles\api\Section.h" />
|
||||
@@ -2321,7 +2429,6 @@
|
||||
<ClInclude Include="..\..\src\ripple\types\api\IdentifierStorage.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\IdentifierType.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\HashMaps.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\JsonPropertyStream.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\RandomNumbers.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\RippleAccountID.h" />
|
||||
<ClInclude Include="..\..\src\ripple\types\api\RippleAccountPrivateKey.h" />
|
||||
@@ -2365,6 +2472,7 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\data\DatabaseCon.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\data\DBInit.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\data\SqliteDatabase.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\DirectoryEntryIterator.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\Ledger.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\LedgerCleaner.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\LedgerMaster.h" />
|
||||
@@ -2378,8 +2486,10 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\InboundLedgers.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\LedgerEntrySet.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\LedgerHistory.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\OrderBookIterator.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\SerializedValidation.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\CollectorManager.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\FullBelowCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\IoServicePool.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\NodeStoreScheduler.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\ParameterTable.h" />
|
||||
@@ -2389,6 +2499,7 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\main\LocalCredentials.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\RippleMain.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\RPCHTTPServer.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\main\Tuning.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\misc\NetworkOPs.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\misc\PowResult.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\misc\AccountItem.h" />
|
||||
@@ -2409,16 +2520,12 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\node\SqliteFactory.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\Pathfinder.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\PathRequest.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\PathRequests.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\PathState.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\RippleCalc.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\RippleLineCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\RippleState.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\NameResolver.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PackedMessage.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PeerDoor.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\ClusterNodeStatus.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\Peers.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\Peer.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PeerSet.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\UniqueNodeList.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\ripple_app.h" />
|
||||
@@ -2452,9 +2559,8 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\websocket\WSConnection.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\websocket\WSDoor.h" />
|
||||
<ClInclude Include="..\..\src\ripple_app\websocket\WSServerHandler.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\KeyCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\RangeSet.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\TaggedCache.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\SyncUnorderedMap.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\log\Log.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\log\LogFile.h" />
|
||||
<ClInclude Include="..\..\src\ripple_basics\log\LoggedTimings.h" />
|
||||
@@ -2484,6 +2590,7 @@
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Database.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\DummyScheduler.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Factory.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Manager.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\NodeObject.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Scheduler.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Task.h" />
|
||||
@@ -2498,7 +2605,7 @@
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\DatabaseImp.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\DecodedBlob.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\EncodedBlob.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\Factories.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\Tuning.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\NodeStore.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\tests\TestBase.h" />
|
||||
<ClInclude Include="..\..\src\ripple_core\ripple_core.h" />
|
||||
@@ -2518,6 +2625,7 @@
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\SerializedObjectTemplate.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\SerializedTypes.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\Serializer.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\STParsedJSON.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\TER.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\TxFlags.h" />
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\TxFormats.h" />
|
||||
@@ -2540,6 +2648,17 @@
|
||||
<ClInclude Include="..\..\src\ripple_net\rpc\RPCErr.h" />
|
||||
<ClInclude Include="..\..\src\ripple_net\rpc\RPCSub.h" />
|
||||
<ClInclude Include="..\..\src\ripple_net\rpc\RPCUtil.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\PackedMessage.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\Peer.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\Peers.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\impl\PeerDoor.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\impl\PeerImp.h" />
|
||||
<ClInclude Include="..\..\src\ripple_overlay\ripple_overlay.h" />
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\ErrorCodes.h" />
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\Manager.h" />
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\Request.h" />
|
||||
<ClInclude Include="..\..\src\ripple_rpc\impl\Command.h" />
|
||||
<ClInclude Include="..\..\src\ripple_rpc\ripple_rpc.h" />
|
||||
<ClInclude Include="..\..\src\ripple_websocket\autosocket\AutoSocket.h" />
|
||||
<ClInclude Include="..\..\src\ripple_websocket\ripple_websocket.h" />
|
||||
<ClInclude Include="..\..\src\BeastConfig.h" />
|
||||
@@ -2652,10 +2771,10 @@
|
||||
<None Include="..\..\src\ripple\json\TODO.md" />
|
||||
<None Include="..\..\src\ripple\peerfinder\README.md" />
|
||||
<None Include="..\..\src\ripple\peerfinder\TODO.md" />
|
||||
<None Include="..\..\src\ripple\radmap\README.md" />
|
||||
<None Include="..\..\src\ripple\radmap\TODO.md" />
|
||||
<None Include="..\..\src\ripple\resource\README.md" />
|
||||
<None Include="..\..\src\ripple\resource\TODO.md" />
|
||||
<None Include="..\..\src\ripple\rpc\README.md" />
|
||||
<None Include="..\..\src\ripple\rpc\TODO.md" />
|
||||
<None Include="..\..\src\ripple\sitefiles\README.md" />
|
||||
<None Include="..\..\src\ripple\sitefiles\TODO.md" />
|
||||
<None Include="..\..\src\ripple\sslutil\README.md" />
|
||||
@@ -2668,6 +2787,10 @@
|
||||
<None Include="..\..\src\ripple\validators\README.md" />
|
||||
<None Include="..\..\src\ripple_app\ledger\TODO.md" />
|
||||
<None Include="..\..\src\ripple_app\TODO.md" />
|
||||
<None Include="..\..\src\ripple_overlay\README.md" />
|
||||
<None Include="..\..\src\ripple_overlay\TODO.md" />
|
||||
<None Include="..\..\src\ripple_rpc\README.md" />
|
||||
<None Include="..\..\src\ripple_rpc\TODO.md" />
|
||||
<None Include="..\QtCreator\rippled.pro" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@@ -2678,31 +2801,32 @@
|
||||
<ProjectGuid>{B7F39ECD-473C-484D-BC34-31F8362506A5}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>RippleD</RootNamespace>
|
||||
<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>Intel C++ Compiler XE 13.0</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>Intel C++ Compiler XE 13.0</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
</PropertyGroup>
|
||||
@@ -187,12 +187,6 @@
|
||||
<Filter Include="[2] Old Ripple\ripple_core\nodestore\tests">
|
||||
<UniqueIdentifier>{071582fa-cf16-4e41-8791-613cfe00eef8}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\rpc">
|
||||
<UniqueIdentifier>{7abb5fcf-8793-45d0-95db-0cf448198765}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\rpc\api">
|
||||
<UniqueIdentifier>{005e1f40-38ac-4904-af7c-4a018c5662f4}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\http">
|
||||
<UniqueIdentifier>{98e572a2-c89a-4ab7-b1d5-7687786e48dd}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -202,9 +196,6 @@
|
||||
<Filter Include="[1] Ripple\http\impl">
|
||||
<UniqueIdentifier>{386ebc1c-0cbe-43a6-b48e-ac3c503da0ee}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\rpc\impl">
|
||||
<UniqueIdentifier>{95c93134-7e8d-47ec-9649-4a8d5d97ce12}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\types">
|
||||
<UniqueIdentifier>{a3a2d1ec-d731-42df-9397-40a561c6809a}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -292,20 +283,44 @@
|
||||
<Filter Include="[1] Ripple\common">
|
||||
<UniqueIdentifier>{b99052d6-a903-4dfd-9c68-ff767a7d8f63}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\common\functional">
|
||||
<UniqueIdentifier>{70365f6a-d1e6-45f2-a064-0e842b0fdd78}</UniqueIdentifier>
|
||||
<Filter Include="[1] Ripple\common\impl">
|
||||
<UniqueIdentifier>{6f3085f6-dbe3-4622-a680-682787d0708c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\common\functional\impl">
|
||||
<UniqueIdentifier>{9b8137bd-737d-4825-98bf-897a0635293a}</UniqueIdentifier>
|
||||
<Filter Include="[1] Ripple\radmap">
|
||||
<UniqueIdentifier>{1b34e7e8-8260-488c-8d09-bdd3b474f9e3}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\radmap\api">
|
||||
<UniqueIdentifier>{19de3695-4341-49db-9da2-b220bc9e0149}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\radmap\impl">
|
||||
<UniqueIdentifier>{67371f65-f9be-45b1-81e8-c83ef3336e5c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[1] Ripple\peerfinder\sim">
|
||||
<UniqueIdentifier>{c429638b-4572-44e4-a48a-c18fdd094ae1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_rpc">
|
||||
<UniqueIdentifier>{21125570-1733-47a2-8f20-1d4c1f2bf2d1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_rpc\api">
|
||||
<UniqueIdentifier>{acdb25ae-4985-483b-ad85-94e06aec7eab}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_rpc\impl">
|
||||
<UniqueIdentifier>{b86f01de-f924-4584-bb22-d70280b224f3}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_overlay">
|
||||
<UniqueIdentifier>{75191c6f-e636-4314-8bee-0d6f40051390}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_overlay\api">
|
||||
<UniqueIdentifier>{92b0fcc6-acfc-4ede-90e1-8f39e87dee4c}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="[2] Old Ripple\ripple_overlay\impl">
|
||||
<UniqueIdentifier>{0ff855ac-5038-4b16-a324-ba85d782c0e2}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\src\ripple_basics\containers\RangeSet.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_basics\containers\TaggedCache.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_basics\utility\CountedObject.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_basics\utility</Filter>
|
||||
</ClCompile>
|
||||
@@ -696,21 +711,9 @@
|
||||
<ClCompile Include="..\..\src\ripple_app\paths\RippleState.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\paths</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\Peer.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\Peers.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PeerSet.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\UniqueNodeList.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PeerDoor.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\rpc\RPCHandler.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\rpc</Filter>
|
||||
</ClCompile>
|
||||
@@ -1026,9 +1029,6 @@
|
||||
<ClCompile Include="..\..\src\ripple_app\main\RPCHTTPServer.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\ripple_rpc.cpp">
|
||||
<Filter>[1] Ripple\rpc</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\http\ripple_http.cpp">
|
||||
<Filter>[1] Ripple\http</Filter>
|
||||
</ClCompile>
|
||||
@@ -1041,15 +1041,6 @@
|
||||
<ClCompile Include="..\..\src\ripple\http\impl\ScopedStream.cpp">
|
||||
<Filter>[1] Ripple\http\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Handler.cpp">
|
||||
<Filter>[1] Ripple\rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Service.cpp">
|
||||
<Filter>[1] Ripple\rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\rpc\impl\Manager.cpp">
|
||||
<Filter>[1] Ripple\rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\http\impl\ServerImpl.cpp">
|
||||
<Filter>[1] Ripple\http\impl</Filter>
|
||||
</ClCompile>
|
||||
@@ -1089,9 +1080,6 @@
|
||||
<ClCompile Include="..\..\src\ripple\sslutil\impl\DHUtil.cpp">
|
||||
<Filter>[1] Ripple\sslutil\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PackedMessage.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\types\impl\RippleIdentifierTests.cpp">
|
||||
<Filter>[1] Ripple\types\impl</Filter>
|
||||
</ClCompile>
|
||||
@@ -1104,36 +1092,12 @@
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\ripple_peerfinder.cpp">
|
||||
<Filter>[1] Ripple\peerfinder</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Endpoint.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Config.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Manager.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Tests.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Slots.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SourceStrings.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\json\impl\Tests.cpp">
|
||||
<Filter>[1] Ripple\json\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Checker.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Cache.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\types\impl\JsonPropertyStream.cpp">
|
||||
<Filter>[1] Ripple\types\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\resource\ripple_resource.cpp">
|
||||
<Filter>[1] Ripple\resource</Filter>
|
||||
</ClCompile>
|
||||
@@ -1155,9 +1119,6 @@
|
||||
<ClCompile Include="..\..\src\ripple\resource\impl\LegacyFees.cpp">
|
||||
<Filter>[1] Ripple\resource\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Resolver.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\sitefiles\ripple_sitefiles.cpp">
|
||||
<Filter>[1] Ripple\sitefiles</Filter>
|
||||
</ClCompile>
|
||||
@@ -1395,9 +1356,6 @@
|
||||
<ClCompile Include="..\..\src\ripple_app\main\CollectorManager.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\NameResolver.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\shamap\FetchPackTests.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\shamap</Filter>
|
||||
</ClCompile>
|
||||
@@ -1410,23 +1368,131 @@
|
||||
<ClCompile Include="..\..\src\ripple\common\ripple_common.cpp">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\functional\impl\counted_bind.cpp">
|
||||
<Filter>[1] Ripple\common\functional\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\backend\RocksDBFactory.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\backend</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Backend.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Factory.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Scheduler.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Task.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Database.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_core\nodestore\impl\Manager.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\peers\PeerSet.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_data\protocol\STParsedJSON.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_data\protocol</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\paths\PathRequests.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\paths</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\OrderBookIterator.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_app\ledger\DirectoryEntryIterator.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\radmap\ripple_radmap.cpp">
|
||||
<Filter>[1] Ripple\radmap</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\radmap\impl\BasicFullBelowCache.cpp">
|
||||
<Filter>[1] Ripple\radmap\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\counted_bind.cpp">
|
||||
<Filter>[1] Ripple\common\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\KeyCache.cpp">
|
||||
<Filter>[1] Ripple\common\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\TaggedCache.cpp">
|
||||
<Filter>[1] Ripple\common\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\common\impl\ResolverAsio.cpp">
|
||||
<Filter>[1] Ripple\common\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Checker.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Config.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Endpoint.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Livecache.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Manager.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SourceStrings.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\sim\Tests.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\ripple_rpc.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_rpc</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\ErrorCodes.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\Manager.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_rpc\impl\DoPrint.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\json\impl\JsonPropertyStream.cpp">
|
||||
<Filter>[1] Ripple\json\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotImp.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\PeerDoor.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\Peers.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\impl\PackedMessage.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple_overlay\ripple_overlay.cpp">
|
||||
<Filter>[2] Old Ripple\ripple_overlay</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\Bootcache.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\ConnectHandouts.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\RedirectHandouts.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotHandouts.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\ripple\peerfinder\impl\SlotImp.cpp">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\KeyCache.h">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\RangeSet.h">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\TaggedCache.h">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_basics\system\BoostIncludes.h">
|
||||
<Filter>[2] Old Ripple\ripple_basics\system</Filter>
|
||||
</ClInclude>
|
||||
@@ -1868,15 +1934,6 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\RippleState.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\paths</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PeerDoor.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\Peer.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PeerSet.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\UniqueNodeList.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
@@ -1970,9 +2027,6 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\websocket\WSServerHandler.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\websocket</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\Peers.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\main\LoadManager.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClInclude>
|
||||
@@ -2259,9 +2313,6 @@
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Factory.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\Factories.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\VisitCallback.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\api</Filter>
|
||||
</ClInclude>
|
||||
@@ -2280,9 +2331,6 @@
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\tests\TestBase.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\tests</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\DatabaseImp.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Task.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\api</Filter>
|
||||
</ClInclude>
|
||||
@@ -2295,9 +2343,6 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\main\RPCHTTPServer.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\rpc\ripple_rpc.h">
|
||||
<Filter>[1] Ripple\rpc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\http\ripple_http.h">
|
||||
<Filter>[1] Ripple\http</Filter>
|
||||
</ClInclude>
|
||||
@@ -2328,18 +2373,6 @@
|
||||
<ClInclude Include="..\..\src\ripple\http\impl\Door.h">
|
||||
<Filter>[1] Ripple\http\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Handler.h">
|
||||
<Filter>[1] Ripple\rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Manager.h">
|
||||
<Filter>[1] Ripple\rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\rpc\api\Service.h">
|
||||
<Filter>[1] Ripple\rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\rpc\impl\ManagerImpl.h">
|
||||
<Filter>[1] Ripple\rpc\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\types\ripple_types.h">
|
||||
<Filter>[1] Ripple\types</Filter>
|
||||
</ClInclude>
|
||||
@@ -2391,9 +2424,6 @@
|
||||
<ClInclude Include="..\..\src\ripple\sslutil\api\DHUtil.h">
|
||||
<Filter>[1] Ripple\sslutil\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PackedMessage.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\types\api\RipplePublicKey.h">
|
||||
<Filter>[1] Ripple\types\api</Filter>
|
||||
</ClInclude>
|
||||
@@ -2439,42 +2469,6 @@
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\ripple_peerfinder.h">
|
||||
<Filter>[1] Ripple\peerfinder</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Types.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Endpoint.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Config.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Callback.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Logic.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Store.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\StoreSqdb.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Slots.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\PeerInfo.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Source.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\SourceStrings.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Manager.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\validators\impl\Validator.h">
|
||||
<Filter>[1] Ripple\validators\impl</Filter>
|
||||
</ClInclude>
|
||||
@@ -2493,24 +2487,9 @@
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Tuning.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LegacyEndpoint.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LegacyEndpointCache.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\CheckerAdapter.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Cache.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\CachedEndpoint.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\types\api\JsonPropertyStream.h">
|
||||
<Filter>[1] Ripple\types\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\resource\ripple_resource.h">
|
||||
<Filter>[1] Ripple\resource</Filter>
|
||||
</ClInclude>
|
||||
@@ -2556,24 +2535,9 @@
|
||||
<ClInclude Include="..\..\src\ripple\resource\api\LegacyFees.h">
|
||||
<Filter>[1] Ripple\resource\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\LogicType.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Resolver.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Giveaways.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\GiveawaysAtHop.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\algorithm\api\CycledSet.h">
|
||||
<Filter>[1] Ripple\algorithm\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\algorithm\api\DiscreteClock.h">
|
||||
<Filter>[1] Ripple\algorithm\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\sitefiles\ripple_sitefiles.h">
|
||||
<Filter>[1] Ripple\sitefiles</Filter>
|
||||
</ClInclude>
|
||||
@@ -2877,21 +2841,216 @@
|
||||
<ClInclude Include="..\..\src\ripple_app\main\CollectorManager.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\NameResolver.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\shamap\RadixMapTest.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\shamap</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\types\api\RippleAssets.h">
|
||||
<Filter>[1] Ripple\types\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\functional\counted_bind.h">
|
||||
<Filter>[1] Ripple\common\functional</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\backend\RocksDBFactory.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\backend</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\api\Manager.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\DatabaseImp.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_core\nodestore\impl\Tuning.h">
|
||||
<Filter>[2] Old Ripple\ripple_core\nodestore\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\DirectoryEntryIterator.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\OrderBookIterator.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\DirectoryEntryIterator.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\ledger\OrderBookIterator.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\peers\PeerSet.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\peers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_data\protocol\STParsedJSON.h">
|
||||
<Filter>[2] Old Ripple\ripple_data\protocol</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\paths\PathRequests.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\paths</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_basics\containers\SyncUnorderedMap.h">
|
||||
<Filter>[2] Old Ripple\ripple_basics\containers</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\radmap\ripple_radmap.h">
|
||||
<Filter>[1] Ripple\radmap</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\radmap\api\BasicFullBelowCache.h">
|
||||
<Filter>[1] Ripple\radmap\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\radmap\api\Tuning.h">
|
||||
<Filter>[1] Ripple\radmap\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\counted_bind.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\KeyCache.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\seconds_clock.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\TaggedCache.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\main\FullBelowCache.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_app\main\Tuning.h">
|
||||
<Filter>[2] Old Ripple\ripple_app\main</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\Resolver.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\common\ResolverAsio.h">
|
||||
<Filter>[1] Ripple\common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Bootcache.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Checker.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\CheckerAdapter.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\iosformat.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Livecache.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Logic.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\PrivateTypes.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Reporting.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Source.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\SourceStrings.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Store.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Tuning.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Callback.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Config.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Endpoint.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Manager.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Types.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\FunctionQueue.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\GraphAlgorithms.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Message.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\NodeSnapshot.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Params.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\Predicates.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\sync_timer.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\sim\WrappedSink.h">
|
||||
<Filter>[1] Ripple\peerfinder\sim</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_rpc\ripple_rpc.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\ErrorCodes.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\Manager.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_rpc\api\Request.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_rpc\impl\Command.h">
|
||||
<Filter>[2] Old Ripple\ripple_rpc\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\json\api\JsonPropertyStream.h">
|
||||
<Filter>[1] Ripple\json\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\api\Slot.h">
|
||||
<Filter>[1] Ripple\peerfinder\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Counts.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\Fixed.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\impl\PeerDoor.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\impl\PeerImp.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\Peer.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\Peers.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\api\PackedMessage.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay\api</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple_overlay\ripple_overlay.h">
|
||||
<Filter>[2] Old Ripple\ripple_overlay</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\handout.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\SlotHandouts.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\RedirectHandouts.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\ConnectHandouts.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\ripple\peerfinder\impl\StoreSqdb.h">
|
||||
<Filter>[1] Ripple\peerfinder\impl</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<CustomBuild Include="..\..\src\ripple_data\protocol\ripple.proto">
|
||||
@@ -2980,12 +3139,6 @@
|
||||
<None Include="..\..\src\ripple\json\TODO.md">
|
||||
<Filter>[1] Ripple\json</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple\rpc\README.md">
|
||||
<Filter>[1] Ripple\rpc</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple\rpc\TODO.md">
|
||||
<Filter>[1] Ripple\rpc</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple\sitefiles\README.md">
|
||||
<Filter>[1] Ripple\sitefiles</Filter>
|
||||
</None>
|
||||
@@ -3007,6 +3160,24 @@
|
||||
<None Include="..\..\src\ripple_app\ledger\TODO.md">
|
||||
<Filter>[2] Old Ripple\ripple_app\ledger</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple\radmap\README.md">
|
||||
<Filter>[1] Ripple\radmap</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple\radmap\TODO.md">
|
||||
<Filter>[1] Ripple\radmap</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple_rpc\README.md">
|
||||
<Filter>[2] Old Ripple\ripple_rpc</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple_rpc\TODO.md">
|
||||
<Filter>[2] Old Ripple\ripple_rpc</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple_overlay\README.md">
|
||||
<Filter>[2] Old Ripple\ripple_overlay</Filter>
|
||||
</None>
|
||||
<None Include="..\..\src\ripple_overlay\TODO.md">
|
||||
<Filter>[2] Old Ripple\ripple_overlay</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Text Include="..\..\doc\todo\NIKB_TODO.txt">
|
||||
@@ -1,9 +1,11 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 2012
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "RippleD", "RippleD.vcxproj", "{B7F39ECD-473C-484D-BC34-31F8362506A5}"
|
||||
# Visual Studio 2013
|
||||
VisualStudioVersion = 12.0.30110.0
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "beast", "..\..\src\beast\Builds\VisualStudio2013\beast.vcxproj", "{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "beast", "..\..\src\beast\Builds\VisualStudio2012\beast.vcxproj", "{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}"
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "RippleD", "RippleD.vcxproj", "{B7F39ECD-473C-484D-BC34-31F8362506A5}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
@@ -13,14 +15,6 @@ Global
|
||||
Release|x64 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|x64.Build.0 = Debug|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|Win32.Build.0 = Release|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|x64.ActiveCfg = Release|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|x64.Build.0 = Release|x64
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Debug|x64.ActiveCfg = Debug|x64
|
||||
@@ -29,6 +23,14 @@ Global
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Release|Win32.Build.0 = Release|Win32
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Release|x64.ActiveCfg = Release|x64
|
||||
{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}.Release|x64.Build.0 = Release|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Debug|x64.Build.0 = Debug|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|Win32.Build.0 = Release|Win32
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|x64.ActiveCfg = Release|x64
|
||||
{B7F39ECD-473C-484D-BC34-31F8362506A5}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
@@ -1,5 +1,6 @@
|
||||
#Ripple - P2P Payment Network
|
||||
|
||||
##[](https://travis-ci.org/ripple/rippled)
|
||||
##[](https://ci.ripple.com/jenkins/job/rippled/)
|
||||
|
||||
This is the repository for Ripple's `rippled`, reference P2P network server.
|
||||
|
||||
82
SConstruct
82
SConstruct
@@ -8,6 +8,7 @@ import glob
|
||||
import os
|
||||
import platform
|
||||
import re
|
||||
import sys
|
||||
|
||||
OSX = bool(platform.mac_ver()[0])
|
||||
FreeBSD = bool('FreeBSD' == platform.system())
|
||||
@@ -16,10 +17,12 @@ Ubuntu = bool(Linux and 'Ubuntu' == platform.linux_distribution()[0])
|
||||
Debian = bool(Linux and 'debian' == platform.linux_distribution()[0])
|
||||
Archlinux = bool(Linux and ('','','') == platform.linux_distribution()) #Arch still has issues with the platform module
|
||||
|
||||
USING_CLANG = OSX or os.environ.get('CC', None) == 'clang'
|
||||
|
||||
#
|
||||
# We expect this to be set
|
||||
#
|
||||
BOOST_HOME = os.environ.get("RIPPLED_BOOST_HOME", None)
|
||||
#
|
||||
BOOST_HOME = os.environ.get("RIPPLED_BOOST_HOME", None)
|
||||
|
||||
|
||||
if OSX or Ubuntu or Debian or Archlinux:
|
||||
@@ -33,8 +36,12 @@ else:
|
||||
# scons tools
|
||||
#
|
||||
|
||||
HONOR_ENVS = ['CC', 'CXX', 'PATH']
|
||||
|
||||
env = Environment(
|
||||
tools = ['default', 'protoc']
|
||||
tools = ['default', 'protoc'],
|
||||
#ENV = dict((k, os.environ[k]) for k in HONOR_ENVS)
|
||||
ENV = dict((k, os.environ[k]) for k in HONOR_ENVS if k in os.environ)
|
||||
)
|
||||
|
||||
# Use a newer gcc on FreeBSD
|
||||
@@ -44,12 +51,18 @@ if FreeBSD:
|
||||
env.Append(CCFLAGS = ['-Wl,-rpath=/usr/local/lib/gcc46'])
|
||||
env.Append(LINKFLAGS = ['-Wl,-rpath=/usr/local/lib/gcc46'])
|
||||
|
||||
if OSX:
|
||||
if USING_CLANG:
|
||||
env.Replace(CC= 'clang')
|
||||
env.Replace(CXX= 'clang++')
|
||||
env.Append(CXXFLAGS = ['-std=c++11', '-stdlib=libc++'])
|
||||
env.Append(LINKFLAGS='-stdlib=libc++')
|
||||
env['FRAMEWORKS'] = ['AppKit','Foundation']
|
||||
|
||||
if Linux:
|
||||
env.Append(CXXFLAGS = ['-std=c++11', '-stdlib=libstdc++'])
|
||||
env.Append(LINKFLAGS='-stdlib=libstdc++')
|
||||
|
||||
if OSX:
|
||||
env.Append(CXXFLAGS = ['-std=c++11', '-stdlib=libc++'])
|
||||
env.Append(LINKFLAGS='-stdlib=libc++')
|
||||
env['FRAMEWORKS'] = ['AppKit','Foundation']
|
||||
|
||||
GCC_VERSION = re.split('\.', commands.getoutput(env['CXX'] + ' -dumpversion'))
|
||||
|
||||
@@ -98,12 +111,23 @@ BOOST_LIBS = [
|
||||
# We whitelist platforms where the non -mt version is linked with pthreads. This
|
||||
# can be verified with: ldd libboost_filesystem.* If a threading library is
|
||||
# included the platform can be whitelisted.
|
||||
if FreeBSD or Ubuntu or Archlinux:
|
||||
# if FreeBSD or Ubuntu or Archlinux or OSX:
|
||||
# if FreeBSD or Ubuntu or Archlinux:
|
||||
|
||||
if not (USING_CLANG and Linux) and (FreeBSD or Ubuntu or Archlinux or OSX):
|
||||
# non-mt libs do link with pthreads.
|
||||
env.Append(
|
||||
LIBS = BOOST_LIBS
|
||||
)
|
||||
elif Linux and USING_CLANG and Ubuntu:
|
||||
# It's likely going to be here if using boost 1.55
|
||||
boost_statics = [ ("/usr/lib/x86_64-linux-gnu/lib%s.a" % a) for a in
|
||||
BOOST_LIBS ]
|
||||
|
||||
if not all(os.path.exists(f) for f in boost_statics):
|
||||
# Else here
|
||||
boost_statics = [("/usr/lib/lib%s.a" % a) for a in BOOST_LIBS]
|
||||
|
||||
env.Append(LIBS = [File(f) for f in boost_statics])
|
||||
else:
|
||||
env.Append(
|
||||
LIBS = [l + '-mt' for l in BOOST_LIBS]
|
||||
@@ -156,18 +180,18 @@ COMPILED_FILES.extend (['src/ripple/beast/ripple_beastc.c'])
|
||||
# New-style Ripple unity sources
|
||||
#
|
||||
COMPILED_FILES.extend([
|
||||
'src/ripple/common/ripple_common.cpp',
|
||||
'src/ripple/http/ripple_http.cpp',
|
||||
'src/ripple/json/ripple_json.cpp',
|
||||
'src/ripple/peerfinder/ripple_peerfinder.cpp',
|
||||
'src/ripple/radmap/ripple_radmap.cpp',
|
||||
'src/ripple/resource/ripple_resource.cpp',
|
||||
'src/ripple/rocksdb/ripple_rocksdb.cpp',
|
||||
'src/ripple/rpc/ripple_rpc.cpp',
|
||||
'src/ripple/sitefiles/ripple_sitefiles.cpp',
|
||||
'src/ripple/sslutil/ripple_sslutil.cpp',
|
||||
'src/ripple/testoverlay/ripple_testoverlay.cpp',
|
||||
'src/ripple/types/ripple_types.cpp',
|
||||
'src/ripple/validators/ripple_validators.cpp'
|
||||
'src/ripple/validators/ripple_validators.cpp',
|
||||
'src/ripple/common/ripple_common.cpp',
|
||||
])
|
||||
|
||||
# ------------------------------
|
||||
@@ -189,6 +213,8 @@ COMPILED_FILES.extend([
|
||||
'src/ripple_hyperleveldb/ripple_hyperleveldb.cpp',
|
||||
'src/ripple_leveldb/ripple_leveldb.cpp',
|
||||
'src/ripple_net/ripple_net.cpp',
|
||||
'src/ripple_overlay/ripple_overlay.cpp',
|
||||
'src/ripple_rpc/ripple_rpc.cpp',
|
||||
'src/ripple_websocket/ripple_websocket.cpp'
|
||||
])
|
||||
|
||||
@@ -227,7 +253,7 @@ env.Append(
|
||||
['rt'] if not OSX else [] +\
|
||||
[
|
||||
'z'
|
||||
]
|
||||
]
|
||||
)
|
||||
|
||||
# We prepend, in case there's another BOOST somewhere on the path
|
||||
@@ -238,23 +264,41 @@ if BOOST_HOME is not None:
|
||||
|
||||
if not OSX:
|
||||
env.Append(LINKFLAGS = [
|
||||
'-rdynamic', '-pthread',
|
||||
'-rdynamic',
|
||||
'-pthread',
|
||||
])
|
||||
|
||||
DEBUGFLAGS = ['-g', '-DDEBUG', '-D_DEBUG']
|
||||
|
||||
env.Append(CCFLAGS = ['-pthread', '-Wall', '-Wno-sign-compare', '-Wno-char-subscripts']+DEBUGFLAGS)
|
||||
env.Append(CXXFLAGS = ['-O1', '-pthread', '-Wno-invalid-offsetof', '-Wformat']+DEBUGFLAGS)
|
||||
if not USING_CLANG:
|
||||
more_warnings = ['-Wno-unused-local-typedefs']
|
||||
else:
|
||||
# This disables the "You said it was a struct AND a class, wth is going on
|
||||
# warnings"
|
||||
more_warnings = ['-Wno-mismatched-tags']
|
||||
# This needs to be a CCFLAGS not a CXXFLAGS
|
||||
env.Append(CCFLAGS = more_warnings)
|
||||
|
||||
env.Append(CXXFLAGS = ['-O1','-pthread', '-Wno-invalid-offsetof', '-Wformat']+more_warnings+DEBUGFLAGS)
|
||||
|
||||
# RTTI is required for Beast and CountedObject.
|
||||
#
|
||||
env.Append(CXXFLAGS = ['-frtti'])
|
||||
|
||||
if (int(GCC_VERSION[0]) == 4 and int(GCC_VERSION[1]) == 6):
|
||||
env.Append(CXXFLAGS = ['-std=c++0x'])
|
||||
elif (int(GCC_VERSION[0]) > 4 or (int(GCC_VERSION[0]) == 4 and int(GCC_VERSION[1]) >= 7)):
|
||||
env.Append(CXXFLAGS = ['-std=c++11'])
|
||||
UBUNTU_GCC_48_INSTALL_STEPS = '''
|
||||
https://ripple.com/wiki/Ubuntu_build_instructions#Ubuntu_versions_older_than_13.10_:_Install_gcc_4.8'''
|
||||
|
||||
if not USING_CLANG:
|
||||
if (int(GCC_VERSION[0]) == 4 and int(GCC_VERSION[1]) < 7):
|
||||
print "\nrippled, using c++11, requires g++ version >= 4.8 to compile"
|
||||
|
||||
if Ubuntu:
|
||||
print UBUNTU_GCC_48_INSTALL_STEPS
|
||||
|
||||
sys.exit(1)
|
||||
else:
|
||||
env.Append(CXXFLAGS = ['-std=c++11'])
|
||||
|
||||
# FreeBSD doesn't support O_DSYNC
|
||||
if FreeBSD:
|
||||
|
||||
@@ -1,118 +0,0 @@
|
||||
// Copyright (c) 2013 The LevelDB Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file. See the AUTHORS file for names of contributors.
|
||||
|
||||
#include "leveldb/db.h"
|
||||
#include "db/db_impl.h"
|
||||
#include "leveldb/cache.h"
|
||||
#include "util/testharness.h"
|
||||
#include "util/testutil.h"
|
||||
|
||||
namespace leveldb {
|
||||
|
||||
class AutoCompactTest {
|
||||
public:
|
||||
std::string dbname_;
|
||||
Cache* tiny_cache_;
|
||||
Options options_;
|
||||
DB* db_;
|
||||
|
||||
AutoCompactTest() {
|
||||
dbname_ = test::TmpDir() + "/autocompact_test";
|
||||
tiny_cache_ = NewLRUCache(100);
|
||||
options_.block_cache = tiny_cache_;
|
||||
DestroyDB(dbname_, options_);
|
||||
options_.create_if_missing = true;
|
||||
options_.compression = kNoCompression;
|
||||
ASSERT_OK(DB::Open(options_, dbname_, &db_));
|
||||
}
|
||||
|
||||
~AutoCompactTest() {
|
||||
delete db_;
|
||||
DestroyDB(dbname_, Options());
|
||||
delete tiny_cache_;
|
||||
}
|
||||
|
||||
std::string Key(int i) {
|
||||
char buf[100];
|
||||
snprintf(buf, sizeof(buf), "key%06d", i);
|
||||
return std::string(buf);
|
||||
}
|
||||
|
||||
uint64_t Size(const Slice& start, const Slice& limit) {
|
||||
Range r(start, limit);
|
||||
uint64_t size;
|
||||
db_->GetApproximateSizes(&r, 1, &size);
|
||||
return size;
|
||||
}
|
||||
|
||||
void DoReads(int n);
|
||||
};
|
||||
|
||||
static const int kValueSize = 200 * 1024;
|
||||
static const int kTotalSize = 100 * 1024 * 1024;
|
||||
static const int kCount = kTotalSize / kValueSize;
|
||||
|
||||
// Read through the first n keys repeatedly and check that they get
|
||||
// compacted (verified by checking the size of the key space).
|
||||
void AutoCompactTest::DoReads(int n) {
|
||||
std::string value(kValueSize, 'x');
|
||||
DBImpl* dbi = reinterpret_cast<DBImpl*>(db_);
|
||||
|
||||
// Fill database
|
||||
for (int i = 0; i < kCount; i++) {
|
||||
ASSERT_OK(db_->Put(WriteOptions(), Key(i), value));
|
||||
}
|
||||
ASSERT_OK(dbi->TEST_CompactMemTable());
|
||||
|
||||
// Delete everything
|
||||
for (int i = 0; i < kCount; i++) {
|
||||
ASSERT_OK(db_->Delete(WriteOptions(), Key(i)));
|
||||
}
|
||||
ASSERT_OK(dbi->TEST_CompactMemTable());
|
||||
|
||||
// Get initial measurement of the space we will be reading.
|
||||
const int64_t initial_size = Size(Key(0), Key(n));
|
||||
const int64_t initial_other_size = Size(Key(n), Key(kCount));
|
||||
|
||||
// Read until size drops significantly.
|
||||
std::string limit_key = Key(n);
|
||||
for (int read = 0; true; read++) {
|
||||
ASSERT_LT(read, 100) << "Taking too long to compact";
|
||||
Iterator* iter = db_->NewIterator(ReadOptions());
|
||||
for (iter->SeekToFirst();
|
||||
iter->Valid() && iter->key().ToString() < limit_key;
|
||||
iter->Next()) {
|
||||
// Drop data
|
||||
}
|
||||
delete iter;
|
||||
// Wait a little bit to allow any triggered compactions to complete.
|
||||
Env::Default()->SleepForMicroseconds(1000000);
|
||||
uint64_t size = Size(Key(0), Key(n));
|
||||
fprintf(stderr, "iter %3d => %7.3f MB [other %7.3f MB]\n",
|
||||
read+1, size/1048576.0, Size(Key(n), Key(kCount))/1048576.0);
|
||||
if (size <= initial_size/10) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Verify that the size of the key space not touched by the reads
|
||||
// is pretty much unchanged.
|
||||
const int64_t final_other_size = Size(Key(n), Key(kCount));
|
||||
ASSERT_LE(final_other_size, initial_other_size + 1048576);
|
||||
ASSERT_GE(final_other_size, initial_other_size/5 - 1048576);
|
||||
}
|
||||
|
||||
TEST(AutoCompactTest, ReadAll) {
|
||||
DoReads(kCount);
|
||||
}
|
||||
|
||||
TEST(AutoCompactTest, ReadHalf) {
|
||||
DoReads(kCount/2);
|
||||
}
|
||||
|
||||
} // namespace leveldb
|
||||
|
||||
int main(int argc, char** argv) {
|
||||
return leveldb::test::RunAllTests();
|
||||
}
|
||||
@@ -60,39 +60,36 @@
|
||||
#
|
||||
# [ips]
|
||||
#
|
||||
# List of ips where the Ripple protocol is served. For a starter list,
|
||||
# you can copy entries from: https://ripple.com/ripple.txt
|
||||
# List of hostnames or ips where the Ripple protocol is served. For a starter
|
||||
# list, you can either copy entries from: https://ripple.com/ripple.txt or if
|
||||
# you prefer you can specify r.ripple.com 51235
|
||||
#
|
||||
# Domain names are not allowed. One ipv4 or ipv6 address per line. A port
|
||||
# may optionally be specified after adding a space to the address. By
|
||||
# convention, if known, IPs are listed in from most to least trusted.
|
||||
# One IPv4 address or domain names per line is allowed. A port may optionally
|
||||
# be specified after adding a space to the address. By convention, if known,
|
||||
# IPs are listed in from most to least trusted.
|
||||
#
|
||||
# Examples:
|
||||
# 192.168.0.1
|
||||
# 192.168.0.1 3939
|
||||
# 2001:0db8:0100:f101:0210:a4ff:fee3:9566
|
||||
# r.ripple.com 51235
|
||||
#
|
||||
# Here's the recent set of good, well known addresses:
|
||||
# This will give you a good, up-to-date list of addresses:
|
||||
#
|
||||
# [ips]
|
||||
# 54.225.112.220 51235
|
||||
# 54.225.123.13 51235
|
||||
# 54.227.239.106 51235
|
||||
# 107.21.251.218 51235
|
||||
# 184.73.226.101 51235
|
||||
# 23.23.201.55 51235
|
||||
# r.ripple.com 51235
|
||||
#
|
||||
#
|
||||
#
|
||||
# [ips_fixed]
|
||||
#
|
||||
# List of IP addresses to which rippled should always maintain peer
|
||||
# connections with. This is useful for manually forming private networks,
|
||||
# for example to configure a validation server that connects to the
|
||||
# List of IP addresses or hostnames to which rippled should always attempt to
|
||||
# maintain peer connections with. This is useful for manually forming private
|
||||
# networks, for example to configure a validation server that connects to the
|
||||
# Ripple network through a public-facing server, or for building a set
|
||||
# of cluster peers.
|
||||
#
|
||||
#
|
||||
# One IPv4 address or domain names per line is allowed. A port may optionally
|
||||
# be specified after adding a space to the address.
|
||||
#
|
||||
# [peer_ip]
|
||||
#
|
||||
@@ -494,6 +491,20 @@
|
||||
#
|
||||
#
|
||||
#
|
||||
# [fetch_depth]
|
||||
#
|
||||
# The number of past ledgers to serve to other peers that request historical
|
||||
# ledger data (or "full" for no limit).
|
||||
#
|
||||
# Servers that require low latency and high local performance may wish to
|
||||
# restrict the historical ledgers they are willing to serve. Setting this
|
||||
# below 32 can harm network stability as servers require easy access to
|
||||
# recent history to stay in sync. Values below 128 are not recommended.
|
||||
#
|
||||
# The default is: full
|
||||
#
|
||||
#
|
||||
#
|
||||
# [validation_seed]
|
||||
#
|
||||
# To perform validation, this section should contain either a validation seed
|
||||
@@ -799,15 +810,9 @@ time.nist.gov
|
||||
pool.ntp.org
|
||||
|
||||
# Where to find some other servers speaking the Ripple protocol.
|
||||
# This set of addresses is recent as of September 5, 2013
|
||||
#
|
||||
[ips]
|
||||
54.225.112.220 51235
|
||||
54.225.123.13 51235
|
||||
54.227.239.106 51235
|
||||
107.21.251.218 51235
|
||||
184.73.226.101 51235
|
||||
23.23.201.55 51235
|
||||
r.ripple.com 51235
|
||||
|
||||
# These validators are taken from the v0.16 release notes on the wiki:
|
||||
# https://ripple.com/wiki/Latest_rippled_release_notes
|
||||
|
||||
@@ -22,7 +22,7 @@ David Features:
|
||||
|
||||
- std::priority_queue for DeadlineTimer
|
||||
|
||||
- Change ProxyInfo to use IPAddress, get rid of IPv4Address from the parsing
|
||||
- Change ProxyInfo to use IP::Endpoint, get rid of IPv4Address from the parsing
|
||||
code
|
||||
|
||||
- Validators should delay the application of newly downloaded lists from
|
||||
@@ -34,7 +34,7 @@ David Features:
|
||||
|
||||
- Look into using CMake
|
||||
|
||||
- IPv6 support in IPAddress
|
||||
- IPv6 support in IP::Endpoint
|
||||
|
||||
- Configuration list for Jenkins
|
||||
|
||||
|
||||
@@ -1,59 +0,0 @@
|
||||
// Copyright (c) 2013 The LevelDB Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file. See the AUTHORS file for names of contributors.
|
||||
|
||||
// Test for issue 200: when iterator switches direction from backward
|
||||
// to forward, the current key can be yielded unexpectedly if a new
|
||||
// mutation has been added just before the current key.
|
||||
|
||||
#include "leveldb/db.h"
|
||||
#include "util/testharness.h"
|
||||
|
||||
namespace leveldb {
|
||||
|
||||
class Issue200 { };
|
||||
|
||||
TEST(Issue200, Test) {
|
||||
// Get rid of any state from an old run.
|
||||
std::string dbpath = test::TmpDir() + "/leveldb_issue200_test";
|
||||
DestroyDB(dbpath, Options());
|
||||
|
||||
DB *db;
|
||||
Options options;
|
||||
options.create_if_missing = true;
|
||||
ASSERT_OK(DB::Open(options, dbpath, &db));
|
||||
|
||||
WriteOptions write_options;
|
||||
ASSERT_OK(db->Put(write_options, "1", "b"));
|
||||
ASSERT_OK(db->Put(write_options, "2", "c"));
|
||||
ASSERT_OK(db->Put(write_options, "3", "d"));
|
||||
ASSERT_OK(db->Put(write_options, "4", "e"));
|
||||
ASSERT_OK(db->Put(write_options, "5", "f"));
|
||||
|
||||
ReadOptions read_options;
|
||||
Iterator *iter = db->NewIterator(read_options);
|
||||
|
||||
// Add an element that should not be reflected in the iterator.
|
||||
ASSERT_OK(db->Put(write_options, "25", "cd"));
|
||||
|
||||
iter->Seek("5");
|
||||
ASSERT_EQ(iter->key().ToString(), "5");
|
||||
iter->Prev();
|
||||
ASSERT_EQ(iter->key().ToString(), "4");
|
||||
iter->Prev();
|
||||
ASSERT_EQ(iter->key().ToString(), "3");
|
||||
iter->Next();
|
||||
ASSERT_EQ(iter->key().ToString(), "4");
|
||||
iter->Next();
|
||||
ASSERT_EQ(iter->key().ToString(), "5");
|
||||
|
||||
delete iter;
|
||||
delete db;
|
||||
DestroyDB(dbpath, options);
|
||||
}
|
||||
|
||||
} // namespace leveldb
|
||||
|
||||
int main(int argc, char** argv) {
|
||||
return leveldb::test::RunAllTests();
|
||||
}
|
||||
@@ -22,7 +22,7 @@
|
||||
},
|
||||
|
||||
"scripts": {
|
||||
"test": "mocha"
|
||||
"test": "mocha test/websocket-test.js test/server-test.js test/*-test.{js,coffee}"
|
||||
},
|
||||
|
||||
"repository": {
|
||||
@@ -31,4 +31,4 @@
|
||||
},
|
||||
|
||||
"readmeFilename": "README.md"
|
||||
}
|
||||
}
|
||||
@@ -184,19 +184,4 @@
|
||||
#define RIPPLE_USE_VALIDATORS 0
|
||||
#endif
|
||||
|
||||
// Turning this on will use the new PeerFinder logic to establish connections
|
||||
// to other peers. Even with this off, PeerFinder will still send mtENDPOINTS
|
||||
// messages as needed, and collect legacy IP endpoint information.
|
||||
//
|
||||
#ifndef RIPPLE_USE_PEERFINDER
|
||||
#define RIPPLE_USE_PEERFINDER 0
|
||||
#endif
|
||||
|
||||
// Here temporarily
|
||||
// Controls whether or not the new RPC::Manager logic will be
|
||||
// used to invoke RPC commands before they pass to the original code.
|
||||
#ifndef RIPPLE_USE_RPC_SERVICE_MANAGER
|
||||
#define RIPPLE_USE_RPC_SERVICE_MANAGER 0
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<ItemDefinitionGroup>
|
||||
<ClCompile>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<PreprocessorDefinitions>BEAST_COMPILING_STATIC_LIBARARY=1;_CRTDBG_MAP_ALLOC;_WIN32_WINNT=0x0600;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>BEAST_COMPILING_STATIC_LIBARARY=1;_CRTDBG_MAP_ALLOC;_WIN32_WINNT=0x0600;_SCL_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
<MinimalRebuild>false</MinimalRebuild>
|
||||
<AdditionalIncludeDirectories>$(RepoDir)\config;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
@@ -83,14 +83,17 @@
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\beast\Arithmetic.h" />
|
||||
<ClInclude Include="..\..\beast\Asio.h" />
|
||||
<ClInclude Include="..\..\beast\asio\io_latency_probe.h" />
|
||||
<ClInclude Include="..\..\beast\asio\IPAddressConversion.h" />
|
||||
<ClInclude Include="..\..\beast\Atomic.h" />
|
||||
<ClInclude Include="..\..\beast\Boost.h" />
|
||||
<ClInclude Include="..\..\beast\boost\ErrorCode.h" />
|
||||
<ClInclude Include="..\..\beast\ByteOrder.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_io.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\CPUMeter.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\abstract_clock.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\basic_seconds_clock.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_io.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_util.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\CPUMeter.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\manual_clock.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\ratio_io.h" />
|
||||
<ClInclude Include="..\..\beast\chrono\RelativeTime.h" />
|
||||
@@ -113,6 +116,20 @@
|
||||
<ClInclude Include="..\..\beast\config\SelectPlatformConfig.h" />
|
||||
<ClInclude Include="..\..\beast\config\SelectStdlibConfig.h" />
|
||||
<ClInclude Include="..\..\beast\config\StandardConfig.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_container_utility.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_container.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_map.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_multimap.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_multiset.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_set.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_map.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_multimap.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_multiset.h" />
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_set.h" />
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_associative_container.h" />
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_ordered_container.h" />
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_container_iterator.h" />
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_unordered_container.h" />
|
||||
<ClInclude Include="..\..\beast\Crypto.h" />
|
||||
<ClInclude Include="..\..\beast\crypto\BinaryEncoding.h" />
|
||||
<ClInclude Include="..\..\beast\crypto\impl\sha2\sha2.h" />
|
||||
@@ -121,6 +138,11 @@
|
||||
<ClInclude Include="..\..\beast\crypto\UnsignedInteger.h" />
|
||||
<ClInclude Include="..\..\beast\crypto\UnsignedIntegerCalc.h" />
|
||||
<ClInclude Include="..\..\beast\CStdInt.h" />
|
||||
<ClInclude Include="..\..\beast\cxx14\algorithm.h" />
|
||||
<ClInclude Include="..\..\beast\cxx14\config.h" />
|
||||
<ClInclude Include="..\..\beast\cxx14\functional.h" />
|
||||
<ClInclude Include="..\..\beast\cxx14\memory.h" />
|
||||
<ClInclude Include="..\..\beast\cxx14\type_traits.h" />
|
||||
<ClInclude Include="..\..\beast\cyclic_iterator.h" />
|
||||
<ClInclude Include="..\..\beast\FixedArray.h" />
|
||||
<ClInclude Include="..\..\beast\HeapBlock.h" />
|
||||
@@ -129,6 +151,8 @@
|
||||
<ClInclude Include="..\..\beast\http\ParsedURL.h" />
|
||||
<ClInclude Include="..\..\beast\http\URL.h" />
|
||||
<ClInclude Include="..\..\beast\Insight.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Base.h" />
|
||||
<ClInclude Include="..\..\beast\insight\BaseImpl.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Collector.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Counter.h" />
|
||||
<ClInclude Include="..\..\beast\insight\CounterImpl.h" />
|
||||
@@ -136,6 +160,8 @@
|
||||
<ClInclude Include="..\..\beast\insight\EventImpl.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Gauge.h" />
|
||||
<ClInclude Include="..\..\beast\insight\GaugeImpl.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Group.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Groups.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Hook.h" />
|
||||
<ClInclude Include="..\..\beast\insight\HookImpl.h" />
|
||||
<ClInclude Include="..\..\beast\insight\Meter.h" />
|
||||
@@ -150,8 +176,12 @@
|
||||
<ClInclude Include="..\..\beast\mpl\IsCallPossible.h" />
|
||||
<ClInclude Include="..\..\beast\Net.h" />
|
||||
<ClInclude Include="..\..\beast\net\BufferType.h" />
|
||||
<ClInclude Include="..\..\beast\net\detail\Parse.h" />
|
||||
<ClInclude Include="..\..\beast\net\DynamicBuffer.h" />
|
||||
<ClInclude Include="..\..\beast\net\IPAddress.h" />
|
||||
<ClInclude Include="..\..\beast\net\IPAddressV4.h" />
|
||||
<ClInclude Include="..\..\beast\net\IPAddressV6.h" />
|
||||
<ClInclude Include="..\..\beast\net\IPEndpoint.h" />
|
||||
<ClInclude Include="..\..\beast\SafeBool.h" />
|
||||
<ClInclude Include="..\..\beast\SmartPtr.h" />
|
||||
<ClInclude Include="..\..\beast\smart_ptr\AbstractObject.h" />
|
||||
@@ -160,8 +190,6 @@
|
||||
<ClInclude Include="..\..\beast\smart_ptr\SharedObject.h" />
|
||||
<ClInclude Include="..\..\beast\smart_ptr\SharedPtr.h" />
|
||||
<ClInclude Include="..\..\beast\StaticAssert.h" />
|
||||
<ClInclude Include="..\..\beast\STL.h" />
|
||||
<ClInclude Include="..\..\beast\stl\shared_ptr.h" />
|
||||
<ClInclude Include="..\..\beast\Strings.h" />
|
||||
<ClInclude Include="..\..\beast\strings\CharacterFunctions.h" />
|
||||
<ClInclude Include="..\..\beast\strings\CharPointer_ASCII.h" />
|
||||
@@ -195,12 +223,11 @@
|
||||
<ClInclude Include="..\..\beast\type_traits\IntegralConstant.h" />
|
||||
<ClInclude Include="..\..\beast\type_traits\IsIntegral.h" />
|
||||
<ClInclude Include="..\..\beast\type_traits\IsSigned.h" />
|
||||
<ClInclude Include="..\..\beast\type_traits\RemoveSigned.h" />
|
||||
<ClInclude Include="..\..\beast\type_traits\maybe_const.h" />
|
||||
<ClInclude Include="..\..\beast\Uncopyable.h" />
|
||||
<ClInclude Include="..\..\beast\Utility.h" />
|
||||
<ClInclude Include="..\..\beast\utility\BaseFromMember.h" />
|
||||
<ClInclude Include="..\..\beast\utility\Debug.h" />
|
||||
<ClInclude Include="..\..\beast\utility\EnableIf.h" />
|
||||
<ClInclude Include="..\..\beast\utility\empty_base_optimization.h" />
|
||||
<ClInclude Include="..\..\beast\utility\Error.h" />
|
||||
<ClInclude Include="..\..\beast\utility\hash_pair.h" />
|
||||
<ClInclude Include="..\..\beast\utility\Journal.h" />
|
||||
@@ -244,7 +271,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_asio\sockets\Socket.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\sockets\SocketBase.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\sockets\SocketWrapper.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\sockets\SocketWrapperStrand.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\system\BoostIncludes.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\system\OpenSSLIncludes.h" />
|
||||
<ClInclude Include="..\..\modules\beast_asio\tests\TestPeer.h" />
|
||||
@@ -293,7 +319,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\Math.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\Random.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\Range.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\uint24.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\memory\CacheLine.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\memory\MemoryAlignment.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\memory\MemoryBlock.h" />
|
||||
@@ -333,7 +358,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_core\text\StringArray.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\text\StringPairArray.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\text\StringPool.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\text\TextDiff.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\threads\ChildProcess.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\threads\CriticalSection.h" />
|
||||
<ClInclude Include="..\..\modules\beast_core\threads\DynamicLibrary.h" />
|
||||
@@ -407,6 +431,12 @@
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\boost\Boost.cpp" />
|
||||
<ClCompile Include="..\..\beast\chrono\Chrono.cpp" />
|
||||
<ClCompile Include="..\..\beast\chrono\impl\basic_seconds_clock.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\chrono\impl\chrono_io.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -431,6 +461,13 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\container\Container.cpp" />
|
||||
<ClCompile Include="..\..\beast\container\impl\aged_associative_container.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\crypto\Crypto.cpp" />
|
||||
<ClCompile Include="..\..\beast\crypto\impl\BinaryEncoding.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
@@ -523,6 +560,18 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\impl\Group.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\impl\Groups.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\impl\Hook.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -560,6 +609,24 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddressV4.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddressV6.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPEndpoint.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\Net.cpp" />
|
||||
<ClCompile Include="..\..\beast\smart_ptr\impl\AbstractObject.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
@@ -568,7 +635,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\smart_ptr\SmartPtr.cpp" />
|
||||
<ClCompile Include="..\..\beast\stl\STL.cpp" />
|
||||
<ClCompile Include="..\..\beast\strings\impl\CharacterFunctions.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -619,6 +685,12 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\threads\Threads.cpp" />
|
||||
<ClCompile Include="..\..\beast\utility\impl\Assert.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\utility\impl\Debug.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
@@ -1194,12 +1266,6 @@
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\modules\beast_core\text\TextDiff.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\modules\beast_core\threads\ChildProcess.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
@@ -1444,31 +1510,32 @@
|
||||
<ProjectGuid>{73C5A0F0-7629-4DE7-9194-BE7AC6C19535}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>beast</RootNamespace>
|
||||
<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v110</PlatformToolset>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
@@ -195,9 +195,6 @@
|
||||
<Filter Include="beast">
|
||||
<UniqueIdentifier>{92d1bb42-289a-4444-85c7-cb87540f2fff}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\intrusive">
|
||||
<UniqueIdentifier>{8832eb52-53f9-4850-8dc9-1d579a386a0e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\mpl">
|
||||
<UniqueIdentifier>{5904368f-a0f2-4d26-a031-8cbe4448dc3f}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -279,9 +276,6 @@
|
||||
<Filter Include="beast\smart_ptr\impl">
|
||||
<UniqueIdentifier>{df4f2935-13a1-4afe-90cc-d86472ec2466}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\stl">
|
||||
<UniqueIdentifier>{793e2d61-14f6-4fa1-a17f-af6bbec13ba1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\insight">
|
||||
<UniqueIdentifier>{174b9125-76a7-4796-be97-79c2dcc751f1}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -297,6 +291,24 @@
|
||||
<Filter Include="beast\crypto\impl\sha2">
|
||||
<UniqueIdentifier>{44489531-f44a-439a-a6ea-d32c252b1e8b}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\net\detail">
|
||||
<UniqueIdentifier>{43cc0f2a-9905-4081-8104-48d2c4be9e7e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\container">
|
||||
<UniqueIdentifier>{48c7ee12-704c-42cb-99ea-9a486bb4b57e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\container\impl">
|
||||
<UniqueIdentifier>{e30eda19-95b4-4831-b86a-ee5fae88abd2}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\container\detail">
|
||||
<UniqueIdentifier>{a4dca8cc-7d1f-4353-b7e1-15eab33e8bd4}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\intrusive">
|
||||
<UniqueIdentifier>{8832eb52-53f9-4850-8dc9-1d579a386a0e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="beast\cxx14">
|
||||
<UniqueIdentifier>{5745a887-7df8-4059-87ea-e0c7eea77a9b}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\modules\beast_core\beast_core.h">
|
||||
@@ -452,9 +464,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_core\text\StringPool.h">
|
||||
<Filter>beast_core\text</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_core\text\TextDiff.h">
|
||||
<Filter>beast_core\text</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_core\threads\ChildProcess.h">
|
||||
<Filter>beast_core\threads</Filter>
|
||||
</ClInclude>
|
||||
@@ -638,9 +647,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_core\diagnostic\SemanticVersion.h">
|
||||
<Filter>beast_core\diagnostic</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\uint24.h">
|
||||
<Filter>beast_core\maths</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_core\diagnostic\MeasureFunctionCallTime.h">
|
||||
<Filter>beast_core\diagnostic</Filter>
|
||||
</ClInclude>
|
||||
@@ -674,9 +680,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_core\maths\Math.h">
|
||||
<Filter>beast_core\maths</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_asio\sockets\SocketWrapperStrand.h">
|
||||
<Filter>beast_asio\sockets</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\modules\beast_asio\basics\SSLContext.h">
|
||||
<Filter>beast_asio\basics</Filter>
|
||||
</ClInclude>
|
||||
@@ -860,12 +863,6 @@
|
||||
<ClInclude Include="..\..\beast\type_traits\IsIntegral.h">
|
||||
<Filter>beast\type_traits</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\type_traits\RemoveSigned.h">
|
||||
<Filter>beast\type_traits</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\EnableIf.h">
|
||||
<Filter>beast\utility</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\Journal.h">
|
||||
<Filter>beast\utility</Filter>
|
||||
</ClInclude>
|
||||
@@ -995,9 +992,6 @@
|
||||
<ClInclude Include="..\..\beast\Chrono.h">
|
||||
<Filter>beast</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\RelativeTime.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\SafeBool.h">
|
||||
<Filter>beast</Filter>
|
||||
</ClInclude>
|
||||
@@ -1065,12 +1059,6 @@
|
||||
<ClInclude Include="..\..\modules\beast_asio\http\HTTPResponseParser.h">
|
||||
<Filter>beast_asio\http</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\ScopedTimeInterval.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\CPUMeter.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\smart_ptr\SharedObject.h">
|
||||
<Filter>beast\smart_ptr</Filter>
|
||||
</ClInclude>
|
||||
@@ -1143,12 +1131,6 @@
|
||||
<ClInclude Include="..\..\beast\threads\ScopedWrapperContext.h">
|
||||
<Filter>beast\threads</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\BaseFromMember.h">
|
||||
<Filter>beast\utility</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\IPAddress.h">
|
||||
<Filter>beast\net</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\Asio.h">
|
||||
<Filter>beast</Filter>
|
||||
</ClInclude>
|
||||
@@ -1161,12 +1143,6 @@
|
||||
<ClInclude Include="..\..\beast\smart_ptr\AbstractObject.h">
|
||||
<Filter>beast\smart_ptr</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\stl\shared_ptr.h">
|
||||
<Filter>beast\stl</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\STL.h">
|
||||
<Filter>beast</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\Insight.h">
|
||||
<Filter>beast</Filter>
|
||||
</ClInclude>
|
||||
@@ -1227,21 +1203,132 @@
|
||||
<ClInclude Include="..\..\beast\crypto\UnsignedIntegerCalc.h">
|
||||
<Filter>beast\crypto</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\hash_pair.h">
|
||||
<Filter>beast\utility</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\asio\io_latency_probe.h">
|
||||
<Filter>beast\asio</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\insight\Base.h">
|
||||
<Filter>beast\insight</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\insight\BaseImpl.h">
|
||||
<Filter>beast\insight</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\insight\Group.h">
|
||||
<Filter>beast\insight</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\insight\Groups.h">
|
||||
<Filter>beast\insight</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\detail\Parse.h">
|
||||
<Filter>beast\net\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\IPAddress.h">
|
||||
<Filter>beast\net</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\IPAddressV4.h">
|
||||
<Filter>beast\net</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\IPAddressV6.h">
|
||||
<Filter>beast\net</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\net\IPEndpoint.h">
|
||||
<Filter>beast\net</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\abstract_clock.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\basic_seconds_clock.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_io.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_util.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\CPUMeter.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\manual_clock.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\ratio_io.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\chrono\chrono_io.h">
|
||||
<ClInclude Include="..\..\beast\chrono\RelativeTime.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\hash_pair.h">
|
||||
<ClInclude Include="..\..\beast\chrono\ScopedTimeInterval.h">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\type_traits\maybe_const.h">
|
||||
<Filter>beast\type_traits</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\utility\empty_base_optimization.h">
|
||||
<Filter>beast\utility</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_associative_container.h">
|
||||
<Filter>beast\container\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_container_iterator.h">
|
||||
<Filter>beast\container\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_map.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_multimap.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_multiset.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_set.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_map.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_multimap.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_multiset.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_unordered_set.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_ordered_container.h">
|
||||
<Filter>beast\container\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_unordered_container.h">
|
||||
<Filter>beast\container\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\detail\aged_associative_container.h">
|
||||
<Filter>beast\container\detail</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_container_utility.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\container\aged_container.h">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\cxx14\type_traits.h">
|
||||
<Filter>beast\cxx14</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\cxx14\functional.h">
|
||||
<Filter>beast\cxx14</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\cxx14\config.h">
|
||||
<Filter>beast\cxx14</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\cxx14\algorithm.h">
|
||||
<Filter>beast\cxx14</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\beast\cxx14\memory.h">
|
||||
<Filter>beast\cxx14</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\modules\beast_core\containers\DynamicObject.cpp">
|
||||
@@ -1388,9 +1475,6 @@
|
||||
<ClCompile Include="..\..\modules\beast_core\text\StringPool.cpp">
|
||||
<Filter>beast_core\text</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\modules\beast_core\text\TextDiff.cpp">
|
||||
<Filter>beast_core\text</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\modules\beast_core\threads\ChildProcess.cpp">
|
||||
<Filter>beast_core\threads</Filter>
|
||||
</ClCompile>
|
||||
@@ -1700,9 +1784,6 @@
|
||||
<ClCompile Include="..\..\beast\chrono\impl\RelativeTime.cpp">
|
||||
<Filter>beast\chrono\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\chrono\Chrono.cpp">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\utility\impl\Debug.cpp">
|
||||
<Filter>beast\utility\impl</Filter>
|
||||
</ClCompile>
|
||||
@@ -1757,9 +1838,6 @@
|
||||
<ClCompile Include="..\..\beast\utility\impl\PropertyStream.cpp">
|
||||
<Filter>beast\utility\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddress.cpp">
|
||||
<Filter>beast\net\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\asio\Asio.cpp">
|
||||
<Filter>beast\asio</Filter>
|
||||
</ClCompile>
|
||||
@@ -1772,9 +1850,6 @@
|
||||
<ClCompile Include="..\..\beast\smart_ptr\impl\AbstractObject.cpp">
|
||||
<Filter>beast\smart_ptr\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\stl\STL.cpp">
|
||||
<Filter>beast\stl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\Insight.cpp">
|
||||
<Filter>beast\insight</Filter>
|
||||
</ClCompile>
|
||||
@@ -1805,6 +1880,39 @@
|
||||
<ClCompile Include="..\..\beast\crypto\impl\UnsignedInteger.cpp">
|
||||
<Filter>beast\crypto\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\impl\Group.cpp">
|
||||
<Filter>beast\insight\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\insight\impl\Groups.cpp">
|
||||
<Filter>beast\insight\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddress.cpp">
|
||||
<Filter>beast\net\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddressV4.cpp">
|
||||
<Filter>beast\net\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPAddressV6.cpp">
|
||||
<Filter>beast\net\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\net\impl\IPEndpoint.cpp">
|
||||
<Filter>beast\net\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\utility\impl\Assert.cpp">
|
||||
<Filter>beast\utility\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\chrono\Chrono.cpp">
|
||||
<Filter>beast\chrono</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\chrono\impl\basic_seconds_clock.cpp">
|
||||
<Filter>beast\chrono\impl</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\container\Container.cpp">
|
||||
<Filter>beast\container</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\beast\container\impl\aged_associative_container.cpp">
|
||||
<Filter>beast\container\impl</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Text Include="..\..\TODO.txt">
|
||||
@@ -207,6 +207,9 @@ private:
|
||||
#define BEAST_64BIT_ATOMICS_UNAVAILABLE 1
|
||||
#endif
|
||||
|
||||
#elif BEAST_CLANG && BEAST_LINUX
|
||||
#define BEAST_ATOMICS_GCC 1
|
||||
|
||||
//==============================================================================
|
||||
#elif BEAST_GCC
|
||||
#define BEAST_ATOMICS_GCC 1 // GCC with intrinsics
|
||||
@@ -297,8 +300,16 @@ template <typename Type>
|
||||
inline Type Atomic<Type>::operator+= (const Type amountToAdd) noexcept
|
||||
{
|
||||
#if BEAST_ATOMICS_MAC
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wint-to-void-pointer-cast"
|
||||
# pragma clang diagnostic ignored "-Wint-to-pointer-cast"
|
||||
# endif
|
||||
return sizeof (Type) == 4 ? (Type) OSAtomicAdd32Barrier ((int32_t) castTo32Bit (amountToAdd), (BEAST_MAC_ATOMICS_VOLATILE int32_t*) &value)
|
||||
: (Type) OSAtomicAdd64Barrier ((int64_t) amountToAdd, (BEAST_MAC_ATOMICS_VOLATILE int64_t*) &value);
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic pop
|
||||
# endif
|
||||
#elif BEAST_ATOMICS_WINDOWS
|
||||
return sizeof (Type) == 4 ? (Type) (beast_InterlockedExchangeAdd ((volatile long*) &value, (long) amountToAdd) + (long) amountToAdd)
|
||||
: (Type) (beast_InterlockedExchangeAdd64 ((volatile __int64*) &value, (__int64) amountToAdd) + (__int64) amountToAdd);
|
||||
@@ -317,13 +328,21 @@ template <typename Type>
|
||||
inline Type Atomic<Type>::operator++() noexcept
|
||||
{
|
||||
#if BEAST_ATOMICS_MAC
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wint-to-void-pointer-cast"
|
||||
# pragma clang diagnostic ignored "-Wint-to-pointer-cast"
|
||||
# endif
|
||||
return sizeof (Type) == 4 ? (Type) OSAtomicIncrement32Barrier ((BEAST_MAC_ATOMICS_VOLATILE int32_t*) &value)
|
||||
: (Type) OSAtomicIncrement64Barrier ((BEAST_MAC_ATOMICS_VOLATILE int64_t*) &value);
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic pop
|
||||
# endif
|
||||
#elif BEAST_ATOMICS_WINDOWS
|
||||
return sizeof (Type) == 4 ? (Type) beast_InterlockedIncrement ((volatile long*) &value)
|
||||
: (Type) beast_InterlockedIncrement64 ((volatile __int64*) &value);
|
||||
#elif BEAST_ATOMICS_GCC
|
||||
return (Type) __sync_add_and_fetch (&value, 1);
|
||||
return (Type) __sync_add_and_fetch (&value, (Type) 1);
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -331,13 +350,21 @@ template <typename Type>
|
||||
inline Type Atomic<Type>::operator--() noexcept
|
||||
{
|
||||
#if BEAST_ATOMICS_MAC
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wint-to-void-pointer-cast"
|
||||
# pragma clang diagnostic ignored "-Wint-to-pointer-cast"
|
||||
# endif
|
||||
return sizeof (Type) == 4 ? (Type) OSAtomicDecrement32Barrier ((BEAST_MAC_ATOMICS_VOLATILE int32_t*) &value)
|
||||
: (Type) OSAtomicDecrement64Barrier ((BEAST_MAC_ATOMICS_VOLATILE int64_t*) &value);
|
||||
# ifdef __clang__
|
||||
# pragma clang diagnostic pop
|
||||
# endif
|
||||
#elif BEAST_ATOMICS_WINDOWS
|
||||
return sizeof (Type) == 4 ? (Type) beast_InterlockedDecrement ((volatile long*) &value)
|
||||
: (Type) beast_InterlockedDecrement64 ((volatile __int64*) &value);
|
||||
#elif BEAST_ATOMICS_GCC
|
||||
return (Type) __sync_add_and_fetch (&value, -1);
|
||||
return (Type) __sync_add_and_fetch (&value, (Type) -1);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@@ -21,7 +21,9 @@
|
||||
#define BEAST_CHRONO_H_INCLUDED
|
||||
|
||||
#include "chrono/abstract_clock.h"
|
||||
#include "chrono/basic_seconds_clock.h"
|
||||
#include "chrono/chrono_io.h"
|
||||
#include "chrono/chrono_util.h"
|
||||
#include "chrono/manual_clock.h"
|
||||
#include "chrono/ratio_io.h"
|
||||
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
#include "insight/EventImpl.h"
|
||||
#include "insight/Gauge.h"
|
||||
#include "insight/GaugeImpl.h"
|
||||
#include "insight/Group.h"
|
||||
#include "insight/Groups.h"
|
||||
#include "insight/Hook.h"
|
||||
#include "insight/HookImpl.h"
|
||||
#include "insight/Collector.h"
|
||||
|
||||
@@ -23,6 +23,9 @@
|
||||
#include "net/BufferType.h"
|
||||
#include "net/DynamicBuffer.h"
|
||||
|
||||
#include "net/IPAddress.h"
|
||||
#include "net/IPEndpoint.h"
|
||||
#include "net/IPAddressV4.h"
|
||||
#include "net/IPAddressV6.h"
|
||||
#include "net/IPEndpoint.h"
|
||||
|
||||
#endif
|
||||
|
||||
@@ -23,6 +23,5 @@
|
||||
#include "type_traits/IntegralConstant.h"
|
||||
#include "type_traits/IsIntegral.h"
|
||||
#include "type_traits/IsSigned.h"
|
||||
#include "type_traits/RemoveSigned.h"
|
||||
|
||||
#endif
|
||||
|
||||
@@ -20,9 +20,7 @@
|
||||
#ifndef BEAST_UTILITY_H_INCLUDED
|
||||
#define BEAST_UTILITY_H_INCLUDED
|
||||
|
||||
#include "utility/BaseFromMember.h"
|
||||
#include "utility/Debug.h"
|
||||
#include "utility/EnableIf.h"
|
||||
#include "utility/Error.h"
|
||||
#include "utility/Journal.h"
|
||||
#include "utility/LeakChecked.h"
|
||||
|
||||
@@ -20,41 +20,47 @@
|
||||
#ifndef BEAST_ASIO_IPADDRESSCONVERSION_H_INCLUDED
|
||||
#define BEAST_ASIO_IPADDRESSCONVERSION_H_INCLUDED
|
||||
|
||||
#include "../net/IPAddress.h"
|
||||
#include "../net/IPEndpoint.h"
|
||||
|
||||
#include <sstream>
|
||||
|
||||
#include <boost/asio.hpp>
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
/** Convert to Endpoint.
|
||||
The port is set to zero.
|
||||
*/
|
||||
Endpoint from_asio (boost::asio::ip::address const& address);
|
||||
|
||||
/** Convert to Endpoint. */
|
||||
Endpoint from_asio (boost::asio::ip::tcp::endpoint const& endpoint);
|
||||
|
||||
/** Convert to asio::ip::address.
|
||||
The port is ignored.
|
||||
*/
|
||||
boost::asio::ip::address to_asio_address (Endpoint const& endpoint);
|
||||
|
||||
/** Convert to asio::ip::tcp::endpoint. */
|
||||
boost::asio::ip::tcp::endpoint to_asio_endpoint (Endpoint const& endpoint);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
namespace beast {
|
||||
|
||||
// DEPRECATED
|
||||
struct IPAddressConversion
|
||||
{
|
||||
/** Convert to IPAddress.
|
||||
The port is set to zero.
|
||||
*/
|
||||
static IPAddress from_asio (boost::asio::ip::address const& address);
|
||||
|
||||
/** Convert to IPAddress, including port. */
|
||||
static IPAddress from_asio (boost::asio::ip::tcp::endpoint const& endpoint);
|
||||
|
||||
/** Convert to asio::ip::address.
|
||||
The port is ignored.
|
||||
*/
|
||||
static boost::asio::ip::address to_asio_address (IPAddress const& address);
|
||||
|
||||
/** Convert to asio::ip::tcp::endpoint. */
|
||||
static boost::asio::ip::tcp::endpoint to_asio_endpoint (IPAddress const& address);
|
||||
|
||||
/** Conversions to string. */
|
||||
/** @{ */
|
||||
static std::string to_string (boost::asio::ip::tcp::endpoint const& endpoint)
|
||||
{
|
||||
std::stringstream ss;
|
||||
ss << endpoint;
|
||||
return ss.str();
|
||||
}
|
||||
/** @} */
|
||||
static IP::Endpoint from_asio (boost::asio::ip::address const& address)
|
||||
{ return IP::from_asio (address); }
|
||||
static IP::Endpoint from_asio (boost::asio::ip::tcp::endpoint const& endpoint)
|
||||
{ return IP::from_asio (endpoint); }
|
||||
static boost::asio::ip::address to_asio_address (IP::Endpoint const& address)
|
||||
{ return IP::to_asio_address (address); }
|
||||
static boost::asio::ip::tcp::endpoint to_asio_endpoint (IP::Endpoint const& address)
|
||||
{ return IP::to_asio_endpoint (address); }
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -20,34 +20,35 @@
|
||||
#include "../IPAddressConversion.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
IPAddress IPAddressConversion::from_asio (boost::asio::ip::address const& address)
|
||||
Endpoint from_asio (boost::asio::ip::address const& address)
|
||||
{
|
||||
if (address.is_v4 ())
|
||||
{
|
||||
boost::asio::ip::address_v4::bytes_type const bytes (
|
||||
address.to_v4().to_bytes());
|
||||
return IPAddress (IPAddress::V4 (
|
||||
return Endpoint (AddressV4 (
|
||||
bytes [0], bytes [1], bytes [2], bytes [3]));
|
||||
}
|
||||
|
||||
// VFALCO TODO IPv6 support
|
||||
bassertfalse;
|
||||
return IPAddress();
|
||||
return Endpoint();
|
||||
}
|
||||
|
||||
IPAddress IPAddressConversion::from_asio (boost::asio::ip::tcp::endpoint const& endpoint)
|
||||
Endpoint from_asio (boost::asio::ip::tcp::endpoint const& endpoint)
|
||||
{
|
||||
return from_asio (endpoint.address()).withPort (endpoint.port());
|
||||
return from_asio (endpoint.address()).at_port (endpoint.port());
|
||||
}
|
||||
|
||||
boost::asio::ip::address IPAddressConversion::to_asio_address (IPAddress const& address)
|
||||
boost::asio::ip::address to_asio_address (Endpoint const& endpoint)
|
||||
{
|
||||
if (address.isV4 ())
|
||||
if (endpoint.address().is_v4())
|
||||
{
|
||||
return boost::asio::ip::address (
|
||||
boost::asio::ip::address_v4 (
|
||||
address.v4().value));
|
||||
endpoint.address().to_v4().value));
|
||||
}
|
||||
|
||||
// VFALCO TODO IPv6 support
|
||||
@@ -56,10 +57,11 @@ boost::asio::ip::address IPAddressConversion::to_asio_address (IPAddress const&
|
||||
boost::asio::ip::address_v6 ());
|
||||
}
|
||||
|
||||
boost::asio::ip::tcp::endpoint IPAddressConversion::to_asio_endpoint (IPAddress const& address)
|
||||
boost::asio::ip::tcp::endpoint to_asio_endpoint (Endpoint const& endpoint)
|
||||
{
|
||||
return boost::asio::ip::tcp::endpoint (
|
||||
to_asio_address (address), address.port());
|
||||
to_asio_address (endpoint), endpoint.port());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
245
src/beast/beast/asio/io_latency_probe.h
Normal file
245
src/beast/beast/asio/io_latency_probe.h
Normal file
@@ -0,0 +1,245 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_ASIO_IO_LATENCY_PROBE_H_INCLUDED
|
||||
#define BEAST_ASIO_IO_LATENCY_PROBE_H_INCLUDED
|
||||
|
||||
#include <chrono>
|
||||
#include <condition_variable>
|
||||
#include <mutex>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <boost/asio/deadline_timer.hpp>
|
||||
#include <boost/asio/io_service.hpp>
|
||||
#include <boost/config.hpp>
|
||||
|
||||
namespace beast {
|
||||
|
||||
/** Measures handler latency on an io_service queue. */
|
||||
template <class Clock>
|
||||
class io_latency_probe
|
||||
{
|
||||
private:
|
||||
typedef typename Clock::duration duration;
|
||||
typedef typename Clock::time_point time_point;
|
||||
|
||||
std::recursive_mutex m_mutex;
|
||||
std::condition_variable_any m_cond;
|
||||
std::size_t m_count;
|
||||
duration const m_period;
|
||||
boost::asio::io_service& m_ios;
|
||||
boost::asio::deadline_timer m_timer;
|
||||
bool m_cancel;
|
||||
|
||||
public:
|
||||
io_latency_probe (duration const& period,
|
||||
boost::asio::io_service& ios)
|
||||
: m_count (1)
|
||||
, m_period (period)
|
||||
, m_ios (ios)
|
||||
, m_timer (m_ios)
|
||||
, m_cancel (false)
|
||||
{
|
||||
}
|
||||
|
||||
~io_latency_probe ()
|
||||
{
|
||||
std::unique_lock <decltype (m_mutex)> lock (m_mutex);
|
||||
cancel (lock, true);
|
||||
}
|
||||
|
||||
/** Return the io_service associated with the latency probe. */
|
||||
/** @{ */
|
||||
boost::asio::io_service& get_io_service ()
|
||||
{
|
||||
return m_ios;
|
||||
}
|
||||
|
||||
boost::asio::io_service const& get_io_service () const
|
||||
{
|
||||
return m_ios;
|
||||
}
|
||||
/** @} */
|
||||
|
||||
/** Cancel all pending i/o.
|
||||
Any handlers which have already been queued will still be called.
|
||||
*/
|
||||
/** @{ */
|
||||
void cancel ()
|
||||
{
|
||||
std::unique_lock <decltype(m_mutex)> lock (m_mutex);
|
||||
cancel (lock, true);
|
||||
}
|
||||
|
||||
void cancel_async ()
|
||||
{
|
||||
std::unique_lock <decltype(m_mutex)> lock (m_mutex);
|
||||
cancel (lock, false);
|
||||
}
|
||||
/** @} */
|
||||
|
||||
/** Measure one sample of i/o latency.
|
||||
Handler will be called with this signature:
|
||||
void Handler (Duration d);
|
||||
*/
|
||||
template <class Handler>
|
||||
void sample_one (Handler&& handler)
|
||||
{
|
||||
std::lock_guard <decltype(m_mutex)> lock (m_mutex);
|
||||
if (m_cancel)
|
||||
throw std::logic_error ("io_latency_probe is canceled");
|
||||
m_ios.post (sample_op <Handler> (
|
||||
std::forward <Handler> (handler),
|
||||
Clock::now(), false, this));
|
||||
}
|
||||
|
||||
/** Initiate continuous i/o latency sampling.
|
||||
Handler will be called with this signature:
|
||||
void Handler (std::chrono::milliseconds);
|
||||
*/
|
||||
template <class Handler>
|
||||
void sample (Handler&& handler)
|
||||
{
|
||||
std::lock_guard <decltype(m_mutex)> lock (m_mutex);
|
||||
if (m_cancel)
|
||||
throw std::logic_error ("io_latency_probe is canceled");
|
||||
m_ios.post (sample_op <Handler> (
|
||||
std::forward <Handler> (handler),
|
||||
Clock::now(), true, this));
|
||||
}
|
||||
|
||||
private:
|
||||
void cancel (std::unique_lock <decltype (m_mutex)>& lock,
|
||||
bool wait)
|
||||
{
|
||||
if (! m_cancel)
|
||||
{
|
||||
--m_count;
|
||||
m_cancel = true;
|
||||
}
|
||||
|
||||
if (wait)
|
||||
#ifdef BOOST_NO_CXX11_LAMBDAS
|
||||
while (m_count != 0)
|
||||
m_cond.wait (lock);
|
||||
#else
|
||||
m_cond.wait (lock, [this] {
|
||||
return this->m_count == 0; });
|
||||
#endif
|
||||
}
|
||||
|
||||
void addref ()
|
||||
{
|
||||
std::lock_guard <decltype(m_mutex)> lock (m_mutex);
|
||||
++m_count;
|
||||
}
|
||||
|
||||
void release ()
|
||||
{
|
||||
std::lock_guard <decltype(m_mutex)> lock (m_mutex);
|
||||
if (--m_count == 0)
|
||||
m_cond.notify_all ();
|
||||
}
|
||||
|
||||
template <class Handler>
|
||||
struct sample_op
|
||||
{
|
||||
Handler m_handler;
|
||||
time_point m_start;
|
||||
bool m_repeat;
|
||||
io_latency_probe* m_probe;
|
||||
|
||||
sample_op (Handler const& handler, time_point const& start,
|
||||
bool repeat, io_latency_probe* probe)
|
||||
: m_handler (handler)
|
||||
, m_start (start)
|
||||
, m_repeat (repeat)
|
||||
, m_probe (probe)
|
||||
{
|
||||
m_probe->addref();
|
||||
}
|
||||
|
||||
sample_op (sample_op const& other)
|
||||
: m_handler (other.m_handler)
|
||||
, m_start (other.m_start)
|
||||
, m_probe (other.m_probe)
|
||||
{
|
||||
m_probe->addref();
|
||||
}
|
||||
|
||||
~sample_op ()
|
||||
{
|
||||
m_probe->release();
|
||||
}
|
||||
|
||||
void operator() () const
|
||||
{
|
||||
typename Clock::time_point const now (Clock::now());
|
||||
typename Clock::duration const elapsed (now - m_start);
|
||||
|
||||
m_handler (elapsed);
|
||||
|
||||
{
|
||||
std::lock_guard <decltype (m_probe->m_mutex)
|
||||
> lock (m_probe->m_mutex);
|
||||
if (m_probe->m_cancel)
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_repeat)
|
||||
{
|
||||
// Calculate when we want to sample again, and
|
||||
// adjust for the expected latency.
|
||||
//
|
||||
typename Clock::time_point const when (
|
||||
now + m_probe->m_period - 2 * elapsed);
|
||||
|
||||
if (when <= now)
|
||||
{
|
||||
// The latency is too high to maintain the desired
|
||||
// period so don't bother with a timer.
|
||||
//
|
||||
m_probe->m_ios.post (sample_op <Handler> (
|
||||
m_handler, now, m_repeat, m_probe));
|
||||
}
|
||||
else
|
||||
{
|
||||
boost::posix_time::microseconds mms (
|
||||
std::chrono::duration_cast <
|
||||
std::chrono::microseconds> (
|
||||
when - now).count ());
|
||||
m_probe->m_timer.expires_from_now (mms);
|
||||
m_probe->m_timer.async_wait (sample_op <Handler> (
|
||||
m_handler, now, m_repeat, m_probe));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void operator () (boost::system::error_code const& ec)
|
||||
{
|
||||
typename Clock::time_point const now (Clock::now());
|
||||
m_probe->m_ios.post (sample_op <Handler> (
|
||||
m_handler, now, m_repeat, m_probe));
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -24,6 +24,7 @@
|
||||
|
||||
#include "impl/abstract_clock.cpp"
|
||||
#include "impl/chrono_io.cpp"
|
||||
#include "impl/basic_seconds_clock.cpp"
|
||||
|
||||
#include "impl/CPUMeter.cpp"
|
||||
#include "impl/RelativeTime.cpp"
|
||||
|
||||
@@ -72,15 +72,15 @@ public:
|
||||
virtual bool is_steady () const = 0;
|
||||
|
||||
/** Returns the current time. */
|
||||
virtual time_point now () = 0;
|
||||
virtual time_point now () const = 0;
|
||||
|
||||
/** Convert the specified time point to a string. */
|
||||
/** @{ */
|
||||
virtual std::string to_string (time_point const& tp) = 0;
|
||||
virtual std::string to_string (time_point const& tp) const = 0;
|
||||
|
||||
template <class Duration2>
|
||||
std::string to_string (
|
||||
std::chrono::time_point <abstract_clock, Duration2> const& tp)
|
||||
std::chrono::time_point <abstract_clock, Duration2> const& tp) const
|
||||
{
|
||||
return to_string (
|
||||
std::chrono::time_point_cast <Duration> (tp));
|
||||
@@ -88,7 +88,7 @@ public:
|
||||
/** @} */
|
||||
|
||||
/** Returning elapsed ticks since the epoch. */
|
||||
rep elapsed ()
|
||||
rep elapsed () const
|
||||
{
|
||||
return now().time_since_epoch().count();
|
||||
}
|
||||
@@ -109,7 +109,7 @@ struct basic_abstract_clock_wrapper : public abstract_clock <Duration>
|
||||
return TrivialClock::is_steady;
|
||||
}
|
||||
|
||||
time_point now ()
|
||||
time_point now () const
|
||||
{
|
||||
return time_point (duration (
|
||||
std::chrono::duration_cast <duration> (
|
||||
@@ -121,9 +121,9 @@ template <class TrivialClock, class Duration>
|
||||
struct abstract_clock_wrapper
|
||||
: public basic_abstract_clock_wrapper <TrivialClock, Duration>
|
||||
{
|
||||
// generic conversion displays the duration
|
||||
// generic conversion displays the duration
|
||||
std::string to_string (typename basic_abstract_clock_wrapper <
|
||||
TrivialClock, Duration>::time_point const& tp)
|
||||
TrivialClock, Duration>::time_point const& tp) const
|
||||
{
|
||||
std::stringstream ss;
|
||||
ss << tp.time_since_epoch();
|
||||
|
||||
237
src/beast/beast/chrono/basic_seconds_clock.h
Normal file
237
src/beast/beast/chrono/basic_seconds_clock.h
Normal file
@@ -0,0 +1,237 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CHRONO_BASIC_SECONDS_CLOCK_H_INCLUDED
|
||||
#define BEAST_CHRONO_BASIC_SECONDS_CLOCK_H_INCLUDED
|
||||
|
||||
#include <algorithm>
|
||||
#include <chrono>
|
||||
|
||||
#ifndef BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND
|
||||
# ifdef _MSC_VER
|
||||
// Visual Studio 2012, 2013 have a bug in std::thread that
|
||||
// causes a hang on exit, in the library function atexit()
|
||||
# if BEAST_USE_BOOST_FEATURES
|
||||
# define BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND 1
|
||||
# else
|
||||
# define BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND 0
|
||||
# endif
|
||||
# else
|
||||
# define BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND
|
||||
# include <boost/version.hpp>
|
||||
# if BOOST_VERSION >= 105500
|
||||
# include <boost/thread/thread.hpp>
|
||||
# include <boost/thread/mutex.hpp>
|
||||
# include <boost/thread/condition_variable.hpp>
|
||||
# include <boost/chrono.hpp>
|
||||
# else
|
||||
# error "Boost version 1.55.0 or later is required"
|
||||
# endif
|
||||
#else
|
||||
# include <condition_variable>
|
||||
# include <mutex>
|
||||
# include <thread>
|
||||
#endif
|
||||
|
||||
#include "../chrono/chrono_util.h"
|
||||
|
||||
namespace beast {
|
||||
|
||||
namespace detail {
|
||||
|
||||
class seconds_clock_worker
|
||||
{
|
||||
public:
|
||||
virtual void sample () = 0;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// Updates the clocks
|
||||
class seconds_clock_thread
|
||||
{
|
||||
public:
|
||||
#if BEAST_BASIC_SECONDS_CLOCK_BOOST_WORKAROUND
|
||||
typedef boost::mutex mutex;
|
||||
typedef boost::condition_variable cond_var;
|
||||
typedef boost::lock_guard <mutex> lock_guard;
|
||||
typedef boost::unique_lock <mutex> unique_lock;
|
||||
typedef boost::chrono::steady_clock clock_type;
|
||||
typedef boost::chrono::seconds seconds;
|
||||
typedef boost::thread thread;
|
||||
#else
|
||||
typedef std::mutex mutex;
|
||||
typedef std::condition_variable cond_var;
|
||||
typedef std::lock_guard <mutex> lock_guard;
|
||||
typedef std::unique_lock <mutex> unique_lock;
|
||||
typedef std::chrono::steady_clock clock_type;
|
||||
typedef std::chrono::seconds seconds;
|
||||
typedef std::thread thread;
|
||||
#endif
|
||||
typedef std::vector <seconds_clock_worker*> workers;
|
||||
|
||||
bool m_stop;
|
||||
mutex m_mutex;
|
||||
cond_var m_cond;
|
||||
workers m_workers;
|
||||
thread m_thread;
|
||||
|
||||
seconds_clock_thread ()
|
||||
: m_stop (false)
|
||||
{
|
||||
m_thread = thread (std::bind(
|
||||
&seconds_clock_thread::run, this));
|
||||
}
|
||||
|
||||
~seconds_clock_thread ()
|
||||
{
|
||||
{
|
||||
lock_guard lock (m_mutex);
|
||||
m_stop = true;
|
||||
}
|
||||
m_cond.notify_all();
|
||||
m_thread.join ();
|
||||
}
|
||||
|
||||
void add (seconds_clock_worker& w)
|
||||
{
|
||||
lock_guard lock (m_mutex);
|
||||
m_workers.push_back (&w);
|
||||
}
|
||||
|
||||
void remove (seconds_clock_worker& w)
|
||||
{
|
||||
lock_guard lock (m_mutex);
|
||||
m_workers.erase (std::find (
|
||||
m_workers.begin (), m_workers.end(), &w));
|
||||
}
|
||||
|
||||
void run ()
|
||||
{
|
||||
unique_lock lock (m_mutex);;
|
||||
|
||||
for (;;)
|
||||
{
|
||||
for (auto iter : m_workers)
|
||||
iter->sample();
|
||||
|
||||
clock_type::time_point const when (
|
||||
floor <seconds> (
|
||||
clock_type::now().time_since_epoch()) +
|
||||
seconds (1));
|
||||
|
||||
if (m_cond.wait_until (lock, when, [this]{ return m_stop; }))
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
static seconds_clock_thread& instance ()
|
||||
{
|
||||
static seconds_clock_thread singleton;
|
||||
return singleton;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** A clock whose minimum resolution is one second.
|
||||
The purpose of this class is to optimize the performance of the now()
|
||||
member function call. It uses a dedicated thread that wakes up at least
|
||||
once per second to sample the requested trivial clock.
|
||||
@tparam TrivialClock The clock to sample.
|
||||
*/
|
||||
template <class TrivialClock>
|
||||
class basic_seconds_clock
|
||||
{
|
||||
public:
|
||||
typedef std::chrono::seconds resolution;
|
||||
typedef typename resolution::rep rep;
|
||||
typedef typename resolution::period period;
|
||||
typedef std::chrono::duration <rep, period> duration;
|
||||
typedef std::chrono::time_point <basic_seconds_clock> time_point;
|
||||
|
||||
static bool const is_steady = TrivialClock::is_steady;
|
||||
|
||||
static time_point now ()
|
||||
{
|
||||
// Make sure the thread is constructed before the
|
||||
// worker otherwise we will crash during destruction
|
||||
// of objects with static storage duration.
|
||||
struct initializer
|
||||
{
|
||||
initializer ()
|
||||
{
|
||||
detail::seconds_clock_thread::instance();
|
||||
}
|
||||
};
|
||||
static initializer init;
|
||||
|
||||
struct worker : detail::seconds_clock_worker
|
||||
{
|
||||
typedef std::mutex mutex;
|
||||
typedef std::lock_guard <mutex> lock_guard;
|
||||
|
||||
time_point m_now;
|
||||
mutex m_mutex;
|
||||
|
||||
static time_point get_now ()
|
||||
{
|
||||
return time_point (floor <resolution> (
|
||||
TrivialClock::now().time_since_epoch()));
|
||||
}
|
||||
|
||||
worker ()
|
||||
: m_now (get_now ())
|
||||
{
|
||||
detail::seconds_clock_thread::instance().add (*this);
|
||||
}
|
||||
|
||||
~worker ()
|
||||
{
|
||||
detail::seconds_clock_thread::instance().remove (*this);
|
||||
}
|
||||
|
||||
time_point now()
|
||||
{
|
||||
lock_guard lock (m_mutex);
|
||||
return m_now;
|
||||
}
|
||||
|
||||
void sample ()
|
||||
{
|
||||
lock_guard lock (m_mutex);
|
||||
m_now = get_now ();
|
||||
}
|
||||
};
|
||||
|
||||
static worker w;
|
||||
|
||||
return w.now ();
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
66
src/beast/beast/chrono/chrono_util.h
Normal file
66
src/beast/beast/chrono/chrono_util.h
Normal file
@@ -0,0 +1,66 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CHRONO_UTIL_H_INCLUDED
|
||||
#define BEAST_CHRONO_UTIL_H_INCLUDED
|
||||
|
||||
// From Howard Hinnant
|
||||
// http://home.roadrunner.com/~hinnant/duration_io/chrono_util.html
|
||||
|
||||
// round down
|
||||
template <class To, class Rep, class Period>
|
||||
To floor(std::chrono::duration <Rep, Period> const& d)
|
||||
{
|
||||
To t = std::chrono::duration_cast<To>(d);
|
||||
if (t > d)
|
||||
--t;
|
||||
return t;
|
||||
}
|
||||
|
||||
// round to nearest, to even on tie
|
||||
template <class To, class Rep, class Period>
|
||||
To round (std::chrono::duration <Rep, Period> const& d)
|
||||
{
|
||||
To t0 = std::chrono::duration_cast<To>(d);
|
||||
To t1 = t0;
|
||||
++t1;
|
||||
auto diff0 = d - t0;
|
||||
auto diff1 = t1 - d;
|
||||
if (diff0 == diff1)
|
||||
{
|
||||
if (t0.count() & 1)
|
||||
return t1;
|
||||
return t0;
|
||||
}
|
||||
else if (diff0 < diff1)
|
||||
return t0;
|
||||
return t1;
|
||||
}
|
||||
|
||||
// round up
|
||||
template <class To, class Rep, class Period>
|
||||
To ceil (std::chrono::duration <Rep, Period> const& d)
|
||||
{
|
||||
To t = std::chrono::duration_cast<To>(d);
|
||||
if (t < d)
|
||||
++t;
|
||||
return t;
|
||||
}
|
||||
|
||||
#endif
|
||||
46
src/beast/beast/chrono/impl/basic_seconds_clock.cpp
Normal file
46
src/beast/beast/chrono/impl/basic_seconds_clock.cpp
Normal file
@@ -0,0 +1,46 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../basic_seconds_clock.h"
|
||||
|
||||
#include "../../Config.h"
|
||||
#include "../../../modules/beast_core/beast_core.h" // for UnitTest
|
||||
|
||||
namespace beast {
|
||||
|
||||
class basic_seconds_clock_Tests : public UnitTest
|
||||
{
|
||||
public:
|
||||
void runTest ()
|
||||
{
|
||||
beginTestCase ("now");
|
||||
|
||||
basic_seconds_clock <std::chrono::steady_clock>::now ();
|
||||
|
||||
pass ();
|
||||
}
|
||||
|
||||
basic_seconds_clock_Tests() : UnitTest("basic_seconds_clock", "beast")
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
static basic_seconds_clock_Tests basic_seconds_clock_tests;
|
||||
|
||||
}
|
||||
@@ -48,12 +48,12 @@ public:
|
||||
return IsSteady;
|
||||
}
|
||||
|
||||
time_point now ()
|
||||
time_point now () const
|
||||
{
|
||||
return m_now;
|
||||
}
|
||||
|
||||
std::string to_string (time_point const& tp)
|
||||
std::string to_string (time_point const& tp) const
|
||||
{
|
||||
std::stringstream ss;
|
||||
ss << tp.time_since_epoch() << " from start";
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
#error "PlatformConfig.h must come first!"
|
||||
#endif
|
||||
|
||||
#include <assert.h>
|
||||
|
||||
// This file defines miscellaneous macros for debugging, assertions, etc.
|
||||
|
||||
#if BEAST_FORCE_DEBUG
|
||||
@@ -109,6 +111,7 @@ extern void beast_reportFatalError (char const* message, char const* fileName, i
|
||||
*/
|
||||
#define BDBG(dbgtext) { beast::String tempDbgBuf; tempDbgBuf << dbgtext; beast::Logger::outputDebugString (tempDbgBuf); }
|
||||
|
||||
#if 0
|
||||
/** This will always cause an assertion failure.
|
||||
It is only compiled in a debug build, (unless BEAST_LOG_ASSERTIONS is enabled for your build).
|
||||
@see bassert
|
||||
@@ -122,6 +125,11 @@ extern void beast_reportFatalError (char const* message, char const* fileName, i
|
||||
@see bassertfalse
|
||||
*/
|
||||
#define bassert(expression) { if (! (expression)) beast_reportFatalError(#expression,__FILE__,__LINE__); }
|
||||
#else
|
||||
|
||||
#define bassertfalse assert(false)
|
||||
#define bassert(expression) assert(expression)
|
||||
#endif
|
||||
|
||||
#else
|
||||
|
||||
|
||||
@@ -19,4 +19,4 @@
|
||||
|
||||
#include "BeastConfig.h"
|
||||
|
||||
#include "shared_ptr.h"
|
||||
#include "impl/aged_associative_container.cpp"
|
||||
@@ -17,16 +17,18 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_STL_SHARED_PTR_H_INCLUDED
|
||||
#define BEAST_STL_SHARED_PTR_H_INCLUDED
|
||||
#ifndef BEAST_CONTAINER_AGED_CONTAINER_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_CONTAINER_H_INCLUDED
|
||||
|
||||
#include <boost/smart_ptr.hpp>
|
||||
#include <type_traits>
|
||||
|
||||
namespace beast {
|
||||
|
||||
using boost::shared_ptr;
|
||||
using boost::make_shared;
|
||||
using boost::enable_shared_from_this;
|
||||
template <class T>
|
||||
struct is_aged_container
|
||||
: std::false_type
|
||||
{
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
51
src/beast/beast/container/aged_container_utility.h
Normal file
51
src/beast/beast/container/aged_container_utility.h
Normal file
@@ -0,0 +1,51 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_CONTAINER_UTILITY_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_CONTAINER_UTILITY_H_INCLUDED
|
||||
|
||||
#include "aged_container.h"
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
namespace beast {
|
||||
|
||||
/** Expire aged container items past the specified age. */
|
||||
template <class AgedContainer, class Rep, class Period>
|
||||
typename std::enable_if <
|
||||
is_aged_container <AgedContainer>::value,
|
||||
std::size_t
|
||||
>::type
|
||||
expire (AgedContainer& c, std::chrono::duration <Rep, Period> const& age)
|
||||
{
|
||||
std::size_t n (0);
|
||||
auto const expired (c.clock().now() - age);
|
||||
for (auto iter (c.chronological.cbegin());
|
||||
iter != c.chronological.cend() &&
|
||||
iter.when() <= expired;)
|
||||
{
|
||||
iter = c.erase (iter);
|
||||
++n;
|
||||
}
|
||||
return n;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
43
src/beast/beast/container/aged_map.h
Normal file
43
src/beast/beast/container/aged_map.h
Normal file
@@ -0,0 +1,43 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_MAP_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_MAP_H_INCLUDED
|
||||
|
||||
#include "detail/aged_ordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class T,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Compare = std::less <Key>,
|
||||
class Allocator = std::allocator <std::pair <Key const, T>>
|
||||
>
|
||||
using aged_map = detail::aged_ordered_container <
|
||||
false, true, Key, T, Duration, Compare, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
43
src/beast/beast/container/aged_multimap.h
Normal file
43
src/beast/beast/container/aged_multimap.h
Normal file
@@ -0,0 +1,43 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_MULTIMAP_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_MULTIMAP_H_INCLUDED
|
||||
|
||||
#include "detail/aged_ordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class T,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Compare = std::less <Key>,
|
||||
class Allocator = std::allocator <std::pair <Key const, T>>
|
||||
>
|
||||
using aged_multimap = detail::aged_ordered_container <
|
||||
true, true, Key, T, Duration, Compare, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
42
src/beast/beast/container/aged_multiset.h
Normal file
42
src/beast/beast/container/aged_multiset.h
Normal file
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_MULTISET_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_MULTISET_H_INCLUDED
|
||||
|
||||
#include "detail/aged_ordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Compare = std::less <Key>,
|
||||
class Allocator = std::allocator <Key>
|
||||
>
|
||||
using aged_multiset = detail::aged_ordered_container <
|
||||
true, false, Key, void, Duration, Compare, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
42
src/beast/beast/container/aged_set.h
Normal file
42
src/beast/beast/container/aged_set.h
Normal file
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_SET_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_SET_H_INCLUDED
|
||||
|
||||
#include "detail/aged_ordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Compare = std::less <Key>,
|
||||
class Allocator = std::allocator <Key>
|
||||
>
|
||||
using aged_set = detail::aged_ordered_container <
|
||||
false, false, Key, void, Duration, Compare, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
44
src/beast/beast/container/aged_unordered_map.h
Normal file
44
src/beast/beast/container/aged_unordered_map.h
Normal file
@@ -0,0 +1,44 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_UNORDERED_MAP_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_UNORDERED_MAP_H_INCLUDED
|
||||
|
||||
#include "detail/aged_unordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class T,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Hash = std::hash <Key>,
|
||||
class KeyEqual = std::equal_to <Key>,
|
||||
class Allocator = std::allocator <std::pair <Key const, T>>
|
||||
>
|
||||
using aged_unordered_map = detail::aged_unordered_container <
|
||||
false, true, Key, T, Duration, Hash, KeyEqual, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
44
src/beast/beast/container/aged_unordered_multimap.h
Normal file
44
src/beast/beast/container/aged_unordered_multimap.h
Normal file
@@ -0,0 +1,44 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_UNORDERED_MULTIMAP_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_UNORDERED_MULTIMAP_H_INCLUDED
|
||||
|
||||
#include "detail/aged_unordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class T,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Hash = std::hash <Key>,
|
||||
class KeyEqual = std::equal_to <Key>,
|
||||
class Allocator = std::allocator <std::pair <Key const, T>>
|
||||
>
|
||||
using aged_unordered_multimap = detail::aged_unordered_container <
|
||||
true, true, Key, T, Duration, Hash, KeyEqual, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
43
src/beast/beast/container/aged_unordered_multiset.h
Normal file
43
src/beast/beast/container/aged_unordered_multiset.h
Normal file
@@ -0,0 +1,43 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_UNORDERED_MULTISET_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_UNORDERED_MULTISET_H_INCLUDED
|
||||
|
||||
#include "detail/aged_unordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Hash = std::hash <Key>,
|
||||
class KeyEqual = std::equal_to <Key>,
|
||||
class Allocator = std::allocator <Key>
|
||||
>
|
||||
using aged_unordered_multiset = detail::aged_unordered_container <
|
||||
true, false, Key, void, Duration, Hash, KeyEqual, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
43
src/beast/beast/container/aged_unordered_set.h
Normal file
43
src/beast/beast/container/aged_unordered_set.h
Normal file
@@ -0,0 +1,43 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_UNORDERED_SET_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_UNORDERED_SET_H_INCLUDED
|
||||
|
||||
#include "detail/aged_unordered_container.h"
|
||||
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <
|
||||
class Key,
|
||||
class Duration = std::chrono::seconds,
|
||||
class Hash = std::hash <Key>,
|
||||
class KeyEqual = std::equal_to <Key>,
|
||||
class Allocator = std::allocator <Key>
|
||||
>
|
||||
using aged_unordered_set = detail::aged_unordered_container <
|
||||
false, false, Key, void, Duration, Hash, KeyEqual, Allocator>;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -17,32 +17,38 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_UTILITY_ENABLEIF_H_INCLUDED
|
||||
#define BEAST_UTILITY_ENABLEIF_H_INCLUDED
|
||||
#ifndef BEAST_CONTAINER_AGED_ASSOCIATIVE_CONTAINER_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_ASSOCIATIVE_CONTAINER_H_INCLUDED
|
||||
|
||||
#include "../type_traits/IntegralConstant.h"
|
||||
#include <type_traits>
|
||||
|
||||
namespace beast
|
||||
namespace beast {
|
||||
namespace detail {
|
||||
|
||||
// Extracts the key portion of value
|
||||
template <bool maybe_map>
|
||||
struct aged_associative_container_extract_t
|
||||
{
|
||||
template <class Value>
|
||||
decltype (Value::first) const&
|
||||
operator() (Value const& value) const
|
||||
{
|
||||
return value.first;
|
||||
}
|
||||
};
|
||||
|
||||
template <bool Enable, class T = void>
|
||||
struct EnableIfBool : TrueType { typedef T type; };
|
||||
|
||||
template <class T>
|
||||
struct EnableIfBool <false, T> : FalseType { };
|
||||
|
||||
template <class Cond, class T = void>
|
||||
struct EnableIf : public EnableIfBool <Cond::value, T> { };
|
||||
|
||||
template <bool Enable, class T = void>
|
||||
struct DisableIfBool : FalseType { typedef T type; };
|
||||
|
||||
template <class T>
|
||||
struct DisableIfBool <true, T> { };
|
||||
|
||||
template <class Cond, class T = void>
|
||||
struct DisableIf : public DisableIfBool <Cond::value, T> { };
|
||||
template <>
|
||||
struct aged_associative_container_extract_t <false>
|
||||
{
|
||||
template <class Value>
|
||||
Value const&
|
||||
operator() (Value const& value) const
|
||||
{
|
||||
return value;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
156
src/beast/beast/container/detail/aged_container_iterator.h
Normal file
156
src/beast/beast/container/detail/aged_container_iterator.h
Normal file
@@ -0,0 +1,156 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CONTAINER_AGED_CONTAINER_ITERATOR_H_INCLUDED
|
||||
#define BEAST_CONTAINER_AGED_CONTAINER_ITERATOR_H_INCLUDED
|
||||
|
||||
#include <iterator>
|
||||
#include <type_traits>
|
||||
|
||||
namespace beast {
|
||||
|
||||
template <bool, bool, class, class, class, class, class>
|
||||
class aged_ordered_container;
|
||||
|
||||
namespace detail {
|
||||
|
||||
// Idea for Base template argument to prevent having to repeat
|
||||
// the base class declaration comes from newbiz on ##c++/Freenode
|
||||
//
|
||||
// If Iterator is SCARY then this iterator will be as well.
|
||||
template <
|
||||
bool is_const,
|
||||
class Iterator,
|
||||
class Base =
|
||||
std::iterator <
|
||||
typename std::iterator_traits <Iterator>::iterator_category,
|
||||
typename std::conditional <is_const,
|
||||
typename Iterator::value_type::stashed::value_type const,
|
||||
typename Iterator::value_type::stashed::value_type>::type,
|
||||
typename std::iterator_traits <Iterator>::difference_type>
|
||||
>
|
||||
class aged_container_iterator
|
||||
: public Base
|
||||
{
|
||||
public:
|
||||
typedef typename Iterator::value_type::stashed::time_point time_point;
|
||||
|
||||
aged_container_iterator ()
|
||||
{
|
||||
}
|
||||
|
||||
template <class OtherIterator, class OtherBase>
|
||||
aged_container_iterator (aged_container_iterator <
|
||||
false, OtherIterator, OtherBase> const& other)
|
||||
: m_iter (other.m_iter)
|
||||
{
|
||||
}
|
||||
|
||||
template <bool other_is_const, class OtherIterator, class OtherBase>
|
||||
aged_container_iterator& operator= (aged_container_iterator <
|
||||
other_is_const, OtherIterator, OtherBase> const& other)
|
||||
{
|
||||
m_iter = other.m_iter;
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <bool other_is_const, class OtherIterator, class OtherBase>
|
||||
bool operator== (aged_container_iterator <
|
||||
other_is_const, OtherIterator, OtherBase> const& other) const
|
||||
{
|
||||
return m_iter == other.m_iter;
|
||||
}
|
||||
|
||||
template <bool other_is_const, class OtherIterator, class OtherBase>
|
||||
bool operator!= (aged_container_iterator <
|
||||
other_is_const, OtherIterator, OtherBase> const& other) const
|
||||
{
|
||||
return m_iter != other.m_iter;
|
||||
}
|
||||
|
||||
aged_container_iterator& operator++ ()
|
||||
{
|
||||
++m_iter;
|
||||
return *this;
|
||||
}
|
||||
|
||||
aged_container_iterator operator++ (int)
|
||||
{
|
||||
aged_container_iterator const prev (*this);
|
||||
++m_iter;
|
||||
return prev;
|
||||
}
|
||||
|
||||
aged_container_iterator& operator-- ()
|
||||
{
|
||||
--m_iter;
|
||||
return *this;
|
||||
}
|
||||
|
||||
aged_container_iterator operator-- (int)
|
||||
{
|
||||
aged_container_iterator const prev (*this);
|
||||
--m_iter;
|
||||
return prev;
|
||||
}
|
||||
|
||||
typename Base::reference operator* () const
|
||||
{
|
||||
return m_iter->value;
|
||||
}
|
||||
|
||||
typename Base::pointer operator-> () const
|
||||
{
|
||||
return &m_iter->value;
|
||||
}
|
||||
|
||||
time_point const& when () const
|
||||
{
|
||||
return m_iter->when;
|
||||
}
|
||||
|
||||
private:
|
||||
template <bool, bool, class, class, class, class, class>
|
||||
friend class aged_ordered_container;
|
||||
|
||||
template <bool, bool, class, class, class, class, class, class>
|
||||
friend class aged_unordered_container;
|
||||
|
||||
template <bool, class, class>
|
||||
friend class aged_container_iterator;
|
||||
|
||||
template <class OtherIterator>
|
||||
aged_container_iterator (OtherIterator const& iter)
|
||||
: m_iter (iter)
|
||||
{
|
||||
}
|
||||
|
||||
Iterator const& iterator() const
|
||||
{
|
||||
return m_iter;
|
||||
}
|
||||
|
||||
Iterator m_iter;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
1926
src/beast/beast/container/detail/aged_ordered_container.h
Normal file
1926
src/beast/beast/container/detail/aged_ordered_container.h
Normal file
File diff suppressed because it is too large
Load Diff
2483
src/beast/beast/container/detail/aged_unordered_container.h
Normal file
2483
src/beast/beast/container/detail/aged_unordered_container.h
Normal file
File diff suppressed because it is too large
Load Diff
1460
src/beast/beast/container/impl/aged_associative_container.cpp
Normal file
1460
src/beast/beast/container/impl/aged_associative_container.cpp
Normal file
File diff suppressed because it is too large
Load Diff
@@ -22,7 +22,8 @@
|
||||
|
||||
#include "../Config.h"
|
||||
#include "../CStdInt.h"
|
||||
#include "../FixedArray.h"
|
||||
|
||||
#include <array>
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
@@ -36,7 +37,7 @@ enum
|
||||
};
|
||||
|
||||
/** A container suitable for holding the resulting hash. */
|
||||
typedef FixedArray <uint8, digestLength> digest_type;
|
||||
typedef std::array <uint8, digestLength> digest_type;
|
||||
|
||||
namespace detail {
|
||||
struct Context
|
||||
@@ -85,7 +86,7 @@ public:
|
||||
|
||||
digest_type& finish (digest_type& digest)
|
||||
{
|
||||
finish (digest.c_array());
|
||||
finish (digest.data());
|
||||
return digest;
|
||||
}
|
||||
|
||||
|
||||
@@ -334,7 +334,7 @@ public:
|
||||
}
|
||||
*lhs++ = UInt (part);
|
||||
}
|
||||
bassert (carry == 0) // overflow
|
||||
bassert (carry == 0); // overflow
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@ void* hash (void const* buffer, std::size_t bytes, void* digest)
|
||||
|
||||
digest_type& hash (void const* buffer, std::size_t bytes, digest_type& digest)
|
||||
{
|
||||
hash (buffer, bytes, digest.c_array());
|
||||
hash (buffer, bytes, digest.data());
|
||||
return digest;
|
||||
}
|
||||
|
||||
|
||||
90
src/beast/beast/cxx14/algorithm.h
Normal file
90
src/beast/beast/cxx14/algorithm.h
Normal file
@@ -0,0 +1,90 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CXX14_ALGORITHM_H_INCLUDED
|
||||
#define BEAST_CXX14_ALGORITHM_H_INCLUDED
|
||||
|
||||
#include "config.h"
|
||||
#include "functional.h"
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
namespace std {
|
||||
|
||||
namespace detail {
|
||||
|
||||
template <class Pred, class FwdIt1, class FwdIt2>
|
||||
bool equal (FwdIt1 first1, FwdIt1 last1,
|
||||
FwdIt2 first2, FwdIt2 last2, Pred pred,
|
||||
std::input_iterator_tag, std::input_iterator_tag)
|
||||
{
|
||||
for (; first1 != last1 && first2 != last2; ++first1, ++first2)
|
||||
if (! pred (*first1, *first2))
|
||||
return false;
|
||||
return first1 == last1 && first2 == last2;
|
||||
}
|
||||
|
||||
template <class Pred, class RanIt1, class RanIt2>
|
||||
bool equal (RanIt1 first1, RanIt1 last1,
|
||||
RanIt2 first2, RanIt2 last2, Pred pred,
|
||||
random_access_iterator_tag,
|
||||
random_access_iterator_tag )
|
||||
{
|
||||
if (std::distance (first1, last1) !=
|
||||
std::distance (first2, last2))
|
||||
return false;
|
||||
for (; first1 != last1; ++first1, ++first2)
|
||||
if (! pred (*first1, *first2))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/** C++14 implementation of std::equal. */
|
||||
/** @{ */
|
||||
template <class FwdIt1, class FwdIt2>
|
||||
bool equal (FwdIt1 first1, FwdIt1 last1,
|
||||
FwdIt2 first2, FwdIt2 last2)
|
||||
{
|
||||
return std::detail::equal (first1, last1,
|
||||
first2, last2, std::equal_to <void>(),
|
||||
typename std::iterator_traits <
|
||||
FwdIt1>::iterator_category(),
|
||||
typename std::iterator_traits <
|
||||
FwdIt2>::iterator_category());
|
||||
}
|
||||
|
||||
template <class FwdIt1, class FwdIt2, class Pred>
|
||||
bool equal (FwdIt1 first1, FwdIt1 last1,
|
||||
FwdIt2 first2, FwdIt2 last2, Pred pred)
|
||||
{
|
||||
return std::detail::equal <
|
||||
typename std::add_lvalue_reference <Pred>::type> (
|
||||
first1, last1, first2, last2, pred,
|
||||
typename std::iterator_traits <
|
||||
FwdIt1>::iterator_category(),
|
||||
typename std::iterator_traits <
|
||||
FwdIt2>::iterator_category());
|
||||
}
|
||||
/** @} */
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
44
src/beast/beast/cxx14/config.h
Normal file
44
src/beast/beast/cxx14/config.h
Normal file
@@ -0,0 +1,44 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CXX14_CONFIG_H_INCLUDED
|
||||
#define BEAST_CXX14_CONFIG_H_INCLUDED
|
||||
|
||||
// Sets C++14 compatibility configuration macros based on build environment
|
||||
|
||||
// Disables beast c++14 compatibility additions when set to 1
|
||||
//
|
||||
#ifndef BEAST_NO_CXX14_COMPATIBILITY
|
||||
# ifdef _MSC_VER
|
||||
# define BEAST_NO_CXX14_COMPATIBILITY 1
|
||||
# else
|
||||
# define BEAST_NO_CXX14_COMPATIBILITY 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
// Disables beast's make_unique
|
||||
#ifndef BEAST_NO_CXX14_MAKE_UNIQUE
|
||||
# ifdef _MSC_VER
|
||||
# define BEAST_NO_CXX14_MAKE_UNIQUE 1
|
||||
# else
|
||||
# define BEAST_NO_CXX14_MAKE_UNIQUE 0
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#endif
|
||||
53
src/beast/beast/cxx14/functional.h
Normal file
53
src/beast/beast/cxx14/functional.h
Normal file
@@ -0,0 +1,53 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CXX14_FUNCTIONAL_H_INCLUDED
|
||||
#define BEAST_CXX14_FUNCTIONAL_H_INCLUDED
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <functional>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
#if ! BEAST_NO_CXX14_COMPATIBILITY
|
||||
|
||||
namespace std {
|
||||
|
||||
// C++14 implementation of std::equal_to <void> specialization.
|
||||
// This supports heterogeneous comparisons.
|
||||
template <>
|
||||
struct equal_to <void>
|
||||
{
|
||||
// VFALCO NOTE Its not clear how to support is_transparent pre c++14
|
||||
typedef std::true_type is_transparent;
|
||||
|
||||
template <class T, class U>
|
||||
auto operator() (T&& lhs, U&& rhs) const ->
|
||||
decltype (std::forward <T> (lhs) == std::forward <U> (rhs))
|
||||
{
|
||||
return std::forward <T> (lhs) == std::forward <U> (rhs);
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
41
src/beast/beast/cxx14/memory.h
Normal file
41
src/beast/beast/cxx14/memory.h
Normal file
@@ -0,0 +1,41 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CXX14_MEMORY_H_INCLUDED
|
||||
#define BEAST_CXX14_MEMORY_H_INCLUDED
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace std {
|
||||
|
||||
#if ! BEAST_NO_CXX14_MAKE_UNIQUE
|
||||
|
||||
template <class T, class... Args>
|
||||
std::unique_ptr <T> make_unique (Args&&... args)
|
||||
{
|
||||
return std::unique_ptr <T> (new T (std::forward <Args> (args)...));
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
147
src/beast/beast/cxx14/type_traits.h
Normal file
147
src/beast/beast/cxx14/type_traits.h
Normal file
@@ -0,0 +1,147 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_CXX14_TYPE_TRAITS_H_INCLUDED
|
||||
#define BEAST_CXX14_TYPE_TRAITS_H_INCLUDED
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include <tuple>
|
||||
#include <type_traits>
|
||||
#include <utility>
|
||||
|
||||
namespace std {
|
||||
|
||||
// Ideas from Howard Hinnant
|
||||
//
|
||||
// Specializations of is_constructible for pair and tuple which
|
||||
// work around an apparent defect in the standard that causes well
|
||||
// formed expressions involving pairs or tuples of non default-constructible
|
||||
// types to generate compile errors.
|
||||
//
|
||||
template <class T, class U>
|
||||
struct is_constructible <pair <T, U>>
|
||||
: integral_constant <bool,
|
||||
is_default_constructible <T>::value &&
|
||||
is_default_constructible <U>::value>
|
||||
{
|
||||
};
|
||||
|
||||
namespace detail {
|
||||
|
||||
template <bool...>
|
||||
struct compile_time_all;
|
||||
|
||||
template <>
|
||||
struct compile_time_all <>
|
||||
{
|
||||
static const bool value = true;
|
||||
};
|
||||
|
||||
template <bool Arg0, bool ... Argn>
|
||||
struct compile_time_all <Arg0, Argn...>
|
||||
{
|
||||
static const bool value =
|
||||
Arg0 && compile_time_all <Argn...>::value;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
template <class ...T>
|
||||
struct is_constructible <tuple <T...>>
|
||||
: integral_constant <bool,
|
||||
detail::compile_time_all <
|
||||
is_default_constructible <T>::value...>::value>
|
||||
{
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
#if ! BEAST_NO_CXX14_COMPATIBILITY
|
||||
|
||||
// From http://llvm.org/svn/llvm-project/libcxx/trunk/include/type_traits
|
||||
|
||||
// const-volatile modifications:
|
||||
template <class T>
|
||||
using remove_const_t = typename remove_const<T>::type; // C++14
|
||||
template <class T>
|
||||
using remove_volatile_t = typename remove_volatile<T>::type; // C++14
|
||||
template <class T>
|
||||
using remove_cv_t = typename remove_cv<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_const_t = typename add_const<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_volatile_t = typename add_volatile<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_cv_t = typename add_cv<T>::type; // C++14
|
||||
|
||||
// reference modifications:
|
||||
template <class T>
|
||||
using remove_reference_t = typename remove_reference<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_lvalue_reference_t = typename add_lvalue_reference<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_rvalue_reference_t = typename add_rvalue_reference<T>::type; // C++14
|
||||
|
||||
// sign modifications:
|
||||
template <class T>
|
||||
using make_signed_t = typename make_signed<T>::type; // C++14
|
||||
template <class T>
|
||||
using make_unsigned_t = typename make_unsigned<T>::type; // C++14
|
||||
|
||||
// array modifications:
|
||||
template <class T>
|
||||
using remove_extent_t = typename remove_extent<T>::type; // C++14
|
||||
template <class T>
|
||||
using remove_all_extents_t = typename remove_all_extents<T>::type; // C++14
|
||||
|
||||
// pointer modifications:
|
||||
template <class T>
|
||||
using remove_pointer_t = typename remove_pointer<T>::type; // C++14
|
||||
template <class T>
|
||||
using add_pointer_t = typename add_pointer<T>::type; // C++14
|
||||
|
||||
// other transformations:
|
||||
|
||||
#if 0
|
||||
// This is not easy to implement in C++11
|
||||
template <size_t Len, std::size_t Align=std::alignment_of<max_align_t>::value>
|
||||
using aligned_storage_t = typename aligned_storage<Len,Align>::type; // C++14
|
||||
template <std::size_t Len, class... Types>
|
||||
using aligned_union_t = typename aligned_union<Len,Types...>::type; // C++14
|
||||
#endif
|
||||
|
||||
template <class T>
|
||||
using decay_t = typename decay<T>::type; // C++14
|
||||
template <bool b, class T=void>
|
||||
using enable_if_t = typename enable_if<b,T>::type; // C++14
|
||||
template <bool b, class T, class F>
|
||||
using conditional_t = typename conditional<b,T,F>::type; // C++14
|
||||
template <class... T>
|
||||
using common_type_t = typename common_type<T...>::type; // C++14
|
||||
template <class T>
|
||||
using underlying_type_t = typename underlying_type<T>::type; // C++14
|
||||
template <class F, class... ArgTypes>
|
||||
using result_of_t = typename result_of<F(ArgTypes...)>::type; // C++14
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -130,9 +130,6 @@ extern std::size_t hash_value (beast::URL const& url);
|
||||
|
||||
namespace std {
|
||||
|
||||
template <typename T>
|
||||
struct hash;
|
||||
|
||||
template <>
|
||||
struct hash <beast::URL>
|
||||
{
|
||||
|
||||
38
src/beast/beast/insight/Base.h
Normal file
38
src/beast/beast/insight/Base.h
Normal file
@@ -0,0 +1,38 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_INSIGHT_BASE_H_INCLUDED
|
||||
#define BEAST_INSIGHT_BASE_H_INCLUDED
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
/** Base for all metrics and hooks. */
|
||||
class Base
|
||||
{
|
||||
public:
|
||||
virtual ~Base () = 0;
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
40
src/beast/beast/insight/BaseImpl.h
Normal file
40
src/beast/beast/insight/BaseImpl.h
Normal file
@@ -0,0 +1,40 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_INSIGHT_BASEIMPL_H_INCLUDED
|
||||
#define BEAST_INSIGHT_BASEIMPL_H_INCLUDED
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
/** Base for all metrics and hook implementations. */
|
||||
class BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef std::shared_ptr <BaseImpl> ptr;
|
||||
|
||||
virtual ~BaseImpl () = 0;
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -44,6 +44,8 @@ namespace insight {
|
||||
class Collector
|
||||
{
|
||||
public:
|
||||
typedef std::shared_ptr <Collector> ptr;
|
||||
|
||||
virtual ~Collector() = 0;
|
||||
|
||||
/** Create a hook.
|
||||
@@ -71,22 +73,58 @@ public:
|
||||
/** Create a counter with the specified name.
|
||||
@see Counter
|
||||
*/
|
||||
/** @{ */
|
||||
virtual Counter make_counter (std::string const& name) = 0;
|
||||
|
||||
Counter make_counter (std::string const& prefix, std::string const& name)
|
||||
{
|
||||
if (prefix.empty ())
|
||||
return make_counter (name);
|
||||
return make_counter (prefix + "." + name);
|
||||
}
|
||||
/** @} */
|
||||
|
||||
/** Create an event with the specified name.
|
||||
@see Event
|
||||
*/
|
||||
/** @{ */
|
||||
virtual Event make_event (std::string const& name) = 0;
|
||||
|
||||
Event make_event (std::string const& prefix, std::string const& name)
|
||||
{
|
||||
if (prefix.empty ())
|
||||
return make_event (name);
|
||||
return make_event (prefix + "." + name);
|
||||
}
|
||||
/** @} */
|
||||
|
||||
/** Create a gauge with the specified name.
|
||||
@see Gauge
|
||||
*/
|
||||
/** @{ */
|
||||
virtual Gauge make_gauge (std::string const& name) = 0;
|
||||
|
||||
Gauge make_gauge (std::string const& prefix, std::string const& name)
|
||||
{
|
||||
if (prefix.empty ())
|
||||
return make_gauge (name);
|
||||
return make_gauge (prefix + "." + name);
|
||||
}
|
||||
/** @} */
|
||||
|
||||
/** Create a meter with the specified name.
|
||||
@see Meter
|
||||
*/
|
||||
/** @{ */
|
||||
virtual Meter make_meter (std::string const& name) = 0;
|
||||
|
||||
Meter make_meter (std::string const& prefix, std::string const& name)
|
||||
{
|
||||
if (prefix.empty ())
|
||||
return make_meter (name);
|
||||
return make_meter (prefix + "." + name);
|
||||
}
|
||||
/** @} */
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "Base.h"
|
||||
#include "CounterImpl.h"
|
||||
|
||||
namespace beast {
|
||||
@@ -35,7 +36,7 @@ namespace insight {
|
||||
This is a lightweight reference wrapper which is cheap to copy and assign.
|
||||
When the last reference goes away, the metric is no longer collected.
|
||||
*/
|
||||
class Counter
|
||||
class Counter : public Base
|
||||
{
|
||||
public:
|
||||
typedef CounterImpl::value_type value_type;
|
||||
@@ -57,21 +58,6 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
/** Set a handler for polling.
|
||||
If a handler is set, it will be called once per collection interval.
|
||||
This may be used to implement polling style collection instead of
|
||||
push style.
|
||||
|
||||
Handler will be called with this signature:
|
||||
void Handler (Counter const&);
|
||||
*/
|
||||
template <class Handler>
|
||||
void set_handler (Handler handler) const
|
||||
{
|
||||
if (m_impl)
|
||||
m_impl->set_handler (handler);
|
||||
}
|
||||
|
||||
/** Increment the counter. */
|
||||
/** @{ */
|
||||
void increment (value_type amount) const
|
||||
@@ -99,6 +85,11 @@ public:
|
||||
{ increment (-1); return *this; }
|
||||
/** @} */
|
||||
|
||||
std::shared_ptr <CounterImpl> const& impl () const
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
|
||||
private:
|
||||
std::shared_ptr <CounterImpl> m_impl;
|
||||
};
|
||||
|
||||
@@ -20,23 +20,24 @@
|
||||
#ifndef BEAST_INSIGHT_COUNTERIMPL_H_INCLUDED
|
||||
#define BEAST_INSIGHT_COUNTERIMPL_H_INCLUDED
|
||||
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
#include "BaseImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
class Counter;
|
||||
|
||||
class CounterImpl : public std::enable_shared_from_this <CounterImpl>
|
||||
class CounterImpl
|
||||
: public std::enable_shared_from_this <CounterImpl>
|
||||
, public BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef int64 value_type;
|
||||
typedef std::function <void (Counter const&)> HandlerType;
|
||||
|
||||
virtual ~CounterImpl () = 0;
|
||||
virtual void increment (value_type amount) = 0;
|
||||
virtual void set_handler (HandlerType const& handler) = 0;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -20,10 +20,14 @@
|
||||
#ifndef BEAST_INSIGHT_EVENT_H_INCLUDED
|
||||
#define BEAST_INSIGHT_EVENT_H_INCLUDED
|
||||
|
||||
#include <chrono>
|
||||
#include <memory>
|
||||
|
||||
#include "Base.h"
|
||||
#include "EventImpl.h"
|
||||
|
||||
#include "../chrono/chrono_util.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
@@ -36,7 +40,7 @@ namespace insight {
|
||||
This is a lightweight reference wrapper which is cheap to copy and assign.
|
||||
When the last reference goes away, the metric is no longer collected.
|
||||
*/
|
||||
class Event
|
||||
class Event : public Base
|
||||
{
|
||||
public:
|
||||
typedef EventImpl::value_type value_type;
|
||||
@@ -45,8 +49,7 @@ public:
|
||||
A null metric reports no information.
|
||||
*/
|
||||
Event ()
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
/** Create the metric reference the specified implementation.
|
||||
Normally this won't be called directly. Instead, call the appropriate
|
||||
@@ -55,17 +58,19 @@ public:
|
||||
*/
|
||||
explicit Event (std::shared_ptr <EventImpl> const& impl)
|
||||
: m_impl (impl)
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
/** Push an event notification.
|
||||
The value specifies the elapsed time in milliseconds, or any other
|
||||
domain specific value.
|
||||
*/
|
||||
void notify (value_type value) const
|
||||
/** Push an event notification. */
|
||||
template <class Rep, class Period>
|
||||
void notify (std::chrono::duration <Rep, Period> const& value) const
|
||||
{
|
||||
if (m_impl)
|
||||
m_impl->notify (value);
|
||||
m_impl->notify (ceil <value_type> (value));
|
||||
}
|
||||
|
||||
std::shared_ptr <EventImpl> const& impl () const
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
@@ -22,18 +22,22 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "BaseImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
class Event;
|
||||
|
||||
class EventImpl : public std::enable_shared_from_this <EventImpl>
|
||||
class EventImpl
|
||||
: public std::enable_shared_from_this <EventImpl>
|
||||
, public BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef uint64 value_type;
|
||||
typedef std::chrono::milliseconds value_type;
|
||||
|
||||
virtual ~EventImpl () = 0;
|
||||
virtual void notify (value_type value) = 0;
|
||||
virtual void notify (value_type const& value) = 0;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "Base.h"
|
||||
#include "GaugeImpl.h"
|
||||
|
||||
namespace beast {
|
||||
@@ -36,7 +37,7 @@ namespace insight {
|
||||
This is a lightweight reference wrapper which is cheap to copy and assign.
|
||||
When the last reference goes away, the metric is no longer collected.
|
||||
*/
|
||||
class Gauge
|
||||
class Gauge : public Base
|
||||
{
|
||||
public:
|
||||
typedef GaugeImpl::value_type value_type;
|
||||
@@ -59,21 +60,6 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
/** Set a handler for polling.
|
||||
If a handler is set, it will be called once per collection interval.
|
||||
This may be used to implement polling style collection instead of
|
||||
push style.
|
||||
|
||||
Handler will be called with this signature:
|
||||
void Handler (Gauge const&);
|
||||
*/
|
||||
template <class Handler>
|
||||
void set_handler (Handler handler) const
|
||||
{
|
||||
if (m_impl)
|
||||
m_impl->set_handler (handler);
|
||||
}
|
||||
|
||||
/** Set the value on the gauge.
|
||||
A Collector implementation should combine multiple calls to value
|
||||
changes into a single change if the calls occur within a single
|
||||
@@ -117,6 +103,11 @@ public:
|
||||
{ increment (-1); return *this; }
|
||||
/** @} */
|
||||
|
||||
std::shared_ptr <GaugeImpl> const& impl () const
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
|
||||
private:
|
||||
std::shared_ptr <GaugeImpl> m_impl;
|
||||
};
|
||||
|
||||
@@ -20,22 +20,26 @@
|
||||
#ifndef BEAST_INSIGHT_GAUGEIMPL_H_INCLUDED
|
||||
#define BEAST_INSIGHT_GAUGEIMPL_H_INCLUDED
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include "BaseImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
class Gauge;
|
||||
|
||||
class GaugeImpl : public std::enable_shared_from_this <GaugeImpl>
|
||||
class GaugeImpl
|
||||
: public std::enable_shared_from_this <GaugeImpl>
|
||||
, public BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef uint64 value_type;
|
||||
typedef int64 difference_type;
|
||||
typedef std::function <void (Gauge const&)> HandlerType;
|
||||
|
||||
virtual ~GaugeImpl () = 0;
|
||||
virtual void set (value_type value) = 0;
|
||||
virtual void increment (difference_type amount) = 0;
|
||||
virtual void set_handler (HandlerType const& handler) = 0;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -17,29 +17,27 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_TYPE_TRAITS_REMOVESIGNED_H_INCLUDED
|
||||
#define BEAST_TYPE_TRAITS_REMOVESIGNED_H_INCLUDED
|
||||
#ifndef BEAST_INSIGHT_GROUP_H_INCLUDED
|
||||
#define BEAST_INSIGHT_GROUP_H_INCLUDED
|
||||
|
||||
#include "IntegralConstant.h"
|
||||
#include "../CStdInt.h"
|
||||
#include <memory>
|
||||
|
||||
#include "Collector.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
/** Returns an equally sized, unsigned type.
|
||||
Requires:
|
||||
IsIntegral<T>::value == true
|
||||
*/
|
||||
template <typename T>
|
||||
struct RemoveSigned
|
||||
/** A collector front-end that manages a group of metrics. */
|
||||
class Group : public Collector
|
||||
{
|
||||
typedef T type;
|
||||
public:
|
||||
typedef std::shared_ptr <Group> ptr;
|
||||
|
||||
/** Returns the name of this group, for diagnostics. */
|
||||
virtual std::string const& name () const = 0;
|
||||
};
|
||||
|
||||
template <> struct RemoveSigned <int8> { typedef uint8 type; };
|
||||
template <> struct RemoveSigned <int16> { typedef uint16 type; };
|
||||
template <> struct RemoveSigned <int32> { typedef uint32 type; };
|
||||
template <> struct RemoveSigned <int64> { typedef uint64 type; };
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
55
src/beast/beast/insight/Groups.h
Normal file
55
src/beast/beast/insight/Groups.h
Normal file
@@ -0,0 +1,55 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_INSIGHT_GROUPS_H_INCLUDED
|
||||
#define BEAST_INSIGHT_GROUPS_H_INCLUDED
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "Collector.h"
|
||||
#include "Group.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
/** A container for managing a set of metric groups. */
|
||||
class Groups
|
||||
{
|
||||
public:
|
||||
virtual ~Groups() = 0;
|
||||
|
||||
/** Find or create a new collector with a given name. */
|
||||
/** @{ */
|
||||
virtual Group::ptr const& get (std::string const& name) = 0;
|
||||
|
||||
Group::ptr const& operator[] (std::string const& name)
|
||||
{
|
||||
return get (name);
|
||||
}
|
||||
/** @} */
|
||||
};
|
||||
|
||||
/** Create a group container that uses the specified collector. */
|
||||
std::unique_ptr <Groups> make_Groups (Collector::ptr const& collector);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -20,15 +20,16 @@
|
||||
#ifndef BEAST_INSIGHT_HOOK_H_INCLUDED
|
||||
#define BEAST_INSIGHT_HOOK_H_INCLUDED
|
||||
|
||||
#include "HookImpl.h"
|
||||
#include <memory>
|
||||
|
||||
#include "../stl/shared_ptr.h"
|
||||
#include "Base.h"
|
||||
#include "HookImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
/** A reference to a handler for performing polled collection. */
|
||||
class Hook
|
||||
class Hook : public Base
|
||||
{
|
||||
public:
|
||||
/** Create a null hook.
|
||||
@@ -44,7 +45,11 @@ public:
|
||||
*/
|
||||
explicit Hook (std::shared_ptr <HookImpl> const& impl)
|
||||
: m_impl (impl)
|
||||
{ }
|
||||
|
||||
std::shared_ptr <HookImpl> const& impl () const
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
@@ -23,10 +23,14 @@
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
#include "BaseImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
class HookImpl : public std::enable_shared_from_this <HookImpl>
|
||||
class HookImpl
|
||||
: public std::enable_shared_from_this <HookImpl>
|
||||
, public BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef std::function <void (void)> HandlerType;
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
#include "../Insight.h"
|
||||
|
||||
#include "impl/Collector.cpp"
|
||||
#include "impl/Group.cpp"
|
||||
#include "impl/Groups.cpp"
|
||||
#include "impl/Hook.cpp"
|
||||
#include "impl/Metric.cpp"
|
||||
#include "impl/NullCollector.cpp"
|
||||
|
||||
@@ -20,9 +20,10 @@
|
||||
#ifndef BEAST_INSIGHT_METER_H_INCLUDED
|
||||
#define BEAST_INSIGHT_METER_H_INCLUDED
|
||||
|
||||
#include "MeterImpl.h"
|
||||
#include <memory>
|
||||
|
||||
#include "../stl/shared_ptr.h"
|
||||
#include "Base.h"
|
||||
#include "MeterImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
@@ -34,7 +35,7 @@ namespace insight {
|
||||
This is a lightweight reference wrapper which is cheap to copy and assign.
|
||||
When the last reference goes away, the metric is no longer collected.
|
||||
*/
|
||||
class Meter
|
||||
class Meter : public Base
|
||||
{
|
||||
public:
|
||||
typedef MeterImpl::value_type value_type;
|
||||
@@ -43,8 +44,7 @@ public:
|
||||
A null metric reports no information.
|
||||
*/
|
||||
Meter ()
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
/** Create the metric reference the specified implementation.
|
||||
Normally this won't be called directly. Instead, call the appropriate
|
||||
@@ -53,22 +53,7 @@ public:
|
||||
*/
|
||||
explicit Meter (std::shared_ptr <MeterImpl> const& impl)
|
||||
: m_impl (impl)
|
||||
{
|
||||
}
|
||||
|
||||
/** Set a handler for polling.
|
||||
If a handler is set, it will be called once per collection interval.
|
||||
This may be used to implement polling style collection instead of
|
||||
push style.
|
||||
|
||||
Handler will be called with this signature:
|
||||
void Handler (Meter const&);
|
||||
*/
|
||||
template <class Handler>
|
||||
void set_handler (Handler handler) const
|
||||
{
|
||||
m_impl->set_handler (handler);
|
||||
}
|
||||
{ }
|
||||
|
||||
/** Increment the meter. */
|
||||
/** @{ */
|
||||
@@ -79,15 +64,29 @@ public:
|
||||
}
|
||||
|
||||
Meter const& operator+= (value_type amount) const
|
||||
{ increment (amount); return *this; }
|
||||
{
|
||||
increment (amount);
|
||||
return *this;
|
||||
}
|
||||
|
||||
Meter const& operator++ () const
|
||||
{ increment (1); return *this; }
|
||||
{
|
||||
increment (1);
|
||||
return *this;
|
||||
}
|
||||
|
||||
Meter const& operator++ (int) const
|
||||
{ increment (1); return *this; }
|
||||
{
|
||||
increment (1);
|
||||
return *this;
|
||||
}
|
||||
/** @} */
|
||||
|
||||
std::shared_ptr <MeterImpl> const& impl () const
|
||||
{
|
||||
return m_impl;
|
||||
}
|
||||
|
||||
private:
|
||||
std::shared_ptr <MeterImpl> m_impl;
|
||||
};
|
||||
|
||||
@@ -20,23 +20,24 @@
|
||||
#ifndef BEAST_INSIGHT_METERIMPL_H_INCLUDED
|
||||
#define BEAST_INSIGHT_METERIMPL_H_INCLUDED
|
||||
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
||||
#include "BaseImpl.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
class Meter;
|
||||
|
||||
class MeterImpl : public std::enable_shared_from_this <MeterImpl>
|
||||
class MeterImpl
|
||||
: public std::enable_shared_from_this <MeterImpl>
|
||||
, public BaseImpl
|
||||
{
|
||||
public:
|
||||
typedef uint64 value_type;
|
||||
typedef std::function <void (Meter const&)> HandlerType;
|
||||
|
||||
virtual ~MeterImpl () = 0;
|
||||
virtual void increment (value_type amount) = 0;
|
||||
virtual void set_handler (HandlerType const& handler) = 0;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
#include "Collector.h"
|
||||
|
||||
#include "../net/IPAddress.h"
|
||||
#include "../net/IPEndpoint.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
@@ -39,7 +39,7 @@ public:
|
||||
@param prefix A string pre-pended before each metric name.
|
||||
@param journal Destination for logging output.
|
||||
*/
|
||||
static std::shared_ptr <StatsDCollector> New (IPAddress const& address,
|
||||
static std::shared_ptr <StatsDCollector> New (IP::Endpoint const& address,
|
||||
std::string const& prefix, Journal journal);
|
||||
};
|
||||
|
||||
|
||||
@@ -17,9 +17,12 @@
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_STL_H_INCLUDED
|
||||
#define BEAST_STL_H_INCLUDED
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
#include "stl/shared_ptr.h"
|
||||
namespace detail {
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
133
src/beast/beast/insight/impl/Groups.cpp
Normal file
133
src/beast/beast/insight/impl/Groups.cpp
Normal file
@@ -0,0 +1,133 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <unordered_map>
|
||||
|
||||
#include "../../cxx14/memory.h"
|
||||
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
namespace detail {
|
||||
|
||||
class GroupImp
|
||||
: public std::enable_shared_from_this <GroupImp>
|
||||
, public Group
|
||||
{
|
||||
public:
|
||||
typedef std::vector <std::shared_ptr <BaseImpl>> Items;
|
||||
|
||||
std::string const m_name;
|
||||
Collector::ptr m_collector;
|
||||
|
||||
GroupImp (std::string const& name_,
|
||||
Collector::ptr const& collector)
|
||||
: m_name (name_)
|
||||
, m_collector (collector)
|
||||
{
|
||||
}
|
||||
|
||||
~GroupImp ()
|
||||
{
|
||||
}
|
||||
|
||||
std::string const& name () const
|
||||
{
|
||||
return m_name;
|
||||
}
|
||||
|
||||
std::string make_name (std::string const& name)
|
||||
{
|
||||
return m_name + "." + name;
|
||||
}
|
||||
|
||||
Hook make_hook (HookImpl::HandlerType const& handler)
|
||||
{
|
||||
return m_collector->make_hook (handler);
|
||||
}
|
||||
|
||||
Counter make_counter (std::string const& name)
|
||||
{
|
||||
return m_collector->make_counter (make_name (name));
|
||||
}
|
||||
|
||||
Event make_event (std::string const& name)
|
||||
{
|
||||
return m_collector->make_event (make_name (name));
|
||||
}
|
||||
|
||||
Gauge make_gauge (std::string const& name)
|
||||
{
|
||||
return m_collector->make_gauge (make_name (name));
|
||||
}
|
||||
|
||||
Meter make_meter (std::string const& name)
|
||||
{
|
||||
return m_collector->make_meter (make_name (name));
|
||||
}
|
||||
|
||||
private:
|
||||
GroupImp& operator= (GroupImp const&);
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
class GroupsImp : public Groups
|
||||
{
|
||||
public:
|
||||
typedef std::unordered_map <std::string, std::shared_ptr <Group>> Items;
|
||||
|
||||
Collector::ptr m_collector;
|
||||
Items m_items;
|
||||
|
||||
GroupsImp (Collector::ptr const& collector)
|
||||
: m_collector (collector)
|
||||
{
|
||||
}
|
||||
|
||||
~GroupsImp ()
|
||||
{
|
||||
}
|
||||
|
||||
Group::ptr const& get (std::string const& name)
|
||||
{
|
||||
std::pair <Items::iterator, bool> result (
|
||||
m_items.emplace (name, Group::ptr ()));
|
||||
Group::ptr& group (result.first->second);
|
||||
if (result.second)
|
||||
group = std::make_shared <GroupImp> (name, m_collector);
|
||||
return group;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
Groups::~Groups ()
|
||||
{
|
||||
}
|
||||
|
||||
std::unique_ptr <Groups> make_Groups (Collector::ptr const& collector)
|
||||
{
|
||||
return std::make_unique <detail::GroupsImp> (collector);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -20,6 +20,14 @@
|
||||
namespace beast {
|
||||
namespace insight {
|
||||
|
||||
Base::~Base ()
|
||||
{
|
||||
}
|
||||
|
||||
BaseImpl::~BaseImpl ()
|
||||
{
|
||||
}
|
||||
|
||||
CounterImpl::~CounterImpl ()
|
||||
{
|
||||
}
|
||||
|
||||
@@ -37,10 +37,6 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void set_handler (HandlerType const&)
|
||||
{
|
||||
}
|
||||
|
||||
private:
|
||||
NullCounterImpl& operator= (NullCounterImpl const&);
|
||||
};
|
||||
@@ -50,7 +46,7 @@ private:
|
||||
class NullEventImpl : public EventImpl
|
||||
{
|
||||
public:
|
||||
void notify (value_type)
|
||||
void notify (value_type const&)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -71,10 +67,6 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void set_handler (HandlerType const&)
|
||||
{
|
||||
}
|
||||
|
||||
private:
|
||||
NullGaugeImpl& operator= (NullGaugeImpl const&);
|
||||
};
|
||||
@@ -88,10 +80,6 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void set_handler (HandlerType const&)
|
||||
{
|
||||
}
|
||||
|
||||
private:
|
||||
NullMeterImpl& operator= (NullMeterImpl const&);
|
||||
};
|
||||
|
||||
@@ -85,7 +85,6 @@ public:
|
||||
~StatsDCounterImpl ();
|
||||
|
||||
void increment (CounterImpl::value_type amount);
|
||||
void set_handler (HandlerType const& handler);
|
||||
|
||||
void flush ();
|
||||
void do_increment (CounterImpl::value_type amount);
|
||||
@@ -98,7 +97,6 @@ private:
|
||||
std::string m_name;
|
||||
CounterImpl::value_type m_value;
|
||||
bool m_dirty;
|
||||
HandlerType m_handler;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
@@ -112,9 +110,9 @@ public:
|
||||
|
||||
~StatsDEventImpl ();
|
||||
|
||||
void notify (EventImpl::value_type value);
|
||||
void notify (EventImpl::value_type const& alue);
|
||||
|
||||
void do_notify (EventImpl::value_type value);
|
||||
void do_notify (EventImpl::value_type const& value);
|
||||
void do_process ();
|
||||
|
||||
private:
|
||||
@@ -138,7 +136,6 @@ public:
|
||||
|
||||
void set (GaugeImpl::value_type value);
|
||||
void increment (GaugeImpl::difference_type amount);
|
||||
void set_handler (HandlerType const& handler);
|
||||
|
||||
void flush ();
|
||||
void do_set (GaugeImpl::value_type value);
|
||||
@@ -153,7 +150,6 @@ private:
|
||||
GaugeImpl::value_type m_last_value;
|
||||
GaugeImpl::value_type m_value;
|
||||
bool m_dirty;
|
||||
HandlerType m_handler;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
@@ -169,7 +165,6 @@ public:
|
||||
~StatsDMeterImpl ();
|
||||
|
||||
void increment (MeterImpl::value_type amount);
|
||||
void set_handler (HandlerType const& handler);
|
||||
|
||||
void flush ();
|
||||
void do_increment (MeterImpl::value_type amount);
|
||||
@@ -182,7 +177,6 @@ private:
|
||||
std::string m_name;
|
||||
MeterImpl::value_type m_value;
|
||||
bool m_dirty;
|
||||
HandlerType m_handler;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
@@ -206,7 +200,7 @@ private:
|
||||
typedef SharedData <StateType> State;
|
||||
|
||||
Journal m_journal;
|
||||
IPAddress m_address;
|
||||
IP::Endpoint m_address;
|
||||
std::string m_prefix;
|
||||
boost::asio::io_service m_io_service;
|
||||
boost::optional <boost::asio::io_service::work> m_work;
|
||||
@@ -219,13 +213,13 @@ private:
|
||||
std::thread m_thread;
|
||||
|
||||
static boost::asio::ip::udp::endpoint to_endpoint (
|
||||
IPAddress const &address)
|
||||
IP::Endpoint const &address)
|
||||
{
|
||||
if (address.isV4 ())
|
||||
if (address.is_v4 ())
|
||||
{
|
||||
return boost::asio::ip::udp::endpoint (
|
||||
boost::asio::ip::address_v4 (
|
||||
address.v4().value), address.port ());
|
||||
address.to_v4().value), address.port ());
|
||||
}
|
||||
|
||||
// VFALCO TODO IPv6 support
|
||||
@@ -236,7 +230,7 @@ private:
|
||||
|
||||
public:
|
||||
StatsDCollectorImp (
|
||||
IPAddress const& address,
|
||||
IP::Endpoint const& address,
|
||||
std::string const& prefix,
|
||||
Journal journal)
|
||||
: m_journal (journal)
|
||||
@@ -316,9 +310,6 @@ public:
|
||||
|
||||
void do_post_buffer (std::string const& buffer)
|
||||
{
|
||||
#if BEAST_STATSDCOLLECTOR_TRACING_ENABLED
|
||||
m_journal.trace << std::endl << buffer;
|
||||
#endif
|
||||
m_data.emplace_back (buffer);
|
||||
}
|
||||
|
||||
@@ -342,6 +333,22 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
void log (std::vector <boost::asio::const_buffer> const& buffers)
|
||||
{
|
||||
(void)buffers;
|
||||
#if BEAST_STATSDCOLLECTOR_TRACING_ENABLED
|
||||
std::stringstream ss;
|
||||
for (auto const& buffer : buffers)
|
||||
{
|
||||
std::string const s (boost::asio::buffer_cast <char const*> (buffer),
|
||||
boost::asio::buffer_size (buffer));
|
||||
ss << s;
|
||||
}
|
||||
//m_journal.trace << std::endl << ss.str ();
|
||||
Logger::outputDebugString (ss.str ());
|
||||
#endif
|
||||
}
|
||||
|
||||
// Send what we have
|
||||
void send_buffers ()
|
||||
{
|
||||
@@ -360,6 +367,9 @@ public:
|
||||
check_precondition (! buffer.empty ());
|
||||
if (! buffers.empty () && (size + length) > max_packet_size)
|
||||
{
|
||||
#if BEAST_STATSDCOLLECTOR_TRACING_ENABLED
|
||||
log (buffers);
|
||||
#endif
|
||||
m_socket.async_send (buffers, boost::bind (
|
||||
&StatsDCollectorImp::on_send, this,
|
||||
boost::asio::placeholders::error,
|
||||
@@ -372,6 +382,9 @@ public:
|
||||
}
|
||||
if (! buffers.empty ())
|
||||
{
|
||||
#if BEAST_STATSDCOLLECTOR_TRACING_ENABLED
|
||||
log (buffers);
|
||||
#endif
|
||||
m_socket.async_send (buffers, boost::bind (
|
||||
&StatsDCollectorImp::on_send, this,
|
||||
boost::asio::placeholders::error,
|
||||
@@ -480,11 +493,6 @@ void StatsDCounterImpl::increment (CounterImpl::value_type amount)
|
||||
shared_from_this ()), amount));
|
||||
}
|
||||
|
||||
void StatsDCounterImpl::set_handler (HandlerType const& handler)
|
||||
{
|
||||
m_handler = handler;
|
||||
}
|
||||
|
||||
void StatsDCounterImpl::flush ()
|
||||
{
|
||||
if (m_dirty)
|
||||
@@ -509,8 +517,6 @@ void StatsDCounterImpl::do_increment (CounterImpl::value_type amount)
|
||||
|
||||
void StatsDCounterImpl::do_process ()
|
||||
{
|
||||
if (m_handler)
|
||||
m_handler (Counter (shared_from_this ()));
|
||||
flush ();
|
||||
}
|
||||
|
||||
@@ -527,7 +533,7 @@ StatsDEventImpl::~StatsDEventImpl ()
|
||||
{
|
||||
}
|
||||
|
||||
void StatsDEventImpl::notify (EventImpl::value_type value)
|
||||
void StatsDEventImpl::notify (EventImpl::value_type const& value)
|
||||
{
|
||||
m_impl->get_io_service().dispatch (std::bind (
|
||||
&StatsDEventImpl::do_notify,
|
||||
@@ -535,13 +541,13 @@ void StatsDEventImpl::notify (EventImpl::value_type value)
|
||||
shared_from_this ()), value));
|
||||
}
|
||||
|
||||
void StatsDEventImpl::do_notify (EventImpl::value_type value)
|
||||
void StatsDEventImpl::do_notify (EventImpl::value_type const& value)
|
||||
{
|
||||
std::stringstream ss;
|
||||
ss <<
|
||||
m_impl->prefix() << "." <<
|
||||
m_name << ":" <<
|
||||
value << "|ms" <<
|
||||
value.count() << "|ms" <<
|
||||
"\n";
|
||||
m_impl->post_buffer (ss.str ());
|
||||
}
|
||||
@@ -580,11 +586,6 @@ void StatsDGaugeImpl::increment (GaugeImpl::difference_type amount)
|
||||
shared_from_this ()), amount));
|
||||
}
|
||||
|
||||
void StatsDGaugeImpl::set_handler (HandlerType const& handler)
|
||||
{
|
||||
m_handler = handler;
|
||||
}
|
||||
|
||||
void StatsDGaugeImpl::flush ()
|
||||
{
|
||||
if (m_dirty)
|
||||
@@ -617,17 +618,18 @@ void StatsDGaugeImpl::do_increment (GaugeImpl::difference_type amount)
|
||||
|
||||
if (amount > 0)
|
||||
{
|
||||
GaugeImpl::value_type const d (
|
||||
static_cast <GaugeImpl::value_type> (amount));
|
||||
value +=
|
||||
(amount >= std::numeric_limits <GaugeImpl::value_type>::max() - m_value)
|
||||
(d >= std::numeric_limits <GaugeImpl::value_type>::max() - m_value)
|
||||
? std::numeric_limits <GaugeImpl::value_type>::max() - m_value
|
||||
: GaugeImpl::value_type (amount);
|
||||
: d;
|
||||
}
|
||||
else if (amount < 0)
|
||||
{
|
||||
value -=
|
||||
(std::abs (amount) >= m_value)
|
||||
? m_value
|
||||
: std::abs (amount);
|
||||
GaugeImpl::value_type const d (
|
||||
static_cast <GaugeImpl::value_type> (-amount));
|
||||
value = (d >= value) ? 0 : value - d;
|
||||
}
|
||||
|
||||
do_set (value);
|
||||
@@ -635,8 +637,6 @@ void StatsDGaugeImpl::do_increment (GaugeImpl::difference_type amount)
|
||||
|
||||
void StatsDGaugeImpl::do_process ()
|
||||
{
|
||||
if (m_handler)
|
||||
m_handler (Gauge (shared_from_this ()));
|
||||
flush ();
|
||||
}
|
||||
|
||||
@@ -665,11 +665,6 @@ void StatsDMeterImpl::increment (MeterImpl::value_type amount)
|
||||
shared_from_this ()), amount));
|
||||
}
|
||||
|
||||
void StatsDMeterImpl::set_handler (HandlerType const& handler)
|
||||
{
|
||||
m_handler = handler;
|
||||
}
|
||||
|
||||
void StatsDMeterImpl::flush ()
|
||||
{
|
||||
if (m_dirty)
|
||||
@@ -694,8 +689,6 @@ void StatsDMeterImpl::do_increment (MeterImpl::value_type amount)
|
||||
|
||||
void StatsDMeterImpl::do_process ()
|
||||
{
|
||||
if (m_handler)
|
||||
m_handler (Meter (shared_from_this ()));
|
||||
flush ();
|
||||
}
|
||||
|
||||
@@ -704,7 +697,7 @@ void StatsDMeterImpl::do_process ()
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
std::shared_ptr <StatsDCollector> StatsDCollector::New (
|
||||
IPAddress const& address, std::string const& prefix, Journal journal)
|
||||
IP::Endpoint const& address, std::string const& prefix, Journal journal)
|
||||
{
|
||||
return std::make_shared <detail::StatsDCollectorImp> (
|
||||
address, prefix, journal);
|
||||
|
||||
@@ -23,401 +23,140 @@
|
||||
#include <string>
|
||||
#include <ios>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
#include "../CStdInt.h"
|
||||
|
||||
namespace std {
|
||||
|
||||
template <typename T>
|
||||
struct hash;
|
||||
|
||||
//template <>
|
||||
//struct hash <beast::IPAddress>;
|
||||
|
||||
}
|
||||
#include "IPAddressV4.h"
|
||||
#include "IPAddressV6.h"
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
/** Represents an IP address (v4 or v6) and port combination. */
|
||||
class IPAddress
|
||||
/** A version-independent IP address.
|
||||
This object can represent either an IPv4 or IPv6 address.
|
||||
*/
|
||||
class Address
|
||||
{
|
||||
public:
|
||||
/** Create an unspecified IPv4 address. */
|
||||
Address ();
|
||||
|
||||
/** Create an IPv4 address. */
|
||||
Address (AddressV4 const& addr);
|
||||
|
||||
/** Create an IPv6 address. */
|
||||
Address (AddressV6 const& addr);
|
||||
|
||||
/** Assign a copy from another address in any format. */
|
||||
/** @{ */
|
||||
Address& operator= (AddressV4 const& addr);
|
||||
Address& operator= (AddressV6 const& addr);
|
||||
/** @} */
|
||||
|
||||
/** Create an Address from a string.
|
||||
@return A pair with the address, and bool set to `true` on success.
|
||||
*/
|
||||
static std::pair <Address, bool> from_string (std::string const& s);
|
||||
|
||||
/** Returns a string representing the address. */
|
||||
std::string to_string () const;
|
||||
|
||||
/** Returns `true` if this address represents an IPv4 address. */
|
||||
bool is_v4 () const
|
||||
{ return m_type == ipv4; }
|
||||
|
||||
/** Returns `true` if this address represents an IPv6 address. */
|
||||
bool is_v6 () const
|
||||
{ return m_type == ipv6; }
|
||||
|
||||
/** Returns the IPv4 address.
|
||||
Precondition:
|
||||
is_v4() returns true
|
||||
*/
|
||||
AddressV4 const& to_v4 () const;
|
||||
|
||||
/** Returns the IPv6 address.
|
||||
Precondition:
|
||||
is_v6() returns true
|
||||
*/
|
||||
AddressV6 const& to_v6 () const;
|
||||
|
||||
/** Arithmetic comparison. */
|
||||
/** @{ */
|
||||
friend bool operator== (Address const& lhs, Address const& rhs);
|
||||
friend bool operator< (Address const& lhs, Address const& rhs);
|
||||
|
||||
friend bool operator!= (Address const& lhs, Address const& rhs)
|
||||
{ return ! (lhs == rhs); }
|
||||
friend bool operator> (Address const& lhs, Address const& rhs)
|
||||
{ return rhs < lhs; }
|
||||
friend bool operator<= (Address const& lhs, Address const& rhs)
|
||||
{ return ! (lhs > rhs); }
|
||||
friend bool operator>= (Address const& lhs, Address const& rhs)
|
||||
{ return ! (rhs > lhs); }
|
||||
/** @} */
|
||||
|
||||
private:
|
||||
enum Type
|
||||
{
|
||||
none,
|
||||
ipv4,
|
||||
ipv6
|
||||
};
|
||||
|
||||
template <typename Number>
|
||||
static std::string numberToString (Number n)
|
||||
{
|
||||
std::ostringstream os;
|
||||
os << std::dec << n;
|
||||
return std::string (os.str());
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
/** Used for IPv4 formats. */
|
||||
struct V4
|
||||
{
|
||||
/** Construct the "any" address. */
|
||||
V4 ();
|
||||
|
||||
/** Construct from a 32-bit unsigned.
|
||||
@note Octets are formed in order from the MSB to the LSB.
|
||||
*/
|
||||
explicit V4 (uint32 value_);
|
||||
|
||||
/** Construct from four individual octets..
|
||||
@note The resulting address is a.b.c.d
|
||||
*/
|
||||
V4 (uint8 a, uint8 b, uint8 c, uint8 d);
|
||||
|
||||
/** Construct a copy of another address. */
|
||||
V4 (V4 const& other);
|
||||
|
||||
/** Assign a copy of another address. */
|
||||
V4& operator= (V4 const& other);
|
||||
|
||||
/** Returns a V4 address representing the local broadcast address. */
|
||||
static V4 localBroadcastAddress ();
|
||||
|
||||
/** Returns the directed broadcast address for the network implied by this address. */
|
||||
V4 broadcastAddress () const;
|
||||
|
||||
/** Returns the IPv4 address class as 'A', 'B', 'C', or 'D'.
|
||||
@note Class 'D' represents multicast addresses (224.*.*.*).
|
||||
*/
|
||||
char getClass () const;
|
||||
|
||||
/** Returns `true` if this is a public routable address. */
|
||||
bool isPublic () const;
|
||||
|
||||
/** Returns `true` if this is a private, non-routable address. */
|
||||
bool isPrivate () const;
|
||||
|
||||
/** Returns `true` if this is a broadcast address. */
|
||||
bool isBroadcast () const;
|
||||
|
||||
/** Returns `true` if this is a multicast address. */
|
||||
bool isMulticast () const;
|
||||
|
||||
/** Returns `true` if this refers to any loopback adapter address. */
|
||||
bool isLoopback () const;
|
||||
|
||||
/** Supports access via operator[]. */
|
||||
template <bool IsConst>
|
||||
class Proxy
|
||||
{
|
||||
public:
|
||||
typedef typename std::conditional <
|
||||
IsConst, uint32 const*, uint32*>::type Pointer;
|
||||
|
||||
Proxy (int shift, Pointer value)
|
||||
: m_shift (shift)
|
||||
, m_value (value)
|
||||
{
|
||||
}
|
||||
|
||||
operator uint8() const
|
||||
{
|
||||
return ((*m_value)>>m_shift) & 0xff;
|
||||
}
|
||||
|
||||
template <typename IntegralType>
|
||||
Proxy& operator= (IntegralType v)
|
||||
{
|
||||
(*m_value) =
|
||||
( (*m_value) & (~((0xff)<<m_shift)) )
|
||||
| ((v&0xff) << m_shift);
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
private:
|
||||
int m_shift;
|
||||
Pointer m_value;
|
||||
};
|
||||
|
||||
/** Provides read access to individual octets of the IPv4 address. */
|
||||
Proxy <true> operator[] (std::size_t index) const;
|
||||
|
||||
/** Provides read/write access to individual octets of the IPv4 address. */
|
||||
Proxy <false> operator[] (std::size_t index);
|
||||
|
||||
/** Convert the address to a human readable string. */
|
||||
/** @{ */
|
||||
std::string to_string () const;
|
||||
operator std::string () const;
|
||||
/** @} */
|
||||
|
||||
struct hasher
|
||||
{
|
||||
std::size_t operator() (V4 const& v) const
|
||||
{
|
||||
return v.value;
|
||||
}
|
||||
};
|
||||
|
||||
/** The value as a 32 bit unsigned. */
|
||||
uint32 value;
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
/** Used for IPv6 formats. */
|
||||
struct V6
|
||||
{
|
||||
/** Returns `true` if this is a public routable address. */
|
||||
bool isPublic () const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Returns `true` if this is a private, non-routable address. */
|
||||
bool isPrivate () const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Returns `true` if this is a broadcast address. */
|
||||
bool isBroadcast () const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Returns `true` if this is a multicast address. */
|
||||
bool isMulticast () const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Returns `true` if this refers to any loopback adapter address. */
|
||||
bool isLoopback () const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Convert the address to a human readable string. */
|
||||
/** @{ */
|
||||
std::string to_string () const
|
||||
{
|
||||
return std::string();
|
||||
}
|
||||
|
||||
operator std::string () const
|
||||
{
|
||||
return to_string();
|
||||
}
|
||||
/** @} */
|
||||
|
||||
struct hasher
|
||||
{
|
||||
std::size_t operator() (V6 const&) const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
/** Create an empty address. */
|
||||
IPAddress ();
|
||||
|
||||
/** Create an IPv4 address with optional port. */
|
||||
IPAddress (V4 const& v4, uint16 port = 0);
|
||||
|
||||
/** Create an IPv6 address with optional port. */
|
||||
IPAddress (V6 const& v6, uint16 port = 0);
|
||||
|
||||
/** Create a copy of another IPAddress. */
|
||||
IPAddress (IPAddress const& other);
|
||||
|
||||
/** Copy assign another IPAddress. */
|
||||
IPAddress& operator= (IPAddress const& other);
|
||||
|
||||
/** Create an IPAddress from a string.
|
||||
If a parsing error occurs, the endpoint will be empty.
|
||||
*/
|
||||
static IPAddress from_string (std::string const& s);
|
||||
|
||||
/** Create an IPAddress from a string.
|
||||
If a parsing error occurs, the endpoint will be empty.
|
||||
This recognizes an alternate form of the text. Instead of a colon
|
||||
separating the optional port specification, any amount of whitespace
|
||||
is allowed.
|
||||
*/
|
||||
static IPAddress from_string_altform (std::string const& s);
|
||||
|
||||
/** Copy assign an IPv4 address.
|
||||
The port is set to zero.
|
||||
*/
|
||||
IPAddress& operator= (V4 const& address);
|
||||
|
||||
/** Copy assign an IPv6 address.
|
||||
The port is set to zero.
|
||||
*/
|
||||
IPAddress& operator= (V6 const& address);
|
||||
|
||||
/** Returns a new IPAddress with this address, and the given port. */
|
||||
IPAddress withPort (uint16 port) const;
|
||||
|
||||
/** Returns `true` if this IPAddress refers to nothing. */
|
||||
bool empty () const;
|
||||
|
||||
/** Returns `true` if this IPAddress refers to nothing. */
|
||||
bool isNull () const;
|
||||
|
||||
/** Returns `true` if this IPAddress refers to something. */
|
||||
bool isNotNull () const;
|
||||
|
||||
/** Returns the type of this IPAddress. */
|
||||
Type type () const;
|
||||
|
||||
/** Returns `true` if this IPAddress represents an IPv4 address. */
|
||||
bool isV4 () const;
|
||||
|
||||
/** Returns `true` if this IPAddress represents an IPv6 address. */
|
||||
bool isV6 () const;
|
||||
|
||||
/** Returns the IPv4 address.
|
||||
Undefined behavior results if type() != ipv4.
|
||||
*/
|
||||
V4 const& v4 () const;
|
||||
|
||||
/** Returns the IPv6 address.
|
||||
Undefined behavior results if type() != ipv4.
|
||||
*/
|
||||
V6 const& v6 () const;
|
||||
|
||||
/** Returns the port number.
|
||||
Undefined if type() == none.
|
||||
*/
|
||||
uint16 port () const;
|
||||
|
||||
/** Returns `true` if this is a public routable address. */
|
||||
bool isPublic () const;
|
||||
|
||||
/** Returns `true` if this is a private, non-routable address. */
|
||||
bool isPrivate () const;
|
||||
|
||||
/** Returns `true` if this is a broadcast address. */
|
||||
bool isBroadcast () const;
|
||||
|
||||
/** Returns `true` if this is a multicast address. */
|
||||
bool isMulticast () const;
|
||||
|
||||
/** Returns `true` if this refers to any loopback adapter address. */
|
||||
bool isLoopback () const;
|
||||
|
||||
/** Convert the address to a human readable string. */
|
||||
/** @{ */
|
||||
std::string to_string () const;
|
||||
operator std::string () const;
|
||||
/** @} */
|
||||
|
||||
typedef std::hash <IPAddress> hasher;
|
||||
|
||||
struct key_equal;
|
||||
|
||||
/** LessThanComparable functor that ignores the port. */
|
||||
struct LessWithoutPort
|
||||
{
|
||||
bool operator() (IPAddress const& lhs, IPAddress const& rhs) const;
|
||||
};
|
||||
|
||||
/** EqualityComparable functor that ignores the port. */
|
||||
struct EqualWithoutPort
|
||||
{
|
||||
bool operator() (IPAddress const& lhs, IPAddress const& rhs) const;
|
||||
};
|
||||
|
||||
private:
|
||||
Type m_type;
|
||||
uint16 m_port;
|
||||
V4 m_v4;
|
||||
V6 m_v6;
|
||||
AddressV4 m_v4;
|
||||
AddressV6 m_v6;
|
||||
};
|
||||
|
||||
/** Comparison. */
|
||||
/** @{ */
|
||||
bool operator== (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
bool operator!= (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
bool operator< (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
bool operator<= (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
bool operator> (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
bool operator>= (IPAddress::V4 const& lhs, IPAddress::V4 const& rhs);
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
bool operator== (IPAddress const& lhs, IPAddress const& rhs);
|
||||
bool operator!= (IPAddress const& lhs, IPAddress const& rhs);
|
||||
bool operator< (IPAddress const& lhs, IPAddress const& rhs);
|
||||
bool operator<= (IPAddress const& lhs, IPAddress const& rhs);
|
||||
bool operator> (IPAddress const& lhs, IPAddress const& rhs);
|
||||
bool operator>= (IPAddress const& lhs, IPAddress const& rhs);
|
||||
// Properties
|
||||
|
||||
/** Output stream conversions. */
|
||||
/** @{ */
|
||||
std::ostream& operator<< (std::ostream& os, IPAddress::V4 const& addr);
|
||||
std::ostream& operator<< (std::ostream& os, IPAddress::V6 const& addr);
|
||||
std::ostream& operator<< (std::ostream& os, IPAddress const& ep);
|
||||
/** @} */
|
||||
/** Returns `true` if this is a loopback address. */
|
||||
bool is_loopback (Address const& addr);
|
||||
|
||||
/** Input stream conversions. */
|
||||
/** @{ */
|
||||
std::istream& operator>> (std::istream& is, IPAddress::V4& addr);
|
||||
std::istream& operator>> (std::istream& is, IPAddress& ep);
|
||||
//std::istream& operator>> (std::istream &is, IPAddress::V6&);
|
||||
/** @} */
|
||||
/** Returns `true` if the address is unspecified. */
|
||||
bool is_unspecified (Address const& addr);
|
||||
|
||||
struct IPAddress::key_equal
|
||||
{
|
||||
bool operator() (IPAddress const& lhs, IPAddress const& rhs) const
|
||||
{
|
||||
return lhs == rhs;
|
||||
}
|
||||
};
|
||||
/** Returns `true` if the address is a multicast address. */
|
||||
bool is_multicast (Address const& addr);
|
||||
|
||||
/** Returns `true` if the address is a private unroutable address. */
|
||||
bool is_private (Address const& addr);
|
||||
|
||||
/** Returns `true` if the address is a public routable address. */
|
||||
bool is_public (Address const& addr);
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** boost::hash support. */
|
||||
std::size_t hash_value (Address const& addr);
|
||||
|
||||
/** Returns the address represented as a string. */
|
||||
inline std::string to_string (Address const& addr)
|
||||
{ return addr.to_string (); }
|
||||
|
||||
/** Output stream conversion. */
|
||||
template <typename OutputStream>
|
||||
OutputStream& operator<< (OutputStream& os, Address const& addr)
|
||||
{ return os << to_string (addr); }
|
||||
|
||||
/** Input stream conversion. */
|
||||
std::istream& operator>> (std::istream& is, Address& addr);
|
||||
|
||||
inline bool IPAddress::LessWithoutPort::operator() (
|
||||
IPAddress const& lhs, IPAddress const& rhs) const
|
||||
{
|
||||
return lhs.withPort (0) < rhs.withPort (0);
|
||||
}
|
||||
|
||||
inline bool IPAddress::EqualWithoutPort::operator() (
|
||||
IPAddress const& lhs, IPAddress const& rhs) const
|
||||
{
|
||||
return lhs.withPort (0) == rhs.withPort (0);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace std {
|
||||
|
||||
template <typename T>
|
||||
struct hash;
|
||||
|
||||
template <>
|
||||
struct hash <beast::IPAddress>
|
||||
struct hash <beast::IP::Address>
|
||||
{
|
||||
std::size_t operator() (beast::IPAddress const& value) const
|
||||
{
|
||||
std::size_t hash (0);
|
||||
if (value.isV4())
|
||||
hash = beast::IPAddress::V4::hasher() (value.v4());
|
||||
else if (value.isV6())
|
||||
hash = beast::IPAddress::V6::hasher() (value.v6());
|
||||
hash += value.port();
|
||||
return hash;
|
||||
}
|
||||
std::size_t operator() (beast::IP::Address const& addr) const
|
||||
{ return hash_value (addr); }
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
196
src/beast/beast/net/IPAddressV4.h
Normal file
196
src/beast/beast/net/IPAddressV4.h
Normal file
@@ -0,0 +1,196 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_NET_IPADDRESSV4_H_INCLUDED
|
||||
#define BEAST_NET_IPADDRESSV4_H_INCLUDED
|
||||
|
||||
#include <string>
|
||||
#include <ios>
|
||||
#include <utility>
|
||||
|
||||
#include "../CStdInt.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
/** Represents a version 4 IP address. */
|
||||
struct AddressV4
|
||||
{
|
||||
/** Default constructor represents the 'any' address. */
|
||||
AddressV4 ();
|
||||
|
||||
/** Construct from a 32-bit unsigned.
|
||||
@note Octets are formed in order from the MSB to the LSB.
|
||||
*/
|
||||
explicit AddressV4 (uint32 value_);
|
||||
|
||||
/** Construct from four individual octets..
|
||||
@note The resulting address is a.b.c.d
|
||||
*/
|
||||
AddressV4 (uint8 a, uint8 b, uint8 c, uint8 d);
|
||||
|
||||
/** Create an address from an IPv4 address string in dotted decimal form.
|
||||
@return A pair with the address, and bool set to `true` on success.
|
||||
*/
|
||||
static std::pair <AddressV4, bool> from_string (std::string const& s);
|
||||
|
||||
/** Returns an address that represents 'any' address. */
|
||||
static AddressV4 any ()
|
||||
{ return AddressV4(); }
|
||||
|
||||
/** Returns an address that represents the loopback address. */
|
||||
static AddressV4 loopback ()
|
||||
{ return AddressV4 (0x7f000001); }
|
||||
|
||||
/** Returns an address that represents the broadcast address. */
|
||||
static AddressV4 broadcast ()
|
||||
{ return AddressV4 (0xffffffff); }
|
||||
|
||||
/** Returns the broadcast address for the specified address. */
|
||||
static AddressV4 broadcast (AddressV4 const& address);
|
||||
|
||||
/** Returns the broadcast address corresponding to the address and mask. */
|
||||
static AddressV4 broadcast (
|
||||
AddressV4 const& address, AddressV4 const& mask);
|
||||
|
||||
/** Returns `true` if this is a broadcast address. */
|
||||
bool is_broadcast () const
|
||||
{ return *this == broadcast (*this); }
|
||||
|
||||
/** Returns the address class for the given address.
|
||||
@note Class 'D' represents multicast addresses (224.*.*.*).
|
||||
*/
|
||||
static char get_class (AddressV4 const& address);
|
||||
|
||||
/** Returns the netmask for the address class or address. */
|
||||
/** @{ */
|
||||
static AddressV4 netmask (char address_class);
|
||||
static AddressV4 netmask (AddressV4 const& v);
|
||||
/** @} */
|
||||
|
||||
/** Arithmetic comparison. */
|
||||
/** @{ */
|
||||
friend bool operator== (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return lhs.value == rhs.value; }
|
||||
friend bool operator< (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return lhs.value < rhs.value; }
|
||||
|
||||
friend bool operator!= (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return ! (lhs == rhs); }
|
||||
friend bool operator> (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return rhs < lhs; }
|
||||
friend bool operator<= (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return ! (lhs > rhs); }
|
||||
friend bool operator>= (AddressV4 const& lhs, AddressV4 const& rhs)
|
||||
{ return ! (rhs > lhs); }
|
||||
/** @} */
|
||||
|
||||
/** Array indexing for reading and writing indiviual octets. */
|
||||
/** @{ */
|
||||
template <bool IsConst>
|
||||
class Proxy
|
||||
{
|
||||
public:
|
||||
typedef typename std::conditional <
|
||||
IsConst, uint32 const*, uint32*>::type Pointer;
|
||||
|
||||
Proxy (int shift, Pointer value)
|
||||
: m_shift (shift)
|
||||
, m_value (value)
|
||||
{
|
||||
}
|
||||
|
||||
operator uint8() const
|
||||
{
|
||||
return ((*m_value)>>m_shift) & 0xff;
|
||||
}
|
||||
|
||||
template <typename IntegralType>
|
||||
Proxy& operator= (IntegralType v)
|
||||
{
|
||||
(*m_value) =
|
||||
( (*m_value) & (~((0xff)<<m_shift)) )
|
||||
| ((v&0xff) << m_shift);
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
private:
|
||||
int m_shift;
|
||||
Pointer m_value;
|
||||
};
|
||||
|
||||
Proxy <true> operator[] (std::size_t index) const;
|
||||
Proxy <false> operator[] (std::size_t index);
|
||||
/** @{ */
|
||||
|
||||
/** The value as a 32 bit unsigned. */
|
||||
uint32 value;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** Returns `true` if this is a loopback address. */
|
||||
bool is_loopback (AddressV4 const& addr);
|
||||
|
||||
/** Returns `true` if the address is unspecified. */
|
||||
bool is_unspecified (AddressV4 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a multicast address. */
|
||||
bool is_multicast (AddressV4 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a private unroutable address. */
|
||||
bool is_private (AddressV4 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a public routable address. */
|
||||
bool is_public (AddressV4 const& addr);
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** boost::hash support. */
|
||||
inline std::size_t hash_value (AddressV4 const& addr)
|
||||
{ return addr.value; }
|
||||
|
||||
/** Returns the address represented as a string. */
|
||||
std::string to_string (AddressV4 const& addr);
|
||||
|
||||
/** Output stream conversion. */
|
||||
template <typename OutputStream>
|
||||
OutputStream& operator<< (OutputStream& os, AddressV4 const& addr)
|
||||
{ return os << to_string (addr); }
|
||||
|
||||
/** Input stream conversion. */
|
||||
std::istream& operator>> (std::istream& is, AddressV4& addr);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace std {
|
||||
/** std::hash support. */
|
||||
template <>
|
||||
struct hash <beast::IP::AddressV4>
|
||||
{
|
||||
std::size_t operator() (beast::IP::AddressV4 const& addr) const
|
||||
{ return hash_value (addr); }
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
||||
104
src/beast/beast/net/IPAddressV6.h
Normal file
104
src/beast/beast/net/IPAddressV6.h
Normal file
@@ -0,0 +1,104 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_NET_IPADDRESSV6_H_INCLUDED
|
||||
#define BEAST_NET_IPADDRESSV6_H_INCLUDED
|
||||
|
||||
#include <string>
|
||||
#include <ios>
|
||||
#include <utility>
|
||||
|
||||
#include "../CStdInt.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
/** Represents a version 4 IP address. */
|
||||
struct AddressV6
|
||||
{
|
||||
// VFALCO TODO
|
||||
|
||||
/** Arithmetic comparison. */
|
||||
/** @{ */
|
||||
friend bool operator== (AddressV6 const&, AddressV6 const&)
|
||||
{ bassertfalse; return false; }
|
||||
friend bool operator< (AddressV6 const&, AddressV6 const&)
|
||||
{ bassertfalse; return false; }
|
||||
|
||||
friend bool operator!= (AddressV6 const& lhs, AddressV6 const& rhs)
|
||||
{ return ! (lhs == rhs); }
|
||||
friend bool operator> (AddressV6 const& lhs, AddressV6 const& rhs)
|
||||
{ return rhs < lhs; }
|
||||
friend bool operator<= (AddressV6 const& lhs, AddressV6 const& rhs)
|
||||
{ return ! (lhs > rhs); }
|
||||
friend bool operator>= (AddressV6 const& lhs, AddressV6 const& rhs)
|
||||
{ return ! (rhs > lhs); }
|
||||
/** @} */
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** Returns `true` if this is a loopback address. */
|
||||
bool is_loopback (AddressV6 const& addr);
|
||||
|
||||
/** Returns `true` if the address is unspecified. */
|
||||
bool is_unspecified (AddressV6 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a multicast address. */
|
||||
bool is_multicast (AddressV6 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a private unroutable address. */
|
||||
bool is_private (AddressV6 const& addr);
|
||||
|
||||
/** Returns `true` if the address is a public routable address. */
|
||||
bool is_public (AddressV6 const& addr);
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** boost::hash support. */
|
||||
inline std::size_t hash_value (AddressV6 const&)
|
||||
{ bassertfalse; return 0; }
|
||||
|
||||
/** Returns the address represented as a string. */
|
||||
std::string to_string (AddressV6 const& addr);
|
||||
|
||||
/** Output stream conversion. */
|
||||
template <typename OutputStream>
|
||||
OutputStream& operator<< (OutputStream& os, AddressV6 const& addr)
|
||||
{ return os << to_string (addr); }
|
||||
|
||||
/** Input stream conversion. */
|
||||
std::istream& operator>> (std::istream& is, AddressV6& addr);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace std {
|
||||
/** std::hash support. */
|
||||
template <>
|
||||
struct hash <beast::IP::AddressV6>
|
||||
{
|
||||
std::size_t operator() (beast::IP::AddressV6 const& addr) const
|
||||
{ return hash_value (addr); }
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
||||
158
src/beast/beast/net/IPEndpoint.h
Normal file
158
src/beast/beast/net/IPEndpoint.h
Normal file
@@ -0,0 +1,158 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_NET_IPENDPOINT_H_INCLUDED
|
||||
#define BEAST_NET_IPENDPOINT_H_INCLUDED
|
||||
|
||||
#include <string>
|
||||
#include <ios>
|
||||
|
||||
#include "../CStdInt.h"
|
||||
#include "IPAddress.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
typedef uint16 Port;
|
||||
|
||||
/** A version-independent IP address and port combination. */
|
||||
class Endpoint
|
||||
{
|
||||
public:
|
||||
/** Create an unspecified endpoint. */
|
||||
Endpoint ();
|
||||
|
||||
/** Create an endpoint from the address and optional port. */
|
||||
explicit Endpoint (Address const& addr, Port port = 0);
|
||||
|
||||
/** Create an Endpoint from a string.
|
||||
If the port is omitted, the endpoint will have a zero port.
|
||||
@return A pair with the endpoint, and bool set to `true` on success.
|
||||
*/
|
||||
static std::pair <Endpoint, bool> from_string_checked (std::string const& s);
|
||||
static Endpoint from_string (std::string const& s);
|
||||
static Endpoint from_string_altform (std::string const& s);
|
||||
|
||||
/** Returns a string representing the endpoint. */
|
||||
std::string to_string () const;
|
||||
|
||||
/** Returns the port number on the endpoint. */
|
||||
Port port () const
|
||||
{ return m_port; }
|
||||
|
||||
/** Returns a new Endpoint with a different port. */
|
||||
Endpoint at_port (Port port) const
|
||||
{ return Endpoint (m_addr, port); }
|
||||
|
||||
/** Returns the address portion of this endpoint. */
|
||||
Address const& address () const
|
||||
{ return m_addr; }
|
||||
|
||||
/** Convenience accessors for the address part. */
|
||||
/** @{ */
|
||||
bool is_v4 () const
|
||||
{ return m_addr.is_v4(); }
|
||||
bool is_v6 () const
|
||||
{ return m_addr.is_v6(); }
|
||||
AddressV4 const& to_v4 () const
|
||||
{ return m_addr.to_v4 (); }
|
||||
AddressV6 const& to_v6 () const
|
||||
{ return m_addr.to_v6 (); }
|
||||
/** @} */
|
||||
|
||||
/** Arithmetic comparison. */
|
||||
/** @{ */
|
||||
friend bool operator== (Endpoint const& lhs, Endpoint const& rhs);
|
||||
friend bool operator< (Endpoint const& lhs, Endpoint const& rhs);
|
||||
|
||||
friend bool operator!= (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{ return ! (lhs == rhs); }
|
||||
friend bool operator> (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{ return rhs < lhs; }
|
||||
friend bool operator<= (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{ return ! (lhs > rhs); }
|
||||
friend bool operator>= (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{ return ! (rhs > lhs); }
|
||||
/** @} */
|
||||
|
||||
private:
|
||||
Address m_addr;
|
||||
Port m_port;
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// Properties
|
||||
|
||||
/** Returns `true` if the endpoint is a loopback address. */
|
||||
inline bool is_loopback (Endpoint const& endpoint)
|
||||
{ return is_loopback (endpoint.address ()); }
|
||||
|
||||
/** Returns `true` if the endpoint is unspecified. */
|
||||
inline bool is_unspecified (Endpoint const& endpoint)
|
||||
{ return is_unspecified (endpoint.address ()); }
|
||||
|
||||
/** Returns `true` if the endpoint is a multicast address. */
|
||||
inline bool is_multicast (Endpoint const& endpoint)
|
||||
{ return is_multicast (endpoint.address ()); }
|
||||
|
||||
/** Returns `true` if the endpoint is a private unroutable address. */
|
||||
inline bool is_private (Endpoint const& endpoint)
|
||||
{ return is_private (endpoint.address ()); }
|
||||
|
||||
/** Returns `true` if the endpoint is a public routable address. */
|
||||
inline bool is_public (Endpoint const& endpoint)
|
||||
{ return is_public (endpoint.address ()); }
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
/** boost::hash support. */
|
||||
std::size_t hash_value (Endpoint const& endpoint);
|
||||
|
||||
/** Returns the endpoint represented as a string. */
|
||||
inline std::string to_string (Endpoint const& endpoint)
|
||||
{ return endpoint.to_string(); }
|
||||
|
||||
/** Output stream conversion. */
|
||||
template <typename OutputStream>
|
||||
OutputStream& operator<< (OutputStream& os, Endpoint const& endpoint)
|
||||
{
|
||||
os << to_string (endpoint);
|
||||
return os;
|
||||
}
|
||||
|
||||
/** Input stream conversion. */
|
||||
std::istream& operator>> (std::istream& is, Endpoint& endpoint);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace std {
|
||||
/** std::hash support. */
|
||||
template <>
|
||||
struct hash <beast::IP::Endpoint>
|
||||
{
|
||||
std::size_t operator() (beast::IP::Endpoint const& endpoint) const
|
||||
{ return hash_value (endpoint); }
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -25,3 +25,8 @@
|
||||
|
||||
#include "impl/DynamicBuffer.cpp"
|
||||
#include "impl/IPAddress.cpp"
|
||||
#include "impl/IPAddressV4.cpp"
|
||||
#include "impl/IPAddressV6.cpp"
|
||||
#include "impl/IPEndpoint.cpp"
|
||||
|
||||
|
||||
|
||||
89
src/beast/beast/net/detail/Parse.h
Normal file
89
src/beast/beast/net/detail/Parse.h
Normal file
@@ -0,0 +1,89 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_NET_DETAIL_PARSE_H_INCLUDED
|
||||
#define BEAST_NET_DETAIL_PARSE_H_INCLUDED
|
||||
|
||||
#include <ios>
|
||||
#include <string>
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
namespace detail {
|
||||
|
||||
/** Require and consume the specified character from the input.
|
||||
@return `true` if the character matched.
|
||||
*/
|
||||
template <typename InputStream>
|
||||
bool expect (InputStream& is, char v)
|
||||
{
|
||||
char c;
|
||||
if (is.get(c) && v == c)
|
||||
return true;
|
||||
is.unget();
|
||||
is.setstate (std::ios_base::failbit);
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Used to disambiguate 8-bit integers from characters. */
|
||||
template <typename IntType>
|
||||
struct integer_holder
|
||||
{
|
||||
IntType* pi;
|
||||
explicit integer_holder (IntType& i)
|
||||
: pi (&i)
|
||||
{
|
||||
}
|
||||
template <typename OtherIntType>
|
||||
IntType& operator= (OtherIntType o) const
|
||||
{
|
||||
*pi = o;
|
||||
return *pi;
|
||||
}
|
||||
};
|
||||
|
||||
/** Parse 8-bit unsigned integer. */
|
||||
template <typename InputStream>
|
||||
InputStream& operator>> (InputStream& is, integer_holder <uint8> const& i)
|
||||
{
|
||||
uint16 v;
|
||||
is >> v;
|
||||
if (! (v>=0 && v<=255))
|
||||
{
|
||||
is.setstate (std::ios_base::failbit);
|
||||
return is;
|
||||
}
|
||||
i = uint8(v);
|
||||
return is;
|
||||
}
|
||||
|
||||
/** Free function for template argument deduction. */
|
||||
template <typename IntType>
|
||||
integer_holder <IntType> integer (IntType& i)
|
||||
{
|
||||
return integer_holder <IntType> (i);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
File diff suppressed because it is too large
Load Diff
177
src/beast/beast/net/impl/IPAddressV4.cpp
Normal file
177
src/beast/beast/net/impl/IPAddressV4.cpp
Normal file
@@ -0,0 +1,177 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../IPAddressV4.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
AddressV4::AddressV4 ()
|
||||
: value (0)
|
||||
{
|
||||
}
|
||||
|
||||
AddressV4::AddressV4 (uint32 value_)
|
||||
: value (value_)
|
||||
{
|
||||
}
|
||||
|
||||
AddressV4::AddressV4 (uint8 a, uint8 b, uint8 c, uint8 d)
|
||||
: value ((a<<24)|(b<<16)|(c<<8)|d)
|
||||
{
|
||||
}
|
||||
|
||||
std::pair <AddressV4, bool> AddressV4::from_string (std::string const& s)
|
||||
{
|
||||
std::stringstream is (s);
|
||||
AddressV4 addr;
|
||||
is >> addr;
|
||||
if (! is.fail() && is.rdbuf()->in_avail() == 0)
|
||||
return std::make_pair (addr, true);
|
||||
return std::make_pair (AddressV4 (), false);
|
||||
}
|
||||
|
||||
AddressV4 AddressV4::broadcast (AddressV4 const& address)
|
||||
{
|
||||
return broadcast (address, netmask (address));
|
||||
}
|
||||
|
||||
AddressV4 AddressV4::broadcast (
|
||||
AddressV4 const& address, AddressV4 const& mask)
|
||||
{
|
||||
return AddressV4 (address.value | (mask.value ^ 0xffffffff));
|
||||
}
|
||||
|
||||
char AddressV4::get_class (AddressV4 const& addr)
|
||||
{
|
||||
static char const* table = "AAAABBCD";
|
||||
return table [(addr.value & 0xE0000000) >> 29];
|
||||
}
|
||||
|
||||
AddressV4 AddressV4::netmask (char address_class)
|
||||
{
|
||||
switch (address_class)
|
||||
{
|
||||
case 'A': return AddressV4 (0xff000000);
|
||||
case 'B': return AddressV4 (0xffff0000);
|
||||
case 'C': return AddressV4 (0xffffff00);
|
||||
case 'D':
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return AddressV4 (0xffffffff);
|
||||
}
|
||||
|
||||
AddressV4 AddressV4::netmask (AddressV4 const& addr)
|
||||
{
|
||||
return netmask (get_class (addr));
|
||||
}
|
||||
|
||||
AddressV4::Proxy <true> AddressV4::operator[] (std::size_t index) const
|
||||
{
|
||||
switch (index)
|
||||
{
|
||||
default:
|
||||
bassertfalse;
|
||||
case 0: return Proxy <true> (24, &value);
|
||||
case 1: return Proxy <true> (16, &value);
|
||||
case 2: return Proxy <true> ( 8, &value);
|
||||
case 3: return Proxy <true> ( 0, &value);
|
||||
};
|
||||
};
|
||||
|
||||
AddressV4::Proxy <false> AddressV4::operator[] (std::size_t index)
|
||||
{
|
||||
switch (index)
|
||||
{
|
||||
default:
|
||||
bassertfalse;
|
||||
case 0: return Proxy <false> (24, &value);
|
||||
case 1: return Proxy <false> (16, &value);
|
||||
case 2: return Proxy <false> ( 8, &value);
|
||||
case 3: return Proxy <false> ( 0, &value);
|
||||
};
|
||||
};
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
bool is_loopback (AddressV4 const& addr)
|
||||
{
|
||||
return (addr.value & 0xff000000) == 0x7f000000;
|
||||
}
|
||||
|
||||
bool is_unspecified (AddressV4 const& addr)
|
||||
{
|
||||
return addr.value == 0;
|
||||
}
|
||||
|
||||
bool is_multicast (AddressV4 const& addr)
|
||||
{
|
||||
return (addr.value & 0xf0000000) == 0xe0000000;
|
||||
}
|
||||
|
||||
bool is_private (AddressV4 const& addr)
|
||||
{
|
||||
return
|
||||
((addr.value & 0xff000000) == 0x0a000000) || // Prefix /8, 10. #.#.#
|
||||
((addr.value & 0xfff00000) == 0xac100000) || // Prefix /12 172. 16.#.# - 172.31.#.#
|
||||
((addr.value & 0xffff0000) == 0xc0a80000) || // Prefix /16 192.168.#.#
|
||||
is_loopback (addr);
|
||||
}
|
||||
|
||||
bool is_public (AddressV4 const& addr)
|
||||
{
|
||||
return
|
||||
! is_private (addr) &&
|
||||
! is_multicast (addr) &&
|
||||
(addr != AddressV4::broadcast (addr));
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
std::string to_string (AddressV4 const& addr)
|
||||
{
|
||||
std::string s;
|
||||
s.reserve (15);
|
||||
s =
|
||||
std::to_string (addr[0]) + "." +
|
||||
std::to_string (addr[1]) + "." +
|
||||
std::to_string (addr[2]) + "." +
|
||||
std::to_string (addr[3]);
|
||||
return s;
|
||||
}
|
||||
|
||||
std::istream& operator>> (std::istream& is, AddressV4& addr)
|
||||
{
|
||||
uint8 octet [4];
|
||||
is >> IP::detail::integer (octet [0]);
|
||||
for (int i = 1; i < 4; ++i)
|
||||
{
|
||||
if (!is || !IP::detail::expect (is, '.'))
|
||||
return is;
|
||||
is >> IP::detail::integer (octet [i]);
|
||||
if (!is)
|
||||
return is;
|
||||
}
|
||||
addr = AddressV4 (octet[0], octet[1], octet[2], octet[3]);
|
||||
return is;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
79
src/beast/beast/net/impl/IPAddressV6.cpp
Normal file
79
src/beast/beast/net/impl/IPAddressV6.cpp
Normal file
@@ -0,0 +1,79 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../IPAddressV6.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
bool is_loopback (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool is_unspecified (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool is_multicast (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool is_private (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool is_public (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return false;
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
std::string to_string (AddressV6 const&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return "";
|
||||
}
|
||||
|
||||
std::istream& operator>> (std::istream& is, AddressV6&)
|
||||
{
|
||||
// VFALCO TODO
|
||||
bassertfalse;
|
||||
return is;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
178
src/beast/beast/net/impl/IPEndpoint.cpp
Normal file
178
src/beast/beast/net/impl/IPEndpoint.cpp
Normal file
@@ -0,0 +1,178 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../detail/Parse.h"
|
||||
|
||||
namespace beast {
|
||||
namespace IP {
|
||||
|
||||
Endpoint::Endpoint ()
|
||||
: m_port (0)
|
||||
{
|
||||
}
|
||||
|
||||
Endpoint::Endpoint (Address const& addr, Port port)
|
||||
: m_addr (addr)
|
||||
, m_port (port)
|
||||
{
|
||||
}
|
||||
|
||||
std::pair <Endpoint, bool> Endpoint::from_string_checked (std::string const& s)
|
||||
{
|
||||
std::stringstream is (s);
|
||||
Endpoint endpoint;
|
||||
is >> endpoint;
|
||||
if (! is.fail() && is.rdbuf()->in_avail() == 0)
|
||||
return std::make_pair (endpoint, true);
|
||||
return std::make_pair (Endpoint (), false);
|
||||
}
|
||||
|
||||
Endpoint Endpoint::from_string (std::string const& s)
|
||||
{
|
||||
std::pair <Endpoint, bool> const result (
|
||||
from_string_checked (s));
|
||||
if (result.second)
|
||||
return result.first;
|
||||
return Endpoint();
|
||||
}
|
||||
|
||||
// VFALCO NOTE This is a hack to support legacy data format
|
||||
//
|
||||
Endpoint Endpoint::from_string_altform (std::string const& s)
|
||||
{
|
||||
// Accept the regular form if it parses
|
||||
{
|
||||
Endpoint ep (Endpoint::from_string (s));
|
||||
if (! is_unspecified (ep))
|
||||
return ep;
|
||||
}
|
||||
|
||||
// Now try the alt form
|
||||
std::stringstream is (s);
|
||||
|
||||
AddressV4 v4;
|
||||
is >> v4;
|
||||
if (! is.fail())
|
||||
{
|
||||
Endpoint ep (v4);
|
||||
|
||||
if (is.rdbuf()->in_avail()>0)
|
||||
{
|
||||
if (! IP::detail::expect (is, ' '))
|
||||
return Endpoint();
|
||||
|
||||
while (is.rdbuf()->in_avail()>0)
|
||||
{
|
||||
char c;
|
||||
is.get(c);
|
||||
if (c != ' ')
|
||||
{
|
||||
is.unget();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Port port;
|
||||
is >> port;
|
||||
if (is.fail())
|
||||
return Endpoint();
|
||||
|
||||
return ep.at_port (port);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Just an address with no port
|
||||
return ep;
|
||||
}
|
||||
}
|
||||
|
||||
// Could be V6 here...
|
||||
|
||||
return Endpoint();
|
||||
}
|
||||
|
||||
std::string Endpoint::to_string () const
|
||||
{
|
||||
std::string s (address ().to_string ());
|
||||
if (port() != 0)
|
||||
s = s + ":" + std::to_string (port());
|
||||
return s;
|
||||
}
|
||||
|
||||
bool operator== (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{
|
||||
return lhs.address() == rhs.address() &&
|
||||
lhs.port() == rhs.port();
|
||||
}
|
||||
|
||||
bool operator< (Endpoint const& lhs, Endpoint const& rhs)
|
||||
{
|
||||
if (lhs.address() < rhs.address())
|
||||
return true;
|
||||
if (lhs.address() > rhs.address())
|
||||
return false;
|
||||
return lhs.port() < rhs.port();
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
std::size_t hash_value (Endpoint const& endpoint)
|
||||
{
|
||||
std::size_t seed (hash_value (endpoint.address ()));
|
||||
// boost::hash_combine()
|
||||
seed ^= (std::hash <Port> () (endpoint.port ()))
|
||||
+ 0x9e3779b9 + (seed << 6) + (seed >> 2);
|
||||
return seed;
|
||||
}
|
||||
|
||||
std::istream& operator>> (std::istream& is, Endpoint& endpoint)
|
||||
{
|
||||
// VFALCO TODO Support ipv6!
|
||||
|
||||
Address addr;
|
||||
is >> addr;
|
||||
if (is.fail())
|
||||
return is;
|
||||
|
||||
if (is.rdbuf()->in_avail()>0)
|
||||
{
|
||||
char c;
|
||||
is.get(c);
|
||||
if (c != ':')
|
||||
{
|
||||
is.unget();
|
||||
endpoint = Endpoint (addr);
|
||||
return is;
|
||||
}
|
||||
|
||||
Port port;
|
||||
is >> port;
|
||||
if (is.fail())
|
||||
return is;
|
||||
|
||||
endpoint = Endpoint (addr, port);
|
||||
return is;
|
||||
}
|
||||
|
||||
endpoint = Endpoint (addr);
|
||||
return is;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -185,6 +185,15 @@ public:
|
||||
*/
|
||||
ObjectType* release() { ObjectType* const o = object; object = nullptr; return o; }
|
||||
|
||||
void reset (ObjectType* object_)
|
||||
{
|
||||
if (object != object_)
|
||||
{
|
||||
ContainerDeletePolicy <ObjectType>::destroy (object);
|
||||
object = object_;
|
||||
}
|
||||
}
|
||||
|
||||
//==============================================================================
|
||||
/** Swaps this object with that of another ScopedPointer.
|
||||
The two objects simply exchange their pointers.
|
||||
|
||||
@@ -343,9 +343,9 @@ public:
|
||||
const beast_wchar c = src.getAndAdvance();
|
||||
const size_t bytesNeeded = DestCharPointerType::getBytesRequiredFor (c);
|
||||
|
||||
maxBytes -= bytesNeeded;
|
||||
if (c == 0 || maxBytes < 0)
|
||||
if (c == 0 || maxBytes < bytesNeeded)
|
||||
break;
|
||||
maxBytes -= bytesNeeded;
|
||||
|
||||
dest.write (c);
|
||||
}
|
||||
|
||||
@@ -64,6 +64,9 @@ public:
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable: 4127) // conditional expression is constant
|
||||
#pragma warning (disable: 4146) // unary minus operator applied to unsigned type, result still unsigned
|
||||
#elif defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
// pass in a pointer to the END of a buffer..
|
||||
template <typename IntegerType>
|
||||
@@ -86,6 +89,8 @@ public:
|
||||
}
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning (pop)
|
||||
#elif defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
struct StackArrayStream : public std::basic_streambuf <char, std::char_traits <char> >
|
||||
|
||||
@@ -437,10 +437,11 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
static int const callsPerThread = 10000;
|
||||
static std::size_t const totalCalls = 10000;
|
||||
|
||||
void testThreads (std::size_t n)
|
||||
{
|
||||
std::size_t const callsPerThread (totalCalls / n);
|
||||
beginTestCase (String::fromNumber (n) + " threads");
|
||||
ServiceQueue service (n);
|
||||
std::vector <ScopedPointer <ServiceThread> > threads;
|
||||
|
||||
38
src/beast/beast/type_traits/maybe_const.h
Normal file
38
src/beast/beast/type_traits/maybe_const.h
Normal file
@@ -0,0 +1,38 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of Beast: https://github.com/vinniefalco/Beast
|
||||
Copyright 2013, Vinnie Falco <vinnie.falco@gmail.com>
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef BEAST_TYPE_TRAITS_MAYBE_CONST_H_INCLUDED
|
||||
#define BEAST_TYPE_TRAITS_MAYBE_CONST_H_INCLUDED
|
||||
|
||||
#include <type_traits>
|
||||
|
||||
namespace beast {
|
||||
|
||||
/** Makes T const or non const depending on a bool. */
|
||||
template <bool IsConst, class T>
|
||||
struct maybe_const
|
||||
{
|
||||
typedef typename std::conditional <IsConst,
|
||||
typename std::remove_const <T>::type const,
|
||||
typename std::remove_const <T>::type>::type type;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user