+ Start a Discussion

Learning Apex Classes and Triggers

HI all,
(System.Trigger.isInsert ||
(lead.Email != System.Trigger.oldMap.
How can I understand this ?here get() is the method in the oldMap or how many methods are there  in oldMap? and where to use get ()put()set()??orelse we can use where ever we want ??

Please help me ..I am Learning Apex classes and Triggers
Nirmal ChristopherNirmal Christopher
trigger.oldmap is a kind of a collection variable which stores the records before the database commit occurs. Its just a map collection element. So all the map supported methods will apply for this element.
please look at the below link for the map methods which can be used.


Hope I answered your question. Hit best anser button if its helpful.