Please solve the programming task below using a self-contained code snippet in a markdown code block.

You are given a binary array nums.
A subarray of an array is good if it contains exactly one element with the value 1.
Return an integer denoting the number of ways to split the array nums into good subarrays. As the number may be too large, return it modulo 109 + 7.
A subarray is a contiguous non-empty sequence of elements within an array.
 
Please complete the following python code precisely:
```python
class Solution:
    def numberOfGoodSubarraySplits(self, nums: List[int]) -> int:
```