MCPcopy Create free account
hub / github.com/OpenDDS/OpenDDS / vwrite

Function vwrite

dds/DCPS/XTypes/DynamicVwrite.cpp:1423–1445  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1421namespace DCPS {
1422
1423bool vwrite(ValueWriter& vw, DDS::DynamicData_ptr value)
1424{
1425 using namespace XTypes;
1426 const DDS::DynamicType_var type = value->type();
1427 const DDS::DynamicType_var base_type = XTypes::get_base_type(type);
1428 const DDS::TypeKind tk = base_type->get_kind();
1429 switch (tk) {
1430 case TK_STRUCTURE:
1431 return vwrite_struct(vw, value, base_type);
1432 case TK_UNION:
1433 return vwrite_union(vw, value, base_type);
1434 case TK_ARRAY:
1435 return vwrite_array(vw, value, base_type);
1436 case TK_SEQUENCE:
1437 return vwrite_sequence(vw, value, base_type);
1438 default:
1439 if (log_level >= LogLevel::Warning) {
1440 ACE_ERROR((LM_WARNING, "(%P|%t) WARNING: vwrite: Unexpected type %C\n",
1441 XTypes::typekind_to_string(tk)));
1442 }
1443 }
1444 return false;
1445}
1446
1447}
1448}

Callers 1

vwrite_itemFunction · 0.70

Calls 8

get_base_typeFunction · 0.85
vwrite_structFunction · 0.85
vwrite_unionFunction · 0.85
vwrite_arrayFunction · 0.85
vwrite_sequenceFunction · 0.85
typekind_to_stringFunction · 0.85
get_kindMethod · 0.80
typeMethod · 0.45

Tested by

no test coverage detected