public T[] GetAll() { List <T> models = new List <T>(); string[] files = ModelConnectionHelpers.GetDirectoryFiles(dataDirectory); if (files == null) { return(models.ToArray()); } foreach (string file in files) { models.Add((T)FSConnection.Read(file)); } return(models.ToArray()); }
public T Get(int id) { string fullPath = GetFullPath(id); return((T)FSConnection.Read(fullPath)); }