The family includes bull-flag, bear-flag, pennant, rectangle-pattern, ascending-triangle and the candle sequences rising-three-methods and falling-three-methods. All describe a pause: price stops trending, ranges for a while, and then continues.
The mechanical logic is simply that trends persist more often than chance in many markets, so a pause inside a trend has a modestly better than even chance of resolving with the trend. That is a small edge, not a certainty.
Every continuation pattern needs a failure rule, because the same shape that continues a trend can also be the first stage of a top. The standard rule is that the pause must stay within the impulse that preceded it; once it retraces the whole move, it is not a continuation pattern any more.
Related: reversal-pattern, bull-flag, pennant, failed-pattern, consolidation