Thanks. I'm not sure there's a name for this style. It's just precomputing some variables to make a complex if expression readable.
There's a downside to it though: if a precomputed variable is not used (e.g. due to an early branch being taken), then it's wasted. For example: all variables except `isEmpty` are wasted if the string is empty, so you have to be careful if this was performance-critical code. Nevertheless, giving names to things communicates the intention better.