Using array cast to avoid reflection usage at runtime for extraction