@@ -41,7 +41,7 @@ public FormMain()
41
41
VdwConfigurationSettings . VdwEventLog . Add ( Event . CreateNewEvent ( EventTypes . Information , $ "{ Text } .") ) ;
42
42
43
43
#region Root Paths
44
- // Make sure the root directories exist, based on (tool) parameters
44
+ // Make sure the root directories exist, based on (tool) parameters.
45
45
46
46
// Configuration Path
47
47
var localEvent = FileHandling . InitialisePath ( GlobalParameters . VdwConfigurationPath ) ;
@@ -51,23 +51,23 @@ public FormMain()
51
51
}
52
52
VdwConfigurationSettings . VdwEventLog . Add ( Event . CreateNewEvent ( EventTypes . Information , $ "Configuration path initialised for { GlobalParameters . VdwConfigurationPath } .") ) ;
53
53
54
- // Input Path
54
+ // Input Path.
55
55
localEvent = FileHandling . InitialisePath ( VdwConfigurationSettings . VdwInputPath ) ;
56
56
if ( localEvent . eventDescription != null )
57
57
{
58
58
VdwConfigurationSettings . VdwEventLog . Add ( localEvent ) ;
59
59
}
60
60
VdwConfigurationSettings . VdwEventLog . Add ( Event . CreateNewEvent ( EventTypes . Information , $ "Input path set for { VdwConfigurationSettings . VdwInputPath } .") ) ;
61
61
62
- // Output Path
62
+ // Output Path.
63
63
localEvent = FileHandling . InitialisePath ( VdwConfigurationSettings . VdwOutputPath ) ;
64
64
if ( localEvent . eventDescription != null )
65
65
{
66
66
VdwConfigurationSettings . VdwEventLog . Add ( localEvent ) ;
67
67
}
68
68
VdwConfigurationSettings . VdwEventLog . Add ( Event . CreateNewEvent ( EventTypes . Information , $ "Output path set for { VdwConfigurationSettings . VdwOutputPath } .") ) ;
69
69
70
- // Examples Path
70
+ // Examples Path.
71
71
localEvent = FileHandling . InitialisePath ( VdwConfigurationSettings . VdwExamplesPath ) ;
72
72
if ( localEvent . eventDescription != null )
73
73
{
@@ -96,8 +96,7 @@ public FormMain()
96
96
// The TeamEnvironmentCollection contains all the environments as specified in TEAM (environments file).
97
97
try
98
98
{
99
- TeamEnvironmentCollection . LoadTeamEnvironmentCollection (
100
- VdwConfigurationSettings . TeamEnvironmentFilePath ) ;
99
+ TeamEnvironmentCollection . LoadTeamEnvironmentCollection ( VdwConfigurationSettings . TeamEnvironmentFilePath ) ;
101
100
}
102
101
catch
103
102
{
@@ -486,22 +485,22 @@ private void saveConfigurationFileToolStripMenuItem_Click(object sender, EventAr
486
485
487
486
if ( ! textBoxTeamConfigurationPath . Text . EndsWith ( @"\" ) )
488
487
{
489
- textBoxTeamConfigurationPath . Text = textBoxTeamConfigurationPath . Text + @"\" ;
488
+ textBoxTeamConfigurationPath . Text += @"\" ;
490
489
}
491
490
492
491
if ( ! textBoxInputPath . Text . EndsWith ( @"\" ) )
493
492
{
494
- textBoxInputPath . Text = textBoxInputPath . Text + @"\" ;
493
+ textBoxInputPath . Text += @"\" ;
495
494
}
496
495
497
496
if ( ! textBoxOutputPath . Text . EndsWith ( @"\" ) )
498
497
{
499
- textBoxOutputPath . Text = textBoxOutputPath . Text + @"\" ;
498
+ textBoxOutputPath . Text += @"\" ;
500
499
}
501
500
502
501
if ( ! textBoxLoadPatternPath . Text . EndsWith ( @"\" ) )
503
502
{
504
- textBoxLoadPatternPath . Text = textBoxLoadPatternPath . Text + @"\" ;
503
+ textBoxLoadPatternPath . Text += @"\" ;
505
504
}
506
505
507
506
new KeyValuePair < string , TeamWorkingEnvironment > ( "" , null ) ;
@@ -563,7 +562,7 @@ private void openTEAMConfigurationSettingsFileToolStripMenuItem_Click(object sen
563
562
}
564
563
catch ( Exception ex )
565
564
{
566
- richTextBoxInformationMain . Text = "An error has occured while attempting to open the TEAM configuration file. The error message is: " + ex . Message ;
565
+ richTextBoxInformationMain . Text = "An error has occurred while attempting to open the TEAM configuration file. The error message is: " + ex . Message ;
567
566
}
568
567
}
569
568
@@ -663,6 +662,10 @@ internal List<LocalPattern> GetMetadata()
663
662
"interfaceSourceLinkAttributeXref.json" ,
664
663
"Development_TEAM_Model_Metadata.json" ,
665
664
"Development_TEAM_Attribute_Mapping.json" ,
665
+ "Development_TEAM_Table_Mapping.json" ,
666
+ "Production_TEAM_Model_Metadata.json" ,
667
+ "Production_TEAM_Attribute_Mapping.json" ,
668
+ "Production_TEAM_Table_Mapping.json"
666
669
} ;
667
670
668
671
if ( fileEntries . Length > 0 )
@@ -689,13 +692,16 @@ internal List<LocalPattern> GetMetadata()
689
692
}
690
693
691
694
// Add the deserialised file to the list of mappings.
692
- VDW_DataObjectMappingList deserialisedMapping = new VDW_DataObjectMappingList ( ) ;
695
+ VDW_DataObjectMappingList deserialisedMapping ;
693
696
694
697
var jsonInput = File . ReadAllText ( fileName ) ;
695
698
deserialisedMapping = JsonConvert . DeserializeObject < VDW_DataObjectMappingList > ( jsonInput ) ;
696
- deserialisedMapping . metadataFileName = fileName ;
699
+ if ( deserialisedMapping != null )
700
+ {
701
+ deserialisedMapping . metadataFileName = fileName ;
697
702
698
- mappingList . Add ( deserialisedMapping ) ;
703
+ mappingList . Add ( deserialisedMapping ) ;
704
+ }
699
705
}
700
706
catch ( Exception exception )
701
707
{
@@ -731,7 +737,7 @@ internal List<LocalPattern> GetMetadata()
731
737
Dictionary < VDW_DataObjectMappingList , Tuple < string , string , string > > objectDictionary =
732
738
new Dictionary < VDW_DataObjectMappingList , Tuple < string , string , string > > ( ) ;
733
739
734
- if ( mappingList . Any ( ) == true )
740
+ if ( mappingList . Any ( ) )
735
741
{
736
742
foreach ( VDW_DataObjectMappingList dataObjectMappings in mappingList )
737
743
{
@@ -1155,7 +1161,7 @@ private void pictureBoxUpdateLoadPatternPath_Click(object sender, EventArgs e)
1155
1161
1156
1162
1157
1163
// Update the parameters in memory.
1158
- VdwConfigurationSettings . LoadPatternPath = finalPath ; ;
1164
+ VdwConfigurationSettings . LoadPatternPath = finalPath ;
1159
1165
textBoxLoadPatternPath . Text = finalPath ;
1160
1166
1161
1167
// Report back to the user.
0 commit comments