Package com.github.tadukoo.parsing
Class TadFormatRegexConverter
java.lang.Object
com.github.tadukoo.parsing.TadFormatRegexConverter
- All Implemented Interfaces:
CommonPatterns
Class used to convert between TadFormatting and Java regexes.
- Since:
- Alpha v.0.1
- Version:
- Alpha v.0.3
- Author:
- Logan Ferree (Tadukoo)
-
Field Summary
Fields inherited from interface com.github.tadukoo.parsing.CommonPatterns
booleanFormat, nullableBooleanFormat, nullFormat, numberFormat, quotedStringFormat
-
Constructor Summary
ModifierConstructorDescriptionprivate
Not allowed to instantiate TadFormatRegexConverter -
Method Summary
Modifier and TypeMethodDescriptionstatic String
convertRegexToTadFormat
(com.github.tadukoo.util.logger.EasyLogger logger, String regex) Convert the given Java regex into TadFormatting.static String
convertTadFormatToRegex
(com.github.tadukoo.util.logger.EasyLogger logger, String TadFormat) Convert the given TadFormatting into a Java regex.
-
Constructor Details
-
TadFormatRegexConverter
private TadFormatRegexConverter()Not allowed to instantiate TadFormatRegexConverter
-
-
Method Details
-
convertTadFormatToRegex
public static String convertTadFormatToRegex(com.github.tadukoo.util.logger.EasyLogger logger, String TadFormat) Convert the given TadFormatting into a Java regex.- Parameters:
logger
- TheEasyLogger
to log any messages toTadFormat
- The TadFormatting string to convert to a regex- Returns:
- The regex resulting from the TadFormatting conversion
-
convertRegexToTadFormat
public static String convertRegexToTadFormat(com.github.tadukoo.util.logger.EasyLogger logger, String regex) Convert the given Java regex into TadFormatting.- Parameters:
logger
- TheEasyLogger
to log any messages toregex
- The Java regex to convert to TadFormatting- Returns:
- The TadFormatting resulting from the regex conversion
-