@Test
public void getResource() throws Exception {

    LWM2MObjectInstance instance = new LWM2MObjectInstance(
            new LWM2MResource(LWM2MID.$1, 42),
            new LWM2MResource(LWM2MID.from("dev"), 56));
    System.out.println(instance);
    assertEquals("42", instance.getResource(LWM2MID.$1).getStringValue() );
    assertEquals("56", instance.getResource(LWM2MID.from("dev")).getStringValue() );
    assertNull(instance.getResource(LWM2MID.$0));
}