mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Somehow this function disappeared.
This commit is contained in:
@@ -467,6 +467,16 @@ void STObject::setValueFieldH160(SOE_Field field, const uint160& v)
|
|||||||
cf->setValue(v);
|
cf->setValue(v);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void STObject::setValueFieldH256(SOE_Field field, const uint256& v)
|
||||||
|
{
|
||||||
|
SerializedType* rf = getPField(field);
|
||||||
|
if (!rf) throw std::runtime_error("Field not found");
|
||||||
|
if (rf->getSType() == STI_NOTPRESENT) rf = makeFieldPresent(field);
|
||||||
|
STHash256* cf = dynamic_cast<STHash256*>(rf);
|
||||||
|
if (!cf) throw std::runtime_error("Wrong field type");
|
||||||
|
cf->setValue(v);
|
||||||
|
}
|
||||||
|
|
||||||
void STObject::setValueFieldAccount(SOE_Field field, const uint160& v)
|
void STObject::setValueFieldAccount(SOE_Field field, const uint160& v)
|
||||||
{
|
{
|
||||||
SerializedType* rf = getPField(field);
|
SerializedType* rf = getPField(field);
|
||||||
|
|||||||
Reference in New Issue
Block a user