code: def _define_array_view(data_type):
      
      element_type = data_type.element_type
      element_view = _resolve_view(element_type)
      if element_view is None:
          mixins = (_DirectArrayViewMixin,)
          attributes = _get_mixin_attributes(mixins)
      elif isinstance(element_type, _ATOMIC):
          mixins = (_IndirectAtomicArrayViewMixin,)
          attributes = _get_mixin_attributes(mixins)
          attributes.update({
              '_element_view': element_view,
          })
      else:
          mixins = (_IndirectCompositeArrayViewMixin,)
          attributes = _get_mixin_attributes(mixins)
          attributes.update({
              '_element_view': element_view,
          })
  
      name = data_type.name if data_type.name else 'ArrayView'
      return type(name, (), attributes)
docs: Define a new view object for a `Array` type.