The sizing keys used in the Salesforce B2B Commerce Global APIs five distinct operations. What are three of these operations? (3 answers)
Correct Answer: A,D,E
The sizing keys used in the Salesforce B2B Commerce Global APIs perform five distinct operations. Three of these operations are: Refetch data (used on some Logic classes): This operation indicates that the data should be refetched from the database instead of using the cached data. For example, ccrz.ccServiceCart.getCart(ccrz.ccAPI.SZ_REFETCH) will refetch the cart data and refresh the cache. Related Query to call (sub queries or direct queries): This operation indicates that the related entities should be retrieved by using sub queries or direct queries. For example, ccrz.ccServiceProduct.getProducts(ccrz.ccAPI.SZ_SUBQUERY) will use sub queries to fetch the related entities for each product, while ccrz.ccServiceProduct.getProducts(ccrz.ccAPI.SZ_DIRECTQUERY) will use direct queries to fetch the related entities separately. Object type casting: This operation indicates that the data should be cast to a specific object type. For example, ccrz.ccServiceProduct.getProducts(ccrz.ccAPI.SZ_SOBJECT) will cast the data to sObjects instead of transformed objects. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Data Sizing Conventions
B2B-Commerce-Developer Exam Question 22
Witch static method invocation is used to initialize ccrz.cc_CallContext with information from ccrz.cc_RemoteActionContext and return an instance of ccrz.cc_RemoteActionResult in an apex @RemoteAction methos?
Correct Answer: B
The static method invocation that is used to initialize ccrz.cc_CallContext with information from ccrz.cc_RemoteActionContext and return an instance of ccrz.cc_RemoteActionResult in an Apex @RemoteAction method is ccrz.cc_CallContext.initCallContext(ccrz.cc_RemoteActionContext). This method takes in a ccrz.cc_RemoteActionContext object as a parameter and returns a ccrz.cc_RemoteActionResult object. The ccrz.cc_RemoteActionContext object contains information about the current storefront, user, cart, price list, currency, locale, and session. The ccrz.cc_RemoteActionResult object contains information about the status, result, and errors of the remote action. The other methods are not valid or do not exist. Salesforce Reference: B2B Commerce Developer Guide: cc_CallContext Class, B2B Commerce Developer Guide: cc_RemoteActionContext Class, B2B Commerce Developer Guide: cc_RemoteActionResult Class
B2B-Commerce-Developer Exam Question 23
A developer has the task to bring some historical data into an org. The data must reside in the org, but cannot be populated in standard or custom objects. The customer is fine with developers building Ul components to surface this data on a case-by-case basis. Which option allows a developer to meet all of these requirements?
Correct Answer: C
To bring some historical data into an org, the data must reside in the org, but cannot be populated in standard or custom objects, and the customer is fine with developers building UI components to surface this data on a case-by-case basis, the option that allows a developer to meet all of these requirements is big objects. Big objects are a type of object that can store and manage massive amounts of data on the Salesforce platform. Big objects can store up to billions of records and are accessible through a subset of SOQL or custom user interfaces. Big objects are not subject to the same storage limits or performance issues as standard or custom objects and are suitable for storing historical or archived data that does not need to be updated frequently. Big objects can be defined using Metadata API or declaratively in Setup. Lightning Canvas is not an option that allows a developer to meet all of these requirements, as it is a framework that allows developers to integrate third-party applications into Salesforce. Lightning Canvas does not store data in the org, but rather displays data from external sources using an iframe. External objects are not an option either, as they are a type of object that map to data stored outside Salesforce. External objects do not store data in the org, but rather access data from external systems using OData services. Lightning Out is not an option either, as it is a feature that allows developers to use Lightning components outside Salesforce. Lightning Out does not store data in the org, but rather renders components on external web pages or applications. Salesforce References: Salesforce Help: Define BigObjects, Salesforce Help: Lightning Canvas Developer's Guide, Salesforce Help: External Objects, Salesforce Developer Blog: Lightning Out
B2B-Commerce-Developer Exam Question 24
What is one requirement to keep in mind when including additional JavaScript 1h files in a Lightning Web Component?
Correct Answer: A
When including additional JavaScript files in a Lightning Web Component, it is required that these files are ECMAScript 6 (ES6) modules and have unique names within the component's folder. This ensures proper module resolution and avoids namespace conflicts. Salesforce LWC documentation provides guidelines on organizing component resources, including JavaScript modules, to ensure they are correctly recognized and utilized within the LWC framework.
B2B-Commerce-Developer Exam Question 25
What is default behavior for how the Salesforce B2B Commerce Global APIs transform Salesforce data?