mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
New JSON functionality.
This commit is contained in:
@@ -89,13 +89,18 @@ LedgerEntryFormat* getLgrFormat(LedgerEntryType t)
|
||||
|
||||
LedgerEntryFormat* getLgrFormat(int t)
|
||||
{
|
||||
LedgerEntryFormat* f = LedgerFormats;
|
||||
while (f->t_name != NULL)
|
||||
{
|
||||
for (LedgerEntryFormat* f = LedgerFormats; f->t_name != NULL; ++f)
|
||||
if (f->t_type == t)
|
||||
return f;
|
||||
++f;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
LedgerEntryFormat* getLgrFormat(const std::string& t)
|
||||
{
|
||||
for (LedgerEntryFormat* f = LedgerFormats; f->t_name != NULL; ++f)
|
||||
if (t == f->t_name)
|
||||
return f;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// vim:ts=4
|
||||
|
||||
Reference in New Issue
Block a user