mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 17:42:43 +00:00 
			
		
		
		
	 0b7baa7e5a
			
		
	
	
		0b7baa7e5a
		
	
	
	
	
		
			
			https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cother-other-default-operation-rules "The compiler is more likely to get the default semantics right and you cannot implement these functions better than the compiler."
		
			
				
	
	
		
			36 lines
		
	
	
	
		
			1,002 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
	
		
			1,002 B
		
	
	
	
		
			C++
		
	
	
	
	
	
| /*
 | |
|  * Copyright (c) 2021, Jan de Visser <jan@de-visser.net>
 | |
|  *
 | |
|  * SPDX-License-Identifier: BSD-2-Clause
 | |
|  */
 | |
| 
 | |
| #pragma once
 | |
| 
 | |
| #include <AK/HashMap.h>
 | |
| #include <LibIPC/ConnectionFromClient.h>
 | |
| #include <SQLServer/SQLClientEndpoint.h>
 | |
| #include <SQLServer/SQLServerEndpoint.h>
 | |
| 
 | |
| namespace SQLServer {
 | |
| 
 | |
| class ConnectionFromClient final
 | |
|     : public IPC::ConnectionFromClient<SQLClientEndpoint, SQLServerEndpoint> {
 | |
|     C_OBJECT(ConnectionFromClient);
 | |
| 
 | |
| public:
 | |
|     virtual ~ConnectionFromClient() override = default;
 | |
| 
 | |
|     virtual void die() override;
 | |
| 
 | |
|     static RefPtr<ConnectionFromClient> client_connection_for(int client_id);
 | |
| 
 | |
| private:
 | |
|     explicit ConnectionFromClient(NonnullOwnPtr<Core::Stream::LocalSocket>, int client_id);
 | |
| 
 | |
|     virtual Messages::SQLServer::ConnectResponse connect(String const&) override;
 | |
|     virtual Messages::SQLServer::SqlStatementResponse sql_statement(int, String const&) override;
 | |
|     virtual void statement_execute(int) override;
 | |
|     virtual void disconnect(int) override;
 | |
| };
 | |
| 
 | |
| }
 |