Author SHA1 Message Date
IBims2CooleTim 19d313f6e6 Merge pull request #15 from MarciiTheDev/bugfix/SpellingError
Update Sammlung.lua
2023-10-01 02:32:13 +02:00
Marcel Lorbeer dc34b97bc5 Update Sammlung.lua
Fixed Spelling Error
2023-10-01 02:24:40 +02:00
Marcel Lorbeer 31229509fe Merge pull request #14 from IBims2CooleTim/main
Fixed a few small spelling errors

- The future of MarcSync is decleared.
2023-10-01 02:07:43 +02:00
IBims2CooleTim db262bb9ff Rename Entry.lua to Eintrag.lua 2023-10-01 00:42:21 +02:00
IBims2CooleTim d3771ce10b Rename Collection.lua to Sammlung.lua 2023-10-01 00:42:03 +02:00
IBims2CooleTim 08e00eb7a6 Rename Authorization.lua to Autorisierung.lua 2023-10-01 00:41:52 +02:00
IBims2CooleTim a2af160002 Update and rename Entry.lua to Eintrag.lua 2023-10-01 00:41:34 +02:00
IBims2CooleTim 7fe4849879 Rename Collection.lua to Sammlung.lua 2023-10-01 00:40:55 +02:00
IBims2CooleTim 633963490f Update Collection.lua 2023-10-01 00:39:44 +02:00
IBims2CooleTim 514ac3db61 Rename EntryData.lua to EintragsDaten.lua 2023-10-01 00:38:30 +02:00
IBims2CooleTim fe85632781 Update MarcSyncv1.0.lua 2023-10-01 00:36:43 +02:00
IBims2CooleTim 2ad6fa4036 Update and rename Utils.lua to Dienstprogramme.lua 2023-10-01 00:36:29 +02:00
IBims2CooleTim f0ef554936 Update Entry.lua 2023-09-30 23:28:06 +02:00
IBims2CooleTim a7142926be Update Collection.lua 2023-09-30 23:27:51 +02:00
IBims2CooleTim c3afb8694c Update Authorization.lua 2023-09-30 23:27:40 +02:00
IBims2CooleTim ee95d5e5e6 Update Entry.lua 2023-09-30 23:27:22 +02:00
IBims2CooleTim 227146a518 Update Collection.lua 2023-09-30 23:27:10 +02:00
IBims2CooleTim 571147e39e Update EntryData.lua 2023-09-30 23:26:54 +02:00
IBims2CooleTim d1bfaf3ccf Update Utils.lua 2023-09-30 23:26:40 +02:00
IBims2CooleTim 57020c6b24 Update MarcSyncv1.0.lua 2023-09-30 23:26:23 +02:00
MarcTheDev 227605746e Merge pull request #13 from MarciiTheDev/MarciiTheDev-patch-1
Update README.md
2023-07-27 07:46:02 +02:00
MarcTheDev 7074c09629 Update README.md 2023-07-27 07:45:53 +02:00
MarcTheDev 2e66e0a61f Merge pull request #12 from MarciiTheDev/MarciiTheDev-patch-1
Create LICENSE
2023-07-27 07:44:32 +02:00
MarcTheDev 99d7fe49bf Create LICENSE 2023-07-27 07:43:12 +02:00
MarcTheDev 1105658521 Merge pull request #11 from MarciiTheDev/dev
Dev
2023-07-26 18:33:30 +02:00
MarcTheDev dee87baca5 Merge pull request #9 from MarciiTheDev/dev
changed wording
2023-07-26 17:48:27 +02:00
MarcTheDev 8f2f927c64 Merge pull request #8 from MarciiTheDev/dev
changed card
2023-07-26 17:39:44 +02:00
MarcTheDev 756f3f4769 Merge pull request #7 from MarciiTheDev/dev
fixed production build
2023-07-26 15:44:06 +02:00
MarcTheDev e9e6286017 Merge pull request #6 from MarciiTheDev/dev
Dev
2023-07-26 15:27:52 +02:00
MarcTheDev e6a2a7028a Merge pull request #4 from MarciiTheDev/dev
initial Docs Commit
2023-07-25 17:21:04 +02:00
MarcTheDev b112c652d7 Merge pull request #3 from MarciiTheDev/dev
docs Setup
2023-07-25 17:06:06 +02:00
MarcTheDev 43f82a250a Merge pull request #2 from MarciiTheDev/dev
Dev
2023-07-25 17:02:42 +02:00
16 changed files with 212 additions and 191 deletions

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2023 Marcel Lorbeer
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
BIN
View File
Binary file not shown.
@@ -1,17 +1,17 @@
local AuthorizationError = require(script.Parent.Errors.Authorization)
local CollectionError = require(script.Parent.Errors.Collection)
local EntryError = require(script.Parent.Errors.Entry)
local AuthorizationError = require(script.Parent.Errors.Autorisierung)
local CollectionError = require(script.Parent.Errors.Sammlung)
local EntryError = require(script.Parent.Errors.Eintrag)
local HttpService = game:GetService("HttpService")
function errorHandler(type: string, resultBody: any, resultObject: {})
function fehlerMisshandlung(type: string, resultBody: any, resultObject: {})
local Error;
if typeof(resultBody) == typeof({}) and resultBody["message"] then
Error = resultBody["message"]
elseif typeof(resultBody) == typeof("") then
Error = resultBody
else
Error = "An Unexpected Error occoured."
Error = "Es ist ein unerwarteter Fehler aufgetreten."
end
if type == "collection" then
@@ -37,7 +37,7 @@ end
local utils = {}
function utils.makeHTTPRequest(type: string, method: string, url: string, body: {}, authorization: string):{["success"]: boolean, ["message"]: string}
function utils.macheHypertexttransferprotokollAnfrage(type: string, method: string, url: string, body: {}, authorization: string):{["success"]: boolean, ["message"]: string}
local resultObj;
local resultBody;
local success = pcall(function()
@@ -51,10 +51,10 @@ function utils.makeHTTPRequest(type: string, method: string, url: string, body:
end
end)
if success and resultBody and resultBody["success"] then
if resultBody["warning"] then warn('[MarcSync HTTPRequest Handler] MarcSync HTTP Request returned warning for URL "'..url..'" with body: "'..HttpService:JSONEncode(body)..'": '..resultBody["warning"]) end
if resultBody["warning"] then warn('[MarkSynchronisation Hypertexttransferprotokoll Misshandler] Die MarcSync-HTTP-Anfrage hat eine Warnung zurückgegeben für die URL "'..url..'" mit Koerper: "'..HttpService:JSONEncode(body)..'": '..resultBody["warning"]) end
return resultBody
end
return errorHandler(type, resultBody, resultObj)
return fehlerMisshandlung(type, resultBody, resultObj)
end
return utils
-5
View File
@@ -1,5 +0,0 @@
return {
InvalidAccessToken = function(message: string):string
return ("[MarcSync Exception] InvalidAccessToken: %s"):format(message)
end
}
+5
View File
@@ -0,0 +1,5 @@
return {
InvalidAccessToken = function(message: string):string
return ("[MarkSynchronisationsausnahme] InvaliederZugriffsToken: %s"):format(message)
end
}
-8
View File
@@ -1,8 +0,0 @@
return {
CollectionNotFound = function(message: string):string
return ("[MarcSync Exception] CollectionNotFound: %s"):format(message)
end,
CollectionAlreadyExists = function(message: string):string
return ("[MarcSync Exception] CollectionAlreadyExists: %s"):format(message)
end
}
+8
View File
@@ -0,0 +1,8 @@
return {
InvalidEntryData = function(message: string):string
return ("[MarkSynchronisationsausnahme] InvaliedeEintragsDaten: %s"):format(message)
end,
EntryNotFound = function(message: string):string
return ("[MarkSynchronisationsausnahme] EintragNichtGefunden: %s"):format(message)
end
}
-8
View File
@@ -1,8 +0,0 @@
return {
InvalidEntryData = function(message: string):string
return ("[MarcSync Exception] InvalidEntryData: %s"):format(message)
end,
EntryNotFound = function(message: string):string
return ("[MarcSync Exception] EntryNotFound: %s"):format(message)
end
}
+8
View File
@@ -0,0 +1,8 @@
return {
CollectionNotFound = function(message: string):string
return ("[MarkSynchronisationsausnahme] SammlungNichtGefunden: %s"):format(message)
end,
CollectionAlreadyExists = function(message: string):string
return ("[MarkSynchronisationsausnahme] SammlungExistiertBereits: %s"):format(message)
end
}
+21 -21
View File
@@ -5,53 +5,53 @@ local tokens = {
-- DO NOT EDIT THE FOLLOWING LINES BELOW, UNLESS YOU KNOW WHAT YOU ARE DOING!
local Utils = require(script.Parent.Utils)
local Utils = require(script.Parent.Dienstprogramme)
local MarcSyncClient = {}
MarcSyncClient.getVersion = function(self:typeof(MarcSyncClient), clientId: number?):string
MarcSyncClient.bekommeVersion = function(self:typeof(MarcSyncClient), clientId: number?):string
self:_checkInstallation()
local url = ""
if clientId then url = "/"..clientId end
local result = Utils.makeHTTPRequest("GET", "https://api.marcsync.dev/v0/utils/version"..url);
local result = Utils.macheHypertexttransferprotokollAnfrage("GET", "https://api.marcsync.dev/v0/utils/version"..url);
return result["version"]
end
MarcSyncClient.createCollection = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Collection).new())
if not self._accessToken then error("[MarcSync] Please set a Token before using MarcSync.") end
if not collectionName then error("No CollectionName Provided") end
local result = Utils.makeHTTPRequest("collection", "POST", "https://api.marcsync.dev/v0/collection/"..collectionName, {}, self._accessToken);
MarcSyncClient.erzeugeSammlung = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Sammlung).new())
if not self._accessToken then error("[MarkSynchronisation] Bitte legen Sie ein Token fest, bevor Sie MarcSync verwenden.") end
if not collectionName then error("Kein CollectionName angegeben") end
local result = Utils.macheHypertexttransferprotokollAnfrage("collection", "POST", "https://api.marcsync.dev/v0/collection/"..collectionName, {}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
result = require(script.Parent.Objects.Collection).new(collectionName, self._accessToken)
result = require(script.Parent.Objects.Sammlung).neu(collectionName, self._accessToken)
return result
end
MarcSyncClient.fetchCollection = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Collection).new())
MarcSyncClient.bringeSammlung = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Sammlung).new())
self:_checkInstallation()
if not collectionName then error("No CollectionName Provided") end
local result = Utils.makeHTTPRequest("collection", "GET", "https://api.marcsync.dev/v0/collection/"..collectionName, {}, self._accessToken);
if not collectionName then error("Kein CollectionName angegeben") end
local result = Utils.macheHypertexttransferprotokollAnfrage("collection", "GET", "https://api.marcsync.dev/v0/collection/"..collectionName, {}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
result = require(script.Parent.Objects.Collection).new(collectionName, self._accessToken)
result = require(script.Parent.Objects.Sammlung).neu(collectionName, self._accessToken)
return result
end
MarcSyncClient.getCollection = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Collection).new())
if typeof(self) ~= "table" then error("Please use : instead of .") end
MarcSyncClient.bekommeSammlung = function(self:typeof(MarcSyncClient), collectionName: string):typeof(require(script.Parent.Objects.Sammlung).new())
if typeof(self) ~= "table" then error("Bitte verwenden Sie : anstelle von .") end
self:_checkInstallation()
if not collectionName then error("No CollectionName Provided") end
return require(script.Parent.Objects.Collection).new(collectionName, self._accessToken)
if not collectionName then error("Kein CollectionName angegeben") end
return require(script.Parent.Objects.Sammlung).neu(collectionName, self._accessToken)
end
return {
new = function(accessToken: string):typeof(MarcSyncClient)
if not accessToken then warn("Token not provided while creating a new MarcSync Object.") end
if not tokens[accessToken] then warn("Token provided for creating a new MarcSync Object not Found in Token Table, using it as token instead.") else accessToken = tokens[accessToken] end
neu = function(accessToken: string):typeof(MarcSyncClient)
if not accessToken then warn("Beim Erstellen eines neuen MarcSync-Objekts wurde kein Token bereitgestellt.") end
if not tokens[accessToken] then warn("Token zum Erstellen eines neuen MarcSync-Objekts, das nicht in der Token-Tabelle gefunden wird und stattdessen als Token verwendet wird.") else accessToken = tokens[accessToken] end
local self = {}
self._accessToken = accessToken
self._checkInstallation = function()
if not self then error("Please Setup MarcSync before using MarcSync.") end
if not self._accessToken then error("[MarcSync] Please set a Token before using MarcSync.") end
if not self then error("Bitte richten Sie MarcSync ein, bevor Sie MarcSync verwenden.") end
if not self._accessToken then error("[MarkSynchronisation] Bitte legen Sie ein Token fest, bevor Sie MarcSync verwenden.") end
--print(HttpService.HttpEnabled)
--if not HttpService.HttpEnabled then error("Please Enable HTTPService in order to use MarcSync.") end
end
-76
View File
@@ -1,76 +0,0 @@
local Utils = require(script.Parent.Parent.Utils)
local Entry = require(script.Parent.Entry)
local types = {
EntryData = require(script.Parent.Parent.Types.EntryData).getType()
}
local Collection = {}
Collection.createEntry = function(self:typeof(Collection), data:typeof(types.EntryData)):typeof(Entry.new())
if not self._collectionName then error("[MarcSync: Collection] Invalid Object created or trying to access an destroied object.") end
local result = Utils.makeHTTPRequest("entry", "POST", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["data"]=data}, self._accessToken);
if result["success"] and result["objectId"] then
data["_id"] = result["objectId"]
result = require(script.Parent.Entry).new(self._collectionName, data, self._accessToken)
else
error(result["errorMessage"])
end
return result
end
Collection.updateEntries = function(self:typeof(Collection), filters:typeof(types.EntryData), data:typeof(types.EntryData)):number
if not self._collectionName then error("[MarcSync: Collection] Invalid Object created or trying to access an destroied object.") end
local result = Utils.makeHTTPRequest("entry", "PUT", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["filters"]=filters,["data"]=data}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
return result["modifiedEntries"]
end
Collection.getEntries = function(self:typeof(Collection), filters:typeof(types.EntryData)):{[number]:typeof(Entry.new())}
if not self._collectionName then error("[MarcSync: Collection] Invalid Object created or trying to access an destroied object.") end
if not filters then filters = {} end
local result = Utils.makeHTTPRequest("entry", "DELETE", "https://api.marcsync.dev/v0/entries/"..self._collectionName.."?isQuery=true", {["filters"]=filters}, self._accessToken);
if result["success"] and result["entries"] then
local _result = {}
for index,entry in pairs(result["entries"]) do
_result[index] = require(script.Parent.Entry).new(self._collectionName, entry, self._accessToken)
end
result = _result
else
error(result["errorMessage"])
end
return result
end
Collection.deleteEntries = function(self:typeof(Collection), filters:typeof(types.EntryData)):number
if not self._collectionName then error("[MarcSync: Collection] Invalid Object created or trying to access an destroied object.") end
local result = Utils.makeHTTPRequest("DELETE", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["filters"]=filters}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
return result["deletedEntries"]
end
Collection.drop = function(self:typeof(Collection))
if not self._collectionName then error("[MarcSync: Collection] Invalid Object created or trying to access an destroied object.") end
local result = Utils.makeHTTPRequest("collection", "DELETE", "https://api.marcsync.dev/v0/collection/"..self._collectionName, {}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
self = nil
end
return {
new = function(collectionName: string, accessToken: string):typeof(Collection)
local self = {}
self._collectionName = collectionName
self._accessToken = accessToken
self = setmetatable(self, {
__index = Collection
})
return self
end
}
+56
View File
@@ -0,0 +1,56 @@
local Utils = require(script.Parent.Parent.Dienstprogramme)
local types = {
EntryData = require(script.Parent.Parent.Types.EntryData).bekommeRassenindentifikationsspezifizierunginstanztextaufzaehlbar()
}
local Entry = {}
Entry.bekommeWert = function(self:typeof(Entry), key:string):any
if not key then return nil end
return self._entryData[key]
end
Entry.bekommeWerte = function(self:typeof(Entry)):typeof(types.EntryData)
return self._entryData
end
Entry.aktualisiereWerte = function(self:typeof(Entry), data:typeof(types.EntryData)):number
local result = Utils.macheHypertexttransferprotokollAnfrage("eintrag", "PUT", "https://api.marcsync.dev/v0/entries/"..self._tableId, {["filters"]={["_id"]=self._objectId},["data"]=data}, self._accessToken);
if result["success"] and result["modifiedEntries"] and result["modifiedEntries"] > 0 then
for i,v in pairs(data) do
self._entryData[i] = v
end
elseif not result["success"] then
error(result["errorMessage"])
end
return result["modifiedEntries"]
end
Entry.loesche = function(self:typeof(Entry))
if typeof(self) ~= "table" then error("Bitte verwenden Sie : anstelle von .") end
local result = Utils.macheHypertexttransferprotokollAnfrage("eintrag", "DELETE", "https://api.marcsync.dev/v0/entries/"..self._tableId, {["filters"]={["_id"]=self._objectId}}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
self = nil
end
return {
neu = function(tableId:string, entryData:typeof(types.EntryData), accessToken:string):typeof(Entry)
if not tableId or not entryData or not entryData["_id"] or not accessToken then error("[MarkSynchronisation: Eintrag] Es wurde versucht, ein ungültiges Eintragsobjekt zu erstellen.") end
local self = {}
self._tableId = tableId
self._entryData = entryData
self._objectId = entryData["_id"]
self._accessToken = accessToken
self = setmetatable(self, {
__index = Entry
})
return self
end
}
-56
View File
@@ -1,56 +0,0 @@
local Utils = require(script.Parent.Parent.Utils)
local types = {
EntryData = require(script.Parent.Parent.Types.EntryData).getType()
}
local Entry = {}
Entry.getValue = function(self:typeof(Entry), key:string):any
if not key then return nil end
return self._entryData[key]
end
Entry.getValues = function(self:typeof(Entry)):typeof(types.EntryData)
return self._entryData
end
Entry.updateValues = function(self:typeof(Entry), data:typeof(types.EntryData)):number
local result = Utils.makeHTTPRequest("entry", "PUT", "https://api.marcsync.dev/v0/entries/"..self._tableId, {["filters"]={["_id"]=self._objectId},["data"]=data}, self._accessToken);
if result["success"] and result["modifiedEntries"] and result["modifiedEntries"] > 0 then
for i,v in pairs(data) do
self._entryData[i] = v
end
elseif not result["success"] then
error(result["errorMessage"])
end
return result["modifiedEntries"]
end
Entry.delete = function(self:typeof(Entry))
if typeof(self) ~= "table" then error("Please use : instead of .") end
local result = Utils.makeHTTPRequest("entry", "DELETE", "https://api.marcsync.dev/v0/entries/"..self._tableId, {["filters"]={["_id"]=self._objectId}}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
self = nil
end
return {
new = function(tableId:string, entryData:typeof(types.EntryData), accessToken:string):typeof(Entry)
if not tableId or not entryData or not entryData["_id"] or not accessToken then error("[MarcSync: Entry] Tried creating invalid Entry Object.") end
local self = {}
self._tableId = tableId
self._entryData = entryData
self._objectId = entryData["_id"]
self._accessToken = accessToken
self = setmetatable(self, {
__index = Entry
})
return self
end
}
+76
View File
@@ -0,0 +1,76 @@
local Utils = require(script.Parent.Parent.Dienstprogramme)
local Entry = require(script.Parent.Eintrag)
local types = {
EntryData = require(script.Parent.Parent.Types.EintragsDaten).bekommeRassenindentifikationsspezifizierunginstanztextaufzaehlbar()
}
local Collection = {}
Collection.erzeugeEintrag = function(self:typeof(Collection), data:typeof(types.EntryData)):typeof(Entry.new())
if not self._collectionName then error("[MarkSynchronisation: Sammlung] Ungültiges Objekt erstellt oder versucht, auf ein zerstörtes Objekt zuzugreifen.") end
local result = Utils.macheHypertexttransferprotokollAnfrage("entry", "POST", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["data"]=data}, self._accessToken);
if result["success"] and result["objectId"] then
data["_id"] = result["objectId"]
result = require(script.Parent.Entrag).neu(self._collectionName, data, self._accessToken)
else
error(result["errorMessage"])
end
return result
end
Collection.aktualisiereEintrag = function(self:typeof(Collection), filters:typeof(types.EntryData), data:typeof(types.EntryData)):number
if not self._collectionName then error("[MarkSynchronisation: Sammlung] Ungültiges Objekt erstellt oder versucht, auf ein zerstörtes Objekt zuzugreifen.") end
local result = Utils.macheHypertexttransferprotokollAnfrage("eintrag", "PUT", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["filters"]=filters,["data"]=data}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
return result["modifiedEntries"]
end
Collection.bekommeEintraege = function(self:typeof(Collection), filters:typeof(types.EntryData)):{[number]:typeof(Entry.new())}
if not self._collectionName then error("[MarkSynchronisation: Sammlung] Ungültiges Objekt erstellt oder versucht, auf ein zerstörtes Objekt zuzugreifen.") end
if not filters then filters = {} end
local result = Utils.macheHypertexttransferprotokollAnfrage("eintrag", "DELETE", "https://api.marcsync.dev/v0/entries/"..self._collectionName.."?isQuery=true", {["filters"]=filters}, self._accessToken);
if result["success"] and result["entries"] then
local _result = {}
for index,entry in pairs(result["entries"]) do
_result[index] = require(script.Parent.Entrag).neu(self._collectionName, entry, self._accessToken)
end
result = _result
else
error(result["errorMessage"])
end
return result
end
Collection.loescheEintrag = function(self:typeof(Collection), filters:typeof(types.EntryData)):number
if not self._collectionName then error("[MarkSynchronisation: Sammlung] Ungültiges Objekt erstellt oder versucht, auf ein zerstörtes Objekt zuzugreifen.") end
local result = Utils.macheHypertexttransferprotokollAnfrage("eintrag", "DELETE", "https://api.marcsync.dev/v0/entries/"..self._collectionName, {["filters"]=filters}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
return result["deletedEntries"]
end
Collection.fallenlassen = function(self:typeof(Collection))
if not self._collectionName then error("[MarkSynchronisation: Sammlung] Ungültiges Objekt erstellt oder versucht, auf ein zerstörtes Objekt zuzugreifen.") end
local result = Utils.macheHypertexttransferprotokollAnfrage("sammlung", "DELETE", "https://api.marcsync.dev/v0/collection/"..self._collectionName, {}, self._accessToken);
if not result["success"] then error(result["errorMessage"]) end
self = nil
end
return {
neu = function(collectionName: string, accessToken: string):typeof(Collection)
local self = {}
self._collectionName = collectionName
self._accessToken = accessToken
self = setmetatable(self, {
__index = Collection
})
return self
end
}
+9
View File
@@ -0,0 +1,9 @@
type EntryData = {
[string]: any
}
return {
bekommeRassenindentifikationsspezifizierunginstanztextaufzaehlbar = function(): EntryData
return {}
end,
}
-9
View File
@@ -1,9 +0,0 @@
type EntryData = {
[string]: any
}
return {
getType = function(): EntryData
return {}
end,
}