IoT::Devices

class ICounter

File Information

Library: IoT/Devices
Package: Generated
Header: IoT/Devices/ICounter.h

Description

A counter counts events.

Inheritance

Direct Base Classes: IDevice

All Base Classes: IDevice, Poco::OSP::Service, Poco::RefCountedObject

Known Derived Classes: CounterRemoteObject, IRotaryEncoder, RotaryEncoderRemoteObject

Member Summary

Member Functions: count, isA, remoting__enableEvents, remoting__typeId, reset, type

Inherited Functions: duplicate, getFeature, getPropertyBool, getPropertyDouble, getPropertyInt, getPropertyInt16, getPropertyInt64, getPropertyString, getPropertyTimestamp, hasFeature, hasProperty, isA, referenceCount, release, remoting__enableEvents, remoting__typeId, setFeature, setPropertyBool, setPropertyDouble, setPropertyInt, setPropertyInt16, setPropertyInt64, setPropertyString, setPropertyTimestamp, type

Types Aliases

Ptr

using Ptr = Poco::AutoPtr < ICounter >;

Constructors

ICounter

ICounter();

Creates a ICounter.

Destructor

~ICounter virtual

virtual ~ICounter();

Destroys the ICounter.

Member Functions

count virtual

virtual Poco::Int32 count() const = 0;

Returns the current value of the counter.

isA virtual

bool isA(
    const std::type_info & otherType
) const;

Returns true if the class is a subclass of the class given by otherType.

remoting__enableEvents virtual

virtual std::string remoting__enableEvents(
    Poco::RemotingNG::Listener::Ptr pListener,
    bool enable = bool (true)
) = 0;

Enable or disable delivery of remote events.

The given Listener instance must implement the Poco::RemotingNG::EventListener interface, otherwise this method will fail with a RemotingException.

This method is only used with Proxy objects; calling this method on a RemoteObject will do nothing.

remoting__typeId static

static const Poco::RemotingNG::Identifiable::TypeId & remoting__typeId();

Returns the TypeId of the class.

reset virtual

virtual Poco::Int32 reset() = 0;

Returns the current value of the counter and sets the counter to 0.

type virtual

const std::type_info & type() const;

Returns the type information for the object's class.

Variables

countChanged

Poco::BasicEvent < const Poco::Int32 > countChanged;

Securely control IoT edge devices from anywhere   Connect a Device