Member predicate StringlikeLiteral::getComponent
Gets the nth component of this string or string-like literal. The result
will be one of StringTextComponent, StringInterpolationComponent, and
StringEscapeSequenceComponent.
In the following example, the result for n = 0 is the
StringTextComponent for foo_, and the result for n = 1 is the
StringInterpolationComponent for Time.now.
"foo_#{ Time.now }"