test_class.file: core/src/test/java/org/carrot2/attrs/AttrBooleanTest.java
test_class.identifier: AttrBooleanTest
test_class.superclass: extends TestBase
test_case.body: @Test
    public void testToFromMap() {
      class Clazz extends AttrComposite {
        public AttrBoolean defValue =
            attributes.register("defValue", AttrBoolean.builder().defaultValue(true));
        public AttrBoolean nullValue =
            attributes.register("nullValue", AttrBoolean.builder().defaultValue(null));
        public AttrBoolean otherValue =
            attributes.register("otherValue", AttrBoolean.builder().defaultValue(null));
      }
  
      AliasMapper mapper = new AliasMapper();
      mapper.alias("clazz", Clazz.class, () -> new Clazz());
  
      Clazz ob = new Clazz();
      ob.otherValue.set(false);
  
      Assertions.assertThat(Attrs.toMap(ob, mapper::toName))
          .containsEntry("defValue", true)
          .containsEntry("nullValue", null)
          .containsEntry("otherValue", false);
  
      Clazz clazz = Attrs.fromMap(Clazz.class, Attrs.toMap(ob, mapper::toName), mapper::fromName);
      Assertions.assertThat(clazz.defValue.get()).isEqualTo(true);
      Assertions.assertThat(clazz.nullValue.get()).isNull();
      Assertions.assertThat(clazz.otherValue.get()).isEqualTo(false);
    }
test_case.class_method_signature: AttrBooleanTest.testToFromMap()
test_case.full_signature: @Test public void testToFromMap()
test_case.identifier: testToFromMap
test_case.invocations: register defaultValue builder register defaultValue builder register defaultValue builder alias set containsEntry containsEntry containsEntry assertThat toMap fromMap toMap isEqualTo assertThat get isNull assertThat get isEqualTo assertThat get
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testToFromMap()
focal_class.file: core/src/main/java/org/carrot2/attrs/AttrBoolean.java
focal_class.identifier: AttrBoolean
focal_class.class_method_signature: AttrBoolean.AttrBoolean(
        Boolean value, List<? extends Constraint<? super Boolean>> constraints, String label)
focal_class.full_signature: private  AttrBoolean(
        Boolean value, List<? extends Constraint<? super Boolean>> constraints, String label)
focal_class.identifier: AttrBoolean
focal_class.modifiers: private
focal_class.parameters: (
        Boolean value, List<? extends Constraint<? super Boolean>> constraints, String label)
focal_class.signature:  AttrBoolean(
        Boolean value, List<? extends Constraint<? super Boolean>> constraints, String label)
focal_class.class_method_signature: AttrBoolean.builder()
focal_class.full_signature: public static Builder builder()
focal_class.identifier: builder
focal_class.modifiers: public static
focal_class.parameters: ()
focal_class.return: Builder
focal_class.signature: Builder builder()
focal_class.superclass: extends Attr<Boolean>
focal_method.body: public static Builder builder() {
      return new Builder();
    }
focal_method.class_method_signature: AttrBoolean.builder()
focal_method.full_signature: public static Builder builder()
focal_method.identifier: builder
focal_method.modifiers: public static
focal_method.parameters: ()
focal_method.return: Builder
focal_method.signature: Builder builder()