test_class.file: api/src/test/java/net/kyori/adventure/text/LinearComponentsTest.java
test_class.identifier: LinearComponentsTest
test_case.body: @Test
    void testSimpleText() {
      final Component c0 = Component.text("kittens", NamedTextColor.DARK_PURPLE);
      assertEquals(c0, LinearComponents.linear(NamedTextColor.DARK_PURPLE, Component.text().content("kittens")));
    }
test_case.class_method_signature: LinearComponentsTest.testSimpleText()
test_case.full_signature: @Test void testSimpleText()
test_case.identifier: testSimpleText
test_case.invocations: text assertEquals linear content text
test_case.modifiers: @Test
test_case.parameters: ()
test_case.return: void
test_case.signature: void testSimpleText()
focal_class.file: api/src/main/java/net/kyori/adventure/text/LinearComponents.java
focal_class.identifier: LinearComponents
focal_class.class_method_signature: LinearComponents.LinearComponents()
focal_class.full_signature: private  LinearComponents()
focal_class.identifier: LinearComponents
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.signature:  LinearComponents()
focal_class.class_method_signature: LinearComponents.linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_class.full_signature: public static @NonNull Component linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_class.identifier: linear
focal_class.modifiers: public static @NonNull
focal_class.parameters: (final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_class.return: Component
focal_class.signature: Component linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_class.class_method_signature: LinearComponents.nothingComponentLike()
focal_class.full_signature: private static IllegalStateException nothingComponentLike()
focal_class.identifier: nothingComponentLike
focal_class.modifiers: private static
focal_class.parameters: ()
focal_class.return: IllegalStateException
focal_class.signature: IllegalStateException nothingComponentLike()
focal_method.body: public static @NonNull Component linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables) {
      final int length = applicables.length;
      if(length == 0) return Component.empty();
      if(length == 1) {
        final ComponentBuilderApplicable ap0 = applicables[0];
        if(ap0 instanceof ComponentLike) {
          return ((ComponentLike) ap0).asComponent();
        }
        throw nothingComponentLike();
      }
      final TextComponentImpl.BuilderImpl builder = new TextComponentImpl.BuilderImpl();
      Style.Builder style = null;
      for(int i = 0; i < length; i++) {
        final ComponentBuilderApplicable applicable = applicables[i];
        if(applicable instanceof StyleBuilderApplicable) {
          if(style == null) {
            style = Style.style();
          }
          style.apply((StyleBuilderApplicable) applicable);
        } else if(style != null && applicable instanceof ComponentLike) {
          builder.applicableApply(((ComponentLike) applicable).asComponent().style(style));
        } else {
          builder.applicableApply(applicable);
        }
      }
      final int size = builder.children.size();
      if(size == 0) {
        throw nothingComponentLike();
      } else if(size == 1) {
        return builder.children.get(0);
      } else {
        return builder.build();
      }
    }
focal_method.class_method_signature: LinearComponents.linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_method.full_signature: public static @NonNull Component linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_method.identifier: linear
focal_method.invocations: empty asComponent nothingComponentLike style apply applicableApply style asComponent applicableApply size nothingComponentLike get build
focal_method.modifiers: public static @NonNull
focal_method.parameters: (final @NonNull ComponentBuilderApplicable@NonNull... applicables)
focal_method.return: Component
focal_method.signature: Component linear(final @NonNull ComponentBuilderApplicable@NonNull... applicables)