Exemple #1
0
        private String ReadFromFile()
        {
            TextFileReaderModule fileReader = new TextFileReaderModule();

            fileReader.Context = Context.AbsoluteFilePath;
            return(fileReader.Read());
        }
Exemple #2
0
        private static void PrintXMLFileToScreen()
        {
            ITextReader textReader = new TextFileReaderModule(XMLFile);
            String      text       = textReader.Read();

            output.Write(text);
            output.Write(Environment.NewLine);
            output.Write(Environment.NewLine);
        }
Exemple #3
0
        private static List <Item> ReadListFromDatabase()
        {
            ITextReader reader   = new TextFileReaderModule(SQLQueryFile);
            String      sqlQuery = reader.Read();
            SqlQuery    query    = new SqlQuery {
                Query = sqlQuery
            };

            SqlListReaderModule <Item> sqlReader = new SqlListReaderModule <Item> {
                Context = ConnectionString
            };
            List <Item> list = sqlReader.Read(query);

            return(list);
        }