📁 File Manager Pro
v10.0.3 | PHP: 8.1.34
Server: Apache
2026-06-21 16:39:09
📂
/ (Root)
/
usr
/
lib
/
python3.6
/
site-packages
/
google
/
protobuf
/
__pycache__
📍 /usr/lib/python3.6/site-packages/google/protobuf/__pycache__
🔄 Refresh
✏️
Editing: symbol_database.cpython-36.opt-1.pyc
Read Only
3 ���h � @ sH d Z ddlmZ ddlmZ G dd� dej�Zeej� d�Zdd� Zd S ) aR A database of Python protocol buffer generated symbols. SymbolDatabase is the MessageFactory for messages generated at compile time, and makes it easy to create new instances of a registered type, given only the type's protocol buffer symbol name. Example usage: db = symbol_database.SymbolDatabase() # Register symbols of interest, from one or multiple files. db.RegisterFileDescriptor(my_proto_pb2.DESCRIPTOR) db.RegisterMessage(my_proto_pb2.MyMessage) db.RegisterEnumDescriptor(my_proto_pb2.MyEnum.DESCRIPTOR) # The database can be used as a MessageFactory, to generate types based on # their name: types = db.GetMessages(['my_proto.proto']) my_message_instance = types['MyMessage']() # The database's underlying descriptor pool can be queried, so it's not # necessary to know a type's filename to be able to generate it: filename = db.pool.FindFileContainingSymbol('MyMessage') my_message_instance = db.GetMessages([filename])['MyMessage']() # This functionality is also provided directly via a convenience method: my_message_instance = db.GetSymbol('MyMessage')() � )�descriptor_pool)�message_factoryc @ sH e Zd ZdZdd� Zdd� Zdd� Zdd � Zd d� Zdd � Z dd� Z dS )�SymbolDatabasez'A database of Python generated symbols.c C s |j }|| j|<