StaticDependencyObject implements IDependencyObject<T> { @Override public void set(@Nullable final Object context, @Nullable final T value) { this.hasChanged = this.value != value; this.value = value; } StaticDependencyObject(@Nullable final T value); @Nullable @Override T get(@Nullable final Object context); @Override void set(@Nullable final Object context, @Nullable final T value); @Override boolean hasChanged(@Nullable final Object context);  }
@Test public void set() { final IDependencyObject<String> depOne = new StaticDependencyObject<>("Static"); Assert.assertEquals("Static", depOne.get(new DummyInjectionTarget())); depOne.set(new DummyInjectionTarget(), "Changed"); Assert.assertEquals("Changed", depOne.get(new DummyInjectionTarget())); }