"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import builtins
import collections.abc
import google.protobuf.descriptor
import google.protobuf.internal.containers
import google.protobuf.message
import google.rpc.status_pb2
import typing
import yandex.cloud.logging.v1.log_entry_pb2
import yandex.cloud.logging.v1.log_resource_pb2

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

@typing.final
class WriteRequest(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    DESTINATION_FIELD_NUMBER: builtins.int
    RESOURCE_FIELD_NUMBER: builtins.int
    ENTRIES_FIELD_NUMBER: builtins.int
    DEFAULTS_FIELD_NUMBER: builtins.int
    @property
    def destination(self) -> yandex.cloud.logging.v1.log_entry_pb2.Destination:
        """Log entries destination.

        See [Destination] for details.
        """

    @property
    def resource(self) -> yandex.cloud.logging.v1.log_resource_pb2.LogEntryResource:
        """Common resource (type, ID) specification for log entries."""

    @property
    def entries(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[yandex.cloud.logging.v1.log_entry_pb2.IncomingLogEntry]:
        """List of log entries."""

    @property
    def defaults(self) -> yandex.cloud.logging.v1.log_entry_pb2.LogEntryDefaults:
        """Log entries defaults.

        See [LogEntryDefaults] for details.
        """

    def __init__(
        self,
        *,
        destination: yandex.cloud.logging.v1.log_entry_pb2.Destination | None = ...,
        resource: yandex.cloud.logging.v1.log_resource_pb2.LogEntryResource | None = ...,
        entries: collections.abc.Iterable[yandex.cloud.logging.v1.log_entry_pb2.IncomingLogEntry] | None = ...,
        defaults: yandex.cloud.logging.v1.log_entry_pb2.LogEntryDefaults | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["defaults", b"defaults", "destination", b"destination", "resource", b"resource"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["defaults", b"defaults", "destination", b"destination", "entries", b"entries", "resource", b"resource"]) -> None: ...

global___WriteRequest = WriteRequest

@typing.final
class WriteResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    @typing.final
    class ErrorsEntry(google.protobuf.message.Message):
        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        KEY_FIELD_NUMBER: builtins.int
        VALUE_FIELD_NUMBER: builtins.int
        key: builtins.int
        @property
        def value(self) -> google.rpc.status_pb2.Status: ...
        def __init__(
            self,
            *,
            key: builtins.int = ...,
            value: google.rpc.status_pb2.Status | None = ...,
        ) -> None: ...
        def HasField(self, field_name: typing.Literal["value", b"value"]) -> builtins.bool: ...
        def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...

    ERRORS_FIELD_NUMBER: builtins.int
    @property
    def errors(self) -> google.protobuf.internal.containers.MessageMap[builtins.int, google.rpc.status_pb2.Status]:
        """Map<idx, status> of ingest failures.

        If entry with idx N is absent, it was ingested successfully.
        """

    def __init__(
        self,
        *,
        errors: collections.abc.Mapping[builtins.int, google.rpc.status_pb2.Status] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["errors", b"errors"]) -> None: ...

global___WriteResponse = WriteResponse
