/commonlibrary/c_utils/base/src/ |
H A D | io_event_epoll.cpp | 92 if (events == Events::EVENT_NONE) { in ModifyEvents() 129 REventId res = Events::EVENT_NONE; in Epoll2Reactor() 131 res |= Events::EVENT_CLOSE; in Epoll2Reactor() 135 res |= Events::EVENT_ERROR; in Epoll2Reactor() 139 res |= Events::EVENT_READ; in Epoll2Reactor() 143 res |= Events::EVENT_WRITE; in Epoll2Reactor() 153 if (reactorEvent & Events::EVENT_READ) { in Reactor2Epoll() 157 if (reactorEvent & Events::EVENT_WRITE) { in Reactor2Epoll() 161 if (reactorEvent & Events::EVENT_ERROR) { in Reactor2Epoll()
|
H A D | io_event_handler.cpp | 25 :prev_(nullptr), next_(nullptr), fd_(IO_EVENT_INVALID_FD), events_(Events::EVENT_NONE), in IOEventHandler() 86 events_ |= Events::EVENT_READ; in EnableRead() 91 events_ |= Events::EVENT_WRITE; in EnableWrite() 96 events_ &= ~Events::EVENT_WRITE; in DisableWrite() 100 events_ = Events::EVENT_NONE; in DisableAll()
|
H A D | event_handler.h | 43 uint32_t Events() const { return (events_); } in Events() function in OHOS::Utils::EventHandler
|
H A D | event_demultiplexer.cpp | 80 if (handler->Events() == EventReactor::NONE_EVENT) { in UpdateEventHandler() 95 event.events = Reactor2Epoll(handler->Events()); in Update()
|
H A D | io_event_reactor.cpp | 245 if (cur->events_ != Events::EVENT_NONE && cur->enabled_ && (cur->events_ & event) && cur->cb_) { in HandleEvents()
|
/commonlibrary/rust/ylong_runtime/ylong_io/src/sys/windows/ |
H A D | events.rs | 58 pub struct Events { structure names 63 impl Events { impls 64 /// Creates a new `Events`. 65 pub fn with_capacity(cap: usize) -> Events { in with_capacity() 66 Events { in with_capacity() 72 /// Clear the Events 94 /// Returns len of Events. 100 impl fmt::Debug for Events { 106 impl<'a> IntoIterator for &'a Events { in fmt()
|
H A D | mod.rs | 37 pub use events::{Event, Events};
|
H A D | selector.rs | 34 Events, ERROR_FLAGS, READABLE_FLAGS, READ_CLOSED_FLAGS, WRITABLE_FLAGS, WRITE_CLOSED_FLAGS, 57 pub(crate) fn select(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { 104 fn select(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { in select() 121 fn select_inner(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<usize> { in select_inner()
|
/commonlibrary/rust/ylong_runtime/ylong_io/src/sys/unix/ |
H A D | kqueue.rs | 47 pub fn select(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { in select() 220 pub struct Events(Vec<Event>); structure names 222 impl Events { impls 225 Events(Vec::with_capacity(capacity)) in with_capacity() 229 impl Deref for Events { 237 impl DerefMut for Events { 245 unsafe impl Send for Events {} 246 unsafe impl Sync for Events {}
|
H A D | mod.rs | 43 pub use epoll::{Event, Events, Selector}; 50 pub use kqueue::{Event, Events, Selector};
|
H A D | epoll.rs | 54 pub fn select(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { in select() 130 pub type Events = Vec<Event>; in fmt() types
|
/commonlibrary/rust/ylong_runtime/ylong_io/src/ |
H A D | poll.rs | 17 use crate::{Events, Interest, Selector, Source, Token}; 37 pub fn poll(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { in poll()
|
H A D | lib.rs | 25 pub use sys::{Event, EventTrait, Events, Selector};
|
/commonlibrary/rust/ylong_runtime/ylong_io/examples/ |
H A D | ylong_io_tcp_server.rs | 23 use ylong_io::{EventTrait, Events, Interest, Poll, TcpListener, Token}; 34 let mut events = Events::with_capacity(128); in main()
|
/commonlibrary/c_utils/base/test/benchmarktest/event_benchmark_test/ |
H A D | event_benchmark_test.cpp | 132 handler->SetEvents(Events::EVENT_READ | Events::EVENT_WRITE); in BENCHMARK_F() 133 AssertEqual(handler->GetEvents(), (Events::EVENT_READ | Events::EVENT_WRITE), in BENCHMARK_F() 134 "handler->GetEvents() did not equal (Events::EVENT_READ | Events::EVENT_WRITE) as expected.", state); in BENCHMARK_F() 143 AssertEqual(handler->GetEvents(), Events::EVENT_NONE, in BENCHMARK_F() 144 "handler->GetEvents() did not equal Events::EVENT_NONE as expected.", state); in BENCHMARK_F() 149 AssertEqual(handler->GetEvents(), (Events::EVENT_READ | Events in BENCHMARK_F() [all...] |
/commonlibrary/rust/ylong_runtime/ylong_runtime/src/net/ |
H A D | driver.rs | 33 use ylong_io::{Events, Poll}; 65 events: Option<Events>, 202 let events = Events::with_capacity(EVENTS_MAX_CAPACITY);
|
/commonlibrary/c_utils/base/include/ |
H A D | io_event_common.h | 35 namespace Events { namespace
|
H A D | io_event_handler.h | 29 explicit IOEventHandler(int fd, EventId events = Events::EVENT_NONE, const EventCallback& cb = nullptr);
|
H A D | io_event_reactor.h | 82 events = Events::EVENT_NONE; in FdEvents()
|
/commonlibrary/c_utils/base/test/unittest/common/ |
H A D | utils_event_test.cpp | 98 handler->SetEvents(Events::EVENT_READ | Events::EVENT_WRITE); in HWTEST_F() 99 EXPECT_EQ(handler->GetEvents(), Events::EVENT_READ | Events::EVENT_WRITE); in HWTEST_F() 108 EXPECT_EQ(handler->GetEvents(), Events::EVENT_NONE); in HWTEST_F() 113 EXPECT_EQ(handler->GetEvents(), Events::EVENT_READ | Events::EVENT_WRITE); in HWTEST_F() 117 EXPECT_EQ(handler->GetEvents(), Events::EVENT_READ); in HWTEST_F() 142 EXPECT_EQ(handler->GetEvents(), Events::EVENT_READ); in HWTEST_F() 386 handler->SetEvents(Events in HWTEST_F() [all...] |
/commonlibrary/rust/ylong_runtime/ylong_io/tests/ |
H A D | uds_test.rs | 23 use ylong_io::{EventTrait, Events, Interest, Poll, Token, UnixDatagram, UnixListener, UnixStream}; 74 let mut events = Events::with_capacity(128); in server()
|