mirror of
https://github.com/danieldemus/openhab-core.git
synced 2025-01-26 20:21:33 +01:00
Move factory interface to public package (#3742)
Signed-off-by: Jan N. Klug <github@klug.nrw>
This commit is contained in:
parent
17e9cf3850
commit
409198cd8c
@ -12,9 +12,12 @@
|
|||||||
*/
|
*/
|
||||||
package org.openhab.core.thing.binding.generic;
|
package org.openhab.core.thing.binding.generic;
|
||||||
|
|
||||||
|
import java.util.function.Consumer;
|
||||||
|
|
||||||
import org.eclipse.jdt.annotation.NonNullByDefault;
|
import org.eclipse.jdt.annotation.NonNullByDefault;
|
||||||
import org.eclipse.jdt.annotation.Nullable;
|
import org.eclipse.jdt.annotation.Nullable;
|
||||||
import org.openhab.core.types.Command;
|
import org.openhab.core.types.Command;
|
||||||
|
import org.openhab.core.types.State;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The {@link ChannelHandler} defines the interface for converting received {@link ChannelHandlerContent}
|
* The {@link ChannelHandler} defines the interface for converting received {@link ChannelHandlerContent}
|
||||||
@ -40,4 +43,11 @@ public interface ChannelHandler {
|
|||||||
* @param command
|
* @param command
|
||||||
*/
|
*/
|
||||||
void send(Command command);
|
void send(Command command);
|
||||||
|
|
||||||
|
@FunctionalInterface
|
||||||
|
public interface Factory {
|
||||||
|
ChannelHandler create(Consumer<State> updateState, Consumer<Command> postCommand,
|
||||||
|
@Nullable Consumer<String> sendHttpValue, ChannelTransformation stateTransformations,
|
||||||
|
ChannelTransformation commandTransformations, ChannelValueConverterConfig channelConfig);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -105,11 +105,4 @@ public abstract class AbstractTransformingChannelHandler implements ChannelHandl
|
|||||||
* @return the string representation of the command
|
* @return the string representation of the command
|
||||||
*/
|
*/
|
||||||
protected abstract String toString(Command command);
|
protected abstract String toString(Command command);
|
||||||
|
|
||||||
@FunctionalInterface
|
|
||||||
public interface Factory {
|
|
||||||
ChannelHandler create(Consumer<State> updateState, Consumer<Command> postCommand,
|
|
||||||
@Nullable Consumer<String> sendHttpValue, ChannelTransformation stateTransformations,
|
|
||||||
ChannelTransformation commandTransformations, ChannelValueConverterConfig channelConfig);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user