What are the different types of controllers?

What are the different types of controllers?

Controller definition: A visual force controller is a set of instructions that specify what happens when a user interacts with the components specified in associated Visualforce markup, such as when a user clicks a button or a link.

Controllers also provide access to the data that should be displayed in a page, and can modify component behavior.

Standard Controller: A standard controller consists of the same functionality and logic that is used for a standard Salesforce page. For example, if we use the standard accounts controller, clicking a Save button in a Visualforce page result in the same behavior as clicking Save on a standard Account edit page.

Custom Controller: A custom controller is a class written in Apex that implements all of a page logic.

If we use custom controller, we can define new navigation elements or behaviors, but we must also reimplement any functionality that was already provided in a standard controller.

Controller Extensions: A controller extensions is a class written in Apex that adds to or overrides behavior in a standard or custom controller. Extensions allow us to leverage that functionality of another controller while adding our own custom logic.

Source: https://www.udemy.com/course/salesforce-interview-question-with-answers/?utm_medium=648408&utm_content=promo&utm_campaign=2021-01-26&utm_source=email-sendgrid&utm_term=6501452&couponCode=LEARNSALESFORCE

2 views0 comments

Recent Posts

See All

Emergency Fund 401K Match High Interest Debt Roth IRA HSA 529 Max 401K Taxable Low Interest Debt Mortgage https://www.youtube.com/watch?v=UfR9WqxDhGk

Dan teaches courses on pluralsight, but he also maintains two sites: 1. A google custom search engine for all things SalesForce https://searchtheforce.com/ 2. advanceapex.com