| /external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/ |
| D | ShadowHandlerTest.java | 10 import android.os.Handler; 29 private Handler.Callback callback = new Handler.Callback() { 48 Handler handler1 = new Handler(looper); in testInsertsRunnablesBasedOnLooper() 51 Handler handler2 = new Handler(looper); in testInsertsRunnablesBasedOnLooper() 61 Handler handler1 = new Handler(); in testDefaultConstructorUsesDefaultLooper() 64 Handler handler2 = new Handler(Looper.myLooper()); in testDefaultConstructorUsesDefaultLooper() 86 Handler handler1 = new Handler(looper1); in testDifferentLoopersGetDifferentQueues() 89 Handler handler2 = new Handler(looper2); in testDifferentLoopersGetDifferentQueues() 99 Handler handler = new Handler(callback); in shouldCallProvidedHandlerCallback() local 100 handler.sendMessage(new Message()); in shouldCallProvidedHandlerCallback() [all …]
|
| /external/robolectric/robolectric/src/test/java/org/robolectric/shadows/ |
| D | ShadowHandlerTest.java | 10 import android.os.Handler; 33 private final Handler.Callback callback = 34 new Handler.Callback() { 53 Handler handler1 = new Handler(looper); in testInsertsRunnablesBasedOnLooper() 56 Handler handler2 = new Handler(looper); in testInsertsRunnablesBasedOnLooper() 66 Handler handler1 = new Handler(); in testDefaultConstructorUsesDefaultLooper() 69 Handler handler2 = new Handler(Looper.myLooper()); in testDefaultConstructorUsesDefaultLooper() 92 Handler handler1 = new Handler(looper1); in testDifferentLoopersGetDifferentQueues() 95 Handler handler2 = new Handler(looper2); in testDifferentLoopersGetDifferentQueues() 105 Handler handler = new Handler(callback); in shouldCallProvidedHandlerCallback() local [all …]
|
| /external/parameter-framework/asio-1.10.6/include/asio/detail/ |
| D | bind_handler.hpp | 25 template <typename Handler, typename Arg1> 29 binder1(const Handler& handler, const Arg1& arg1) in binder1() argument 30 : handler_(handler), in binder1() 35 binder1(Handler& handler, const Arg1& arg1) in binder1() argument 36 : handler_(ASIO_MOVE_CAST(Handler)(handler)), in binder1() 52 Handler handler_; 56 template <typename Handler, typename Arg1> 58 binder1<Handler, Arg1>* this_handler) in asio_handler_allocate() argument 64 template <typename Handler, typename Arg1> 66 binder1<Handler, Arg1>* this_handler) in asio_handler_deallocate() argument [all …]
|
| D | wrapped_handler.hpp | 27 template <typename Dispatcher, typename Handler> 28 bool operator()(Dispatcher&, Handler& handler) const in operator ()() 30 return asio_handler_cont_helpers::is_continuation(handler); in operator ()() 36 template <typename Dispatcher, typename Handler> 37 bool operator()(Dispatcher& dispatcher, Handler&) const in operator ()() 43 template <typename Dispatcher, typename Handler, 50 wrapped_handler(Dispatcher dispatcher, Handler& handler) in wrapped_handler() argument 52 handler_(ASIO_MOVE_CAST(Handler)(handler)) in wrapped_handler() 64 handler_(ASIO_MOVE_CAST(Handler)(other.handler_)) in wrapped_handler() 70 dispatcher_.dispatch(ASIO_MOVE_CAST(Handler)(handler_)); in operator ()() [all …]
|
| D | reactive_socket_service.hpp | 221 template <typename ConstBufferSequence, typename Handler> 225 Handler& handler) in async_send_to() argument 228 asio_handler_cont_helpers::is_continuation(handler); in async_send_to() 230 // Allocate and construct an operation to wrap the handler. in async_send_to() 232 endpoint_type, Handler> op; in async_send_to() 233 typename op::ptr p = { asio::detail::addressof(handler), in async_send_to() 235 sizeof(op), handler), 0 }; in async_send_to() 236 p.p = new (p.v) op(impl.socket_, buffers, destination, flags, handler); in async_send_to() 245 template <typename Handler> 247 const endpoint_type&, socket_base::message_flags, Handler& handler) in async_send_to() argument [all …]
|
| D | reactive_socket_service_base.hpp | 62 // Destroy all user-defined handler objects owned by the service. 193 template <typename ConstBufferSequence, typename Handler> 196 socket_base::message_flags flags, Handler& handler) in async_send() argument 199 asio_handler_cont_helpers::is_continuation(handler); in async_send() 201 // Allocate and construct an operation to wrap the handler. in async_send() 202 typedef reactive_socket_send_op<ConstBufferSequence, Handler> op; in async_send() 203 typename op::ptr p = { asio::detail::addressof(handler), in async_send() 205 sizeof(op), handler), 0 }; in async_send() 206 p.p = new (p.v) op(impl.socket_, buffers, flags, handler); in async_send() 218 template <typename Handler> [all …]
|
| /external/grpc-grpc/test/core/tsi/alts/frame_protector/ |
| D | frame_handler_test.cc | 44 frame_handler* handler = in create_frame_handler() local 46 handler->writer = alts_create_frame_writer(); in create_frame_handler() 47 handler->reader = alts_create_frame_reader(); in create_frame_handler() 48 handler->buffer = nullptr; in create_frame_handler() 49 handler->buffer_size = 0; in create_frame_handler() 50 return handler; in create_frame_handler() 53 static void destroy_frame_handler(frame_handler* handler) { in destroy_frame_handler() argument 54 if (handler != nullptr) { in destroy_frame_handler() 55 alts_destroy_frame_reader(handler->reader); in destroy_frame_handler() 56 alts_destroy_frame_writer(handler->writer); in destroy_frame_handler() [all …]
|
| /external/ow2-asm/asm/src/test/java/org/objectweb/asm/ |
| D | HandlerTest.java | 35 * Unit tests for {@link Handler}. 49 Handler handler = new Handler(startPc, endPc, handlerPc, catchType, catchDescriptor); in testConstructor() local 51 assertEquals(startPc, handler.startPc); in testConstructor() 52 assertEquals(endPc, handler.endPc); in testConstructor() 53 assertEquals(handlerPc, handler.handlerPc); in testConstructor() 54 assertEquals(catchType, handler.catchType); in testConstructor() 55 assertEquals(catchDescriptor, handler.catchTypeDescriptor); in testConstructor() 65 Handler handler1 = new Handler(startPc1, endPc1, handlerPc, catchType, catchDescriptor); in testCopyConstructor() 69 Handler handler2 = new Handler(handler1, startPc2, endPc2); in testCopyConstructor() 80 Handler handler = newHandler(10, 20); in testRemoveRange_removeAllOrNothing() local [all …]
|
| /external/apache-harmony/logging/src/test/java/org/apache/harmony/logging/tests/java/util/logging/ |
| D | MemoryHandlerTest.java | 28 import java.util.logging.Handler; 58 MemoryHandler handler; field in MemoryHandlerTest 60 Handler target = new MockHandler(); 71 handler = new MemoryHandler(); in setUp() 102 Filter filter = handler.getFilter(); in testClose() 103 Formatter formatter = handler.getFormatter(); in testClose() 105 handler.close(); in testClose() 107 assertEquals(handler.getFilter(), filter); in testClose() 108 assertEquals(handler.getFormatter(), formatter); in testClose() 109 assertNull(handler.getEncoding()); in testClose() [all …]
|
| D | FileHandlerTest.java | 34 import java.util.logging.Handler; 59 FileHandler handler; field in FileHandlerTest 73 handler = new FileHandler(); in setUp() 97 if (null != handler) { in tearDown() 98 handler.close(); in tearDown() 169 assertEquals(handler.getEncoding(), "iso-8859-1"); in testFileHandler() 170 assertTrue(handler.getFilter() instanceof MockFilter); in testFileHandler() 171 assertTrue(handler.getFormatter() instanceof MockFormatter); in testFileHandler() 172 assertEquals(handler.getLevel(), Level.FINE); in testFileHandler() 173 assertNotNull(handler.getErrorManager()); in testFileHandler() [all …]
|
| /external/ow2-asm/asm/src/main/java/org/objectweb/asm/ |
| D | Handler.java | 31 * Information about an exception handler. Corresponds to an element of the exception_table array of 32 * a Code attribute, as defined in the Java Virtual Machine Specification (JVMS). Handler instances 40 final class Handler { class 44 * exception handler's scope (inclusive). 50 * handler's scope (exclusive). 56 * exception handler's code. 62 * internal name of the type of exceptions handled by this handler, or 0 to catch any exceptions. 67 * The internal name of the type of exceptions handled by this handler, or {@literal null} to 72 /** The next exception handler. */ 73 Handler nextHandler; [all …]
|
| /external/grpc-grpc/src/python/grpcio_testing/grpc_testing/_channel/ |
| D | _invocation.py | 25 def _cancel(handler): argument 26 return handler.cancel(grpc.StatusCode.CANCELLED, 'Locally cancelled!') 29 def _is_active(handler): argument 30 return handler.is_active() 37 def _add_callback(handler, callback): argument 38 return handler.add_callback(callback) 41 def _initial_metadata(handler): argument 42 return handler.initial_metadata() 45 def _trailing_metadata(handler): argument 46 trailing_metadata, unused_code, unused_details = handler.termination() [all …]
|
| /external/grpc-grpc/src/objective-c/tests/ |
| D | RxLibraryUnitTests.m | 37 + (instancetype)handler; class 41 + (instancetype)handler { class 69 CapturingSingleValueHandler *handler = [CapturingSingleValueHandler handler]; 73 id<GRXWriteable> writeable = [GRXWriteable writeableWithSingleHandler:handler.block]; 78 XCTAssertEqual(handler.timesCalled, 1); 79 XCTAssertEqualObjects(handler.value, anyValue); 80 XCTAssertEqualObjects(handler.errorOrNil, nil); 85 CapturingSingleValueHandler *handler = [CapturingSingleValueHandler handler]; 89 id<GRXWriteable> writeable = [GRXWriteable writeableWithSingleHandler:handler.block]; 93 XCTAssertEqual(handler.timesCalled, 1); [all …]
|
| /external/exoplayer/tree_8e57d3715f9092d5ec54ebe2e538f34bfcc34479/library/common/src/main/java/com/google/android/exoplayer2/util/ |
| D | SystemHandlerWrapper.java | 20 import android.os.Handler; 35 private final android.os.Handler handler; field in SystemHandlerWrapper 37 public SystemHandlerWrapper(android.os.Handler handler) { in SystemHandlerWrapper() argument 38 this.handler = handler; in SystemHandlerWrapper() 43 return handler.getLooper(); in getLooper() 48 return handler.hasMessages(what); in hasMessages() 53 return obtainSystemMessage().setMessage(handler.obtainMessage(what), /* handler= */ this); in obtainMessage() 58 return obtainSystemMessage().setMessage(handler.obtainMessage(what, obj), /* handler= */ this); in obtainMessage() 64 .setMessage(handler.obtainMessage(what, arg1, arg2), /* handler= */ this); in obtainMessage() 70 .setMessage(handler.obtainMessage(what, arg1, arg2, obj), /* handler= */ this); in obtainMessage() [all …]
|
| /external/exoplayer/tree_15dc86382f17a24a3e881e52e31a810c1ea44b49/library/common/src/main/java/com/google/android/exoplayer2/util/ |
| D | SystemHandlerWrapper.java | 20 import android.os.Handler; 35 private final android.os.Handler handler; field in SystemHandlerWrapper 37 public SystemHandlerWrapper(android.os.Handler handler) { in SystemHandlerWrapper() argument 38 this.handler = handler; in SystemHandlerWrapper() 43 return handler.getLooper(); in getLooper() 48 return handler.hasMessages(what); in hasMessages() 53 return obtainSystemMessage().setMessage(handler.obtainMessage(what), /* handler= */ this); in obtainMessage() 58 return obtainSystemMessage().setMessage(handler.obtainMessage(what, obj), /* handler= */ this); in obtainMessage() 64 .setMessage(handler.obtainMessage(what, arg1, arg2), /* handler= */ this); in obtainMessage() 70 .setMessage(handler.obtainMessage(what, arg1, arg2, obj), /* handler= */ this); in obtainMessage() [all …]
|
| /external/parameter-framework/asio-1.10.6/include/asio/ |
| D | handler_type.hpp | 21 /// Default handler type traits provided for all handlers. 23 * The handler_type traits class is used for determining the concrete handler 24 * type to be used for an asynchronous operation. It allows the handler type to 25 * be determined at the point where the specific completion handler signature 28 * This template may be specialised for user-defined handler types. 30 template <typename Handler, typename Signature> 33 /// The handler type for the specific signature. 34 typedef Handler type; 38 template <typename Handler, typename Signature> 39 struct handler_type<const Handler, Signature> [all …]
|
| /external/grpc-grpc/src/python/grpcio_testing/grpc_testing/_server/ |
| D | _server.py | 47 def _stream_unary_service(handler): argument 50 _service.stream_unary(implementation, rpc, handler, servicer_context) 55 def _stream_stream_service(handler): argument 58 _service.stream_stream(implementation, rpc, handler, servicer_context) 69 def _invoke(self, service_behavior, method_descriptor, handler, argument 73 rpc = _rpc.Rpc(handler, invocation_metadata) 74 if handler.add_termination_callback(rpc.extrinsic_abort): 86 def invoke_unary_unary(self, method_descriptor, handler, argument 89 _unary_unary_service(request), method_descriptor, handler, 92 def invoke_unary_stream(self, method_descriptor, handler, argument [all …]
|
| /external/python/mobly/tests/mobly/snippet/ |
| D | callback_handler_base_test.py | 47 """Initializes a fake callback handler object used for unit tests.""" 70 'the default timeout of the callback handler. ' 76 handler = FakeCallbackHandler(rpc_max_timeout_sec=20, 78 self.assertEqual(handler.rpc_max_timeout_sec, 20) 79 self.assertEqual(handler.default_timeout_sec, 10) 81 handler.rpc_max_timeout_sec = 5 84 handler.default_timeout_sec = 5 87 handler = FakeCallbackHandler(callback_id=MOCK_CALLBACK_ID) 88 self.assertEqual(handler.callback_id, MOCK_CALLBACK_ID) 90 handler.callback_id = 'ha' [all …]
|
| /external/libbrillo/brillo/dbus/ |
| D | dbus_object.h | 99 // 1. That takes a handler as base::Callback 102 // The signature of the handler for AddSimpleMethodHandler must be one of: 105 // The signature of the handler for AddSimpleMethodHandlerWithError must be: 107 // The signature of the handler for AddSimpleMethodHandlerWithErrorAndMessage: 109 // The signature of the handler for AddMethodHandler must be: 112 // The signature of the handler for AddMethodHandlerWithMessage must be: 116 // handler that can parse its own input parameter and construct a custom 118 // The signature of the handler for AddRawMethodHandler must be: 124 // Register sync DBus method handler for |method_name| as base::Callback. 128 const base::Callback<R(Args...)>& handler) { in AddSimpleMethodHandler() argument [all …]
|
| /external/cronet/base/android/junit/src/org/chromium/base/supplier/ |
| D | OneShotCallbackTest.java | 13 import android.os.Handler; 38 Handler handler = new Handler(); in testNotCalledWithNoValue() local 41 handler.post(() -> new OneShotCallback<>(supplier, mCallbackMock)); in testNotCalledWithNoValue() 43 handler.post(() -> { verify(mCallbackMock, never()).onResult(any()); }); in testNotCalledWithNoValue() 48 Handler handler = new Handler(); in testCalledWithPresetValue() local 52 handler.post(() -> { new OneShotCallback<>(supplier, mCallbackMock); }); in testCalledWithPresetValue() 54 handler.post(() -> { verify(mCallbackMock, times(1)).onResult(5); }); in testCalledWithPresetValue() 59 Handler handler = new Handler(); in testCalledWithSet() local 62 handler.post(() -> new OneShotCallback<>(supplier, mCallbackMock)); in testCalledWithSet() 63 handler.post(() -> { verify(mCallbackMock, never()).onResult(any()); }); in testCalledWithSet() [all …]
|
| /external/wpa_supplicant_8/src/utils/ |
| D | eloop.h | 77 * eloop_register_read_sock - Register handler for read events 79 * @handler: Callback function to be called when data is available for reading 84 * Register a read socket notifier for the given file descriptor. The handler 86 * socket. The handler function is responsible for clearing the event after 87 * having processed it in order to avoid eloop from calling the handler again 90 int eloop_register_read_sock(int sock, eloop_sock_handler handler, 94 * eloop_unregister_read_sock - Unregister handler for read events 103 * eloop_register_sock - Register handler for socket events 106 * @handler: Callback function to be called when the event is triggered 112 * handler function will be called whenever the that event is triggered for the [all …]
|
| /external/python/cpython2/Modules/expat/ |
| D | xmlrole.c | 116 ((state)->handler = ((state)->documentEntity \ 120 #define setTopLevel(state) ((state)->handler = internalSubset) 158 state->handler = prolog1; in prolog0() 161 state->handler = prolog1; in prolog0() 164 state->handler = prolog1; in prolog0() 167 state->handler = prolog1; in prolog0() 177 state->handler = doctype0; in prolog0() 180 state->handler = error; in prolog0() 215 state->handler = doctype0; in prolog1() 218 state->handler = error; in prolog1() [all …]
|
| /external/robolectric/sandbox/src/test/java/org/robolectric/internal/bytecode/ |
| D | NativeCallHandlerTest.java | 29 // Create handler, which loads exemptions from file. It's fine for the file to be missing. in jarInstrumentorLegacyUsage() 30 NativeCallHandler handler = in jarInstrumentorLegacyUsage() local 35 assertThat(handler.shouldThrow("org.example.MyClass#someOtherMethod()V")).isFalse(); in jarInstrumentorLegacyUsage() 36 assertThat(handler.shouldThrow("org.example.MyClass#someOtherMethod(II)V")).isFalse(); in jarInstrumentorLegacyUsage() 60 // Create handler, which loads exemptions from file. ThrowOnNatives is enabled. in jarInstrumentorUsage_throwOnNativesEnabled() 61 NativeCallHandler handler = in jarInstrumentorUsage_throwOnNativesEnabled() local 66 assertThat(handler.shouldThrow("org.example.MyClass#someOtherMethod()V")).isFalse(); in jarInstrumentorUsage_throwOnNativesEnabled() 69 assertThat(handler.shouldThrow("org.example.MyClass#someOtherMethod(II)V")).isTrue(); in jarInstrumentorUsage_throwOnNativesEnabled() 72 assertThat(handler.shouldThrow("")).isTrue(); in jarInstrumentorUsage_throwOnNativesEnabled() 73 assertThat(handler.shouldThrow(" \t ")).isTrue(); in jarInstrumentorUsage_throwOnNativesEnabled() [all …]
|
| /external/google-breakpad/src/common/dwarf/ |
| D | dwarf2reader_cfi_unittest.cc | 100 class MockCallFrameInfoHandler: public CallFrameInfo::Handler { 145 enum { kCFARegister = CallFrameInfo::Handler::kCFARegister }; 148 // Default expectations for the data handler. in CFIFixture() 159 EXPECT_CALL(handler, UndefinedRule(_, _)).Times(0); in CFIFixture() 160 EXPECT_CALL(handler, SameValueRule(_, _)).Times(0); in CFIFixture() 161 EXPECT_CALL(handler, OffsetRule(_, _, _, _)).Times(0); in CFIFixture() 162 EXPECT_CALL(handler, ValOffsetRule(_, _, _, _)).Times(0); in CFIFixture() 163 EXPECT_CALL(handler, RegisterRule(_, _, _)).Times(0); in CFIFixture() 164 EXPECT_CALL(handler, ExpressionRule(_, _, _)).Times(0); in CFIFixture() 165 EXPECT_CALL(handler, ValExpressionRule(_, _, _)).Times(0); in CFIFixture() [all …]
|
| /external/kotlinx.coroutines/ui/kotlinx-coroutines-android/src/ |
| D | HandlerDispatcher.kt | 18 * Dispatches execution onto Android [Handler]. in <lambda>() 25 …* (current looper is the same as this handler's looper) without an additional [re-dispatch][Corout… in <lambda>() 26 …* This dispatcher does not use [Handler.post] when current looper is the same as looper of the han… in <lambda>() 40 * * `Handler.post` will be triggered. in <lambda>() 66 * Represents an arbitrary [Handler] as an implementation of [CoroutineDispatcher] in hintOnError() 71 * If the underlying handler is closed and its message-scheduling methods start to return `false` on in hintOnError() 78 public fun Handler.asCoroutineDispatcher(name: String? = null): HandlerDispatcher = in hintOnError() 84 internal fun Looper.asHandler(async: Boolean): Handler { in hintOnError() 87 return Handler(this) in hintOnError() 92 val factoryMethod = Handler::class.java.getDeclaredMethod("createAsync", Looper::class.java) in hintOnError() [all …]
|