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

Given an integer array nums, return the maximum possible sum of elements of the array such that it is divisible by three.
 
Please complete the following python code precisely:
```python
class Solution:
    def maxSumDivThree(self, nums: List[int]) -> int:
```