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

This program source code file is part of KiCad, a free EDA CAD application.

Copyright (C) 2024 KiCad Developers, see AUTHORS.txt for contributors.

This program is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation, either version 3 of the License, or (at your
option) any later version.

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
General Public License for more details.

You should have received a copy of the GNU General Public License along
with this program.  If not, see <http://www.gnu.org/licenses/>.
"""
import builtins
import collections.abc
from ... import common
import google.protobuf.descriptor
import google.protobuf.internal.containers
import google.protobuf.internal.enum_type_wrapper
import google.protobuf.message
import sys
import typing
if sys.version_info >= (3, 10):
    import typing as typing_extensions
else:
    import typing_extensions
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class _CreateNetClassStatus:
    ValueType = typing.NewType('ValueType', builtins.int)
    V: typing_extensions.TypeAlias = ValueType

class _CreateNetClassStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_CreateNetClassStatus.ValueType], builtins.type):
    DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
    CNCS_UNKNOWN: _CreateNetClassStatus.ValueType
    CNCS_OK: _CreateNetClassStatus.ValueType
    'Net class was created successfully'
    CNCS_ALREADY_EXISTS: _CreateNetClassStatus.ValueType
    'A net class with this name already exists'
    CNCS_INVALID_NAME: _CreateNetClassStatus.ValueType
    'The net class name is invalid (empty or reserved)'

class CreateNetClassStatus(_CreateNetClassStatus, metaclass=_CreateNetClassStatusEnumTypeWrapper):
    ...
CNCS_UNKNOWN: CreateNetClassStatus.ValueType
CNCS_OK: CreateNetClassStatus.ValueType
'Net class was created successfully'
CNCS_ALREADY_EXISTS: CreateNetClassStatus.ValueType
'A net class with this name already exists'
CNCS_INVALID_NAME: CreateNetClassStatus.ValueType
'The net class name is invalid (empty or reserved)'
global___CreateNetClassStatus = CreateNetClassStatus

class _DeleteNetClassStatus:
    ValueType = typing.NewType('ValueType', builtins.int)
    V: typing_extensions.TypeAlias = ValueType

class _DeleteNetClassStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_DeleteNetClassStatus.ValueType], builtins.type):
    DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
    DNCS_UNKNOWN: _DeleteNetClassStatus.ValueType
    DNCS_OK: _DeleteNetClassStatus.ValueType
    'Net class was deleted successfully'
    DNCS_NOT_FOUND: _DeleteNetClassStatus.ValueType
    'Net class does not exist'
    DNCS_CANNOT_DELETE_DEFAULT: _DeleteNetClassStatus.ValueType
    'Cannot delete the "Default" net class'

class DeleteNetClassStatus(_DeleteNetClassStatus, metaclass=_DeleteNetClassStatusEnumTypeWrapper):
    ...
DNCS_UNKNOWN: DeleteNetClassStatus.ValueType
DNCS_OK: DeleteNetClassStatus.ValueType
'Net class was deleted successfully'
DNCS_NOT_FOUND: DeleteNetClassStatus.ValueType
'Net class does not exist'
DNCS_CANNOT_DELETE_DEFAULT: DeleteNetClassStatus.ValueType
'Cannot delete the "Default" net class'
global___DeleteNetClassStatus = DeleteNetClassStatus

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

    def __init__(self) -> None:
        ...
global___GetNetClasses = GetNetClasses

@typing.final
class NetClassesResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    NET_CLASSES_FIELD_NUMBER: builtins.int

    @property
    def net_classes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.project_settings_pb2.NetClass]:
        ...

    def __init__(self, *, net_classes: collections.abc.Iterable[common.types.project_settings_pb2.NetClass] | None=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['net_classes', b'net_classes']) -> None:
        ...
global___NetClassesResponse = NetClassesResponse

@typing.final
class SetNetClasses(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    NET_CLASSES_FIELD_NUMBER: builtins.int
    MERGE_MODE_FIELD_NUMBER: builtins.int
    merge_mode: common.types.base_types_pb2.MapMergeMode.ValueType
    'Whether to merge or replace the existing netclasses with the contents of this message\n    Note that this only happens at the level of netclass name: for example, if merge_mode is set to\n    MMM_MERGE, the design has netclasses ["Default", "HV"], and this message has netclasses\n    ["Default", "LV"], the resulting set will be ["Default", "HV", "LV"] -- the Default netclass\n    will have its properties replaced with those in this message, the "LV" netclass will be added,\n    and the "HV" netclass will be left alone.  If merge_mode is set to MMM_REPLACE, the "HV" class\n    will be erased.  Note that there must always be a "Default" netclass, so it will not be erased\n    even if merge_mode is MMM_REPLACE and there is no "Default" class specified in this message.\n    '

    @property
    def net_classes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.project_settings_pb2.NetClass]:
        ...

    def __init__(self, *, net_classes: collections.abc.Iterable[common.types.project_settings_pb2.NetClass] | None=..., merge_mode: common.types.base_types_pb2.MapMergeMode.ValueType=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['merge_mode', b'merge_mode', 'net_classes', b'net_classes']) -> None:
        ...
global___SetNetClasses = SetNetClasses

@typing.final
class CreateNetClass(google.protobuf.message.Message):
    """/ Creates a new net class"""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    NET_CLASS_FIELD_NUMBER: builtins.int

    @property
    def net_class(self) -> common.types.project_settings_pb2.NetClass:
        ...

    def __init__(self, *, net_class: common.types.project_settings_pb2.NetClass | None=...) -> None:
        ...

    def HasField(self, field_name: typing.Literal['net_class', b'net_class']) -> builtins.bool:
        ...

    def ClearField(self, field_name: typing.Literal['net_class', b'net_class']) -> None:
        ...
global___CreateNetClass = CreateNetClass

@typing.final
class CreateNetClassResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    STATUS_FIELD_NUMBER: builtins.int
    ERROR_MESSAGE_FIELD_NUMBER: builtins.int
    status: global___CreateNetClassStatus.ValueType
    error_message: builtins.str

    def __init__(self, *, status: global___CreateNetClassStatus.ValueType=..., error_message: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['error_message', b'error_message', 'status', b'status']) -> None:
        ...
global___CreateNetClassResponse = CreateNetClassResponse

@typing.final
class DeleteNetClass(google.protobuf.message.Message):
    """/ Deletes a net class by name"""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    NAME_FIELD_NUMBER: builtins.int
    name: builtins.str
    'Name of the net class to delete'

    def __init__(self, *, name: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['name', b'name']) -> None:
        ...
global___DeleteNetClass = DeleteNetClass

@typing.final
class DeleteNetClassResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    STATUS_FIELD_NUMBER: builtins.int
    ERROR_MESSAGE_FIELD_NUMBER: builtins.int
    status: global___DeleteNetClassStatus.ValueType
    error_message: builtins.str

    def __init__(self, *, status: global___DeleteNetClassStatus.ValueType=..., error_message: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['error_message', b'error_message', 'status', b'status']) -> None:
        ...
global___DeleteNetClassResponse = DeleteNetClassResponse

@typing.final
class ExpandTextVariables(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    DOCUMENT_FIELD_NUMBER: builtins.int
    TEXT_FIELD_NUMBER: builtins.int

    @property
    def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
        ...

    @property
    def text(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
        ...

    def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=..., text: collections.abc.Iterable[builtins.str] | None=...) -> None:
        ...

    def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
        ...

    def ClearField(self, field_name: typing.Literal['document', b'document', 'text', b'text']) -> None:
        ...
global___ExpandTextVariables = ExpandTextVariables

@typing.final
class ExpandTextVariablesResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    TEXT_FIELD_NUMBER: builtins.int

    @property
    def text(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
        ...

    def __init__(self, *, text: collections.abc.Iterable[builtins.str] | None=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['text', b'text']) -> None:
        ...
global___ExpandTextVariablesResponse = ExpandTextVariablesResponse

@typing.final
class GetTextVariables(google.protobuf.message.Message):
    """returns kiapi.common.project.TextVariables"""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    DOCUMENT_FIELD_NUMBER: builtins.int

    @property
    def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
        ...

    def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=...) -> None:
        ...

    def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
        ...

    def ClearField(self, field_name: typing.Literal['document', b'document']) -> None:
        ...
global___GetTextVariables = GetTextVariables

@typing.final
class SetTextVariables(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    DOCUMENT_FIELD_NUMBER: builtins.int
    VARIABLES_FIELD_NUMBER: builtins.int
    MERGE_MODE_FIELD_NUMBER: builtins.int
    merge_mode: common.types.base_types_pb2.MapMergeMode.ValueType
    'Whether to merge or replace the existing text variables map with the contents of this message'

    @property
    def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
        ...

    @property
    def variables(self) -> common.types.project_settings_pb2.TextVariables:
        ...

    def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=..., variables: common.types.project_settings_pb2.TextVariables | None=..., merge_mode: common.types.base_types_pb2.MapMergeMode.ValueType=...) -> None:
        ...

    def HasField(self, field_name: typing.Literal['document', b'document', 'variables', b'variables']) -> builtins.bool:
        ...

    def ClearField(self, field_name: typing.Literal['document', b'document', 'merge_mode', b'merge_mode', 'variables', b'variables']) -> None:
        ...
global___SetTextVariables = SetTextVariables

@typing.final
class NetClassAssignment(google.protobuf.message.Message):
    """/ A netclass pattern assignment (pattern -> netclass).
    / Stored at the project level in NET_SETTINGS.
    """
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    PATTERN_FIELD_NUMBER: builtins.int
    NETCLASS_FIELD_NUMBER: builtins.int
    pattern: builtins.str
    'Wildcard pattern to match net names'
    netclass: builtins.str
    'Netclass to assign'

    def __init__(self, *, pattern: builtins.str=..., netclass: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['netclass', b'netclass', 'pattern', b'pattern']) -> None:
        ...
global___NetClassAssignment = NetClassAssignment

@typing.final
class GetNetClassAssignments(google.protobuf.message.Message):
    """/ Gets all netclass pattern assignments"""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(self) -> None:
        ...
global___GetNetClassAssignments = GetNetClassAssignments

@typing.final
class GetNetClassAssignmentsResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    ASSIGNMENTS_FIELD_NUMBER: builtins.int

    @property
    def assignments(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___NetClassAssignment]:
        ...

    def __init__(self, *, assignments: collections.abc.Iterable[global___NetClassAssignment] | None=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['assignments', b'assignments']) -> None:
        ...
global___GetNetClassAssignmentsResponse = GetNetClassAssignmentsResponse

@typing.final
class SetNetClassAssignments(google.protobuf.message.Message):
    """/ Sets all netclass pattern assignments (replaces existing)"""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    ASSIGNMENTS_FIELD_NUMBER: builtins.int

    @property
    def assignments(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___NetClassAssignment]:
        ...

    def __init__(self, *, assignments: collections.abc.Iterable[global___NetClassAssignment] | None=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['assignments', b'assignments']) -> None:
        ...
global___SetNetClassAssignments = SetNetClassAssignments

@typing.final
class LaunchEditor(google.protobuf.message.Message):
    """/ Launch an editor (schematic or PCB) via the project manager's KIWAY.
    / Editors launched this way run in non-standalone mode, enabling features like
    / pcb_sync_schematic that require both editors to share a project context.
    / Only handled by the project manager's API server.
    """
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    DOC_TYPE_FIELD_NUMBER: builtins.int
    doc_type: common.types.base_types_pb2.DocumentType.ValueType

    def __init__(self, *, doc_type: common.types.base_types_pb2.DocumentType.ValueType=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['doc_type', b'doc_type']) -> None:
        ...
global___LaunchEditor = LaunchEditor

@typing.final
class LaunchEditorResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    ALREADY_OPEN_FIELD_NUMBER: builtins.int
    SOCKET_PATH_FIELD_NUMBER: builtins.int
    already_open: builtins.bool
    'True if the editor was already open'
    socket_path: builtins.str
    'API socket path of the launched editor'

    def __init__(self, *, already_open: builtins.bool=..., socket_path: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['already_open', b'already_open', 'socket_path', b'socket_path']) -> None:
        ...
global___LaunchEditorResponse = LaunchEditorResponse

@typing.final
class GetInstructions(google.protobuf.message.Message):
    """/ Retrieve the agent instructions (system prompt) from the C++ app.
    / Returns the core instructions markdown that is shared between the in-app agent
    / and the MCP server. Consumers append their own context-specific addendum.
    / Only handled by the project manager's API server.
    """
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(self) -> None:
        ...
global___GetInstructions = GetInstructions

@typing.final
class GetInstructionsResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    INSTRUCTIONS_MD_FIELD_NUMBER: builtins.int
    instructions_md: builtins.str
    'Core instructions markdown content'

    def __init__(self, *, instructions_md: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['instructions_md', b'instructions_md']) -> None:
        ...
global___GetInstructionsResponse = GetInstructionsResponse

@typing.final
class GetToolSchemas(google.protobuf.message.Message):
    """/ Retrieve the tool manifest (schemas, script paths, metadata) from the C++ app.
    / The manifest is built at startup by TOOL_SCRIPT_LOADER and cached as JSON.
    / Only handled by the project manager's API server.
    """
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(self) -> None:
        ...
global___GetToolSchemas = GetToolSchemas

@typing.final
class GetToolSchemasResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    MANIFEST_JSON_FIELD_NUMBER: builtins.int
    manifest_json: builtins.str
    'JSON array of tool definitions'

    def __init__(self, *, manifest_json: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['manifest_json', b'manifest_json']) -> None:
        ...
global___GetToolSchemasResponse = GetToolSchemasResponse

@typing.final
class ExecuteTool(google.protobuf.message.Message):
    """/ Execute an MCP tool through the C++ application's embedded Python executor.
    / Routes tool execution through HEADLESS_PYTHON_EXECUTOR with proper timeouts,
    / cancellation support, and optional transaction management (undo snapshots).
    / Only handled by the project manager's API server.
    """
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    TOOL_NAME_FIELD_NUMBER: builtins.int
    TOOL_ARGS_JSON_FIELD_NUMBER: builtins.int
    APP_FIELD_NUMBER: builtins.int
    SCRIPT_FIELD_NUMBER: builtins.int
    tool_name: builtins.str
    'Tool name, e.g. "sch_add", "pcb_place" '
    tool_args_json: builtins.str
    'JSON-encoded tool arguments — C++ resolves app/script from manifest'
    app: builtins.str
    'DEPRECATED: C++ resolves from manifest. Kept for wire compat.'
    script: builtins.str
    'DEPRECATED: C++ resolves from manifest. Kept for wire compat.'

    def __init__(self, *, tool_name: builtins.str=..., tool_args_json: builtins.str=..., app: builtins.str=..., script: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['app', b'app', 'script', b'script', 'tool_args_json', b'tool_args_json', 'tool_name', b'tool_name']) -> None:
        ...
global___ExecuteTool = ExecuteTool

@typing.final
class ExecuteToolResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    SUCCESS_FIELD_NUMBER: builtins.int
    RESULT_JSON_FIELD_NUMBER: builtins.int
    ERROR_MESSAGE_FIELD_NUMBER: builtins.int
    success: builtins.bool
    result_json: builtins.str
    'JSON result from tool execution'
    error_message: builtins.str

    def __init__(self, *, success: builtins.bool=..., result_json: builtins.str=..., error_message: builtins.str=...) -> None:
        ...

    def ClearField(self, field_name: typing.Literal['error_message', b'error_message', 'result_json', b'result_json', 'success', b'success']) -> None:
        ...
global___ExecuteToolResponse = ExecuteToolResponse