New ValidDumps PDI Exam Questions Real PDI Dumps Updated on Aug 05, 2022 [Q173-Q194]

Share

New ValidDumps PDI Exam Questions| Real PDI Dumps Updated on Aug 05, 2022

PDI Braindumps – PDI Questions to Get Better Grades


For more info visit:

PDI Exam Reference


Certification Path

There is no prerequisite for this exam.

 

NEW QUESTION 173
What is the result of the debug statements in testMethod3 when you create test data using testSetup in below code?

  • A. Account0.Phone=888-1515, Account1.Phone=999-1515
  • B. Account0.Phone=333-8780, Account1.Phone=333-8781
  • C. Account0.Phone=333-8781, Account1.Phone=333-8780
  • D. Account0.Phone=888-1515, Account1.Phone=999-2525

Answer: B

 

NEW QUESTION 174
What is a valid statement about Apex classes and interfaces? Choose 2 answers:

  • A. Exception classes must end with the word exception.
  • B. A class can have multiple levels of inner classes.
  • C. The default modifier for an interface is private.
  • D. The default modifier for a class is private.

Answer: A,C

 

NEW QUESTION 175
Given the following block code: try{ List <Accounts> retrievedRecords = [SELECT Id FROM Account WHERE Website = null]; }catch(Exception e){ //manage exception logic } What should a developer do to ensure the code execution is disrupted if the retrievedRecordslist remains empty after the SOQL query?

  • A. Check the state of the retrievedRecords variable and access the first element of the list if the variable is empty.
  • B. Check the state of the retrieveRecords variable and throw a custom exception if the variable is empty.
  • C. Check the state of the retrievedRecords variable and use System.assert(false) if the variable is empty
  • D. Replace the retrievedRecords variable declaration from ftount to a single Account.

Answer: C

 

NEW QUESTION 176
As part of a data cleanup strategy, AW Computing wants to proactively delete associated opportunity records when the related Account is deleted.
Which automation tool should be used to meet this business requirement?

  • A. Workflow Rules
  • B. Process Builder
  • C. Scheduled job
  • D. Record-Triggered Flow

Answer: D

 

NEW QUESTION 177
A developer must create a CreditcardPayment class that provides an implementation of an existing Payment class. Public virtual class Payment { public virtual void makePayment(Decimal amount) { /*implementation*/
} } Which is the correct implementation?

  • A. Public class CreditCardPayment implements Payment {
    public override void makePayment(Decimal amount) { /*Implementation*/ }
    }
  • B. Public class CreditcardPayment extends Payment {
    public override void makePayment(Decimal amount) { /*implementation*/ }
    }
  • C. Public class CreditCardPayment implements Payment {
    public virtual void makePayment(Decimal amount) { /*implementation*/ }
    }
  • D. Public class CreditCardPayment extends Payment {
    public virtual void makePayment(Decimal amount) { /*implementation*/ }
    }

Answer: B

 

NEW QUESTION 178
A develop completed modification to a customized feature that is comprised of two elements:
Apex trigger
Trigger handler Apex class
What are two factors that the developer must take into account to properly deploy the modification to the production environment?

  • A. Apex classes must have at least 75% code coverage org-wide.
  • B. At least one line of code must be executed for the Apex trigger.
  • C. All methods in the test classes must use @isTest.
  • D. Test methods must be declared with the testMethod keyword.

Answer: A,B

 

NEW QUESTION 179
A developer wants to display all of the available record types for a Case object. The developer also wants to display the picklist values for the Case.Status field. The Case object and the Case Status field are on a custom visualforce page.
Which action can the developer perform to get the record types and picklist values in the controller? Choose 2 answers

  • A. Use SOQL to query Case records in the org to get all value for the Status picklist field.
  • B. Use SOQL to query Case records in the org to get all the RecordType values available for Case.
  • C. Use Schema.RecordTypeinfo returned by Case.SObjectType getDescribe().getRecordTypelnfos()
  • D. Use Schema.PicklistEntry returned by Case Status getDescribe().getPicklistValues().

Answer: C,D

 

NEW QUESTION 180
A developer has a requirement to create an Order When an Opportunity reaches a "Closed-Won" status.
Which tool should be used to implement this requirement?

  • A. Apex trigger
  • B. Lightning
  • C. Lightning Component
  • D. Process Builder

Answer: D

 

NEW QUESTION 181
Where are two locations a developer can look to find information about the status of asynchronous or future methods? Choose 2 answers

  • A. Paused Flow Interviews component
  • B. Apex Jobs
  • C. Apex Flex Queue
  • D. Time-Based Workflow Monitor

Answer: B,C

 

NEW QUESTION 182
Managers at Universal Containers want to ensure that only decommissioned containers are able to be deleted in the system. To meet the business requirement a Salesforce developer adds ^Decommissioned" as a picklist value for the Status__: custom field within the Contact__c object.
Which tool should the developer use to enforce only Container records with a status of "Decommissioned" can be deleted?

  • A. Apex trigger
  • B. Before record-triggered flow
  • C. After record-triggered flow
  • D. Validation rule

Answer: A

 

NEW QUESTION 183
How many level of child records can be returned in a single SOQL query from one parent object

  • A. 0
  • B. 1
  • C. 2
  • D. 3

Answer: B

 

NEW QUESTION 184
What are two benefits of using declarative customizations over code? Choose 2 answers What are two benefits of using declarative customizations over code?

  • A. Declarative customizations automatically generate test classes.
  • B. Declarative customizations automatically update with each Salesforce release.
  • C. Declarative customizations generally require less maintenance.
  • D. Declarative customizations automatically generate test classes.

Answer: B,D

 

NEW QUESTION 185
Universal Containers has large number of custom applications that were built using a third-party javaScript framework and exposed using Visualforce pages. The Company wants to update these applications to apply styling that resembles the look and feel of Lightning Experience. What should the developer do to fulfill the business request in the quickest and most effective manner?

  • A. Enable Available for Lightning Experience, Lightning Communities, and the mobile app on Visualforce pages used by the custom application.
  • B. Set the attribute enableLightning to true in the definition.
  • C. Rewrite all Visualforce pages asLightning components.
  • D. Incorporate the Salesforce Lightning Design System CSS stylesheet into the JavaScript applications.

Answer: D

 

NEW QUESTION 186
A developer writes a before insert trigger.How can the developer access the incoming records in the trigger body?

  • A. By accessing the Trigger.newMap context variable.
  • B. By accessing the Tripper.newList context variable.
  • C. By accessing the Trigger.newRecords context variable.
  • D. By accessing the Trigger.new context variable.

Answer: D

 

NEW QUESTION 187
A developer has an integer variable called maxAttempts. The developer meeds to ensure that once maxAttempts is initialized, it preserves its value for the lenght of the Apex transaction; while being able to share the variable's state between trigger executions. How should the developer declare maxAttempts to meet these requirements?

  • A. Declare maxattempts as a constant using the static and final keywords
  • B. Declare maxattempts as a private static variable on a helper class
  • C. Declare maxattempts as a variable on a helper class
  • D. Declare maxattempts as a member variable on the trigger definition.

Answer: B

 

NEW QUESTION 188
A developer writes a trigger on the Account object on the before update event that increments a count field. A workflow rule also increments the count field every time that an Account is created or update. The field update in the workflow rule is configured to not re-evaluate workflow rules. What is the value of the count field if an Account is inserted with an initial value of zero, assuming no other automation logic is implemented on the Account?

  • A. 0
  • B. 1
  • C. 2
  • D. 3

Answer: D

 

NEW QUESTION 189
Given the following Apex statement:
Account myAccount = [SELECT Id, Name FROM Account];
What occurs when more than one Account is returned by the SOQL query?

  • A. The query fails and an error is written to the debug log.
  • B. The first Account returned is assigned to myAccount.
  • C. An unhandled exception is thrown and the code terminates.
  • D. The variable, myAccount, is automatically cast to the List data type.

Answer: C

 

NEW QUESTION 190
In which two trigger types can a developer modify the new sObject records that are obtained by the trigger.new context? Choose 2 answers

  • A. Before insert
  • B. After update
  • C. Before update
  • D. After insert

Answer: A,C

 

NEW QUESTION 191
A Visual Flow uses an apex Action to provide additional information about multiple Contacts, stored in a custom class, contactInfo. Which is the correct definition of the Apex method that gets additional information?

  • A. @InvocableMethod(Label='additional Info')
    public ContactInfo(Id contactId)
    { /*implementation*/ }
  • B. @InvocableMethod(label='additional Info')
    public static ContactInfo getInfo(Id contactId)
    { /*implementation*/ }
  • C. @InvocableMethod(label='Additional Info')
    public List<ContactInfo> getInfo(List<Id> contactIds)
    { /*implementation*/ }
  • D. @invocableMethod(label)='Additional Info')
    public static List<ContactInfo> getInfo(List<Id> contactIds)
    { /*Implementation*/ }

Answer: D

 

NEW QUESTION 192
A developer needs to create a custom button for the Account object that, when clicked, will perform a series of calculations and redirect the user to a custom Visualforce page. The developer wants to ensure the Visualforce page matches the Lightning Experience user interface.
What attribute needs to be defined within the <apex:page> tag to meet the requirement?

  • A. lightningStylesheets=''true"
  • B. setup="true"
  • C. applyHtmlTag="true"
  • D. wizard=true"

Answer: A

 

NEW QUESTION 193
D18912E1457D5D1DDCBD40AB3BF70D5D
A developer must create a ShippingCalculator class that cannot be instantiated and must include a working default implementation of a calculate method, that sub-classes can override.
What is the correct implementation of the ShippingCalculator class?

  • A. Option A
  • B. Option C
  • C. Option D
  • D. Option B

Answer: D

 

NEW QUESTION 194
......

PDI Exam Dumps - Try Best PDI Exam Questions: https://www.validdumps.top/PDI-exam-torrent.html

Get New PDI Certification – Valid Exam Dumps Questions: https://drive.google.com/open?id=1pSqtAAYoec935sXM2_9pldiMwfy666U8