#ifndef SPRINKLER_H
#define SPRINKLER_H

#include <QObject>
#include <QList>
#include "SprinklerMasterCtrlInterface.h"
#include "SprinklerGui.h"
#include "SprinklerDevice.h"


class CSprinkler : public QObject
{
    Q_OBJECT

public:
    CSprinkler(CSprinklerGui *GUI);
    ~CSprinkler();

    int SetSprinklerState(int DeviceAddress, unsigned char State);
    int SetSprinklerFlow(int DeviceAddress, unsigned short Flow);

private:
    CSprinklerDevice *FindSprinkler(int DeviceAddress);

public:

    CSprinklerMasterCtrlInterface *mNetworkInterface;
    CSprinklerGui *mGui;
    QList<CSprinklerDevice*> mSprinklers;


};

#endif // SPRINKLER_H
