package net.openhft.chronicle.wire;

import net.openhft.chronicle.bytes.Bytes;
import org.jetbrains.annotations.NotNull;
import org.junit.Test;

@SuppressWarnings("rawtypes")
public class FloatDtoTest extends WireTestCommon {

    @Test
    public void test() {
        @NotNull final Value value = new Value(99, 2000f);
        final Bytes bytes = Wires.acquireBytes();
        final Wire w = WireType.BINARY.apply(bytes);
        w.write().marshallable(value);
        @NotNull Value object1 = new Value(0, 0.0f);
        w.read().marshallable(object1);
    }

     static class Key extends SelfDescribingMarshallable implements
             KeyedMarshallable {
         @SuppressWarnings("unused")
         int uiid;

         Key(int uiid) {
             this.uiid = uiid;
         }
     }

    static class Value extends Key implements Marshallable {

        @SuppressWarnings("unused")
        final float myFloat;

        Value(int uiid,
              float myFloat) {
            super(uiid);
            this.myFloat = myFloat;
        }
    }

}

@@ -560,17 +560,16 @@
  %7D%0A%0A    
- 
 static c
@@ -622,29 +622,16 @@
 plements
-%0A            
  KeyedMa
@@ -643,17 +643,16 @@
 lable %7B%0A
- 
         
@@ -687,17 +687,16 @@
         
- 
 int uiid
@@ -698,17 +698,16 @@
  uiid;%0A%0A
- 
         
@@ -718,25 +718,24 @@
 int uiid) %7B%0A
- 
             
@@ -760,20 +760,18 @@
         
- 
 %7D%0A
- 
     %7D%0A%0A 

Simplify KeyedMarshallable