Salesforce Developer Flashcards
What do you lose when choosing a Visualforce Edit page over a Standard Edit page?
Ability to change page layout use Page Layout Editor and lose Inline editing capabilities in list views
What is the declarative alternative to writing Triggers?
Automate Field Updates using Workflow
- What is a declarative alternative for calculating field values in a controller extension?
a. Formula Fields and Roll-Up Summary Fields
What is the only relationship a Roll-Up Summary can exist on?
Master-Detail Relationship
What Declarative tool can Enforce Business Rules?
a. Validation Rules
What two declarative tools can be used to define complex custom business logic and business processes?
a. Approval Processes and Flows
What is state and behavior in reference to objects?
a. State is what an object knows while behaviors is what an object can do
What specifies the state and behavior of an object?
Variables specify the state while Methods specify the Behavior.
Define an Interface
a class in which none of the methods have been implemented—the method signatures are there, but the body of each method is empty
What is the condition to use an interface?
a. another class must implement it by providing a body for all of the methods contained in the interface.
How many levels of inner classes can exist in Apex?
One
What is not necessary in the declaration of an inner class?
An access modifier
What is required to define a class?
Access Modifier, Keyword Class
What does the Private Access Modifier do?
Class is only known locally, only by this section of code
What happens if you don’t specify an access modifier for an inner class?
It defaults to private
What does the global access modifier do?
Declares class to be known by all Apex Code everywhere
Classes with the Webservice keyword must have what access modifier?
Global
What is required if an inner class is defined as global?
The outer class must also be defined as global
What keyword can be used to run a class in the sharing mode that called it?
Use the inherited sharing keyword
What keyword enforces sharing rules of the current user?
The with sharing keyword
What does without sharing keyword do?
Runs class without the current users sharing rules
What does the ‘virtual’ definition modifier do?
Declares that the class allows extensions and overrides
What is the requirement to use the override keyword?
The class must be defined as virtual
What does the ‘abstract’ definition modifier do?
Declares a class to have abstract methods (methods that only have signatures declared and no body defined)
A class can implement_____ ______, but only extend _______ _________ _________.
many interfaces, one existing class
What are possible modifiers for variables?
public, final, and static
What is required to declare a variable?
Datatype and the Name
What are the 8 Primitive Data Types supported by Apex?
Integer, Double, Long, Date, Datetime, String, Boolean and ID
What is enum?
A data type consisting of typed list of values
Define the three collection types
LIst: ordered collection
Set: unordered list without duplicates
Map: list of Key:Value pairs
A Set<ID> is commonly used in?</ID>
In a SOQL query as part of the WHERE clause