commit 2e36967f016662807efa0eaeece8e53944754ab8
parent dcecc5f29b1adfa38ec1309298edf8ad877932a7
Author: cfillion <cfillion@users.noreply.github.com>
Date: Sun, 4 Jun 2017 04:33:08 -0400
api: remove EnumRepositories
Diffstat:
3 files changed, 0 insertions(+), 23 deletions(-)
diff --git a/src/api.cpp b/src/api.cpp
@@ -184,27 +184,6 @@ type: see <a href="#ReaPack_GetEntryInfo">ReaPack_GetEntryInfo</a>.)",
return entry->files.size() > i + 1;
});
-DEFINE_API(bool, EnumRepositories, ((int, index))
- ((char*, nameOut))((int, nameOut_sz)),
-R"(Enumerate the repository list. Returns false once the end of the list is reached.)",
-{
- const size_t i = index;
- const RemoteList &list = reapack->config()->remotes;
-
- if(i >= list.size())
- return false;
-
- auto it = list.begin();
- advance(it, i);
-
- const Remote &remote = *it;
-
- if(nameOut)
- snprintf(nameOut, nameOut_sz, "%s", remote.name().c_str());
-
- return list.size() > i + 1;
-});
-
DEFINE_API(bool, FreeEntry, ((PackageEntry*, entry)),
R"(Free resources allocated for the given package entry.)",
{
diff --git a/src/api.hpp b/src/api.hpp
@@ -50,7 +50,6 @@ namespace API {
extern APIFunc AddSetRepository;
extern APIFunc CompareVersions;
extern APIFunc EnumOwnedFiles;
- extern APIFunc EnumRepositories;
extern APIFunc FreeEntry;
extern APIFunc GetEntryInfo;
extern APIFunc GetOwner;
diff --git a/src/main.cpp b/src/main.cpp
@@ -165,7 +165,6 @@ static void setupAPI()
reapack->setupAPI(&API::AddSetRepository);
reapack->setupAPI(&API::CompareVersions);
reapack->setupAPI(&API::EnumOwnedFiles);
- reapack->setupAPI(&API::EnumRepositories);
reapack->setupAPI(&API::FreeEntry);
reapack->setupAPI(&API::GetEntryInfo);
reapack->setupAPI(&API::GetOwner);