MObject.apex

  • Docs
  • Tutorials
Docs Menu
  • MObject
  • MObject.Funcs
    • Funcs
  • MObject Instance
    • Creation Methods
    • Methods

Funcs Guide

MObject Funcs

create

Create an instance of MObject

MObject mo = (MObject)MObject.F.create.run(new Pricebook2(Name='test'));

toMap

Convert the MObject to map

 Map data = (Map)MObject.F.toMap.run(false, mo);

get

Get the value mapped by the path

Object value = MObject.F.get.run('default', 'Name', mo);

put

Set the value mapped by the path

MObject.F.put.run('Name', 'new Name', mo);

markDeleted

Mark the MObject as deleted

MObject.F.markDeleted.run(true, mo);

persist

Persist the MObject(s)

MObject.F.persist.run(mos);

Contribute on Github! Edit this section.