이 페이지에서

QtProtobuf Namespace

QtProtobuf 네임스페이스에는 Qt Protobuf 를 지원하는 데 필요한 유형 별칭과 클래스가 포함되어 있습니다. 더 보기...

헤더: #include <QtProtobuf>
CMake: find_package(Qt6 REQUIRED COMPONENTS Protobuf)
target_link_libraries(mytarget PRIVATE Qt6::Protobuf)
다음과 같이: Qt 6.5

클래스

(since 6.6) class Any

형

함수

상세 설명

클래스

Any 클래스

protobuf의 Any 유형을 더 쉽게 다룰 수 있도록 도와주는 헬퍼 클래스입니다. 더 보기...

타입 문서

enum class QtProtobuf::WireTypes

WireTypes 열거형은 protobuf의 기본 와이어타입을 반영합니다.

다음 표는 열거형의 값과 해당 유형을 보여줍니다:

상수값설명
QtProtobuf::WireTypes::Unknown-1잘못된 와이어 유형
QtProtobuf::WireTypes::Varint0int32, int64, uint32, uint64, sint32, sint64, bool, enum
QtProtobuf::WireTypes::Fixed641fixed64, sfixed64, double
QtProtobuf::WireTypes::LengthDelimited2string, bytes, 임베디드 메시지, 압축된 반복 필드
QtProtobuf::WireTypes::StartGroup3그룹. proto 구문 3에서 더 이상 사용되지 않습니다. Qt Protobuf 에서는 지원되지 않습니다.
QtProtobuf::WireTypes::EndGroup4그룹. proto 구문 3에서 더 이상 사용되지 않습니다. Qt Protobuf 에서는 지원되지 않습니다.
QtProtobuf::WireTypes::Fixed325fixed32, sfixed32, float

‘encoding’항목도 참조하십시오 .

[alias] QtProtobuf::boolList

bool 값으로 구성된 목록의 별칭.

[alias] QtProtobuf::doubleList

double型の 리스트에 대한 별칭.

[alias] QtProtobuf::fixed32

fixed32는 protobuf에서 고정 길이의 32비트 필드로 표현되는 부호 없는 32비트 정수이며, ` WireTypes::Fixed32`의 별칭입니다.

[alias] QtProtobuf::fixed64

fixed64는 부호 없는 64비트 정수이며, 프로토버프(protobuf)에서는 고정 길이의 64비트 필드로 표현되며, WireTypes::Fixed64 의 별칭입니다.

[alias] QtProtobuf::fixed32List

QtProtobuf::fixed32 의 목록에 대한 별칭.

[alias] QtProtobuf::fixed64List

QtProtobuf::fixed64 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::floatList

부동소수점 숫자 목록에 대한 별칭.

[alias] QtProtobuf::int32

int32는 일반적인 부호 있는 32비트 정수이며, Protobuf에서는 가변 길이 정수로 표현되며, WireTypes::Varint 의 별칭입니다.

[alias] QtProtobuf::int64

int64는 일반적인 부호 있는 64비트 정수로, protobuf에서는 가변 길이 정수로 표현되며, WireTypes::Varint 의 별칭입니다.

[alias] QtProtobuf::int32List

QtProtobuf::int32 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::int64List

QtProtobuf::int64 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::sfixed32

sfixed32는 부호 있는 32비트 정수이며, protobuf에서는 고정 길이의 32비트 필드로 표현되며, WireTypes::Fixed32 의 별칭입니다.

[alias] QtProtobuf::sfixed64

sfixed64는 부호 있는 64비트 정수이며, 프로토버프(protobuf)에서는 고정 길이의 64비트 필드로 표현되며, WireTypes::Fixed64 의 별칭입니다.

[alias] QtProtobuf::sfixed32List

QtProtobuf::sfixed32 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::sfixed64List

QtProtobuf::sfixed64 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::sint32

sint32는 부호 강제 지정 마커가 있는 32비트 정수로, protobuf에서는 가변 크기 정수로 표현되며, WireTypes::Varint 의 별칭입니다. sint32는 음수의 크기를 줄이기 위해 ZigZag 변환을 사용하여 직렬화됩니다.

signed-integers항목도 참조하십시오 .

[alias] QtProtobuf::sint64

sint64는 강제 부호 마커가 있는 64비트 정수로, protobuf에서는 가변 길이 정수로 표현되며, WireTypes::Varint 의 별칭입니다. sint64는 음수의 크기를 줄이기 위해 ZigZag 변환을 사용하여 직렬화됩니다.

signed-integers항목도 참조하십시오 .

[alias] QtProtobuf::sint32List

QtProtobuf::sint32 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::sint64List

QtProtobuf::sint64 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::uint32

uint32는 부호 없는 32비트 정수이며, 프로토버프(Protobuf)에서는 가변 길이 정수로 표현되며, ` WireTypes::Varint`의 별칭입니다.

[alias] QtProtobuf::uint64

uint64는 부호 없는 64비트 정수로, Protobuf에서는 가변 길이 정수로 표현되며, WireTypes::Varint 의 별칭입니다.

[alias] QtProtobuf::uint32List

QtProtobuf::uint32 의 목록에 대한 별칭입니다.

[alias] QtProtobuf::uint64List

QtProtobuf::uint64 의 목록에 대한 별칭입니다.

함수 문서

template <typename T, std::enable_if_t<std::is_enum<T>::value, bool> = true> void qRegisterProtobufEnumType()

T 열거형에 대한 직렬화기를 QtProtobuf 전역 직렬화기 레지스트리에 등록합니다.

이 함수는 일반적으로 생성된 코드에 의해 호출됩니다.

template <typename K, typename V> requires QtProtobuf::if_protobuf_map<K, V> void qRegisterProtobufMapType()

Protobuf 맵 유형 K 과 V 을 등록합니다. V 는 반드시 QProtobufMessage 이어야 합니다. 이 함수는 일반적으로 생성된 코드에 의해 호출됩니다.

template <typename T> requires QtProtobuf::if_protobuf_message<T> void qRegisterProtobufType()

Protobuf 유형 T를 등록합니다. 이 함수는 일반적으로 생성된 코드에서 호출됩니다.

void qRegisterProtobufTypes()

이 함수를 호출하면 현재 알려진 모든 protobuf 유형이 직렬화기 레지스트리에 등록됩니다.

참고: Qt 6.6.3버전부터는 이 함수가 자동으로 호출되므로 수동으로 호출할 필요가 없습니다. 이전 버전의 경우, 직렬화/역직렬화를 시도하기 전에 이 함수를 호출하는 것이 좋습니다.

void QtProtobuf::registerProtobufQtCoreTypes()

Qt::ProtobufQtCoreTypes 라이브러리의 직렬화기를 등록합니다.

void QtProtobuf::registerProtobufQtGuiTypes()

Qt::ProtobufQtGuiTypes 라이브러리에 대한 직렬화기를 등록합니다.

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.