+/*
+ * Copyright (C) 1996-2017 The Squid Software Foundation and contributors
+ *
+ * Squid software is distributed under GPLv2+ license and includes
+ * contributions from numerous individuals and organizations.
+ * Please see the COPYING and CONTRIBUTORS files for details.
+ */
+
#ifndef SQUID_ADAPTATION__SERVICE_GROUPS_H
#define SQUID_ADAPTATION__SERVICE_GROUPS_H
-#include "SquidString.h"
-#include "Array.h"
#include "adaptation/Elements.h"
#include "adaptation/forward.h"
#include "base/RefCount.h"
+#include "SquidString.h"
+
+#include <vector>
namespace Adaptation
{
public:
typedef RefCount<ServiceGroup> Pointer;
- typedef Vector<String> Store;
+ typedef std::vector<String> Store;
typedef String Id;
- typedef unsigned int Pos; // Vector<>::poistion_type
+ typedef unsigned int Pos; // vector<>::position_type
friend class ServicePlan;
public:
protected:
virtual bool replace(Pos &pos) const { return has(++pos); }
- virtual bool advance(Pos &pos) const { return false; }
+ virtual bool advance(Pos &) const { return false; }
};
// corner case: a group consisting of one service
SingleService(const String &aServiceKey);
protected:
- virtual bool replace(Pos &pos) const { return false; }
- virtual bool advance(Pos &pos) const { return false; }
+ virtual bool replace(Pos &) const { return false; }
+ virtual bool advance(Pos &) const { return false; }
};
/// a group of services that must be used one after another
ServiceChain();
protected:
- virtual bool replace(Pos &pos) const { return false; }
+ virtual bool replace(Pos &) const { return false; }
virtual bool advance(Pos &pos) const { return has(++pos); }
};
class ServicePlan
{
public:
- typedef unsigned int Pos; // Vector<>::poistion_type
+ typedef unsigned int Pos; // vector<>::position_type
public:
ServicePlan();
return p.print(os);
}
-typedef Vector<ServiceGroupPointer> Groups;
+typedef std::vector<ServiceGroupPointer> Groups;
Groups &AllGroups();
ServiceGroupPointer FindGroup(const ServiceGroup::Id &id);