Home
last modified time | relevance | path

Searched full:pw (Results 1 – 25 of 3785) sorted by relevance

12345678910>>...152

/external/pigweed/pw_result/
Dstatusor_test.cc37 #define EXPECT_OK(expression) EXPECT_EQ(::pw::OkStatus(), expression)
38 #define ASSERT_OK(expression) ASSERT_EQ(::pw::OkStatus(), expression)
74 ASSERT_EQ(::pw::OkStatus(), temp_status_or.status()); \
83 ASSERT_EQ(::pw::OkStatus(), temp_status_or.status()); \
117 pw::Result<std::unique_ptr<int>> ReturnUniquePtr() { in ReturnUniquePtr()
123 static_assert(std::is_same<pw::Result<int>::value_type, int>()); in TEST()
124 static_assert(std::is_same<pw::Result<char>::value_type, char>()); in TEST()
128 pw::Result<std::unique_ptr<int>> thing(ReturnUniquePtr()); in TEST()
140 pw::Result<std::unique_ptr<int>> thing(ReturnUniquePtr()); in TEST()
158 decltype(std::declval<const pw::Result<int>&&>().value())>(), in TEST()
[all …]
Ddocs.rst13 ``pw::Result<T>`` is a union of an error (:cpp:class:`pw::Status`) and a value
26 pw::Result<int> GetBatteryVoltageMillivolts(); // Can fail
28 pw::Status UpdateChargerDisplay() {
29 const pw::Result<int> battery_mv = GetBatteryVoltageMillivolts();
36 return pw::OkStatus();
43 pw::Status UpdateChargerDisplay() {
47 return pw::OkStatus();
50 The ``pw::Result<T>`` class is based on Abseil's ``absl::StatusOr<T>`` class.
131 ``pw::Result<T>`` objects represent either:
140 A ``pw::Result<T>`` instance can never contain both an OK status and a value. In
[all …]
/external/pigweed/pw_channel/
Dchannel_test.cc28 using ::pw::allocator::test::AllocatorForTest;
29 using ::pw::async2::Context;
30 using ::pw::async2::Pending;
31 using ::pw::async2::Poll;
32 using ::pw::async2::Ready;
33 using ::pw::async2::Waker;
34 using ::pw::channel::ByteChannel;
35 using ::pw::channel::DatagramWriter;
36 using ::pw::channel::kReadable;
37 using ::pw::channel::kReliable;
[all …]
Dforwarding_channel_test.cc28 using ::pw::Result;
29 using ::pw::async2::Context;
30 using ::pw::async2::Pending;
31 using ::pw::async2::Poll;
32 using ::pw::async2::Ready;
33 using ::pw::async2::Task;
34 using ::pw::async2::Waker;
35 using ::pw::channel::ByteReader;
36 using ::pw::channel::DatagramReader;
37 using ::pw::multibuf::MultiBuf;
[all …]
Depoll_channel_test.cc38 using ::pw::async2::Context;
39 using ::pw::async2::Dispatcher;
40 using ::pw::async2::Pending;
41 using ::pw::async2::Poll;
42 using ::pw::async2::Ready;
43 using ::pw::async2::Task;
44 using ::pw::channel::ByteReader;
45 using ::pw::channel::ByteWriter;
46 using ::pw::channel::EpollChannel;
47 using ::pw::multibuf::MultiBuf;
[all …]
/external/pigweed/pw_bluetooth_sapphire/host/hci-spec/
Dutil.cc26 pw::bluetooth::emboss::CoreSpecificationVersion version) { in HCIVersionToString()
28 case pw::bluetooth::emboss::CoreSpecificationVersion::V1_0B: in HCIVersionToString()
30 case pw::bluetooth::emboss::CoreSpecificationVersion::V1_1: in HCIVersionToString()
32 case pw::bluetooth::emboss::CoreSpecificationVersion::V1_2: in HCIVersionToString()
34 case pw::bluetooth::emboss::CoreSpecificationVersion::V2_0_EDR: in HCIVersionToString()
36 case pw::bluetooth::emboss::CoreSpecificationVersion::V2_1_EDR: in HCIVersionToString()
38 case pw::bluetooth::emboss::CoreSpecificationVersion::V3_0_HS: in HCIVersionToString()
40 case pw::bluetooth::emboss::CoreSpecificationVersion::V4_0: in HCIVersionToString()
42 case pw::bluetooth::emboss::CoreSpecificationVersion::V4_1: in HCIVersionToString()
44 case pw::bluetooth::emboss::CoreSpecificationVersion::V4_2: in HCIVersionToString()
[all …]
/external/pigweed/pw_containers/
Dalgorithm_test.cc32 class TestItem : public pw::IntrusiveList<TestItem>::Item {
53 pw::span<int> span_{NonMutatingTest::span_array_};
54 pw::Vector<int, 3> vector_ = {1, 2, 3};
60 pw::Vector<int, 10> calls;
70 const pw::Vector<int>& v = vector_; in TEST_F()
71 EXPECT_FALSE(pw::containers::AllOf(v, [](int x) { return x > 1; })); in TEST_F()
72 EXPECT_TRUE(pw::containers::AllOf(v, [](int x) { return x > 0; })); in TEST_F()
76 const pw::Vector<int>& v = vector_; in TEST_F()
77 EXPECT_TRUE(pw::containers::AnyOf(v, [](int x) { return x > 2; })); in TEST_F()
78 EXPECT_FALSE(pw::containers::AnyOf(v, [](int x) { return x > 5; })); in TEST_F()
[all …]
/external/icu/icu4j/tools/build/src/main/java/com/ibm/icu/dev/tool/docs/
DReportAPI.java78 public void print(PrintWriter pw, boolean detail, boolean html) { in print() argument
79 pw.print(" "); in print()
80 removed.print(pw, detail, html); in print()
82 pw.println("</br>"); in print()
84 pw.println(); in print()
85 pw.print("--> "); in print()
87 added.print(pw, detail, html); in print()
279 PrintWriter pw = null; in writeReport() local
281 pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(os, "UTF-8"))); in writeReport()
309 pw.println("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">"); in writeReport()
[all …]
/external/pigweed/pw_function/
Ddocs.rst20 // pw::Function can be constructed from a function pointer...
22 pw::Function<int(int, int)> add(_a);
24 pw::Function<int(int)> square([](int num) { return num * num; });
26 // pw::Callback can only be invoked once. After the first call, the target
29 pw::Callback<void(void)> flip_table_once([](void) {
34 add = nullptr; // pw::Function and pw::Callback are nullable
110 Construct ``pw::Function`` from a function pointer
112 :cpp:type:`pw::Function` is a move-only callable wrapper constructable from any
114 implements the call operator; invoking a ``pw::Function`` object forwards to
122 pw::Function<int(int, int)> add_function(Add);
[all …]
/external/pigweed/pw_i2c/
Dreference.rst14 * :cpp:class:`pw::i2c::Address` is a helper class for representing I2C
16 * :cpp:class:`pw::i2c::Initiator` is the common, base driver interface for
18 * :cpp:class:`pw::i2c::Device` is a helper class that takes a reference
19 to an :cpp:class:`pw::i2c::Initiator` instance and provides easier access
21 * :cpp:class:`pw::i2c::RegisterDevice` extends :cpp:class:`pw::i2c::Device`
23 * :cpp:class:`pw::i2c::I2cService` is a service for performing I2C
25 * :cpp:class:`pw::i2c::MockInitiator` is a generic mocked backend for
26 :cpp:class:`pw::i2c::Initiator`. It uses :cpp:class:`pw::i2c::Transaction`
30 ``pw::i2c::Address``
32 .. doxygenclass:: pw::i2c::Address
[all …]
/external/pigweed/pw_protobuf_compiler/py/
Dpython_protos_test.py27 package pw.protobuf_compiler.test1;
55 package pw.protobuf_compiler.test2;
76 package pw.protobuf_compiler.test2;
147 msg = self._library.packages.pw.protobuf_compiler.test1.SomeMessage
151 msg = self._library.packages.pw.protobuf_compiler.test2.Request
154 val = self._library.packages.pw.protobuf_compiler.test2.YO
162 _ = self._library.packages.pw.NOT_HERE
165 _ = self._library.packages.pw.protobuf_compiler.test1.NotARealMsg
168 test1 = self._library.modules_by_package['pw.protobuf_compiler.test1']
172 test2 = self._library.modules_by_package['pw.protobuf_compiler.test2']
[all …]
/external/pigweed/pw_string/
Dapi.rst15 **pw::StringBuilder**
20 **pw::InlineString**
31 pw::StringBuilder
35 .. doxygenclass:: pw::StringBuilder
39 pw::InlineString
44 .. doxygenclass:: pw::InlineBasicString
47 .. doxygentypedef:: pw::InlineString
53 pw::string::Assign()
55 .. doxygenfunction:: pw::string::Assign(InlineString<> &string, std::string_view view)
57 pw::string::Append()
[all …]
Dguide.rst86 Choose between pw::InlineString and pw::StringBuilder
88 `pw::InlineString` is intended to replace typical null terminated character
89 arrays in embedded data structures. Use :cpp:type:`pw::InlineString` if you
97 `pw::StringBuilder` is intended to ease constructing strings in external data;
99 :cpp:class:`pw::StringBuilder` if you need:
108 An example of when to prefer :cpp:type:`pw::InlineString` is wrapping a
123 pw::InlineString<kMaxNameLen>(name).c_str());
126 An example of when to prefer :cpp:class:`pw::StringBuilder` is when
133 pw::Status FlushSensorValueToUart(int32_t sensor_value) {
134 pw::StringBuffer<42> sb;
[all …]
/external/pigweed/pw_spi/
Ddocs.rst17 - ``pw::spi::Initiator`` - Interface for configuring a SPI bus, and using it
19 - ``pw::spi::ChipSelector`` - Interface for enabling/disabling a SPI
21 - ``pw::spi::Device`` - primary HAL interface used to interact with a SPI
23 - ``pw::spi::Responder`` - Interface for implementing a SPI responder.
26 ``pw::spi::Initiator`` and ``pw::spi::ChipSelector`` to be defined, and
27 injected into ``pw::spi::Device`` objects which are used to communicate with a
34 constexpr pw::spi::Config kConfig = {
35 .polarity = pw::spi::ClockPolarity::kActiveHigh,
36 .phase = pw::spi::ClockPhase::kRisingEdge,
37 .bits_per_word = pw::spi::BitsPerWord(8),
[all …]
/external/pigweed/pw_rpc/py/tests/
Dclient_test.py32 package pw.test1;
60 package pw.test2;
116 self._channel_client.rpcs.pw.test1.PublicService,
117 self._channel_client.rpcs['pw.test1.PublicService'],
120 self._channel_client.rpcs.pw.test1.PublicService,
122 pw_rpc.ids.calculate('pw.test1.PublicService')
128 self._channel_client.rpcs.pw.test2.Alpha.Unary,
129 self._channel_client.rpcs['pw.test2.Alpha']['Unary'],
132 self._channel_client.rpcs.pw.test2.Alpha.Unary,
133 self._channel_client.rpcs['pw.test2.Alpha'][
[all …]
/external/pigweed/pw_bluetooth_sapphire/host/testing/
Dfake_controller.cc56 hci_version = pw::bluetooth::emboss::CoreSpecificationVersion::V5_0; in ApplyDualModeDefaults()
174 hci_version = pw::bluetooth::emboss::CoreSpecificationVersion::V4_2; in ApplyLegacyLEConfig()
212 pw::bluetooth::emboss::StatusCode::SUCCESS); in ApplyAndroidVendorExtensionDefaults()
218 hci_spec::OpCode opcode, pw::bluetooth::emboss::StatusCode status) { in SetDefaultCommandStatus()
227 hci_spec::OpCode opcode, pw::bluetooth::emboss::StatusCode status) { in SetDefaultResponseStatus()
228 BT_DEBUG_ASSERT(status != pw::bluetooth::emboss::StatusCode::SUCCESS); in SetDefaultResponseStatus()
262 void FakeController::SendCommand(pw::span<const std::byte> command) { in SendCommand()
268 pw::async::Context /*ctx*/, pw::Status status) { in SendCommand()
294 hci_spec::OpCode opcode, pw::bluetooth::emboss::StatusCode status) { in RespondWithCommandComplete()
319 ->template view<pw::bluetooth::emboss::CommandCompleteEventWriter>(); in RespondWithCommandComplete()
[all …]
/external/pigweed/pw_cli/
Ddocs.rst11 - **Accelerate workflows**: Create custom ``pw`` commands to streamline
27 This directory contains the ``pw`` command line interface (CLI) that facilitates
29 ``pw``, and provides a mechanism for other Pigweed modules to behave as
30 "plugins" and register themselves as ``pw`` commands as well. After activating
33 ``pw`` includes the following commands by default:
39 help Display detailed information about pw commands.
46 To see an up-to-date list of ``pw`` subcommands, run ``pw --help``.
49 Invoking ``pw``
51 ``pw`` subcommands are invoked by providing the command name. Arguments prior to
52 the command are interpreted by ``pw`` itself; all arguments after the command
[all …]
/external/pigweed/pw_clock_tree/
Dexamples.cc21 static pw::Status EnableClock() { in EnableClock()
23 return pw::OkStatus(); in EnableClock()
26 static pw::Status DisableClock() { in DisableClock()
28 return pw::OkStatus(); in DisableClock()
31 static pw::Status EnableClockDivider(uint32_t, uint32_t) { in EnableClockDivider()
33 return pw::OkStatus(); in EnableClockDivider()
36 static pw::Status SetSelector(uint32_t) { in SetSelector()
38 return pw::OkStatus(); in SetSelector()
48 class ClockSourceExample : public pw::clock_tree::ClockSource<ElementType> {
50 pw::Status DoEnable() final { return EnableClock(); } in DoEnable()
[all …]
/external/pigweed/pw_allocator/
Dblock_test.cc27 using ::pw::allocator::Layout;
28 using LargeOffsetBlock = ::pw::allocator::Block<uint64_t>;
29 using SmallOffsetBlock = ::pw::allocator::Block<uint16_t>;
30 using PoisonedBlock = ::pw::allocator::Block<uint32_t, alignof(uint32_t), true>;
56 ASSERT_EQ(result.status(), pw::OkStatus()); in TEST_FOR_EACH_BLOCK_TYPE()
72 pw::ByteSpan aligned(bytes); in TEST_FOR_EACH_BLOCK_TYPE()
75 EXPECT_EQ(result.status(), pw::OkStatus()); in TEST_FOR_EACH_BLOCK_TYPE()
82 EXPECT_EQ(result.status(), pw::Status::ResourceExhausted()); in TEST_FOR_EACH_BLOCK_TYPE()
86 using BlockType = ::pw::allocator::Block<uint8_t>; in TEST()
90 pw::Result<BlockType*> result = BlockType::Init(bytes); in TEST()
[all …]
/external/pigweed/pw_async2/examples/
Dcoro.cc21 using ::pw::OkStatus;
22 using ::pw::Result;
23 using ::pw::Status;
24 using ::pw::allocator::Allocator;
25 using ::pw::async2::Context;
26 using ::pw::async2::Poll;
64 using ::pw::OkStatus;
65 using ::pw::Result;
66 using ::pw::Status;
67 using ::pw::allocator::Allocator;
[all …]
/external/pigweed/pw_bluetooth_sapphire/public/pw_bluetooth_sapphire/internal/host/testing/
Dfake_controller.h62 pw::chrono::SystemClock::duration le_connection_delay =
66 pw::bluetooth::emboss::CoreSpecificationVersion hci_version =
67 pw::bluetooth::emboss::CoreSpecificationVersion::V5_0;
94 StaticPacket<pw::bluetooth::vendor::android_hci::
104 pw::bluetooth::emboss::GenericEnableParam::DISABLE,
122 pw::bluetooth::emboss::LEScanType scan_type =
123 pw::bluetooth::emboss::LEScanType::PASSIVE;
124 pw::bluetooth::emboss::LEOwnAddressType own_address_type =
125 pw::bluetooth::emboss::LEOwnAddressType::PUBLIC;
126 pw::bluetooth::emboss::LEScanFilterPolicy filter_policy =
[all …]
Dcontroller_test_double_base.h29 class ControllerTestDoubleBase : public pw::bluetooth::Controller {
31 using PwStatusCallback = pw::Callback<void(pw::Status)>;
34 pw::bluetooth::VendorCommandParameters,
35 pw::Callback<void(pw::Result<pw::span<const std::byte>>)>)>;
41 fit::callback<void(pw::Status)>)>;
43 using ResetScoFunction = fit::function<void(fit::callback<void(pw::Status)>)>;
45 explicit ControllerTestDoubleBase(pw::async::Dispatcher& pw_dispatcher);
48 pw::async::Dispatcher& pw_dispatcher() { return pw_dispatcher_; } in pw_dispatcher()
49 pw::async::HeapDispatcher& heap_dispatcher() { return heap_dispatcher_; } in heap_dispatcher()
66 void Stop() { SignalError(pw::Status::Aborted()); } in Stop()
[all …]
/external/openthread/third_party/mbedtls/repo/tests/suites/
Dtest_suite_pkparse.data81 Parse RSA Key #20.1 (PKCS#8 encrypted SHA1-3DES, wrong PW)
85 Parse RSA Key #20.2 (PKCS#8 encrypted SHA1-3DES, no PW)
93 Parse RSA Key #21.1 (PKCS#8 encrypted SHA1-3DES, 2048-bit, wrong PW)
97 Parse RSA Key #21.2 (PKCS#8 encrypted SHA1-3DES, 2048-bit, no PW)
105 Parse RSA Key #22.1 (PKCS#8 encrypted SHA1-3DES, 4096-bit, wrong PW)
109 Parse RSA Key #22.2 (PKCS#8 encrypted SHA1-3DES, 4096-bit, no PW)
129 Parse RSA Key #26.1 (PKCS#8 encrypted SHA1-2DES, wrong PW)
133 Parse RSA Key #26.2 (PKCS#8 encrypted SHA1-2DES, no PW)
141 Parse RSA Key #27.1 (PKCS#8 encrypted SHA1-2DES, 2048-bit, wrong PW)
145 Parse RSA Key #27.2 (PKCS#8 encrypted SHA1-2DES, 2048-bit no PW)
[all …]
/external/pigweed/pw_rpc/pwpb/
Dclient_integration_test.cc25 using pw::ByteSpan;
26 using pw::ConstByteSpan;
27 using pw::Function;
28 using pw::OkStatus;
29 using pw::Status;
31 using pw::rpc::pw_rpc::pwpb::Benchmark;
42 Function<void(const pw::rpc::Payload::Message&, Status)> UnaryOnCompleted() { in UnaryOnCompleted()
43 return [this](const pw::rpc::Payload::Message& data, Status) { in UnaryOnCompleted()
48 Function<void(const pw::rpc::Payload::Message&)> OnNext() { in OnNext()
49 return [this](const pw::rpc::Payload::Message& data) { CopyPayload(data); }; in OnNext()
[all …]
/external/pigweed/pw_protobuf/
Ddocs.rst86 pw::InlineString<32> name;
96 pw::Status EncodeCustomer(Customer::StreamEncoder& encoder) {
110 pw::Status DecodeCustomer(Customer::StreamDecoder& decoder) {
114 return pw::OkStatus();
167 static_assert(pw::protobuf::IsTriviallyComparable<Point::Message>());
169 static_assert(!pw::protobuf::IsTriviallyComparable<Label::Message>());
244 return pw::OkStatus();
281 class Customer::StreamEncoder : pw::protobuf::StreamEncoder {
284 pw::Status Write(const Customer::Message&);
287 pw::Status WriteAge(int32_t);
[all …]

12345678910>>...152