Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove RegistryHook #18134

Merged
merged 1 commit into from
Jan 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,12 @@
import org.openhab.core.items.Item;
import org.openhab.core.items.ItemNotFoundException;
import org.openhab.core.items.ItemRegistry;
import org.openhab.core.items.RegistryHook;

/**
* @author David Graeff - Initial contribution
*/
@NonNullByDefault
public class DummyItemRegistry implements ItemRegistry {

Check failure on line 33 in bundles/org.openhab.io.hueemulation/src/test/java/org/openhab/io/hueemulation/internal/rest/mocks/DummyItemRegistry.java

View workflow job for this annotation

GitHub Actions / Build (Java 21, ubuntu-24.04)

The type org.openhab.io.hueemulation.internal.rest.mocks.DummyItemRegistry must implement the inherited abstract method org.openhab.core.items.ItemRegistry.removeRegistryHook(org.openhab.core.items.RegistryHook<org.openhab.core.items.Item>)

Check failure on line 33 in bundles/org.openhab.io.hueemulation/src/test/java/org/openhab/io/hueemulation/internal/rest/mocks/DummyItemRegistry.java

View workflow job for this annotation

GitHub Actions / Build (Java 21, ubuntu-24.04)

The type org.openhab.io.hueemulation.internal.rest.mocks.DummyItemRegistry must implement the inherited abstract method org.openhab.core.items.ItemRegistry.addRegistryHook(org.openhab.core.items.RegistryHook<org.openhab.core.items.Item>)
Map<String, Item> items = new TreeMap<>();
List<RegistryChangeListener<Item>> listeners = new ArrayList<>();

Expand Down Expand Up @@ -150,12 +149,4 @@
}
return put;
}

@Override
public void addRegistryHook(RegistryHook<Item> hook) {
}

@Override
public void removeRegistryHook(RegistryHook<Item> hook) {
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
import org.openhab.core.items.ItemNotFoundException;
import org.openhab.core.items.ItemNotUniqueException;
import org.openhab.core.items.ItemRegistry;
import org.openhab.core.items.RegistryHook;
import org.openhab.core.library.items.CallItem;
import org.openhab.core.library.items.ColorItem;
import org.openhab.core.library.items.ContactItem;
Expand Down Expand Up @@ -298,16 +297,6 @@ public <T extends Item> Collection<T> getItemsByTag(Class<T> typeFilter, String.
public @Nullable Item remove(String itemName, boolean recursive) {
throw new UnsupportedOperationException();
}

@Override
public void addRegistryHook(RegistryHook<Item> hook) {
throw new UnsupportedOperationException();
}

@Override
public void removeRegistryHook(RegistryHook<Item> hook) {
throw new UnsupportedOperationException();
}
}, UNIT_PROVIDER, localEndpointOverride);

service.activate(null, config);
Expand Down
Loading