Beispiel #1
0
        public ClassAndDataPathPair GetClassAndDataPathPairFromInput()
        {
            var pair = new ClassAndDataPathPair();

            Console.Write("Path to .cs file: ");
            var input = Console.ReadLine();

            input = @"SampleData\ManagerWarning.cs";
            if (input == "close")
            {
                return(new ClassAndDataPathPair());
            }
            pair.ClassPath = input;

            Console.Write("Path to Json file: ");
            input = Console.ReadLine();
            input = @"SampleData\WarningsList.json";
            if (input == "close")
            {
                return(new ClassAndDataPathPair());
            }
            pair.CollectionPath = input;

            return(pair);
        }
 public void HandleSerialization(ClassAndDataPathPair data)
 {
     _modelLoader.GetClass(data.ClassPath);
     //var data = _jsonStorage.GetAllData < typeof(type) > (dataPath);
 }
Beispiel #3
0
 public static bool IsFilled(this ClassAndDataPathPair pair)
 => !string.IsNullOrEmpty(pair.ClassPath) && !string.IsNullOrEmpty(pair.CollectionPath);