MCPcopy Create free account
hub / github.com/SoarGroup/Soar / smem_reverse_hash

Function smem_reverse_hash

Core/SoarKernel/src/semantic_memory.cpp:1089–1115  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1087}
1088
1089inline Symbol* smem_reverse_hash(agent* thisAgent, byte symbol_type, smem_hash_id hash_value)
1090{
1091 Symbol* return_val = NULL;
1092 std::string dest;
1093
1094 switch (symbol_type)
1095 {
1096 case STR_CONSTANT_SYMBOL_TYPE:
1097 smem_reverse_hash_str(thisAgent, hash_value, dest);
1098 return_val = make_str_constant(thisAgent, const_cast<char*>(dest.c_str()));
1099 break;
1100
1101 case INT_CONSTANT_SYMBOL_TYPE:
1102 return_val = make_int_constant(thisAgent, smem_reverse_hash_int(thisAgent, hash_value));
1103 break;
1104
1105 case FLOAT_CONSTANT_SYMBOL_TYPE:
1106 return_val = make_float_constant(thisAgent, smem_reverse_hash_float(thisAgent, hash_value));
1107 break;
1108
1109 default:
1110 return_val = NULL;
1111 break;
1112 }
1113
1114 return return_val;
1115}
1116
1117
1118//////////////////////////////////////////////////////////

Callers 1

smem_install_memoryFunction · 0.85

Calls 6

smem_reverse_hash_strFunction · 0.85
make_str_constantFunction · 0.85
make_int_constantFunction · 0.85
smem_reverse_hash_intFunction · 0.85
make_float_constantFunction · 0.85
smem_reverse_hash_floatFunction · 0.85

Tested by

no test coverage detected