/* * Copyright (c) 2018-2020 Atmosphère-NX * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #pragma once #include namespace ams::htcs::server { class ManagerServiceObject : public sf::ISharedObject { public: Result Socket(sf::Out out_err, sf::Out out_sock); Result Close(sf::Out out_err, sf::Out out_res, s32 desc); Result Connect(sf::Out out_err, sf::Out out_res, s32 desc, const htcs::SockAddrHtcs &address); Result Bind(sf::Out out_err, sf::Out out_res, s32 desc, const htcs::SockAddrHtcs &address); Result Listen(sf::Out out_err, sf::Out out_res, s32 desc, s32 backlog_count); Result Accept(sf::Out out_err, sf::Out out_res, sf::Out out_address, s32 desc); Result Recv(sf::Out out_err, sf::Out out_size, const sf::OutBuffer &buffer, s32 desc, s32 flags); Result Send(sf::Out out_err, sf::Out out_size, s32 desc, const sf::InBuffer &buffer, s32 flags); Result Shutdown(sf::Out out_err, sf::Out out_res, s32 desc, s32 how); Result Fcntl(sf::Out out_err, sf::Out out_res, s32 desc, s32 command, s32 value); Result GetPeerNameAny(sf::Out out); Result GetDefaultHostName(sf::Out out); Result CreateSocketOld(sf::Out out_err, sf::Out> out); Result CreateSocket(sf::Out out_err, sf::Out> out, bool enable_disconnection_emulation); Result RegisterProcessId(const sf::ClientProcessId &client_pid); Result MonitorManager(const sf::ClientProcessId &client_pid); Result StartSelect(sf::Out out_task_id, sf::OutCopyHandle out_event, const sf::InMapAliasArray &read_handles, const sf::InMapAliasArray &write_handles, const sf::InMapAliasArray &exception_handles, s64 tv_sec, s64 tv_usec); Result EndSelect(sf::Out out_err, sf::Out out_res, const sf::OutMapAliasArray &read_handles, const sf::OutMapAliasArray &write_handles, const sf::OutMapAliasArray &exception_handles, u32 task_id); }; static_assert(tma::IsIHtcsManager); }