Get Number Of Sub Contexts
- 19 Jan 2023
- 1 Minute to read
- Print
- DarkLight
Get Number Of Sub Contexts
- Updated on 19 Jan 2023
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Step Details | |
Introduced in Version | 4.0.0 |
Last Modified in Version | 5.12.0 |
Location | System > Advanced > Debugger |
The Get Number Of Sub Contexts step will return the number of the specified sub context type.
Properties
Inputs
Property | Description | Data Type |
---|---|---|
Debug Id | The Id of the debugged Flow | String |
Only Children | Determines whether only child elements are returned | Boolean |
Sub Context Type | Allows the user to specify the sub context type to be returned (All, Flows, Rules, Forms) | --- |
Outputs
Property | Description | Data Type |
---|---|---|
Output | The number of sub contexts within the debugged Flow | String |
Example Inputs and Outputs
Debug Id | Only Children | Sub Context Type | Output |
---|---|---|---|
6892a6da85c343148757ba98156a6e34_debug.5a2b35e7-afc3-45df-9b65-211a435d2e8d | False | Flows | 0 |
1160d151c0854eadb54ca79a76eab017_debug.ff4150cf-63c8-4e12-b3ff-cd047f33988a | True | Forms | 1 |
Null | True | All | EXCEPTION MESSAGE |
1160d151c0854eadb54ca79a76eab017_debug.ff4150cf-63c8-4e12-b3ff-cd047f33988a | False | Null | EXCEPTION MESSAGE |
Common Errors
Debug entity with id = '' not found
If the debug id is null or empty, the step will cause an error.
To correct this, ensure that the Debug Id is entered or mapped correctly.
Exception Message:
Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Get Number Of Sub Contexts 1[GetNumberOfSubContexts] in flow [Flow 6]: Exception invoking method GetNumberOfSubContexts on class DebuggerSteps
---> DecisionsFramework.LoggedException: Exception invoking method GetNumberOfSubContexts on class DebuggerSteps
---> System.InvalidOperationException: Debug entity with id = '' not found.
at DecisionsFramework.Design.Flow.Service.Debugging.DebugData.DebugDataStorage.Retrieve(String id, Boolean failIfNotFound
at DecisionsFramework.Design.Flow.Service.Debugging.DebugData.DebuggerSteps.GetNumberOfSubContexts(String debugId, DebuggerStepContextType subContextType, Boolean onlyChildren)
--- End of inner exception stack trace --- at DecisionsFramework.Design.Flow.StepImplementations.InvokeMethodStep.Run(StepStartData data
at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData
at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData)
--- End of inner exception stack trace ---
Parameter 'subContextType' of 'GetNumberOfSubContexts' can not be null
If the Sub Context Type value is null or empty, the step will cause an error.
To correct this, ensure that the Sub Context type is specified using a Constant mapping and selecting one of the options.
Exception Message:
Exception Stack Trace: DecisionsFramework.BusinessRuleException: [BusinessRule] Parameter 'subContextType' of 'GetNumberOfSubContexts' can not be null
at DecisionsFramework.Design.Flow.CoreSteps.InvokeMethodUtility.ThrowErrorIfNullIsNotAllowed(MethodInfo methodInfo, Object[] parameterValues, String errorMessage
at DecisionsFramework.Design.Flow.StepImplementations.InvokeMethodStep.Run(StepStartData data
at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData
at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData)
Was this article helpful?