private void arrayOutputFunc(StructureContext<T> context, Structure structure,
			FieldOutputInfo<T> foi) throws IOException {
		// only outputs array of primitive value
		Object fieldValue = foi.getValue(context.getStructureInstance(), Object.class);
		DataType dt = ReflectionHelper.getArrayOutputDataType(fieldValue, fmi.getField().getType(),
			fmi.getLength(), fmi.getSignedness(), context.getDataTypeMapper());
		preAddField(structure);
		structure.add(dt, fmi.getFieldName(), null);
	}
Returns the value of this java field.

@param <R> type of the result value
@param structInstance object containing the field
@param expectedType expected class of the value 
@return value of the field, or null if the field's value is not of expected type
@throws IOException if error accessing java field
Ghidra/Features/Base/src/main/java/ghidra/app/util/bin/format/golang/structmapping/FieldOutputInfo.java