コード例 #1
0
        /// <summary>
        /// Parses an Entry Logger document file.
        /// </summary>
        /// <param name="filePath">Path to the document to be parsed.</param>
        /// <returns>Object representation of the document.</returns>
        public ELDocument ParseFile(string filePath)
        {
            Document = new ELDocument(filePath);
            ParseLines(File.ReadLines(filePath));

            return(Document);
        }
コード例 #2
0
ファイル: MainForm.cs プロジェクト: nathanpc/entry-logger
        private void mniFileOpen_Click(object sender, EventArgs e)
        {
            if (dlgOpen.ShowDialog() == DialogResult.OK)
            {
                DocumentParser parser = new DocumentParser(dlgOpen.FileName);
                elDocument = parser.Document;

                UpdateStatistics();
            }
        }
コード例 #3
0
 /// <summary>
 /// Contructs a data entry form with a model from a document.
 /// </summary>
 /// <param name="elDocument">Entry Logger document object.</param>
 public DataEntryForm(ELDocument elDocument) : this()
 {
     this.elDocument = elDocument;
     PopulateForm();
 }
コード例 #4
0
 /// <summary>
 /// Constructs an empty Entry Logger document parser.
 /// </summary>
 public DocumentParser()
 {
     Document = new ELDocument();
 }
コード例 #5
0
ファイル: MainForm.cs プロジェクト: nathanpc/entry-logger
 private void mniFileNew_Click(object sender, EventArgs e)
 {
     elDocument = new ELDocument();
     UpdateStatistics();
 }
コード例 #6
0
ファイル: MainForm.cs プロジェクト: nathanpc/entry-logger
 /// <summary>
 /// Constructs a main form already with a document associated with it.
 /// </summary>
 /// <param name="elDocument">Entry Logger document.</param>
 public MainForm(ELDocument elDocument) : this()
 {
     this.elDocument = elDocument;
 }
コード例 #7
0
ファイル: ModelForm.cs プロジェクト: nathanpc/entry-logger
 /// <summary>
 /// Contructs an entry model form with an Entry Logger document attached to it.
 /// </summary>
 /// <param name="elDocument">Entry Logger document associated with the form.</param>
 public ModelForm(ELDocument elDocument) : this()
 {
     this.elDocument = elDocument;
     PopulateList();
 }
コード例 #8
0
 /// <summary>
 /// Initializes a spreadsheet form with a document attached to it.
 /// </summary>
 /// <param name="elDocument">Entry Logger document to populate the spreadsheet with.</param>
 public SpreadsheetForm(ELDocument elDocument) : this()
 {
     this.elDocument = elDocument;
     PopulateSpreadsheet();
 }