public static DateTimeFormatter formatWithDefault ( String lang , String country ) { return ( StringUtils . isNotBlank ( lang ) ) ? DateTimeFormat . longDateTime ( ) . withLocale ( DateTimeUtils . getLocaleByCountry ( lang , country ) ) : DateTimeFormat . longDateTime ( ) . withLocale ( Locale . getDefault ( ) ) ; }
Generates a DateTimeFormatter using full date pattern with the default locale or a new one according to what language and country are provided as params .