I recently looked at wrapper classes and looked at the following page ... http://wiki.developerforce.com/page/Wrapper_Class
While I understood wrapper classes, I was puzzled by the following ...
public List<cContact> getContacts() { if(contactList == null) { contactList = new List<cContact>(); for(Contact c: [select Id, Name, Email, Phone from Contact limit 10]) {
and in particular...
for(Contact c: [select Id, Name, Email, Phone from Contact limit 10]) { ... }
What it is? Where can I see more information about this in foreach?
I know about LINQ and select, from, where, etc., but I have never seen the syntax of _this _ . What is it and how do I understand this syntax more?
c # foreach apex-code
Christopher rucinski
source share