com.ibm.streamsx.iot

Class IotStreams

  • java.lang.Object
    • com.ibm.streamsx.iot.IotStreams


  • public class IotStreams
    extends java.lang.Object
    IBM Watson IoT Platform streams. These streams using the micro-service model promoted by the com.ibm.streamsx.iot toolkit. In order to interact with IoT Platform the Streams application com.ibm.streamsx.iot.watson.apps::IotPlatform must be running.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method and Description
      static void commandPublish(com.ibm.streamsx.topology.TStream<DeviceCmd> commandStream) 
      static com.ibm.streamsx.topology.TStream<DeviceCmd> commandsSubscribe(com.ibm.streamsx.topology.TopologyElement te, java.lang.String... cmdId)
      Subscribe to commands as DeviceCmd instances.
      static com.ibm.streamsx.topology.TStream<DeviceCmd> commandsSubscribe(com.ibm.streamsx.topology.TopologyElement te, java.lang.String[] typeIds, java.lang.String... cmdId) 
      static com.ibm.streamsx.topology.TStream<DeviceEvent> eventsSubscribe(com.ibm.streamsx.topology.TopologyElement te, java.lang.String... eventId)
      Subscribe to events as DeviceEvent instances.
      static com.ibm.streamsx.topology.TStream<DeviceEvent> eventsSubscribe(com.ibm.streamsx.topology.TopologyElement te, java.lang.String[] typeIds, java.lang.String... eventId)
      Subscribe to events as DeviceEvent instances.
      static com.ibm.streamsx.topology.TStream<DeviceStatus> statusesSubscribe(com.ibm.streamsx.topology.TopologyElement te, java.lang.String... typeId) 
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • eventsSubscribe

        public static com.ibm.streamsx.topology.TStream<DeviceEventeventsSubscribe(com.ibm.streamsx.topology.TopologyElement te,
                                                                                     java.lang.String... eventId)
        Subscribe to events as DeviceEvent instances. Subscribes to all device events with event identifiers listed in eventId. If eventId is empty or passed as a null array then all device events are subscribed to. To receive device events the Streams application com.ibm.streamsx.iot.watson.apps::IotPlatform must be running in the same Streams instance.
        Parameters:
        te - Topology to create this source in.
        eventId - Event identifiers to subscribe to. If none are provided then all event identifiers are subscribed to.
        Returns:
        Stream containing device events.
      • eventsSubscribe

        public static com.ibm.streamsx.topology.TStream<DeviceEventeventsSubscribe(com.ibm.streamsx.topology.TopologyElement te,
                                                                                     java.lang.String[] typeIds,
                                                                                     java.lang.String... eventId)
        Subscribe to events as DeviceEvent instances. Subscribes to all device events with:
        • All device type identifiers listed in typeIds. If typeIds is empty or passed as a null array reference then no filtering against type identifier is applied.
        • AND
        • All device event identifiers listed in eventId. If eventId is empty or passed as a null array reference then no filtering against event identifier is applied.
        To receive device events the Streams application com.ibm.streamsx.iot.watson.apps::IotPlatform must be running in the same Streams instance.
        Parameters:
        te - Topology to create this source in.
        typeIds - Type identifers to subscribe to. If this is empty or null then all type identifiers are subscribed to.
        eventId - Event identifiers to subscribe to. If none are provided then all event identifiers are subscribed to.
        Returns:
        Stream containing device events.
      • commandsSubscribe

        public static com.ibm.streamsx.topology.TStream<DeviceCmdcommandsSubscribe(com.ibm.streamsx.topology.TopologyElement te,
                                                                                     java.lang.String... cmdId)
        Subscribe to commands as DeviceCmd instances. Subscribes to all device commands with commands identifiers listed in cmdId. If cmdId is empty or passed as a null array then all device commands are subscribed to. To receive device events the Streams application com.ibm.streamsx.iot.watson.apps::IotPlatform must be running in the same Streams instance.
        Parameters:
        te - Topology to create this source in.
        cmdId - Command identifiers to subscribe to.
        Returns:
        Stream containing device events.
      • commandsSubscribe

        public static com.ibm.streamsx.topology.TStream<DeviceCmdcommandsSubscribe(com.ibm.streamsx.topology.TopologyElement te,
                                                                                     java.lang.String[] typeIds,
                                                                                     java.lang.String... cmdId)
      • statusesSubscribe

        public static com.ibm.streamsx.topology.TStream<DeviceStatusstatusesSubscribe(com.ibm.streamsx.topology.TopologyElement te,
                                                                                        java.lang.String... typeId)
streamsx.iot @ IBMStreams GitHub