citra/src/core/hle/kernel/kernel.h

47 lines
1 KiB
C++
Raw Normal View History

2014-05-10 04:11:18 +02:00
// Copyright 2014 Citra Emulator Project / PPSSPP Project
2014-12-17 06:38:14 +01:00
// Licensed under GPLv2 or any later version
// Refer to the license.txt file included.
2014-05-10 04:11:18 +02:00
#pragma once
#include <string>
#include <boost/smart_ptr/intrusive_ptr.hpp>
2015-05-06 09:06:12 +02:00
#include "common/common_types.h"
2014-05-10 04:11:18 +02:00
namespace Kernel {
class AddressArbiter;
2018-10-11 21:48:16 +02:00
class Event;
enum class ResetType {
OneShot,
Sticky,
Pulse,
};
template <typename T>
using SharedPtr = boost::intrusive_ptr<T>;
2018-10-11 20:49:52 +02:00
class KernelSystem {
public:
explicit KernelSystem(u32 system_mode);
~KernelSystem();
/**
* Creates an address arbiter.
*
* @param name Optional name used for debugging.
* @returns The created AddressArbiter.
*/
SharedPtr<AddressArbiter> CreateAddressArbiter(std::string name = "Unknown");
2018-10-11 21:48:16 +02:00
/**
* Creates an event
* @param reset_type ResetType describing how to create event
* @param name Optional name of event
*/
SharedPtr<Event> CreateEvent(ResetType reset_type, std::string name = "Unknown");
2018-10-11 20:49:52 +02:00
};
} // namespace Kernel