#include "ui/webui/examples/browser/devtools/devtools_server.h"
#include "base/atomicops.h"
#include "base/command_line.h"
#include "base/files/file_path.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/devtools_agent_host.h"
#include "content/public/browser/devtools_socket_factory.h"
#include "content/public/common/content_switches.h"
#include "net/base/net_errors.h"
#include "net/socket/tcp_server_socket.h"
namespace webui_examples::devtools {
namespace {
base::subtle::Atomic32 g_last_used_port;
class TCPServerSocketFactory : public content::DevToolsSocketFactory { … };
}
void StartHttpHandler(content::BrowserContext* browser_context) { … }
void StopHttpHandler() { … }
int GetHttpHandlerPort() { … }
}