local super = require "Artifact"

IndexArtifact = super:new()

function IndexArtifact:new()
    self = super.new(self)
    
    self._function = IndexArtifact.applicatorFunction()
    
    return self
end

function IndexArtifact:trySetValue(input, errorFunction)
    warn('IndexArtifact:trySetValue!')
end

IndexArtifact.applicatorFunction = function()
    return function(dataset)
        return (dataset and dataset:entrySequence():map(Dataset.getEntryIndex)) or Sequence:newWithArray({})
    end
end

return IndexArtifact