private Optional<OAuthFlows> getOAuthFlows(io.swagger.v3.oas.annotations.security.OAuthFlows oAuthFlows, Locale locale) {
		if (isEmpty(oAuthFlows))
			return Optional.empty();

		OAuthFlows oAuthFlowsObject = new OAuthFlows();
		if (oAuthFlows.extensions().length > 0) {
			Map<String, Object> extensions = AnnotationsUtils.getExtensions(propertyResolverUtils.isOpenapi31(), oAuthFlows.extensions());
			if (propertyResolverUtils.isResolveExtensionsProperties()) {
				Map<String, Object> extensionsResolved = propertyResolverUtils.resolveExtensions(locale, extensions);
				extensionsResolved.forEach(oAuthFlowsObject::addExtension);
			}
			else {
				extensions.forEach(oAuthFlowsObject::addExtension);
			}
		}
		getOAuthFlow(oAuthFlows.authorizationCode(), locale).ifPresent(oAuthFlowsObject::setAuthorizationCode);
		getOAuthFlow(oAuthFlows.clientCredentials(), locale).ifPresent(oAuthFlowsObject::setClientCredentials);
		getOAuthFlow(oAuthFlows.implicit(), locale).ifPresent(oAuthFlowsObject::setImplicit);
		getOAuthFlow(oAuthFlows.password(), locale).ifPresent(oAuthFlowsObject::setPassword);
		return Optional.of(oAuthFlowsObject);
	}
Gets o auth flows.

@param oAuthFlows the o auth flows
@param locale     the locale
@return the o auth flows
springdoc-openapi-starter-common/src/main/java/org/springdoc/core/service/SecurityService.java