Tidy up includes

This commit is contained in:
Vinnie Falco
2014-03-24 07:21:19 -07:00
parent c51ac9d6da
commit eb122f45f9
24 changed files with 78 additions and 12 deletions

View File

@@ -20,6 +20,8 @@
#ifndef BEAST_ASIO_BASICS_SSLCONTEXT_H_INCLUDED
#define BEAST_ASIO_BASICS_SSLCONTEXT_H_INCLUDED
#include <boost/asio/ssl/context.hpp>
namespace beast {
namespace asio {

View File

@@ -20,6 +20,8 @@
#ifndef BEAST_ASIO_HTTPFIELD_H_INCLUDED
#define BEAST_ASIO_HTTPFIELD_H_INCLUDED
#include "../../../beast/strings/String.h"
namespace beast {
/** A single header.

View File

@@ -20,6 +20,10 @@
#ifndef BEAST_ASIO_HTTPHEADERS_H_INCLUDED
#define BEAST_ASIO_HTTPHEADERS_H_INCLUDED
#include "HTTPField.h"
#include "../../beast_core/text/StringPairArray.h"
namespace beast {
/** A set of HTTP headers. */

View File

@@ -20,7 +20,12 @@
#ifndef BEAST_ASIO_HTTPMESSAGE_H_INCLUDED
#define BEAST_ASIO_HTTPMESSAGE_H_INCLUDED
#include "HTTPHeaders.h"
#include "HTTPVersion.h"
#include "../../../beast/smart_ptr/SharedObject.h"
#include "../../../beast/net/DynamicBuffer.h"
#include "../../beast_core/text/StringPairArray.h"
namespace beast {

View File

@@ -20,6 +20,9 @@
#ifndef BEAST_ASIO_HTTPPARSER_H_INCLUDED
#define BEAST_ASIO_HTTPPARSER_H_INCLUDED
#include "HTTPRequest.h"
#include "HTTPResponse.h"
namespace beast {
class HTTPParserImpl;

View File

@@ -20,6 +20,8 @@
#ifndef BEAST_ASIO_HTTPREQUEST_H_INCLUDED
#define BEAST_ASIO_HTTPREQUEST_H_INCLUDED
#include "HTTPMessage.h"
namespace beast {
class HTTPRequest : public HTTPMessage

View File

@@ -20,6 +20,9 @@
#ifndef BEAST_ASIO_HANDSHAKE_HANDSHAKEDETECTLOGICPROXY_H_INCLUDED
#define BEAST_ASIO_HANDSHAKE_HANDSHAKEDETECTLOGICPROXY_H_INCLUDED
#include "HandshakeDetectLogic.h"
#include "InputParser.h"
namespace beast {
namespace asio {

View File

@@ -20,6 +20,8 @@
#ifndef BEAST_ASIO_HANDSHAKE_INPUTPARSER_H_INCLUDED
#define BEAST_ASIO_HANDSHAKE_INPUTPARSER_H_INCLUDED
#include "../basics/FixedInputBuffer.h"
namespace beast {
namespace asio {

View File

@@ -35,7 +35,7 @@ namespace beast {
@see String, StringPairArray
*/
class StringArray : LeakChecked <StringArray>
class StringArray
{
public:
//==============================================================================

View File

@@ -20,7 +20,11 @@
#ifndef RIPPLE_COMMON_MULTISOCKET_H_INCLUDED
#define RIPPLE_COMMON_MULTISOCKET_H_INCLUDED
#include "../../beast/modules/beast_asio/beast_asio.h"
#include "../../beast/beast/asio/abstract_socket.h"
#include "../../beast/beast/net/IPEndpoint.h"
#include "../../beast/modules/beast_asio/protocol/HandshakeDetectLogicPROXY.h"
#include <boost/asio/ip/tcp.hpp>
namespace ripple {

View File

@@ -20,7 +20,7 @@
#ifndef RIPPLE_COMMON_SSLCONTEXT_H_INCLUDED
#define RIPPLE_COMMON_SSLCONTEXT_H_INCLUDED
#include "../../beast/modules/beast_asio/beast_asio.h"
#include "../../beast/modules/beast_asio/basics/SSLContext.h"
#include <string>

View File

@@ -20,6 +20,11 @@
#ifndef RIPPLE_HTTP_PORT_H_INCLUDED
#define RIPPLE_HTTP_PORT_H_INCLUDED
#include "../../beast/beast/net/IPEndpoint.h"
#include "../../beast/modules/beast_asio/basics/SSLContext.h"
#include <cstdint>
namespace ripple {
namespace HTTP {

View File

@@ -20,6 +20,11 @@
#ifndef RIPPLE_HTTP_SESSION_H_INCLUDED
#define RIPPLE_HTTP_SESSION_H_INCLUDED
#include "../../beast/beast/smart_ptr/SharedPtr.h"
#include "../../beast/beast/net/IPEndpoint.h"
#include "../../beast/beast/utility/Journal.h"
#include "../../beast/modules/beast_asio/http/HTTPRequest.h"
#include <ostream>
namespace ripple {
@@ -31,9 +36,12 @@ namespace HTTP {
Some fields are input parameters, some are output parameters,
and all only become defined during specific callbacks.
*/
class Session : public beast::Uncopyable
class Session
{
public:
Session() = default;
Session (Session const&) = delete;
/** A user-definable pointer.
The initial value is always zero.
Changes to the value are persisted between calls.

View File

@@ -20,10 +20,15 @@
#ifndef RIPPLE_HTTP_PEER_H_INCLUDED
#define RIPPLE_HTTP_PEER_H_INCLUDED
#include <memory>
#include "../api/Session.h"
#include "../../ripple/common/MultiSocket.h"
#include "../../beast/modules/beast_asio/async/AsyncObject.h"
#include "../../beast/modules/beast_asio/basics/SharedArg.h"
#include "../../beast/modules/beast_asio/http/HTTPRequestParser.h"
#include <memory>
namespace ripple {
namespace HTTP {

View File

@@ -20,6 +20,9 @@
#ifndef RIPPLE_HTTP_SERVERIMPL_H_INCLUDED
#define RIPPLE_HTTP_SERVERIMPL_H_INCLUDED
#include "../../beast/beast/threads/Thread.h"
#include "../../beast/modules/beast_asio/basics/SharedArg.h"
namespace ripple {
namespace HTTP {

View File

@@ -20,6 +20,8 @@
#ifndef RIPPLE_HTTP_H_INCLUDED
#define RIPPLE_HTTP_H_INCLUDED
// VFALCO This entire file is deprecated now, I'm working on a replacement
// VFALCO NOTE this sucks that we have to include asio in the header
// just for HTTPMessage!!
#include "../../beast/modules/beast_asio/beast_asio.h"

View File

@@ -17,11 +17,16 @@
*/
//==============================================================================
#include "Tuning.h"
#include "../../ripple/common/seconds_clock.h"
#include "../../ripple_rpc/api/Manager.h"
#include "../../ripple_overlay/api/make_Overlay.h"
#include "../../ripple_overlay/api/make_Overlay.h"
#include "../../ripple/common/seconds_clock.h"
#include "../../ripple_rpc/api/Manager.h"
#include "Tuning.h"
#include "../../beast/modules/beast_core/thread/DeadlineTimer.h"
namespace ripple {

View File

@@ -20,6 +20,8 @@
#ifndef RIPPLE_FATALERRORREPORTER_H_INCLUDED
#define RIPPLE_FATALERRORREPORTER_H_INCLUDED
#include "../../beast/modules/beast_core/diagnostic/FatalError.h"
namespace ripple {
/** FatalError reporter.

View File

@@ -17,6 +17,10 @@
*/
//==============================================================================
#include "../../beast/modules/beast_core/text/LexicalCast.h"
#include <string>
namespace ripple {
SETUP_LOG (HTTPRequest)

View File

@@ -56,7 +56,6 @@ public:
void startListening ()
{
// VFALCO NOTE Why not use make_shared?
RPCServerImp::pointer new_connection (boost::make_shared <RPCServerImp> (
boost::ref (mAcceptor.get_io_service ()),
boost::ref (m_sslContext->get ()),
@@ -130,16 +129,15 @@ private:
RPCServer::Handler& m_rpcServerHandler;
boost::asio::ip::tcp::acceptor mAcceptor;
boost::asio::deadline_timer mDelayTimer;
beast::ScopedPointer <RippleSSLContext> m_sslContext;
std::unique_ptr <RippleSSLContext> m_sslContext;
};
//------------------------------------------------------------------------------
// VFALCO TODO Return std::unique_ptr here
RPCDoor* RPCDoor::New (boost::asio::io_service& io_service, RPCServer::Handler& handler)
{
beast::ScopedPointer <RPCDoor> result (new RPCDoorImp (io_service, handler));
return result.release ();
return new RPCDoorImp (io_service, handler);
}
}

View File

@@ -17,6 +17,8 @@
*/
//==============================================================================
#include "../../beast/beast/threads/Thread.h"
namespace ripple {
SETUP_LOG (SNTPClient)

View File

@@ -17,6 +17,8 @@
*/
//==============================================================================
#include "../../beast/beast/asio/IPAddressConversion.h"
namespace ripple {
SETUP_LOG (RPCServer)

View File

@@ -33,6 +33,8 @@
// just include what is needed.
#include "../../ripple_app/ripple_app.h"
#include "../../beast/beast/asio/IPAddressConversion.h"
#include <cstdint>
namespace ripple {

View File

@@ -27,6 +27,7 @@
#include "../ripple_net/ripple_net.h"
#include "../beast/modules/beast_core/text/LexicalCast.h"
#include "../beast/modules/beast_core/system/BeforeBoost.h"
#include <boost/asio.hpp>
#include <boost/asio/ssl.hpp>