Question 380
A logistics vendor must swap carrier pricing implementations based on an enum selection while calling the same method signature. A targeted trial still reproduces the original gap after the team attempted this change: Define an AL interface and implement it in the provider codeunits. Which repair directly addresses the remaining defect?
Explanation
Correct Answer
Align the codeunit implementations with the interface method signatures and correct provider selection. This directly addresses the remaining defect for the requirement—A logistics vendor must swap carrier pricing implementations based on an enum selection while calling the same method signature. It restores the mechanism described here: interfaces define a contract and enable polymorphic dispatch without hard-coding a concrete provider into every caller.
Incorrect Answers
This correction is for the separate condition: A fiscal app requires a default setup row the first time it is installed for a customer. It would not directly restore the intended behavior in this situation: A logistics vendor must swap carrier pricing implementations based on an enum selection while calling the same method signature. Here, align the codeunit implementations with the interface method signatures and correct provider selection, because interfaces define a contract and enable polymorphic dispatch without hard-coding a concrete provider into every caller.
This correction is for the separate condition: A vendor moves invoice surcharge settings from one table to another in a new app version. It would not directly restore the intended behavior in this situation: A logistics vendor must swap carrier pricing implementations based on an enum selection while calling the same method signature. Here, align the codeunit implementations with the interface method signatures and correct provider selection, because interfaces define a contract and enable polymorphic dispatch without hard-coding a concrete provider into every caller.
This correction is for the separate condition: Three extensions all implement the same freight-cost calculation with small inconsistent differences. It would not directly restore the intended behavior in this situation: A logistics vendor must swap carrier pricing implementations based on an enum selection while calling the same method signature. Here, align the codeunit implementations with the interface method signatures and correct provider selection, because interfaces define a contract and enable polymorphic dispatch without hard-coding a concrete provider into every caller.





Microsoft Dynamics 365 Business Central Developer (MB-820) Practice Tests