Home
last modified time | relevance | path

Searched refs:Events (Results 1 - 21 of 21) sorted by relevance

/commonlibrary/c_utils/base/src/
H A Dio_event_epoll.cpp92 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 Dio_event_handler.cpp25 :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 Devent_handler.h43 uint32_t Events() const { return (events_); } in Events() function in OHOS::Utils::EventHandler
H A Devent_demultiplexer.cpp80 if (handler->Events() == EventReactor::NONE_EVENT) { in UpdateEventHandler()
95 event.events = Reactor2Epoll(handler->Events()); in Update()
H A Dio_event_reactor.cpp245 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 Devents.rs58 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 Dmod.rs37 pub use events::{Event, Events};
H A Dselector.rs34 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 Dkqueue.rs47 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 Dmod.rs43 pub use epoll::{Event, Events, Selector};
50 pub use kqueue::{Event, Events, Selector};
H A Depoll.rs54 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 Dpoll.rs17 use crate::{Events, Interest, Selector, Source, Token};
37 pub fn poll(&self, events: &mut Events, timeout: Option<Duration>) -> io::Result<()> { in poll()
H A Dlib.rs25 pub use sys::{Event, EventTrait, Events, Selector};
/commonlibrary/rust/ylong_runtime/ylong_io/examples/
H A Dylong_io_tcp_server.rs23 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 Devent_benchmark_test.cpp132 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 Ddriver.rs33 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 Dio_event_common.h35 namespace Events { namespace
H A Dio_event_handler.h29 explicit IOEventHandler(int fd, EventId events = Events::EVENT_NONE, const EventCallback& cb = nullptr);
H A Dio_event_reactor.h82 events = Events::EVENT_NONE; in FdEvents()
/commonlibrary/c_utils/base/test/unittest/common/
H A Dutils_event_test.cpp98 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 Duds_test.rs23 use ylong_io::{EventTrait, Events, Interest, Poll, Token, UnixDatagram, UnixListener, UnixStream};
74 let mut events = Events::with_capacity(128); in server()

Completed in 9 milliseconds