Remove deprecated stuff

It was breaking encapsulation
This commit is contained in:
Dawid Drozd 2018-07-24 13:03:15 +02:00
parent 1e7500607b
commit 66a7945084
2 changed files with 0 additions and 39 deletions

View File

@ -11,36 +11,6 @@
namespace Dexode
{
class [[deprecated("This class will be removed, is breaking API")]] BusAttorney
{
public:
BusAttorney(std::shared_ptr<EventBus> bus)
: _bus(std::move(bus))
{
}
/**
* Notify all listeners for event
*
* @param event your event struct
*/
template<typename Event>
[[deprecated]]
void notify(const Event& event) const
{
_bus->notify(event);
}
[[deprecated]]
std::shared_ptr<EventBus> extract() const
{
return _bus;
}
private:
std::shared_ptr<EventBus> _bus;
};
class EventCollector
{
public:
@ -93,10 +63,6 @@ public:
bool isUsing(const std::shared_ptr<EventBus>& bus) const;
///I wan't explicitly say getBus. Ok we could add method for notify but this is more explicit
[[deprecated("This method will be removed, is breaking encapsulation")]]
BusAttorney getBus() const;
private:
int _token = 0;
std::shared_ptr<EventBus> _bus;

View File

@ -87,11 +87,6 @@ void EventCollector::unlistenAll()
}
}
BusAttorney EventCollector::getBus() const
{
return BusAttorney{_bus};
}
bool EventCollector::isUsing(const std::shared_ptr<EventBus>& bus) const
{
return _bus == bus;