MCPcopy Create free account
hub / github.com/SakuraEngine/SakuraEngine / BeginValue

Method BeginValue

modules/engine/graphics/src/d3d12/D3D12MemAlloc.cpp:1610–1635  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1608}
1609
1610void JsonWriter::BeginValue(bool isString)
1611{
1612 if (!m_Stack.empty())
1613 {
1614 StackItem& currItem = m_Stack.back();
1615 if (currItem.type == COLLECTION_TYPE_OBJECT && currItem.valueCount % 2 == 0)
1616 {
1617 D3D12MA_ASSERT(isString);
1618 }
1619
1620 if (currItem.type == COLLECTION_TYPE_OBJECT && currItem.valueCount % 2 == 1)
1621 {
1622 m_SB.Add(L':'); m_SB.Add(L' ');
1623 }
1624 else if (currItem.valueCount > 0)
1625 {
1626 m_SB.Add(L','); m_SB.Add(L' ');
1627 WriteIndent();
1628 }
1629 else
1630 {
1631 WriteIndent();
1632 }
1633 ++currItem.valueCount;
1634 }
1635}
1636
1637void JsonWriter::WriteIndent(bool oneLess)
1638{

Callers

nothing calls this directly

Calls 3

emptyMethod · 0.45
backMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected