public boolean needsPointerAccess(PropertyField field) {
        boolean isAnTypeOfOptional = "optional".equals(field.getTypeName());
        return isAnTypeOfOptional && needPointerAccess(field.getType());
    }
Returns true if the given property field needs pointer access or not.

<p>
This method returns true if the property field has an optional attribute and its type reference
needs pointer access or not. This is the case if the type reference is not a complex type reference
and the type reference is not an array type reference or if the array type reference has an
element type reference that is not a complex type reference.

@param field the property field to check
@return true if the property field needs pointer access, false otherwise
code-generation/language-python/src/main/java/org/apache/plc4x/language/python/PythonLanguageTemplateHelper.java