Apex Code Flashcards

1
Q

Primitive Data Types

A
Integer
Double
Long
Date
Date/Time
String
ID
Boolean
Blob
Decimal
Object
Time
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

IDEs compatible with SalesForce

A

VS Code
Force.com IDE
Dev Console

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Collections

A

Maps
Lists
Sets

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Coding best practices 10

A
Comment
Bulkify 
Efficient for loops
Utilize collections
No SOQL/SOSL in loops
One trigger per object
Query large data sets
Use limits class
Use @future appropriately 
Test large data sets
Don’t hard core ID’s
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Testing best practices 10

A
Always test
Single actions
Bulk actions
Positive actions 
Negative actions 
User access
Test each branch of if statement 
No exceptions outside of try catch
Use system.assert to verify data
Test bulk of at least 20 records
Set up test data
Comment tests
Order by
Test individually to catch all errors
Start with most specific tests and get broader as you move along
How well did you know this?
1
Not at all
2
3
4
5
Perfectly