:py:mod:`viam.gen.component.powersensor.v1.powersensor_pb2` =========================================================== .. py:module:: viam.gen.component.powersensor.v1.powersensor_pb2 .. autoapi-nested-parse:: @generated by mypy-protobuf. Do not edit manually! isort:skip_file Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: viam.gen.component.powersensor.v1.powersensor_pb2.GetVoltageRequest viam.gen.component.powersensor.v1.powersensor_pb2.GetVoltageResponse viam.gen.component.powersensor.v1.powersensor_pb2.GetCurrentRequest viam.gen.component.powersensor.v1.powersensor_pb2.GetCurrentResponse viam.gen.component.powersensor.v1.powersensor_pb2.GetPowerRequest viam.gen.component.powersensor.v1.powersensor_pb2.GetPowerResponse Attributes ~~~~~~~~~~ .. autoapisummary:: viam.gen.component.powersensor.v1.powersensor_pb2.DESCRIPTOR viam.gen.component.powersensor.v1.powersensor_pb2.global___GetVoltageRequest viam.gen.component.powersensor.v1.powersensor_pb2.global___GetVoltageResponse viam.gen.component.powersensor.v1.powersensor_pb2.global___GetCurrentRequest viam.gen.component.powersensor.v1.powersensor_pb2.global___GetCurrentResponse viam.gen.component.powersensor.v1.powersensor_pb2.global___GetPowerRequest viam.gen.component.powersensor.v1.powersensor_pb2.global___GetPowerResponse .. py:data:: DESCRIPTOR :type: google.protobuf.descriptor.FileDescriptor .. py:class:: GetVoltageRequest(*, name: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:property:: extra :type: google.protobuf.struct_pb2.Struct Additional arguments to the method .. py:attribute:: name :type: str Name of a power sensor .. py:method:: HasField(field_name: Literal[extra, b'extra']) -> bool Checks if a certain field is set for the message. For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor, :exc:`ValueError` will be raised. :param field_name: The name of the field to check for presence. :type field_name: str :returns: Whether a value has been set for the named field. :rtype: bool :raises ValueError: if the `field_name` is not a member of this message. .. py:data:: global___GetVoltageRequest .. py:class:: GetVoltageResponse(*, volts: float = ..., is_ac: bool = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:attribute:: volts :type: float Voltage in volts .. py:attribute:: is_ac :type: bool Bool describing whether the voltage is DC or AC .. py:data:: global___GetVoltageResponse .. py:class:: GetCurrentRequest(*, name: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:property:: extra :type: google.protobuf.struct_pb2.Struct Additional arguments to the method .. py:attribute:: name :type: str Name of a power sensor .. py:method:: HasField(field_name: Literal[extra, b'extra']) -> bool Checks if a certain field is set for the message. For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor, :exc:`ValueError` will be raised. :param field_name: The name of the field to check for presence. :type field_name: str :returns: Whether a value has been set for the named field. :rtype: bool :raises ValueError: if the `field_name` is not a member of this message. .. py:data:: global___GetCurrentRequest .. py:class:: GetCurrentResponse(*, amperes: float = ..., is_ac: bool = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:attribute:: amperes :type: float Current in amperes .. py:attribute:: is_ac :type: bool Bool descibing whether the current is DC or AC .. py:data:: global___GetCurrentResponse .. py:class:: GetPowerRequest(*, name: str = ..., extra: google.protobuf.struct_pb2.Struct | None = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:property:: extra :type: google.protobuf.struct_pb2.Struct Additional arguments to the method .. py:attribute:: name :type: str Name of a power sensor .. py:method:: HasField(field_name: Literal[extra, b'extra']) -> bool Checks if a certain field is set for the message. For a oneof group, checks if any field inside is set. Note that if the field_name is not defined in the message descriptor, :exc:`ValueError` will be raised. :param field_name: The name of the field to check for presence. :type field_name: str :returns: Whether a value has been set for the named field. :rtype: bool :raises ValueError: if the `field_name` is not a member of this message. .. py:data:: global___GetPowerRequest .. py:class:: GetPowerResponse(*, watts: float = ...) Bases: :py:obj:`google.protobuf.message.Message` Abstract base class for protocol messages. Protocol message classes are almost always generated by the protocol compiler. These generated types subclass Message and implement the methods shown below. .. py:attribute:: watts :type: float Power in watts .. py:data:: global___GetPowerResponse