in src/scip-lib/mapper/scip_lsp.go [62:139]
func ScipSymbolKindToDocumentSymbolKind(symbolKind scip.SymbolInformation_Kind) protocol.SymbolKind {
symKindMap := map[scip.SymbolInformation_Kind]protocol.SymbolKind{
scip.SymbolInformation_Function: protocol.SymbolKindFunction,
scip.SymbolInformation_Delegate: protocol.SymbolKindFunction,
scip.SymbolInformation_Macro: protocol.SymbolKindFunction,
scip.SymbolInformation_File: protocol.SymbolKindFile,
scip.SymbolInformation_Module: protocol.SymbolKindModule,
scip.SymbolInformation_Library: protocol.SymbolKindModule,
scip.SymbolInformation_Namespace: protocol.SymbolKindNamespace,
scip.SymbolInformation_Package: protocol.SymbolKindPackage,
scip.SymbolInformation_PackageObject: protocol.SymbolKindPackage,
scip.SymbolInformation_Class: protocol.SymbolKindClass,
scip.SymbolInformation_TypeClass: protocol.SymbolKindClass,
scip.SymbolInformation_Mixin: protocol.SymbolKindClass,
scip.SymbolInformation_SingletonClass: protocol.SymbolKindClass,
scip.SymbolInformation_Contract: protocol.SymbolKindClass,
scip.SymbolInformation_Method: protocol.SymbolKindMethod,
scip.SymbolInformation_MethodReceiver: protocol.SymbolKindMethod,
scip.SymbolInformation_AbstractMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_StaticMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_SingletonMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_MethodSpecification: protocol.SymbolKindMethod,
scip.SymbolInformation_MethodAlias: protocol.SymbolKindMethod,
scip.SymbolInformation_TraitMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_ProtocolMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_PureVirtualMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_TypeClassMethod: protocol.SymbolKindMethod,
scip.SymbolInformation_Property: protocol.SymbolKindProperty,
scip.SymbolInformation_Getter: protocol.SymbolKindProperty,
scip.SymbolInformation_Setter: protocol.SymbolKindProperty,
scip.SymbolInformation_Accessor: protocol.SymbolKindProperty,
scip.SymbolInformation_StaticProperty: protocol.SymbolKindProperty,
scip.SymbolInformation_Subscript: protocol.SymbolKindProperty,
scip.SymbolInformation_Attribute: protocol.SymbolKindProperty,
scip.SymbolInformation_Field: protocol.SymbolKindField,
scip.SymbolInformation_StaticField: protocol.SymbolKindField,
scip.SymbolInformation_StaticDataMember: protocol.SymbolKindField,
scip.SymbolInformation_Constructor: protocol.SymbolKindConstructor,
scip.SymbolInformation_Enum: protocol.SymbolKindEnum,
scip.SymbolInformation_EnumMember: protocol.SymbolKindEnumMember,
scip.SymbolInformation_Interface: protocol.SymbolKindInterface,
scip.SymbolInformation_Trait: protocol.SymbolKindInterface,
scip.SymbolInformation_Protocol: protocol.SymbolKindInterface,
scip.SymbolInformation_Variable: protocol.SymbolKindVariable,
scip.SymbolInformation_Parameter: protocol.SymbolKindVariable,
scip.SymbolInformation_ParameterLabel: protocol.SymbolKindVariable,
scip.SymbolInformation_SelfParameter: protocol.SymbolKindVariable,
scip.SymbolInformation_ThisParameter: protocol.SymbolKindVariable,
scip.SymbolInformation_StaticVariable: protocol.SymbolKindVariable,
scip.SymbolInformation_Value: protocol.SymbolKindVariable,
scip.SymbolInformation_Constant: protocol.SymbolKindConstant,
scip.SymbolInformation_String: protocol.SymbolKindString,
scip.SymbolInformation_Number: protocol.SymbolKindNumber,
scip.SymbolInformation_Boolean: protocol.SymbolKindBoolean,
scip.SymbolInformation_Array: protocol.SymbolKindArray,
scip.SymbolInformation_Object: protocol.SymbolKindObject,
scip.SymbolInformation_Key: protocol.SymbolKindKey,
scip.SymbolInformation_Null: protocol.SymbolKindNull,
scip.SymbolInformation_Struct: protocol.SymbolKindStruct,
scip.SymbolInformation_Union: protocol.SymbolKindStruct,
scip.SymbolInformation_Message: protocol.SymbolKindStruct,
scip.SymbolInformation_Event: protocol.SymbolKindEvent,
scip.SymbolInformation_StaticEvent: protocol.SymbolKindEvent,
scip.SymbolInformation_Operator: protocol.SymbolKindOperator,
scip.SymbolInformation_Type: protocol.SymbolKindTypeParameter,
scip.SymbolInformation_TypeAlias: protocol.SymbolKindTypeParameter,
scip.SymbolInformation_TypeParameter: protocol.SymbolKindTypeParameter,
scip.SymbolInformation_AssociatedType: protocol.SymbolKindTypeParameter,
scip.SymbolInformation_TypeFamily: protocol.SymbolKindTypeParameter,
}
kind, ok := symKindMap[symbolKind]
if !ok {
return protocol.SymbolKindNull
}
return kind
}