Compare commits
No commits in common. "app-source-code" and "v0.0.2" have entirely different histories.
app-source
...
v0.0.2
7
SOURCE/Application/Form1.Designer.cs
generated
7
SOURCE/Application/Form1.Designer.cs
generated
@ -30,7 +30,7 @@ namespace App
|
|||||||
private void InitializeComponent()
|
private void InitializeComponent()
|
||||||
{
|
{
|
||||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
|
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
|
||||||
this.deviceDescription1 = new Aml.Editor.Plugin.DeviceDescription(new Aml.Editor.Plugin.MWController());
|
this.deviceDescription1 = new Aml.Editor.Plugin.DeviceDescription();
|
||||||
this.SuspendLayout();
|
this.SuspendLayout();
|
||||||
//
|
//
|
||||||
// deviceDescription1
|
// deviceDescription1
|
||||||
@ -41,10 +41,11 @@ namespace App
|
|||||||
this.deviceDescription1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
this.deviceDescription1.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||||
this.deviceDescription1.Location = new System.Drawing.Point(0, 0);
|
this.deviceDescription1.Location = new System.Drawing.Point(0, 0);
|
||||||
this.deviceDescription1.Margin = new System.Windows.Forms.Padding(0);
|
this.deviceDescription1.Margin = new System.Windows.Forms.Padding(0);
|
||||||
|
this.deviceDescription1.MaximumSize = new System.Drawing.Size(1750, 866);
|
||||||
|
this.deviceDescription1.MinimumSize = new System.Drawing.Size(1750, 866);
|
||||||
this.deviceDescription1.Name = "deviceDescription1";
|
this.deviceDescription1.Name = "deviceDescription1";
|
||||||
this.deviceDescription1.Size = new System.Drawing.Size(884, 461);
|
this.deviceDescription1.Size = new System.Drawing.Size(1750, 866);
|
||||||
this.deviceDescription1.TabIndex = 0;
|
this.deviceDescription1.TabIndex = 0;
|
||||||
this.deviceDescription1.Load += new System.EventHandler(this.deviceDescription1_Load);
|
|
||||||
//
|
//
|
||||||
// Form1
|
// Form1
|
||||||
//
|
//
|
||||||
|
@ -1,4 +1,11 @@
|
|||||||
using System;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Data;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace App
|
namespace App
|
||||||
@ -9,10 +16,5 @@ namespace App
|
|||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void deviceDescription1_Load(object sender, EventArgs e)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Binary file not shown.
@ -1,4 +1,7 @@
|
|||||||
using System;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace App
|
namespace App
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// Allgemeine Informationen über eine Assembly werden über die folgenden
|
// Allgemeine Informationen über eine Assembly werden über die folgenden
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<packages>
|
|
||||||
<package id="Aml.Engine" version="1.5.8" targetFramework="net472" />
|
|
||||||
<package id="System.IO.FileSystem.AccessControl" version="5.0.0" targetFramework="net472" />
|
|
||||||
<package id="System.IO.FileSystem.Primitives" version="4.3.0" targetFramework="net472" />
|
|
||||||
<package id="System.IO.Packaging" version="5.0.0" targetFramework="net472" />
|
|
||||||
<package id="System.Security.AccessControl" version="5.0.0" targetFramework="net472" />
|
|
||||||
<package id="System.Security.Principal.Windows" version="5.0.0" targetFramework="net472" />
|
|
||||||
</packages>
|
|
Binary file not shown.
Before Width: | Height: | Size: 66 KiB |
@ -45,13 +45,13 @@
|
|||||||
<ScrollViewer>
|
<ScrollViewer>
|
||||||
<StackPanel MinWidth="200">
|
<StackPanel MinWidth="200">
|
||||||
<TextBlock Margin="10,5" Style="{StaticResource Heading2}">
|
<TextBlock Margin="10,5" Style="{StaticResource Heading2}">
|
||||||
<Run Text="About the Modelling Wizard for Devices Application!" />
|
<Run Text="About the Modelling Wizard for Devices PlugIn!" />
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Width="400"
|
Width="400"
|
||||||
Margin="10,5"
|
Margin="10,5"
|
||||||
Text="This Modelling Wizard for Devices standalone application can be used to create or modify Devices and Interfaces. It can also be used to import IODD and GSDML Files which will be converted to an AMLX Package."
|
Text="This Modelling Wizard for Devices PlugIn can be used to create or modify Devices and Interfaces. It can also be used to import IODD and GSDML Files which will be converted to an AMLX Package."
|
||||||
TextWrapping="Wrap" />
|
TextWrapping="Wrap" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
@ -90,16 +90,9 @@
|
|||||||
<TextBlock Margin="15,0,0,0">
|
<TextBlock Margin="15,0,0,0">
|
||||||
<Run FontWeight="Bold" Text="DHBW Stuttgart" />
|
<Run FontWeight="Bold" Text="DHBW Stuttgart" />
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
<TextBlock Margin="15,0,0,0">
|
|
||||||
<Run Text="and" />
|
|
||||||
</TextBlock>
|
|
||||||
<TextBlock FontWeight="Bold" Margin="15,5,0,0" Text="TINF20C" />
|
|
||||||
<TextBlock Margin="15,0,0,0">
|
|
||||||
<Run FontWeight="Bold" Text="DHBW Stuttgart" />
|
|
||||||
</TextBlock>
|
|
||||||
|
|
||||||
<TextBlock Margin="15,5,0,10" Text="This Plugin was created as a group project in the class "Software Engineering"" />
|
<TextBlock Margin="15,5,0,10" Text="This Plugin was created as a group project in the class "Software Engineering"" />
|
||||||
<TextBlock Margin="15,5,0,10" Text="Later this plugin was developed as a sample tool that create vendor independent 
automation component, and included as part of Master Thesis" />
|
<TextBlock Margin="15,5,0,10" Text="Later this plugin was developed as a sample tool that create vendor independent 
automation component, and included as part of Master Thesis "" />
|
||||||
|
|
||||||
|
|
||||||
<Border Margin="0,2,0,2" BorderThickness="0,2,0,0">
|
<Border Margin="0,2,0,2" BorderThickness="0,2,0,0">
|
||||||
@ -117,13 +110,8 @@
|
|||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Margin="10,5,0,8"
|
Margin="10,5,0,8"
|
||||||
Text="This project is licensed under the GPL 3.0 license"
|
Text="The MIT License (MIT)
Copyright (c) 2021 TINF19C DHBW Stuttgart

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files ('the Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sub license, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 

 The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE."
|
||||||
TextWrapping="Wrap" />
|
TextWrapping="Wrap" />
|
||||||
<TextBlock
|
|
||||||
Margin="10,5,0,8"
|
|
||||||
TextWrapping="Wrap">
|
|
||||||
Visit our <Hyperlink NavigateUri="https://github.com/H4CK3R-01/TINF20C_ModellingWizard_Devices/blob/main/LICENSE" RequestNavigate="Hyperlink_RequestNavigate">GitHub-Repository</Hyperlink> to learn more about this.
|
|
||||||
</TextBlock>
|
|
||||||
|
|
||||||
|
|
||||||
<Border Margin="0,2,0,2" BorderThickness="0,2,0,0">
|
<Border Margin="0,2,0,2" BorderThickness="0,2,0,0">
|
||||||
@ -136,7 +124,7 @@
|
|||||||
</Border>
|
</Border>
|
||||||
|
|
||||||
<TextBlock Margin="10,5,0,0" FontWeight="Bold">
|
<TextBlock Margin="10,5,0,0" FontWeight="Bold">
|
||||||
© TINF20C DHBW Stuttgart 2022
|
© TINF19C DHBW Stuttgart 2021
|
||||||
<!-- Copyright symbol -->
|
<!-- Copyright symbol -->
|
||||||
</TextBlock>
|
</TextBlock>
|
||||||
|
|
||||||
@ -148,9 +136,13 @@
|
|||||||
Name="TextBlock2WithHyperlink"
|
Name="TextBlock2WithHyperlink"
|
||||||
Margin="10,5,0,0"
|
Margin="10,5,0,0"
|
||||||
TextWrapping="Wrap">
|
TextWrapping="Wrap">
|
||||||
Visit <Hyperlink NavigateUri="https://github.com/H4CK3R-01/TINF20C_ModellingWizard_Devices" RequestNavigate="Hyperlink_RequestNavigate">ModellingWizard</Hyperlink>
|
Visit <Hyperlink NavigateUri="https://github.com/DekaAthlos/TINF19C-ModellingWizard" RequestNavigate="Hyperlink_RequestNavigate">ModellingWizard</Hyperlink>
|
||||||
on GitHub to get more informations about this project.</TextBlock>
|
on GitHub to get more informations about this project.</TextBlock>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
<Border BorderBrush="Gray" BorderThickness="0,0,0,0" Width="491" Height="45">
|
<Border BorderBrush="Gray" BorderThickness="0,0,0,0" Width="491" Height="45">
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
|
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
|
using System.Windows.Controls;
|
||||||
using System.Windows.Navigation;
|
using System.Windows.Navigation;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
@ -17,10 +18,10 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
var assembly = Assembly.GetCallingAssembly();
|
var assembly = Assembly.GetCallingAssembly();
|
||||||
|
|
||||||
txtVersion.Text = "Version " + assembly.GetName().Version.ToString();
|
txtVersion.Text = "Version "+ assembly.GetName().Version.ToString();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Close_Click(object sender, RoutedEventArgs e)
|
private void Close_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
using Aml.Editor.Plugin.Properties;
|
using System;
|
||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Drawing;
|
using System.Linq;
|
||||||
using System.IO;
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
using Aml.Editor.Plugin.Properties;
|
||||||
|
using System.IO;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.Web;
|
||||||
|
using System.Net;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
@ -16,7 +22,7 @@ namespace Aml.Editor.Plugin
|
|||||||
public Button DisplayBtn { get; set; }
|
public Button DisplayBtn { get; set; }
|
||||||
public DataGridView dataGridView { get; set; }
|
public DataGridView dataGridView { get; set; }
|
||||||
public string words { get; set; }
|
public string words { get; set; }
|
||||||
// public TreeNode Node { get; set; }
|
// public TreeNode Node { get; set; }
|
||||||
|
|
||||||
|
|
||||||
public AnimationClass()
|
public AnimationClass()
|
||||||
@ -25,7 +31,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Method for window size maximum and minimum
|
// Method for window size maximum and minimum
|
||||||
public void WindowSizeChanger(Panel panelNumber, Button buttonNumber)
|
public void WindowSizeChanger(Panel panelNumber,Button buttonNumber)
|
||||||
{
|
{
|
||||||
PanelNumber = panelNumber;
|
PanelNumber = panelNumber;
|
||||||
ButtonNumber = buttonNumber;
|
ButtonNumber = buttonNumber;
|
||||||
@ -44,7 +50,7 @@ namespace Aml.Editor.Plugin
|
|||||||
public void WindowSizeChanger(Panel panelNumber)
|
public void WindowSizeChanger(Panel panelNumber)
|
||||||
{
|
{
|
||||||
PanelNumber = panelNumber;
|
PanelNumber = panelNumber;
|
||||||
// Node = node;
|
// Node = node;
|
||||||
if (panelNumber.Size == panelNumber.MaximumSize)
|
if (panelNumber.Size == panelNumber.MaximumSize)
|
||||||
{
|
{
|
||||||
panelNumber.Size = panelNumber.MinimumSize;
|
panelNumber.Size = panelNumber.MinimumSize;
|
||||||
@ -60,13 +66,13 @@ namespace Aml.Editor.Plugin
|
|||||||
public string OpenFileDialog(TextBox textboxName)
|
public string OpenFileDialog(TextBox textboxName)
|
||||||
{
|
{
|
||||||
TextboxName = textboxName;
|
TextboxName = textboxName;
|
||||||
|
|
||||||
OpenFileDialog open = new OpenFileDialog();
|
OpenFileDialog open = new OpenFileDialog();
|
||||||
open.Filter = "Document Files(*.pdf; *.doc;*.jpg; *.jpeg; *.gif; *.bmp; *.png;)|*.pdf; *.doc;*.jpg; *.jpeg; *.gif; *.bmp; *.png;";
|
open.Filter = "Document Files(*.pdf; *.doc;*.jpg; *.jpeg; *.gif; *.bmp; *.png;)|*.pdf; *.doc;*.jpg; *.jpeg; *.gif; *.bmp; *.png;";
|
||||||
if (open.ShowDialog() == DialogResult.OK)
|
if (open.ShowDialog() == DialogResult.OK)
|
||||||
{
|
{
|
||||||
textboxName.Text = open.FileName;
|
textboxName.Text = open.FileName;
|
||||||
|
|
||||||
}
|
}
|
||||||
string nameOfFile = Path.GetFileName(open.FileName);
|
string nameOfFile = Path.GetFileName(open.FileName);
|
||||||
return nameOfFile;
|
return nameOfFile;
|
||||||
@ -84,23 +90,23 @@ namespace Aml.Editor.Plugin
|
|||||||
textboxName.Text = open.FileName;
|
textboxName.Text = open.FileName;
|
||||||
pdfDisplayBtn.Visible = true;
|
pdfDisplayBtn.Visible = true;
|
||||||
pdfDisplayBtn.Text = Path.GetFileName(open.FileName);
|
pdfDisplayBtn.Text = Path.GetFileName(open.FileName);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// method for opening IEC-CDD urls
|
// method for opening IEC-CDD urls
|
||||||
public void ManualOpener(string btnText)
|
public void ManualOpener(string btnText)
|
||||||
{
|
{
|
||||||
string mainUrl = "https://cdd.iec.ch/CDD/IEC62683/iec62683.nsf/PropertiesAllVersions/0112-2---62683%23";
|
string mainUrl = "https://cdd.iec.ch/CDD/IEC62683/iec62683.nsf/PropertiesAllVersions/0112-2---62683%23";
|
||||||
string lastUrl = "?OpenDocument";
|
string lastUrl = "?OpenDocument";
|
||||||
string midUrl = btnText.Substring(15);
|
string midUrl = btnText.Substring(15);
|
||||||
string finalUrl = mainUrl + midUrl + lastUrl;
|
string finalUrl = mainUrl +midUrl+ lastUrl;
|
||||||
|
|
||||||
System.Diagnostics.Process.Start(finalUrl);
|
System.Diagnostics.Process.Start(finalUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Open Dialog Box related method that takes parmeters of textbox name and the picture box number.
|
// Open Dialog Box related method that takes parmeters of textbox name and the picture box number.
|
||||||
public void OpenFileDialog(TextBox textboxName, PictureBox pictureBoxNumber)
|
public void OpenFileDialog(TextBox textboxName,PictureBox pictureBoxNumber)
|
||||||
{
|
{
|
||||||
TextboxName = textboxName;
|
TextboxName = textboxName;
|
||||||
PictureboxNumber = pictureBoxNumber;
|
PictureboxNumber = pictureBoxNumber;
|
||||||
@ -130,7 +136,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
// this method dispaly all hidden buttons with the Refsemantic Id in them.
|
// this method dispaly all hidden buttons with the Refsemantic Id in them.
|
||||||
public void DispalySemanticBtn(Button refSemanticBtn, DataGridView dataGrids, string word)
|
public void DispalySemanticBtn(Button refSemanticBtn, DataGridView dataGrids,string word)
|
||||||
{
|
{
|
||||||
words = word;
|
words = word;
|
||||||
DisplayBtn = refSemanticBtn;
|
DisplayBtn = refSemanticBtn;
|
||||||
|
@ -1,17 +1,20 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Drawing;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
using System.Drawing;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
class AutomationMLDataTables
|
class AutomationMLDataTables
|
||||||
{
|
{
|
||||||
public DataTable AMLAttributeParameters()
|
public DataTable AMLAttributeParameters()
|
||||||
{
|
{
|
||||||
DataTable AMLAttributeParameters = new DataTable();
|
DataTable AMLAttributeParameters = new DataTable();
|
||||||
|
|
||||||
AMLAttributeParameters.Columns.Add("AttributeName");
|
AMLAttributeParameters.Columns.Add("AttributeName");
|
||||||
AMLAttributeParameters.Columns.Add("Value");
|
AMLAttributeParameters.Columns.Add("Value");
|
||||||
AMLAttributeParameters.Columns.Add("Default");
|
AMLAttributeParameters.Columns.Add("Default");
|
||||||
@ -24,19 +27,19 @@ namespace Aml.Editor.Plugin
|
|||||||
return AMLAttributeParameters;
|
return AMLAttributeParameters;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CreateDataTableWithColumns(DataTable dataRowName, DataGridView dataGridViewName,
|
public void CreateDataTableWithColumns( DataTable dataRowName, DataGridView dataGridViewName,
|
||||||
KeyValuePair<string, List<List<ClassOfListsFromReferencefile>>> pair)
|
KeyValuePair<string, List<List<ClassOfListsFromReferencefile>>> pair)
|
||||||
{
|
{
|
||||||
KeyValuePair<string, List<List<ClassOfListsFromReferencefile>>> Pair = pair;
|
KeyValuePair<string, List<List<ClassOfListsFromReferencefile>>> Pair = pair;
|
||||||
|
|
||||||
DataTable DataRowName = dataRowName;
|
DataTable DataRowName = dataRowName;
|
||||||
DataGridView DataGridViewName = dataGridViewName;
|
DataGridView DataGridViewName = dataGridViewName;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
foreach (var valueList in Pair.Value)
|
foreach (var valueList in Pair.Value)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
foreach (var item in valueList)
|
foreach (var item in valueList)
|
||||||
{
|
{
|
||||||
@ -60,7 +63,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
DataGridViewName.Rows[num].Cells[0].Value = item.Name;
|
DataGridViewName.Rows[num].Cells[0].Value = item.Name;
|
||||||
}
|
}
|
||||||
|
|
||||||
DataGridViewName.Rows[num].Cells[1].Value = item.Value;
|
DataGridViewName.Rows[num].Cells[1].Value = item.Value;
|
||||||
DataGridViewName.Rows[num].Cells[2].Value = item.Default;
|
DataGridViewName.Rows[num].Cells[2].Value = item.Default;
|
||||||
DataGridViewName.Rows[num].Cells[3].Value = item.Unit;
|
DataGridViewName.Rows[num].Cells[3].Value = item.Unit;
|
||||||
@ -85,19 +88,19 @@ namespace Aml.Editor.Plugin
|
|||||||
dgvcbc.Items.Add(items);
|
dgvcbc.Items.Add(items);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
DataRowName.Rows.Add(row);
|
DataRowName.Rows.Add(row);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
public void CheckForSameNameTextOfInternalAttributes(DataTable dataRowName, DataGridView dataGridViewName, KeyValuePair<string, List<ClassOfListsFromReferencefile>> pair)
|
public void CheckForSameNameTextOfInternalAttributes(DataTable dataRowName, DataGridView dataGridViewName, KeyValuePair<string, List<ClassOfListsFromReferencefile>> pair)
|
||||||
{
|
{
|
||||||
@ -108,10 +111,10 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
/* if (eachrow.Cells[0].Value.Equals(item.Name))
|
/* if (eachrow.Cells[0].Value.Equals(item.Name))
|
||||||
{
|
{
|
||||||
|
|
||||||
}*/
|
}*/
|
||||||
}
|
}
|
||||||
catch (Exception) { }
|
catch (Exception) { }
|
||||||
}
|
}
|
||||||
@ -125,9 +128,9 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
foreach (var item in Pair.Value)
|
foreach (var item in Pair.Value)
|
||||||
{
|
{
|
||||||
|
|
||||||
DataRow row = DataRowName.NewRow();
|
DataRow row = DataRowName.NewRow();
|
||||||
|
|
||||||
|
|
||||||
row["AttributeName"] = item.AttributeName;
|
row["AttributeName"] = item.AttributeName;
|
||||||
row["Value"] = item.Values;
|
row["Value"] = item.Values;
|
||||||
@ -140,10 +143,10 @@ namespace Aml.Editor.Plugin
|
|||||||
DataRowName.Rows.Add(row);
|
DataRowName.Rows.Add(row);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* break;*/
|
||||||
/* break;*/
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,10 @@
|
|||||||
namespace Aml.Editor.Plugin
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
class ClassOfListsFromDataGridViews
|
class ClassOfListsFromDataGridViews
|
||||||
{
|
{
|
||||||
@ -17,7 +23,7 @@
|
|||||||
//public CAEXSequence<RefSemanticType> RefSemanticList { get; set; }
|
//public CAEXSequence<RefSemanticType> RefSemanticList { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public ClassOfListsFromDataGridViews()
|
public ClassOfListsFromDataGridViews()
|
||||||
{
|
{
|
||||||
|
@ -1,4 +1,10 @@
|
|||||||
using Aml.Engine.CAEX;
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Aml.Engine.AmlObjects;
|
||||||
|
using Aml.Engine.CAEX;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
@ -14,7 +20,7 @@ namespace Aml.Editor.Plugin
|
|||||||
public string CopyRight { get; set; }
|
public string CopyRight { get; set; }
|
||||||
public string AttributePath { get; set; }
|
public string AttributePath { get; set; }
|
||||||
public string RefBaseClassPath { get; set; }
|
public string RefBaseClassPath { get; set; }
|
||||||
public string ID { get; set; }
|
public string ID { get; set; }
|
||||||
public string ReferencedClassName { get; set; }
|
public string ReferencedClassName { get; set; }
|
||||||
public CAEXSequence<RefSemanticType> RefSemanticList { get; set; }
|
public CAEXSequence<RefSemanticType> RefSemanticList { get; set; }
|
||||||
public string SupportesRoleClassType { get; set; }
|
public string SupportesRoleClassType { get; set; }
|
||||||
@ -25,14 +31,14 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
public ClassOfListsFromReferencefile()
|
public ClassOfListsFromReferencefile()
|
||||||
{
|
{
|
||||||
// RefSemanticList = new List<CAEXSequence<RefSemanticType>>();
|
// RefSemanticList = new List<CAEXSequence<RefSemanticType>>();
|
||||||
}
|
}
|
||||||
|
|
||||||
public ClassOfListsFromReferencefile(string name, string value,
|
public ClassOfListsFromReferencefile(string name, string value,
|
||||||
string _default, string unit,
|
string _default, string unit,
|
||||||
string reference, string description,
|
string reference, string description,
|
||||||
string copyRight, string semantic, string
|
string copyRight, string semantic, string
|
||||||
attributePath, string refBaseClassPath,
|
attributePath, string refBaseClassPath,
|
||||||
string id, string referencedClassName, CAEXSequence<RefSemanticType> refSemanticList, string supportesRoleClassType, string dataType)
|
string id, string referencedClassName, CAEXSequence<RefSemanticType> refSemanticList, string supportesRoleClassType, string dataType)
|
||||||
: this()
|
: this()
|
||||||
{
|
{
|
||||||
@ -55,8 +61,8 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return "ClassOfListsFromReferencefile(" + Name + "=" + Value + "=" + Default + "=" + Unit + "=" + Reference + "="
|
return "ClassOfListsFromReferencefile("+Name+"="+Value+"="+Default+"="+Unit+"="+Reference+"="
|
||||||
+ Description + "=" + CopyRight + "=" + Semantic + "=" + AttributePath + "=" + RefBaseClassPath + "=" + ID
|
+Description+"="+CopyRight+"="+Semantic+"="+AttributePath+ "=" + RefBaseClassPath + "=" + ID
|
||||||
+ "=" + ReferencedClassName + "=" + RefSemanticList + "=" + SupportesRoleClassType + "=" + DataType + ")";
|
+ "=" + ReferencedClassName + "=" + RefSemanticList + "=" + SupportesRoleClassType + "=" + DataType + ")";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
1314
SOURCE/Plugin/DeviceDescription.Designer.cs
generated
1314
SOURCE/Plugin/DeviceDescription.Designer.cs
generated
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -123,6 +123,54 @@
|
|||||||
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<value>265, 17</value>
|
<value>265, 17</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
<metadata name="toolStrip5.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>273, 146</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="deleteRoleClassesButton.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>17, 80</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="toolStrip2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>1330, 103</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="toolStrip24.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>1066, 103</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn24.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn25.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn26.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn27.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn28.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn29.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn24.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn25.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn26.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn27.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn28.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn29.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
<metadata name="imageList2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="imageList2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<value>278, 103</value>
|
<value>278, 103</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
@ -131,7 +179,7 @@
|
|||||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAD6
|
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAD6
|
||||||
DAAAAk1TRnQBSQFMAgEBAwEAAaABBAGgAQQBHAEAARwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
DAAAAk1TRnQBSQFMAgEBAwEAAcgBAwHIAQMBHAEAARwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||||
AwABcAMAARwDAAEBAQABCAUAAUABDBgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
AwABcAMAARwDAAEBAQABCAUAAUABDBgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
||||||
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
||||||
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
||||||
@ -204,8 +252,23 @@
|
|||||||
<metadata name="dataGridViewCheckBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewCheckBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn31.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewTextBoxColumn32.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="loadfromLibrary.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="loadFromComponentFile.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewCheckBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
<metadata name="deleteRoleClassesButton.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="deleteRoleClassesButton.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<value>853, 146</value>
|
<value>17, 80</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||||
<data name="deleteRoleClassButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="deleteRoleClassButton.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
@ -223,27 +286,24 @@
|
|||||||
TgDQASA1MVpwzwAAAABJRU5ErkJggg==
|
TgDQASA1MVpwzwAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
<metadata name="dataGridViewTextBoxColumn24.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn17.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="dataGridViewTextBoxColumn25.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn18.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="dataGridViewTextBoxColumn26.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn19.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="dataGridViewTextBoxColumn27.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn20.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="dataGridViewTextBoxColumn28.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn21.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="dataGridViewTextBoxColumn29.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn22.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="toolStrip5.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
|
||||||
<value>1038, 146</value>
|
|
||||||
</metadata>
|
|
||||||
<metadata name="dataGridViewTextBoxColumn17.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn17.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
@ -262,8 +322,20 @@
|
|||||||
<metadata name="dataGridViewTextBoxColumn22.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="dataGridViewTextBoxColumn22.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="toolStrip2.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="SerialNumber.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>1330, 103</value>
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="SelectedClassorInterface.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="libraryFile.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="componentFile.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="dataGridViewCheckBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
<metadata name="SerialNumber.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="SerialNumber.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
@ -298,6 +370,18 @@
|
|||||||
TgDQASA1MVpwzwAAAABJRU5ErkJggg==
|
TgDQASA1MVpwzwAAAABJRU5ErkJggg==
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
|
<metadata name="toolStrip19.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>1179, 60</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="ElementName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="FilePath.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="Add.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
|
<value>True</value>
|
||||||
|
</metadata>
|
||||||
<metadata name="ElementName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
<metadata name="ElementName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||||
<value>True</value>
|
<value>True</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
@ -328,6 +412,9 @@
|
|||||||
<metadata name="toolStrip13.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="toolStrip13.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<value>729, 60</value>
|
<value>729, 60</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
|
<metadata name="toolStrip13.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>729, 60</value>
|
||||||
|
</metadata>
|
||||||
<data name="addRole.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
<data name="addRole.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||||
<value>
|
<value>
|
||||||
iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
|
||||||
@ -336,6 +423,12 @@
|
|||||||
RgtnViTyCJEC4UCoEdfIj94AAAAASUVORK5CYII=
|
RgtnViTyCJEC4UCoEdfIj94AAAAASUVORK5CYII=
|
||||||
</value>
|
</value>
|
||||||
</data>
|
</data>
|
||||||
|
<metadata name="toolStrip7.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>1311, 60</value>
|
||||||
|
</metadata>
|
||||||
|
<metadata name="toolStrip9.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
|
<value>1435, 60</value>
|
||||||
|
</metadata>
|
||||||
<metadata name="imageList1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
<metadata name="imageList1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||||
<value>149, 103</value>
|
<value>149, 103</value>
|
||||||
</metadata>
|
</metadata>
|
||||||
@ -344,7 +437,7 @@
|
|||||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAABC
|
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAABC
|
||||||
DQAAAk1TRnQBSQFMAgEBAwEAAaABBAGgAQQBHAEAARwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
DQAAAk1TRnQBSQFMAgEBAwEAAcgBAwHIAQMBHAEAARwBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||||
AwABcAMAARwDAAEBAQABCAUAAUABDBgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
AwABcAMAARwDAAEBAQABCAUAAUABDBgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
||||||
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
||||||
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
||||||
@ -417,7 +510,7 @@
|
|||||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAC4
|
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAC4
|
||||||
CQAAAk1TRnQBSQFMAgEBAgEAAZgBBAGYAQQBGQEAARkBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
CQAAAk1TRnQBSQFMAgEBAgEAAcABAwHAAQMBGQEAARkBAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||||
AwABZAMAARkDAAEBAQABCAUAAcQBCRgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
AwABZAMAARkDAAEBAQABCAUAAcQBCRgAAYACAAGAAwACgAEAAYADAAGAAQABgAEAAoACAAPAAQABwAHc
|
||||||
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
AcABAAHwAcoBpgEAATMFAAEzAQABMwEAATMBAAIzAgADFgEAAxwBAAMiAQADKQEAA1UBAANNAQADQgEA
|
||||||
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
AzkBAAGAAXwB/wEAAlAB/wEAAZMBAAHWAQAB/wHsAcwBAAHGAdYB7wEAAdYC5wEAAZABqQGtAgAB/wEz
|
||||||
@ -472,7 +565,7 @@
|
|||||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAA
|
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAA
|
||||||
CAAAAk1TRnQBSQFMAwEBAAGgAQQBoAEEARABAAEQAQAE/wEJAQAI/wFCAU0BNgEEBgABNgEEAgABKAMA
|
CAAAAk1TRnQBSQFMAwEBAAHIAQMByAEDARABAAEQAQAE/wEJAQAI/wFCAU0BNgEEBgABNgEEAgABKAMA
|
||||||
AUADAAEQAwABAQEAAQgGAAEEGAABgAIAAYADAAKAAQABgAMAAYABAAGAAQACgAIAA8ABAAHAAdwBwAEA
|
AUADAAEQAwABAQEAAQgGAAEEGAABgAIAAYADAAKAAQABgAMAAYABAAGAAQACgAIAA8ABAAHAAdwBwAEA
|
||||||
AfABygGmAQABMwUAATMBAAEzAQABMwEAAjMCAAMWAQADHAEAAyIBAAMpAQADVQEAA00BAANCAQADOQEA
|
AfABygGmAQABMwUAATMBAAEzAQABMwEAAjMCAAMWAQADHAEAAyIBAAMpAQADVQEAA00BAANCAQADOQEA
|
||||||
AYABfAH/AQACUAH/AQABkwEAAdYBAAH/AewBzAEAAcYB1gHvAQAB1gLnAQABkAGpAa0CAAH/ATMDAAFm
|
AYABfAH/AQACUAH/AQABkwEAAdYBAAH/AewBzAEAAcYB1gHvAQAB1gLnAQABkAGpAa0CAAH/ATMDAAFm
|
||||||
|
@ -9,11 +9,11 @@ namespace Aml.Editor.Plugin
|
|||||||
public class MWController
|
public class MWController
|
||||||
{
|
{
|
||||||
// the (initialised) GUIs
|
// the (initialised) GUIs
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private DeviceDescription deviceDescriptionForm;
|
private DeviceDescription deviceDescriptionForm;
|
||||||
|
|
||||||
|
|
||||||
// the interface class to the AML Editor
|
// the interface class to the AML Editor
|
||||||
private ModellingWizard modellingWizard;
|
private ModellingWizard modellingWizard;
|
||||||
@ -28,16 +28,19 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Init the controller and reload all amlx devices
|
/// Init the controller and reload all amlx devices
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public MWController()
|
/// <param name="modellingWizard"></param>
|
||||||
|
public MWController(ModellingWizard modellingWizard)
|
||||||
{
|
{
|
||||||
|
this.modellingWizard = modellingWizard;
|
||||||
mWData = new MWData(this);
|
mWData = new MWData(this);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create the new CreateDevice GUI or return the previously created GUI
|
/// Create the new CreateDevice GUI or return the previously created GUI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>the CreateDevice GUI for this session</returns>
|
/// <returns>the CreateDevice GUI for this session</returns>
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// create the new DeviceDescription GUI or return the previously created GUI
|
/// create the new DeviceDescription GUI or return the previously created GUI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -56,28 +59,28 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <param name="newDevice"></param>
|
/// <param name="newDevice"></param>
|
||||||
/// <param name="isEdit"></param>
|
/// <param name="isEdit"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public String CreateDeviceOnClick(MWDevice newDevice, bool isEdit, bool useCaex2_15)
|
public String CreateDeviceOnClick(MWDevice newDevice, bool isEdit)
|
||||||
{
|
{
|
||||||
string result = "";
|
string result = "";
|
||||||
|
|
||||||
if (newDevice.deviceName != null && newDevice.vendorName != null)
|
if (newDevice.deviceName != null && newDevice.vendorName != null)
|
||||||
{
|
{
|
||||||
// create the device
|
// create the device
|
||||||
result = mWData.CreateDevice(newDevice, isEdit, useCaex2_15);
|
result = mWData.CreateDevice(newDevice, isEdit);
|
||||||
}
|
}
|
||||||
|
|
||||||
// update the device list
|
// update the device list
|
||||||
if (isEdit)
|
if (isEdit)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
devices.Add(newDevice);
|
devices.Add(newDevice);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -86,11 +89,11 @@ namespace Aml.Editor.Plugin
|
|||||||
/// Show the correct GUI for the selected device
|
/// Show the correct GUI for the selected device
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="selectedIndex">The index of the selected item in the dropdown</param>
|
/// <param name="selectedIndex">The index of the selected item in the dropdown</param>
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Reload all .amlx files in ./modellingwizard/ and update the dropdown.
|
/// Reload all .amlx files in ./modellingwizard/ and update the dropdown.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Switch the displayed
|
/// Switch the displayed
|
||||||
@ -98,10 +101,9 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <param name="targetGUI">the GUI Type to display</param>
|
/// <param name="targetGUI">the GUI Type to display</param>
|
||||||
public void ChangeGui(MWGUIType targetGUI)
|
public void ChangeGui(MWGUIType targetGUI)
|
||||||
{
|
{
|
||||||
// TODO modellingWizard is null
|
|
||||||
switch (targetGUI)
|
switch (targetGUI)
|
||||||
{
|
{
|
||||||
|
|
||||||
case MWGUIType.DeviceDescription:
|
case MWGUIType.DeviceDescription:
|
||||||
modellingWizard.changeGUI(GetDeviceDescriptionForm());
|
modellingWizard.changeGUI(GetDeviceDescriptionForm());
|
||||||
break;
|
break;
|
||||||
@ -137,7 +139,7 @@ namespace Aml.Editor.Plugin
|
|||||||
result = "Invalid Filetype";
|
result = "Invalid Filetype";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -7,6 +7,7 @@ using System.IO.Packaging;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
@ -15,7 +16,7 @@ namespace Aml.Editor.Plugin
|
|||||||
// holds the controller to report created devices to
|
// holds the controller to report created devices to
|
||||||
private readonly MWController mWController;
|
private readonly MWController mWController;
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create the MWData Object
|
/// Create the MWData Object
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -55,32 +56,49 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <param name="device">The device which will be created</param>
|
/// <param name="device">The device which will be created</param>
|
||||||
/// <param name="isEdit">true if an amlx file get update, false if a new file will be created</param>
|
/// <param name="isEdit">true if an amlx file get update, false if a new file will be created</param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public string CreateDevice(MWDevice device, bool isEdit, bool useCaex2_15)
|
public string CreateDevice(MWDevice device, bool isEdit)
|
||||||
{
|
{
|
||||||
CAEXDocument document;
|
|
||||||
|
CAEXDocument document = null;
|
||||||
AutomationMLContainer amlx = null;
|
AutomationMLContainer amlx = null;
|
||||||
|
|
||||||
// Init final .amlx Filepath
|
// Init final .amlx Filepath
|
||||||
|
//first of all create a folder on "Vendor Name"
|
||||||
|
string vendorCompanyName = device.vendorName;
|
||||||
|
|
||||||
string amlFilePath;
|
string amlFilePath;
|
||||||
|
|
||||||
string fileName = device.fileName;
|
string fileName = device.fileName;
|
||||||
|
|
||||||
amlFilePath = fileName.Contains(".amlx") ? Path.Combine(device.filepath, fileName) : Path.Combine(device.filepath, fileName + ".amlx");
|
if (fileName.Contains(".amlx"))
|
||||||
|
{
|
||||||
|
amlFilePath = System.IO.Path.Combine(device.filepath, fileName);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
amlFilePath = System.IO.Path.Combine(device.filepath, fileName + ".amlx");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
FileInfo file = new FileInfo(amlFilePath);
|
FileInfo file = new FileInfo(amlFilePath);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Create directory if it's not existing
|
// Create directory if it's not existing
|
||||||
file.Directory.Create();
|
file.Directory.Create();
|
||||||
|
|
||||||
|
|
||||||
// Init CAEX Document
|
// Init CAEX Document
|
||||||
if (isEdit)
|
if (isEdit)
|
||||||
{
|
{
|
||||||
// Load the amlx file
|
// Load the amlx file
|
||||||
amlx = new AutomationMLContainer(amlFilePath, FileMode.OpenOrCreate);
|
amlx = new AutomationMLContainer(amlFilePath, FileMode.Open);
|
||||||
|
|
||||||
IEnumerable<PackagePart> rootParts = amlx.GetPartsByRelationShipType(AutomationMLContainer.RelationshipType.Root);
|
IEnumerable<PackagePart> rootParts = amlx.GetPartsByRelationShipType(AutomationMLContainer.RelationshipType.Root);
|
||||||
|
|
||||||
// We expect the aml to only have one root part
|
// We expect the aml to only have one root part
|
||||||
if (rootParts.Count() != 0 && rootParts.First() != null)
|
if (rootParts.First() != null)
|
||||||
{
|
{
|
||||||
PackagePart part = rootParts.First();
|
PackagePart part = rootParts.First();
|
||||||
|
|
||||||
@ -90,36 +108,37 @@ namespace Aml.Editor.Plugin
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
// the amlx contains no aml file
|
// the amlx contains no aml file
|
||||||
if (useCaex2_15) document = CAEXDocument.New_CAEXDocument(CAEXDocument.CAEXSchema.CAEX2_15);
|
document = CAEXDocument.New_CAEXDocument();
|
||||||
else document = CAEXDocument.New_CAEXDocument(CAEXDocument.CAEXSchema.CAEX3_0);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// create a new CAEX document
|
// create a new CAEX document
|
||||||
if (useCaex2_15) document = CAEXDocument.New_CAEXDocument(CAEXDocument.CAEXSchema.CAEX2_15);
|
document = CAEXDocument.New_CAEXDocument();
|
||||||
else document = CAEXDocument.New_CAEXDocument(CAEXDocument.CAEXSchema.CAEX3_0);
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
amlx = new AutomationMLContainer(amlFilePath, FileMode.OpenOrCreate);
|
amlx = new AutomationMLContainer(amlFilePath, FileMode.Create);
|
||||||
}
|
}
|
||||||
catch (Exception)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
Console.WriteLine("Failed to create AutomationMLContainer object");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// Init the default Libs
|
// Init the default Libs
|
||||||
AutomationMLBaseRoleClassLibType.RoleClassLib(document);
|
AutomationMLBaseRoleClassLibType.RoleClassLib(document) ;
|
||||||
AutomationMLInterfaceClassLibType.InterfaceClassLib(document);
|
AutomationMLInterfaceClassLibType.InterfaceClassLib(document) ;
|
||||||
|
|
||||||
var structureRoleFamilyType = AutomationMLBaseRoleClassLibType.RoleClassLib(document).Structure;
|
var structureRoleFamilyType = AutomationMLBaseRoleClassLibType.RoleClassLib(document).Structure;
|
||||||
|
|
||||||
|
|
||||||
SystemUnitFamilyType systemUnitClass = null;
|
SystemUnitFamilyType systemUnitClass = null;
|
||||||
// Create the SystemUnitClass for our device
|
// Create the SystemUnitClass for our device
|
||||||
if (!isEdit)
|
if (!isEdit)
|
||||||
{
|
{
|
||||||
systemUnitClass = document.CAEXFile.SystemUnitClassLib.Append("ComponentSystemUnitClassLib").SystemUnitClass.Append(device.deviceName);
|
systemUnitClass = document.CAEXFile.SystemUnitClassLib.Append("ComponentSystemUnitClassLib").SystemUnitClass.Append(device.deviceName);
|
||||||
|
|
||||||
@ -134,8 +153,14 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
||||||
Boolean myBool;
|
Boolean myBool;
|
||||||
Boolean.TryParse(eachparameter.AddToFile, out myBool);
|
Boolean.TryParse(eachparameter.AddToFile, out myBool);
|
||||||
|
|
||||||
|
if (myBool == true)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
Uri eachUri = null;
|
Uri eachUri = null;
|
||||||
AttachablesDataGridViewParameters par = new AttachablesDataGridViewParameters();
|
AttachablesDataGridViewParameters par = new AttachablesDataGridViewParameters();
|
||||||
@ -144,11 +169,14 @@ namespace Aml.Editor.Plugin
|
|||||||
par.FilePath = eachparameter.FilePath;
|
par.FilePath = eachparameter.FilePath;
|
||||||
|
|
||||||
device.listWithURIConvertedToString.Add(par);
|
device.listWithURIConvertedToString.Add(par);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (var pair in device.DictionaryForRoleClassofComponent)
|
foreach (var pair in device.DictionaryForRoleClassofComponent)
|
||||||
{
|
{
|
||||||
|
|
||||||
Match numberfromElectricalConnectorType = Regex.Match(pair.Key.ToString(), @"\((\d+)\)");
|
Match numberfromElectricalConnectorType = Regex.Match(pair.Key.ToString(), @"\((\d+)\)");
|
||||||
string initialnumberbetweenparanthesisofElectricalConnectorType =
|
string initialnumberbetweenparanthesisofElectricalConnectorType =
|
||||||
numberfromElectricalConnectorType.Groups[1].Value;
|
numberfromElectricalConnectorType.Groups[1].Value;
|
||||||
@ -258,6 +286,8 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
SRC.RefRoleClassPath = item.SupportesRoleClassType;
|
SRC.RefRoleClassPath = item.SupportesRoleClassType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -298,14 +328,15 @@ namespace Aml.Editor.Plugin
|
|||||||
foundSysClassLib = true;
|
foundSysClassLib = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!foundSysClassLib) systemUnitClass = document.CAEXFile.SystemUnitClassLib.Append("ComponentSystemUnitClassLib").SystemUnitClass.Append(device.deviceName);
|
if (!foundSysClassLib)
|
||||||
|
systemUnitClass = document.CAEXFile.SystemUnitClassLib.Append("ComponentSystemUnitClassLib").SystemUnitClass.Append(device.deviceName);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create the internalElement Interfaces
|
// Create the internalElement Interfaces
|
||||||
if (device.vendorName != null)
|
if (device.vendorName != null)
|
||||||
{
|
{
|
||||||
InternalElementType electricalInterface = null;
|
InternalElementType electricalInterface = null;
|
||||||
RoleRequirementsType roleRequirements = null;
|
RoleRequirementsType roleRequirements = null ;
|
||||||
foreach (var internalElement in systemUnitClass.InternalElement)
|
foreach (var internalElement in systemUnitClass.InternalElement)
|
||||||
{
|
{
|
||||||
if (internalElement.Name.Equals("Interfaces"))
|
if (internalElement.Name.Equals("Interfaces"))
|
||||||
@ -318,9 +349,9 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
if (electricalInterface == null)
|
if (electricalInterface == null)
|
||||||
electricalInterface = systemUnitClass.InternalElement.Append("Interfaces");
|
electricalInterface = systemUnitClass.InternalElement.Append("Interfaces");
|
||||||
roleRequirements = electricalInterface.RoleRequirements.Append();
|
roleRequirements = electricalInterface.RoleRequirements.Append();
|
||||||
|
|
||||||
roleRequirements.RefBaseRoleClassPath = structureRoleFamilyType.CAEXPath();
|
roleRequirements.RefBaseRoleClassPath = structureRoleFamilyType.CAEXPath();
|
||||||
|
|
||||||
foreach (var pair in device.DictionaryForInterfaceClassesInElectricalInterfaces)
|
foreach (var pair in device.DictionaryForInterfaceClassesInElectricalInterfaces)
|
||||||
{
|
{
|
||||||
@ -428,6 +459,9 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
electricalConnectorType.RefBaseClassPath = item.RefBaseClassPath;
|
electricalConnectorType.RefBaseClassPath = item.RefBaseClassPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -439,7 +473,10 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
string electricalConnectorPinName = Regex.Replace(pairofList.Key.ToString(), @"\(.*?\)", "");
|
string electricalConnectorPinName = Regex.Replace(pairofList.Key.ToString(), @"\(.*?\)", "");
|
||||||
electricalConnectorPinName = Regex.Replace(electricalConnectorPinName, @"\{.*?\}", "");
|
electricalConnectorPinName = Regex.Replace(electricalConnectorPinName, @"\{.*?\}", "");
|
||||||
electricalConnectorPinName = electricalConnectorPinName.Replace(electricalConnectorTypeName, "");
|
electricalConnectorPinName = electricalConnectorPinName.Replace(electricalConnectorTypeName,"");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (initialnumberbetweenparanthesisofElectricalConnectorType == initialnumberbetweenparanthesisElectricalConnectorPins)
|
if (initialnumberbetweenparanthesisofElectricalConnectorType == initialnumberbetweenparanthesisElectricalConnectorPins)
|
||||||
{
|
{
|
||||||
@ -553,7 +590,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
// delete the old aml file
|
// delete the old aml file
|
||||||
amlx.Package.DeletePart(partUri);
|
amlx.Package.DeletePart(partUri);
|
||||||
|
|
||||||
// delete all files in the amlx package.
|
// delete all files in the amlx package.
|
||||||
// Directory.Delete(Path.GetFullPath(amlx.ContainerFilename), true);
|
// Directory.Delete(Path.GetFullPath(amlx.ContainerFilename), true);
|
||||||
|
|
||||||
@ -561,9 +598,9 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
// write the new aml file into the package
|
// write the new aml file into the package
|
||||||
PackagePart root = amlx.AddRoot(path, partUri);
|
PackagePart root = amlx.AddRoot(path, partUri);
|
||||||
|
|
||||||
|
|
||||||
if (!isEdit)
|
if (!isEdit)
|
||||||
{
|
{
|
||||||
foreach (AttachablesDataGridViewParameters listWithUri in device.listWithURIConvertedToString)
|
foreach (AttachablesDataGridViewParameters listWithUri in device.listWithURIConvertedToString)
|
||||||
{
|
{
|
||||||
@ -575,22 +612,29 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
DirectoryInfo directory = new DirectoryInfo(Path.GetDirectoryName(amlFilePath));
|
DirectoryInfo directory = new DirectoryInfo(Path.GetDirectoryName(amlFilePath));
|
||||||
|
|
||||||
foreach (FileInfo fileInfos in directory.GetFiles())
|
foreach (FileInfo fileInfos in directory.GetFiles())
|
||||||
{
|
{
|
||||||
if (fileInfos.Extension != ".amlx")
|
if (fileInfos.Extension != ".amlx")
|
||||||
{
|
{
|
||||||
fileInfos.Delete();
|
fileInfos.Delete();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
amlx.Save();
|
amlx.Save();
|
||||||
amlx.Close();
|
amlx.Close();
|
||||||
|
|
||||||
return isEdit ? "Sucessfully updated device!\nFilepath " + amlFilePath : "Device description file created!\nFilepath " + amlFilePath;
|
if (isEdit)
|
||||||
|
{
|
||||||
|
return "Sucessfully updated device!\nFilepath " + amlFilePath;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return "Device description file created!\nFilepath " + amlFilePath;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SearchForAttributesInsideAttributesofAutomationComponent(string searchName, AttributeType attribute, ClassOfListsFromReferencefile item, SupportedRoleClassType SRC)
|
public void SearchForAttributesInsideAttributesofAutomationComponent(string searchName, AttributeType attribute, ClassOfListsFromReferencefile item, SupportedRoleClassType SRC)
|
||||||
@ -623,14 +667,14 @@ namespace Aml.Editor.Plugin
|
|||||||
SearchForAttributesInsideAttributesofAutomationComponent(searchName, nestedAttribute, item, SRC);
|
SearchForAttributesInsideAttributesofAutomationComponent(searchName, nestedAttribute, item, SRC);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SearchAttributesInsideAttributesOFElectricConnectorType(string searchName, AttributeType attribute, ClassOfListsFromReferencefile item, ExternalInterfaceType electricConnectorType)
|
public void SearchAttributesInsideAttributesOFElectricConnectorType(string searchName, AttributeType attribute, ClassOfListsFromReferencefile item, ExternalInterfaceType electricConnectorType)
|
||||||
{
|
{
|
||||||
foreach (var nestedAttribute in attribute.Attribute)
|
foreach (var nestedAttribute in attribute.Attribute)
|
||||||
{
|
{
|
||||||
|
|
||||||
if (nestedAttribute.Name == searchName)
|
if (nestedAttribute.Name == searchName)
|
||||||
{
|
{
|
||||||
var eachattribute = nestedAttribute.Attribute.Append(item.Name.ToString());
|
var eachattribute = nestedAttribute.Attribute.Append(item.Name.ToString());
|
||||||
@ -653,14 +697,14 @@ namespace Aml.Editor.Plugin
|
|||||||
electricConnectorType.RefBaseClassPath = item.RefBaseClassPath;
|
electricConnectorType.RefBaseClassPath = item.RefBaseClassPath;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nestedAttribute.Attribute.Exists)
|
if (nestedAttribute.Attribute.Exists)
|
||||||
{
|
{
|
||||||
SearchAttributesInsideAttributesOFElectricConnectorType(searchName, nestedAttribute, item, electricConnectorType);
|
SearchAttributesInsideAttributesOFElectricConnectorType(searchName, nestedAttribute, item, electricConnectorType);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Takes the url of the picture and setup in the value attribute of the corresponding internal element <paramref name="pic"/>.
|
/// Takes the url of the picture and setup in the value attribute of the corresponding internal element <paramref name="pic"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -709,7 +753,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
urlAtt.AttributeDataType = "xs:anyURI";
|
urlAtt.AttributeDataType = "xs:anyURI";
|
||||||
urlAtt.Value = url.ToString();
|
urlAtt.Value = url.ToString();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -765,7 +809,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
pictureAtt.AttributeDataType = "xs:anyURI";
|
pictureAtt.AttributeDataType = "xs:anyURI";
|
||||||
pictureAtt.Value = picturePart.ToString();
|
pictureAtt.Value = picturePart.ToString();
|
||||||
|
|
||||||
|
|
||||||
return picturePart;
|
return picturePart;
|
||||||
}
|
}
|
||||||
@ -851,7 +895,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
// Load Libary .dll
|
// Load Libary .dll
|
||||||
Assembly assembly = Assembly.Load(File.ReadAllBytes("Dd2Aml.Lib.dll"));
|
Assembly assembly = Assembly.Load("Iodd2AmlConverter.Library");
|
||||||
Type conversionHandler = null;
|
Type conversionHandler = null;
|
||||||
// Iterate over all Types in the Libary and get the ConversionHandler Type
|
// Iterate over all Types in the Libary and get the ConversionHandler Type
|
||||||
foreach (Type type in assembly.ExportedTypes)
|
foreach (Type type in assembly.ExportedTypes)
|
||||||
@ -902,7 +946,7 @@ namespace Aml.Editor.Plugin
|
|||||||
// If it is, then it's calling the Convert Function
|
// If it is, then it's calling the Convert Function
|
||||||
// Gsd2Aml.Lib.Converter.Convert(string inputFilepath, bool strictValidation)
|
// Gsd2Aml.Lib.Converter.Convert(string inputFilepath, bool strictValidation)
|
||||||
|
|
||||||
Assembly assembly = Assembly.Load(File.ReadAllBytes("Gsd2Aml.Lib.dll"));
|
Assembly assembly = Assembly.Load("Gsd2Aml.Lib");
|
||||||
Type conversionHandler = null;
|
Type conversionHandler = null;
|
||||||
// Iterate over all Types in the Libary and get the ConversionHandler Type
|
// Iterate over all Types in the Libary and get the ConversionHandler Type
|
||||||
foreach (Type type in assembly.ExportedTypes)
|
foreach (Type type in assembly.ExportedTypes)
|
||||||
@ -956,7 +1000,6 @@ namespace Aml.Editor.Plugin
|
|||||||
byte[] bytearray = System.Text.Encoding.Unicode.GetBytes(caex);
|
byte[] bytearray = System.Text.Encoding.Unicode.GetBytes(caex);
|
||||||
CAEXDocument document = CAEXDocument.LoadFromBinary(bytearray);
|
CAEXDocument document = CAEXDocument.LoadFromBinary(bytearray);
|
||||||
|
|
||||||
|
|
||||||
// create the amlx file
|
// create the amlx file
|
||||||
string name = Path.GetFileNameWithoutExtension(filename);
|
string name = Path.GetFileNameWithoutExtension(filename);
|
||||||
|
|
||||||
@ -964,11 +1007,11 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
if (name.Contains(".amlx"))
|
if (name.Contains(".amlx"))
|
||||||
{
|
{
|
||||||
amlx = new AutomationMLContainer(".\\modellingwizard\\" + name, FileMode.Create);
|
amlx = new AutomationMLContainer(".\\modellingwizard\\" + name, FileMode.Create);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
amlx = new AutomationMLContainer(".\\modellingwizard\\" + name + ".amlx", FileMode.Create);
|
amlx = new AutomationMLContainer(".\\modellingwizard\\" + name + ".amlx", FileMode.Create);
|
||||||
}
|
}
|
||||||
|
|
||||||
// create the aml package path
|
// create the aml package path
|
||||||
@ -1002,7 +1045,7 @@ namespace Aml.Editor.Plugin
|
|||||||
// Just as an interface
|
// Just as an interface
|
||||||
}
|
}
|
||||||
|
|
||||||
public void copyFiles(string sourceFilePath, string destinationFilePath)
|
public void copyFiles(string sourceFilePath, string destinationFilePath )
|
||||||
{
|
{
|
||||||
string sourFile = Path.GetFileName(sourceFilePath);
|
string sourFile = Path.GetFileName(sourceFilePath);
|
||||||
string destFile = Path.Combine(destinationFilePath, sourFile);
|
string destFile = Path.Combine(destinationFilePath, sourFile);
|
||||||
|
@ -1,23 +1,26 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
// this class initialize the parameters exclusively for the "Device Identofication", "DataGridViews in "Generic Data Tab" AND "Field Attachables Tab""
|
// this class initialize the parameters exclusively for the "Device Identofication", "DataGridViews in "Generic Data Tab" AND "Field Attachables Tab""
|
||||||
public class MWDevice : MWData.MWObject
|
public class MWDevice: MWData.MWObject
|
||||||
{
|
{
|
||||||
public string environment { get; set; }
|
public string environment { get; set; }
|
||||||
public string fileName { get; set; }
|
public string fileName { get; set; }
|
||||||
public string filepath { get; set; }
|
public string filepath { get; set; }
|
||||||
|
|
||||||
|
|
||||||
public string vendorName { get; set; }
|
public string vendorName { get; set; }
|
||||||
|
|
||||||
public string deviceName { get; set; }
|
public string deviceName { get; set; }
|
||||||
|
|
||||||
// Can contain letters:
|
// Can contain letters:
|
||||||
public List<DataGridParameters> dataGridParametersLists { get; set; }
|
public List<DataGridParameters> dataGridParametersLists { get; set; }
|
||||||
|
|
||||||
|
|
||||||
//Properties for Electrical Interface
|
//Properties for Electrical Interface
|
||||||
public List<ElectricalParameters> ElectricalInterfaces { get; set; }
|
public List<ElectricalParameters> ElectricalInterfaces { get; set; }
|
||||||
@ -58,13 +61,13 @@ namespace Aml.Editor.Plugin
|
|||||||
public string RefSemantics { get; set; }
|
public string RefSemantics { get; set; }
|
||||||
public string Attributes { get; set; }
|
public string Attributes { get; set; }
|
||||||
public string Values { get; set; }
|
public string Values { get; set; }
|
||||||
|
|
||||||
|
|
||||||
public DataGridParameters() { }
|
public DataGridParameters() { }
|
||||||
|
|
||||||
public DataGridParameters(string refSemantic, string attributes, string value)
|
public DataGridParameters(string refSemantic, string attributes, string value)
|
||||||
{
|
{
|
||||||
this.RefSemantics = refSemantic;
|
this.RefSemantics = refSemantic;
|
||||||
this.Attributes = attributes;
|
this.Attributes = attributes;
|
||||||
this.Values = value;
|
this.Values = value;
|
||||||
}
|
}
|
||||||
@ -73,8 +76,8 @@ namespace Aml.Editor.Plugin
|
|||||||
return "DataGridParameters(" + RefSemantics + "=" + Attributes + "=" + Values + ")";
|
return "DataGridParameters(" + RefSemantics + "=" + Attributes + "=" + Values + ")";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -95,19 +98,19 @@ namespace Aml.Editor.Plugin
|
|||||||
//public string Units { get; set; }
|
//public string Units { get; set; }
|
||||||
|
|
||||||
|
|
||||||
public ElectricalParameters()
|
public ElectricalParameters()
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public ElectricalParameters(string connector, string connectorCode, string connectorType, string pins, string lis)
|
public ElectricalParameters(string connector, string connectorCode, string connectorType,string pins,string lis)
|
||||||
|
|
||||||
{
|
{
|
||||||
this.Connector = connector;
|
this.Connector = connector;
|
||||||
this.ConnectorCode = connectorCode;
|
this.ConnectorCode = connectorCode;
|
||||||
this.ConnectorType = connectorType;
|
this.ConnectorType = connectorType;
|
||||||
this.Pins = pins;
|
this.Pins = pins;
|
||||||
|
|
||||||
}
|
}
|
||||||
//public ElectricalParameters(string referenceID, string attribute, string values, string units, string pins)
|
//public ElectricalParameters(string referenceID, string attribute, string values, string units, string pins)
|
||||||
//{
|
//{
|
||||||
@ -117,19 +120,19 @@ namespace Aml.Editor.Plugin
|
|||||||
// this.Units = units;
|
// this.Units = units;
|
||||||
// this.Pins = pins;
|
// this.Pins = pins;
|
||||||
//}
|
//}
|
||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
|
|
||||||
return "ElectricalParameters(" + Connector + "=" + ConnectorCode + "=" + ConnectorType + "=" + Pins + ")";
|
return "ElectricalParameters(" + Connector + "=" + ConnectorCode + "=" + ConnectorType + "="+Pins+")";
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
//This Class is responsible to hold the parameters in "ElectricalDataDataGrid View"
|
//This Class is responsible to hold the parameters in "ElectricalDataDataGrid View"
|
||||||
|
|
||||||
public class ElectricalParametersInElectricalDataDataGridView
|
public class ElectricalParametersInElectricalDataDataGridView
|
||||||
{
|
{
|
||||||
|
|
||||||
public string ReferenceID { get; set; }
|
public string ReferenceID { get; set; }
|
||||||
public string Attributes { get; set; }
|
public string Attributes { get; set; }
|
||||||
public string Values { get; set; }
|
public string Values { get; set; }
|
||||||
@ -145,11 +148,11 @@ namespace Aml.Editor.Plugin
|
|||||||
this.Attributes = attribute;
|
this.Attributes = attribute;
|
||||||
this.Values = values;
|
this.Values = values;
|
||||||
this.Units = units;
|
this.Units = units;
|
||||||
|
|
||||||
}
|
}
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return "ElectricalParametersInElectricalDataDataGridView(" + ReferenceID + "=" + Attributes + "=" + Values + "=" + Units + ")";
|
return "ElectricalParametersInElectricalDataDataGridView("+ ReferenceID + "=" + Attributes + "=" + Values + "=" + Units + ")";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -165,7 +168,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
public PinParametersInPinInfoDataGridView(string pinNumber, string referenceID, string attribute, string values, string units)
|
public PinParametersInPinInfoDataGridView(string pinNumber,string referenceID, string attribute, string values, string units)
|
||||||
{
|
{
|
||||||
this.PinNumber = pinNumber;
|
this.PinNumber = pinNumber;
|
||||||
this.ReferenceID = referenceID;
|
this.ReferenceID = referenceID;
|
||||||
@ -176,7 +179,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return "PinParametersInPinInfoDataGridView(" + PinNumber + "=" + ReferenceID + "=" + Attributes + "=" + Values + "=" + Units + ")";
|
return "PinParametersInPinInfoDataGridView(" +PinNumber+"="+ ReferenceID + "=" + Attributes + "=" + Values + "=" + Units + ")";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -185,7 +188,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
public string ElementName { get; set; }
|
public string ElementName { get; set; }
|
||||||
public string FilePath { get; set; }
|
public string FilePath { get; set; }
|
||||||
public string AddToFile { get; set; }
|
public string AddToFile { get; set; }
|
||||||
|
|
||||||
public AttachablesDataGridViewParameters()
|
public AttachablesDataGridViewParameters()
|
||||||
{
|
{
|
||||||
@ -199,7 +202,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return "AttachablesDataGridViewParameters(" + ElementName + "=" + FilePath + "=" + AddToFile + ")";
|
return "AttachablesDataGridViewParameters(" + ElementName + "=" + FilePath +"="+ AddToFile + ")";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
<DebugType>full</DebugType>
|
<DebugType>full</DebugType>
|
||||||
<Optimize>false</Optimize>
|
<Optimize>false</Optimize>
|
||||||
<OutputPath>bin\Release\</OutputPath>
|
<OutputPath>..\..\TINF20C_ModellingWizard_Devices\SOURCE\bin\Release\</OutputPath>
|
||||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||||
<ErrorReport>prompt</ErrorReport>
|
<ErrorReport>prompt</ErrorReport>
|
||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
@ -179,7 +179,6 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="DeviceDescription.resx">
|
<EmbeddedResource Include="DeviceDescription.resx">
|
||||||
<DependentUpon>DeviceDescription.cs</DependentUpon>
|
<DependentUpon>DeviceDescription.cs</DependentUpon>
|
||||||
<SubType>Designer</SubType>
|
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Properties\Resources.resx">
|
<EmbeddedResource Include="Properties\Resources.resx">
|
||||||
<Generator>ResXFileCodeGenerator</Generator>
|
<Generator>ResXFileCodeGenerator</Generator>
|
||||||
@ -231,6 +230,15 @@
|
|||||||
</BootstrapperPackage>
|
</BootstrapperPackage>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<COMReference Include="Microsoft.Vbe.Interop.Forms">
|
||||||
|
<Guid>{0D452EE1-E08F-101A-852E-02608C4D0BB4}</Guid>
|
||||||
|
<VersionMajor>2</VersionMajor>
|
||||||
|
<VersionMinor>0</VersionMinor>
|
||||||
|
<Lcid>0</Lcid>
|
||||||
|
<WrapperTool>primary</WrapperTool>
|
||||||
|
<Isolated>False</Isolated>
|
||||||
|
<EmbedInteropTypes>True</EmbedInteropTypes>
|
||||||
|
</COMReference>
|
||||||
<COMReference Include="stdole">
|
<COMReference Include="stdole">
|
||||||
<Guid>{00020430-0000-0000-C000-000000000046}</Guid>
|
<Guid>{00020430-0000-0000-C000-000000000046}</Guid>
|
||||||
<VersionMajor>2</VersionMajor>
|
<VersionMajor>2</VersionMajor>
|
||||||
|
@ -28,8 +28,8 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
public ModellingWizard()
|
public ModellingWizard()
|
||||||
{
|
{
|
||||||
mWController = new MWController();
|
mWController = new MWController(this);
|
||||||
|
|
||||||
// Defines the Command list, which will contain user commands, which a user can select
|
// Defines the Command list, which will contain user commands, which a user can select
|
||||||
// via the PlugIn Menu.
|
// via the PlugIn Menu.
|
||||||
Commands = new List<PluginCommand>();
|
Commands = new List<PluginCommand>();
|
||||||
@ -38,7 +38,7 @@ namespace Aml.Editor.Plugin
|
|||||||
// Every PlugIn needs at least an Activation command, which will be called by a user to activate the PlugIn.
|
// Every PlugIn needs at least an Activation command, which will be called by a user to activate the PlugIn.
|
||||||
ActivatePlugin = new PluginCommand()
|
ActivatePlugin = new PluginCommand()
|
||||||
{
|
{
|
||||||
Command = new RelayCommand<object>(this.StartCommandExecute,
|
Command = new RelayCommand<object>(this.StartCommandExecute,
|
||||||
this.StartCommandCanExecute),
|
this.StartCommandCanExecute),
|
||||||
CommandName = "Start",
|
CommandName = "Start",
|
||||||
CommandToolTip = "Start the PlugIn"
|
CommandToolTip = "Start the PlugIn"
|
||||||
@ -92,7 +92,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
private void ReloadObjectsExecute(object obj)
|
private void ReloadObjectsExecute(object obj)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -105,7 +105,7 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <see cref="StopCommand"/> ).
|
/// <see cref="StopCommand"/> ).
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public event EventHandler PluginTerminated;
|
public event EventHandler PluginTerminated;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The AboutCommand - Command
|
/// The AboutCommand - Command
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -294,7 +294,7 @@ namespace Aml.Editor.Plugin
|
|||||||
/// <param name="selectedObject">The selected object, may be null.</param>
|
/// <param name="selectedObject">The selected object, may be null.</param>
|
||||||
public void PublishAutomationMLFileAndObject(string amlFilePath, CAEXBasicObject selectedObject)
|
public void PublishAutomationMLFileAndObject(string amlFilePath, CAEXBasicObject selectedObject)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -337,7 +337,7 @@ namespace Aml.Editor.Plugin
|
|||||||
private void StartCommandExecute(object parameter)
|
private void StartCommandExecute(object parameter)
|
||||||
{
|
{
|
||||||
this.IsActive = true;
|
this.IsActive = true;
|
||||||
|
|
||||||
// create the new PlugInUI and add it to the forms host
|
// create the new PlugInUI and add it to the forms host
|
||||||
mWController.ChangeGui(MWController.MWGUIType.DeviceDescription);
|
mWController.ChangeGui(MWController.MWGUIType.DeviceDescription);
|
||||||
|
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
using System.Runtime.CompilerServices;
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// Allgemeine Informationen über eine Assembly werden über die folgenden
|
// Allgemeine Informationen über eine Assembly werden über die folgenden
|
||||||
@ -9,7 +10,7 @@ using System.Runtime.InteropServices;
|
|||||||
[assembly: AssemblyConfiguration("")]
|
[assembly: AssemblyConfiguration("")]
|
||||||
[assembly: AssemblyCompany("DHBW-Stuttgart")]
|
[assembly: AssemblyCompany("DHBW-Stuttgart")]
|
||||||
[assembly: AssemblyProduct("ModellingWizard")]
|
[assembly: AssemblyProduct("ModellingWizard")]
|
||||||
[assembly: AssemblyCopyright("Copyright © DHBW-Stuttgart TINF20C")]
|
[assembly: AssemblyCopyright("Copyright © DHBW-Stuttgart TINF19C")]
|
||||||
[assembly: AssemblyTrademark("ModellingWizard")]
|
[assembly: AssemblyTrademark("ModellingWizard")]
|
||||||
[assembly: AssemblyCulture("")]
|
[assembly: AssemblyCulture("")]
|
||||||
|
|
||||||
|
26
SOURCE/Plugin/Properties/Settings.Designer.cs
generated
26
SOURCE/Plugin/Properties/Settings.Designer.cs
generated
@ -1,26 +0,0 @@
|
|||||||
//------------------------------------------------------------------------------
|
|
||||||
// <auto-generated>
|
|
||||||
// Dieser Code wurde von einem Tool generiert.
|
|
||||||
// Laufzeitversion:4.0.30319.42000
|
|
||||||
//
|
|
||||||
// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
|
|
||||||
// der Code erneut generiert wird.
|
|
||||||
// </auto-generated>
|
|
||||||
//------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin.Properties {
|
|
||||||
|
|
||||||
|
|
||||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
|
||||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.10.0.0")]
|
|
||||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
|
||||||
|
|
||||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
|
||||||
|
|
||||||
public static Settings Default {
|
|
||||||
get {
|
|
||||||
return defaultInstance;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,6 +0,0 @@
|
|||||||
<?xml version='1.0' encoding='utf-8'?>
|
|
||||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
|
||||||
<Profiles>
|
|
||||||
<Profile Name="(Default)" />
|
|
||||||
</Profiles>
|
|
||||||
</SettingsFile>
|
|
@ -1,214 +0,0 @@
|
|||||||
# Gsd2Aml.Lib
|
|
||||||
|
|
||||||
Welcome to the Gsd2Aml.Lib! This library was developed as a student project by (in alphabetical order)
|
|
||||||
1. Nico Dietz
|
|
||||||
2. Steffen Gerdes
|
|
||||||
3. Constantin Ruhdorfer
|
|
||||||
4. Jonas Komarek
|
|
||||||
5. Phuc Quang Vu
|
|
||||||
6. Michael Weidmann
|
|
||||||
|
|
||||||
at [Cooperate State University Stuttgart](https://www.dhbw-stuttgart.de/home/).
|
|
||||||
This project is distributed via:
|
|
||||||
1. [GitHub](https://github.com/TINF17C/GSD2AML-Converter)
|
|
||||||
2. [NuGet](https://www.nuget.org/packages/Gsd2Aml.Lib)
|
|
||||||
|
|
||||||
We can be found as a [GitHub Team](https://github.com/orgs/TINF17C/teams/gsd2aml).
|
|
||||||
|
|
||||||
## About this project
|
|
||||||
|
|
||||||
This library converts a Profinet (PN-)GSD file to AutomationML.
|
|
||||||
The library can either
|
|
||||||
1. return a string containing the AutomatonML content.
|
|
||||||
2. convert the GSD file to an .aml file and package that, including all its dependencies, into an .amlx package. This process uses the [AML.Engine](https://www.nuget.org/packages/Aml.Engine).
|
|
||||||
|
|
||||||
## Contributing to this project
|
|
||||||
|
|
||||||
Contributions are always welcome!
|
|
||||||
If you want to contribute feel free to fork this repo and later perform a pull request.
|
|
||||||
|
|
||||||
## File structure
|
|
||||||
|
|
||||||
The relevant files and folders are listed here.
|
|
||||||
|
|
||||||
### Logging/
|
|
||||||
Contains the logging service.
|
|
||||||
|
|
||||||
### Models/
|
|
||||||
Contains the classes representing AML and GSD.
|
|
||||||
Also contains the used XSD files.
|
|
||||||
|
|
||||||
### Properties/
|
|
||||||
Contains the assembly info.
|
|
||||||
|
|
||||||
### Compressor.cs
|
|
||||||
Contains all the logic that is required to:
|
|
||||||
1. Create a temporary folder
|
|
||||||
2. Find files and copy them to this folder
|
|
||||||
3. Uses the AML.Engine to build the .amlx package
|
|
||||||
|
|
||||||
### Converter.cs
|
|
||||||
Contains all the logic that traverses the GSD file and uses the rulesset file to translate the GSD file to AML.
|
|
||||||
|
|
||||||
### Util.cs
|
|
||||||
Contains the utility functionality.
|
|
||||||
|
|
||||||
### gsd2aml.xml
|
|
||||||
This is the rulesset file.
|
|
||||||
Please have a look below.
|
|
||||||
|
|
||||||
## GSD2AML Rules
|
|
||||||
|
|
||||||
The rules for conversion are written in XML and are listed here.
|
|
||||||
|
|
||||||
### Tables of Content
|
|
||||||
|
|
||||||
1. [Structure](#structure)
|
|
||||||
2. [References](#references)
|
|
||||||
3. [Reference Types](#reference_types)
|
|
||||||
4. [GUID](#guid)
|
|
||||||
5. [The Rule Element](#rule_element)
|
|
||||||
|
|
||||||
### <a name="structure"></a>Structure
|
|
||||||
|
|
||||||
This section will explain the structure of a gsd2aml rulesset file.
|
|
||||||
|
|
||||||
The gsd2aml file will consist of one, and only one, element, the `<Body>`. Each seperate rule shall be direct child of this element.
|
|
||||||
|
|
||||||
A rule must start with the GSD element, which is to be replaced. It must have a child `<Replacement>` describing the corresponding XML-structure of the AML replacement.
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<ProfileBody>
|
|
||||||
<Replacement>
|
|
||||||
<SystemUnitClassLib Name="ComponentSystemUnitClassLib">
|
|
||||||
<Version>1.0.0</Version>
|
|
||||||
</SystemUnitClassLib>
|
|
||||||
</Replacement>
|
|
||||||
</ProfileBody>
|
|
||||||
```
|
|
||||||
|
|
||||||
Additionally a rule can also have any number of `<Reference>` childs. References will be explained in the following section.
|
|
||||||
|
|
||||||
### <a name="references"></a>References
|
|
||||||
|
|
||||||
#### <a name="references-normal_references"></a>Normal Reference
|
|
||||||
|
|
||||||
It may not be possible to replace a GSD element with a static replacements. Let's look at this example:
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<SubslotItem SubslotNumber="32768" TextId="TOK_Subslot_8000" />
|
|
||||||
```
|
|
||||||
|
|
||||||
This element has a attribute "SubslotNumber". In order to transform this element to AML the attribute "SubslotNumber" should be converted into an `Attribute`, `<Value>` pair.
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<ExternalInterface Name="" ID="">
|
|
||||||
<Attribute Name="SubslotNumber" AttributeDataType="xs:integer">
|
|
||||||
<Value></Value>
|
|
||||||
</Attribute>
|
|
||||||
</ExternalInterface>
|
|
||||||
```
|
|
||||||
|
|
||||||
Unfortunately the converter itself cannot figure out where this information is located. A referece, signaled by a `$` followed by an identifier like `$1`, is necessary.
|
|
||||||
|
|
||||||
The conversion rule for "SubslotItem" may look like this:
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<SubslotItem>
|
|
||||||
<Replacement>
|
|
||||||
<ExternalInterface Name="" ID="">
|
|
||||||
<Attribute Name="SubslotNumber" AttriubteDataType="xs:integer">
|
|
||||||
<Value>$1<Value>
|
|
||||||
</Attribute>
|
|
||||||
</ExternalInterface>
|
|
||||||
</Replacement>
|
|
||||||
<Reference Ref="$1">
|
|
||||||
<ISO15745Profile.ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SlotList.SlotItem SubslotNumber="" />
|
|
||||||
</Reference>
|
|
||||||
</SubslotItem>
|
|
||||||
```
|
|
||||||
|
|
||||||
Every reference within the replacement element shall have a corresponding reference element. This element must have the attribute `Ref=""` with the identifier. There are different [types](#reference_types) of references. These will be explained later. The content of the reference shall be a the location of the referenced value. A reference only has one child. The child is the full qualified path to the referenced element in a point sepearted list without whitespace.
|
|
||||||
|
|
||||||
The element shall have one attribute, which shall be the same attribute that is being referenced. If the attribute exists, its value will be the return value.
|
|
||||||
|
|
||||||
#### <a name="references-true_references"></a>True Reference
|
|
||||||
|
|
||||||
You may have noticed that the example above never resolved the GSD attribute TextId of the "SubslotItem" element. This is because the TextId attribute in itself is also a reference within the GSD file and as such must be handled differently. To differentiate this case from a normal reference, it shall be named "true reference".
|
|
||||||
|
|
||||||
A true reference within an GSD file will always reference another element within a "List", that has the attribute `ID` or other identifying attribute like `TextId`.
|
|
||||||
|
|
||||||
These references must be handled differently by the GSD2AML Converter. The converter will know of the different "reference lists" (such as `ExternalTextList`) and their location within the GSD. The converter merely needs to know which list to look in and the corresponding id. Therefore each list will receive its own "type" which can be used as an attribute of the reference element. The other way around, this means that the converter __cannot__ handle true references of lists that the converter does not know.
|
|
||||||
|
|
||||||
Consider the example from above. `TextId=TOK_Subslot_8000` signifies that this attribute references an element within a text list with the id `TOK_Subslot_8000`.
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<SubslotItem>
|
|
||||||
<Replacement>
|
|
||||||
<ExternalInterface Name="$1" ID="GUID" RefBaseClassPath="physicalEndPoint/SubSlot">
|
|
||||||
<Attribute Name="SubslotNumber" AttributeDataType="xs:integer">
|
|
||||||
<Value>$2</Value>
|
|
||||||
</Attribute>
|
|
||||||
</ExternalInterface>
|
|
||||||
</Replacement>
|
|
||||||
<Reference Ref="$1" Type="TextRef">
|
|
||||||
<ISO15745Profile.ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SlotList.SlotItem TextId="" />
|
|
||||||
</Reference>
|
|
||||||
<Reference Ref="$2">
|
|
||||||
<ISO15745Profile.ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SlotList.SlotItem SubslotNumber="" />
|
|
||||||
</Reference>
|
|
||||||
</SubslotItem>
|
|
||||||
```
|
|
||||||
|
|
||||||
The type `TextRef` will tell the converter to search under `ExternalTextList/PrimaryLanguage`. The content of a true reference is the location of the corresponding id.
|
|
||||||
|
|
||||||
Other languages will be ignored.
|
|
||||||
|
|
||||||
### <a name="reference_types"></a>Reference Types
|
|
||||||
|
|
||||||
This section will list the different reference types and their uses.
|
|
||||||
|
|
||||||
#### <a name="reference_types-Normal-Ref></a>Normal Ref
|
|
||||||
|
|
||||||
No type is specified. The refernced value will be used.
|
|
||||||
|
|
||||||
#### <a name="reference_types-TextRef"></a>TextRef
|
|
||||||
|
|
||||||
A `TextRef` is a true reference. Within the GSD it will reference an element within `<ExternalTextList>`. As the name suggest it will only return a single text. It will only over use the `<PrimaryLanguage>`. The location of the reference __id__ used in the GSD will be given as content of the reference.
|
|
||||||
|
|
||||||
|
|
||||||
#### <a name="reference_types-graphicref"></a>GraphicRef
|
|
||||||
|
|
||||||
A `GraphicRef` is a true reference. Within the GSD it will reference an element within `GraphicsList`. The location of the reference __id__ used in the GSD will be given as content of the reference.
|
|
||||||
|
|
||||||
#### <a name="special_reference_types"></a>RelGsdFilePath
|
|
||||||
|
|
||||||
`RelGsdFilePath` returns a relative path to the original GSD file.
|
|
||||||
|
|
||||||
### <a name="guid"></a>GUID
|
|
||||||
|
|
||||||
Every time the converters reads the string `GUID`, it will be replaced with a real GUID.
|
|
||||||
|
|
||||||
### <a name="rule_element"></a> The Rule Element
|
|
||||||
|
|
||||||
In order to maintain modularity while also providing a way to define the structure of the result aml in terms of parent-child relationships, a `<Rule></Rule>` element is introduced.
|
|
||||||
|
|
||||||
The content of the `<Rule></Rule>` tag shall be a full a string consisting of the relative path from the parent rule element to the GSD element, which should be placed here.
|
|
||||||
|
|
||||||
That path shall a rule of its own and a child of the `<Body>` element.
|
|
||||||
|
|
||||||
Example:
|
|
||||||
|
|
||||||
```xml
|
|
||||||
<InternalElement CAEXObject.Name="LogicalInterface" CAEXObject.ID="GUID">
|
|
||||||
<SystemUnitClassType.InternalElement>
|
|
||||||
<Rule>
|
|
||||||
ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SystemDefinedSubmoduleList.InterfaceSubmoduleItem
|
|
||||||
</Rule>
|
|
||||||
</SystemUnitClassType.InternalElement>
|
|
||||||
</InternalElement>
|
|
||||||
|
|
||||||
<ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SystemDefinedSubmoduleList.InterfaceSubmoduleItem>
|
|
||||||
...
|
|
||||||
</ProfileBody.ApplicationProcess.DeviceAccessPointList.DeviceAccessPointItem.SystemDefinedSubmoduleList.InterfaceSubmoduleItem>
|
|
||||||
```
|
|
@ -1,6 +1,9 @@
|
|||||||
using Aml.Engine.CAEX;
|
using System;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Aml.Engine.CAEX;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
@ -16,7 +19,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
public SearchAMLComponentFile()
|
public SearchAMLComponentFile()
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CheckForAttributesOfExternalIterface(int i, ExternalInterfaceType externalInterface)
|
public void CheckForAttributesOfExternalIterface(int i, ExternalInterfaceType externalInterface)
|
||||||
@ -27,8 +30,8 @@ namespace Aml.Editor.Plugin
|
|||||||
foreach (var attribute in externalInterface.Attribute)
|
foreach (var attribute in externalInterface.Attribute)
|
||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfExternalIterface(i, attributelist, attribute, externalInterface);
|
StoreEachAttributeValueInListOfExternalIterface(i, attributelist, attribute, externalInterface);
|
||||||
CkeckForNestedAttributesOfExternalIterface(i, attribute, externalInterface);
|
CkeckForNestedAttributesOfExternalIterface(i,attribute, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -40,7 +43,7 @@ namespace Aml.Editor.Plugin
|
|||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (DictionaryofElectricalConnectorType.ContainsKey("(" + i + ")" + externalInterface.Name.ToString() + "{" + "Class:" + " " + externalInterface.BaseClass + "}"))
|
if (DictionaryofElectricalConnectorType.ContainsKey( "("+i+")"+ externalInterface.Name.ToString()+ "{" + "Class:" + " " + externalInterface.BaseClass + "}"))
|
||||||
{
|
{
|
||||||
DictionaryofElectricalConnectorType["(" + i + ")" + externalInterface.Name.ToString()
|
DictionaryofElectricalConnectorType["(" + i + ")" + externalInterface.Name.ToString()
|
||||||
+ "{" + "Class:" + " " + externalInterface.BaseClass + "}"].AddRange(list);
|
+ "{" + "Class:" + " " + externalInterface.BaseClass + "}"].AddRange(list);
|
||||||
@ -60,8 +63,8 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CkeckForNestedAttributesOfExternalIterface(int i, AttributeType attributeType, ExternalInterfaceType externalInterface)
|
public void CkeckForNestedAttributesOfExternalIterface(int i, AttributeType attributeType, ExternalInterfaceType externalInterface)
|
||||||
{
|
{
|
||||||
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
if (attributeType.Attribute.Exists)
|
if (attributeType.Attribute.Exists)
|
||||||
@ -70,8 +73,8 @@ namespace Aml.Editor.Plugin
|
|||||||
foreach (var attributeinattribute in attributeType.Attribute)
|
foreach (var attributeinattribute in attributeType.Attribute)
|
||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfExternalIterface(i, attributelist, attributeinattribute, attributeType, externalInterface);
|
StoreEachAttributeValueInListOfExternalIterface(i, attributelist, attributeinattribute, attributeType, externalInterface);
|
||||||
CkeckForNestedAttributesOfExternalIterface(i, attributeinattribute, externalInterface);
|
CkeckForNestedAttributesOfExternalIterface(i,attributeinattribute, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -113,7 +116,7 @@ namespace Aml.Editor.Plugin
|
|||||||
attributeparameters.CopyRight = attributeType.Copyright;
|
attributeparameters.CopyRight = attributeType.Copyright;
|
||||||
attributeparameters.AttributePath = attributeType.AttributePath;
|
attributeparameters.AttributePath = attributeType.AttributePath;
|
||||||
attributeparameters.RefSemanticList = attributeType.RefSemantic;
|
attributeparameters.RefSemanticList = attributeType.RefSemantic;
|
||||||
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
||||||
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
||||||
attributeparameters.ID = externalInterface.ID;
|
attributeparameters.ID = externalInterface.ID;
|
||||||
|
|
||||||
@ -160,7 +163,7 @@ namespace Aml.Editor.Plugin
|
|||||||
attributeparameters.CopyRight = AttributeInAttribute.Copyright;
|
attributeparameters.CopyRight = AttributeInAttribute.Copyright;
|
||||||
attributeparameters.AttributePath = AttributeInAttribute.AttributePath;
|
attributeparameters.AttributePath = AttributeInAttribute.AttributePath;
|
||||||
attributeparameters.RefSemanticList = AttributeInAttribute.RefSemantic;
|
attributeparameters.RefSemanticList = AttributeInAttribute.RefSemantic;
|
||||||
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
||||||
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
||||||
attributeparameters.ID = externalInterface.ID;
|
attributeparameters.ID = externalInterface.ID;
|
||||||
|
|
||||||
@ -190,7 +193,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfElectricalConnectorPins(i, attributelist, attribute, externalInterface, classType);
|
StoreEachAttributeValueInListOfElectricalConnectorPins(i, attributelist, attribute, externalInterface, classType);
|
||||||
CkeckForNestedAttributesOfElectricalConnectorPins(i, attribute, externalInterface, classType);
|
CkeckForNestedAttributesOfElectricalConnectorPins(i, attribute, externalInterface, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -223,7 +226,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CkeckForNestedAttributesOfElectricalConnectorPins(int i, AttributeType attributeType, ExternalInterfaceType externalInterface, ExternalInterfaceType classType)
|
public void CkeckForNestedAttributesOfElectricalConnectorPins(int i, AttributeType attributeType, ExternalInterfaceType externalInterface, ExternalInterfaceType classType)
|
||||||
{
|
{
|
||||||
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
@ -234,7 +237,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfElectricalConnectorPins(i, attributelist, attributeinattribute, attributeType, externalInterface, classType);
|
StoreEachAttributeValueInListOfElectricalConnectorPins(i, attributelist, attributeinattribute, attributeType, externalInterface, classType);
|
||||||
CkeckForNestedAttributesOfElectricalConnectorPins(i, attributeinattribute, externalInterface, classType);
|
CkeckForNestedAttributesOfElectricalConnectorPins(i, attributeinattribute, externalInterface, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -276,7 +279,7 @@ namespace Aml.Editor.Plugin
|
|||||||
attributeparameters.CopyRight = attributeType.Copyright;
|
attributeparameters.CopyRight = attributeType.Copyright;
|
||||||
attributeparameters.AttributePath = attributeType.AttributePath;
|
attributeparameters.AttributePath = attributeType.AttributePath;
|
||||||
attributeparameters.RefSemanticList = attributeType.RefSemantic;
|
attributeparameters.RefSemanticList = attributeType.RefSemantic;
|
||||||
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
// attributeparameters.ReferencedClassName = externalInterface.BaseClass.ToString();
|
||||||
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
attributeparameters.RefBaseClassPath = externalInterface.RefBaseClassPath;
|
||||||
attributeparameters.ID = externalInterface.ID;
|
attributeparameters.ID = externalInterface.ID;
|
||||||
|
|
||||||
@ -354,7 +357,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfComponent(i, attributelist, attribute, supportedRoleClass, classType);
|
StoreEachAttributeValueInListOfComponent(i, attributelist, attribute, supportedRoleClass, classType);
|
||||||
CkeckForNestedAttributesOfComponent(i, attribute, supportedRoleClass, classType);
|
CkeckForNestedAttributesOfComponent(i, attribute, supportedRoleClass, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -366,7 +369,7 @@ namespace Aml.Editor.Plugin
|
|||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (DictionaryofRolesforAutomationComponenet.ContainsKey("(" + i + ")" + supportedRoleClass.RoleReference.ToString()))
|
if (DictionaryofRolesforAutomationComponenet.ContainsKey("(" + i + ")" + supportedRoleClass.RoleReference.ToString() ))
|
||||||
{
|
{
|
||||||
DictionaryofRolesforAutomationComponenet["(" + i + ")" + supportedRoleClass.RoleReference.ToString()].AddRange(list);
|
DictionaryofRolesforAutomationComponenet["(" + i + ")" + supportedRoleClass.RoleReference.ToString()].AddRange(list);
|
||||||
}
|
}
|
||||||
@ -384,7 +387,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void CkeckForNestedAttributesOfComponent(int i, AttributeType attributeType, SupportedRoleClassType supportedRoleClass, SystemUnitFamilyType classType)
|
public void CkeckForNestedAttributesOfComponent(int i, AttributeType attributeType, SupportedRoleClassType supportedRoleClass, SystemUnitFamilyType classType)
|
||||||
{
|
{
|
||||||
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> attributelist = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
@ -395,7 +398,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfComponent(i, attributelist, attributeinattribute, attributeType, supportedRoleClass, classType);
|
StoreEachAttributeValueInListOfComponent(i, attributelist, attributeinattribute, attributeType, supportedRoleClass, classType);
|
||||||
CkeckForNestedAttributesOfComponent(i, attributeinattribute, supportedRoleClass, classType);
|
CkeckForNestedAttributesOfComponent(i, attributeinattribute, supportedRoleClass, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,18 @@
|
|||||||
using Aml.Engine.CAEX;
|
using System;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
using Aml.Engine.AmlObjects;
|
||||||
|
using Aml.Engine.CAEX;
|
||||||
|
using System.IO;
|
||||||
|
using System.IO.Packaging;
|
||||||
|
using System.Xml;
|
||||||
|
using System.Collections;
|
||||||
|
using System.IO.Compression;
|
||||||
|
using Aml.Editor.Plugin.Contracts;
|
||||||
|
|
||||||
namespace Aml.Editor.Plugin
|
namespace Aml.Editor.Plugin
|
||||||
{
|
{
|
||||||
@ -75,7 +85,7 @@ namespace Aml.Editor.Plugin
|
|||||||
//This method search for "Referenced Class" of "External Interface"
|
//This method search for "Referenced Class" of "External Interface"
|
||||||
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -97,7 +107,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +129,7 @@ namespace Aml.Editor.Plugin
|
|||||||
foreach (var item in classTypeSearchForReferencedClassName.InterfaceClass)
|
foreach (var item in classTypeSearchForReferencedClassName.InterfaceClass)
|
||||||
{
|
{
|
||||||
//If "Refrenced Class Name" is existing...
|
//If "Refrenced Class Name" is existing...
|
||||||
if (item.Name == referencedClassName)
|
if (item.Name == referencedClassName)
|
||||||
{
|
{
|
||||||
//If external Interface is existing....
|
//If external Interface is existing....
|
||||||
if (item.ExternalInterface.Exists)
|
if (item.ExternalInterface.Exists)
|
||||||
@ -134,7 +144,7 @@ namespace Aml.Editor.Plugin
|
|||||||
//This method search for "Referenced Class" of "External Interface"
|
//This method search for "Referenced Class" of "External Interface"
|
||||||
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -149,7 +159,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
//If "Interface Class" inside "Interface Class" is existng....
|
//If "Interface Class" inside "Interface Class" is existng....
|
||||||
if (item.InterfaceClass.Exists)
|
if (item.InterfaceClass.Exists)
|
||||||
{
|
{
|
||||||
//This class is responsible to search for interface classes ´nested inside Interface classes and recursion of
|
//This class is responsible to search for interface classes ´nested inside Interface classes and recursion of
|
||||||
@ -169,7 +179,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
||||||
CkeckForNestedAttributesOfReferencedClassName(attribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(attribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -181,7 +191,7 @@ namespace Aml.Editor.Plugin
|
|||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (DictionaryForInterfaceClassInstancesAttributes.ContainsKey(classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}"))
|
if (DictionaryForInterfaceClassInstancesAttributes.ContainsKey(classType.Name.ToString()+"{"+ "Class:" + " " +classType.ReferencedClassName+"}"))
|
||||||
{
|
{
|
||||||
DictionaryForInterfaceClassInstancesAttributes[classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}"].AddRange(list);
|
DictionaryForInterfaceClassInstancesAttributes[classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}"].AddRange(list);
|
||||||
}
|
}
|
||||||
@ -196,7 +206,7 @@ namespace Aml.Editor.Plugin
|
|||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -210,7 +220,7 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
||||||
CkeckForNestedAttributesOfReferencedClassName(attributeinattribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(attributeinattribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -229,7 +239,7 @@ namespace Aml.Editor.Plugin
|
|||||||
DictionaryForInterfaceClassInstancesAttributes.Add(classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}", list);
|
DictionaryForInterfaceClassInstancesAttributes.Add(classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}", list);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -251,7 +261,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
||||||
//This method is responsible to check nested attributes of "Referenced Class Name"
|
//This method is responsible to check nested attributes of "Referenced Class Name"
|
||||||
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -286,7 +296,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is responsible to check nested attributes of "Referenced Class Name"
|
/// This method is responsible to check nested attributes of "Referenced Class Name"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -307,7 +317,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
||||||
//This method is recursion of it self.
|
//This method is recursion of it self.
|
||||||
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attributeinattribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attributeinattribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -318,7 +328,7 @@ namespace Aml.Editor.Plugin
|
|||||||
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
||||||
|
|
||||||
//Add sublist to list
|
//Add sublist to list
|
||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
//If dictioanry contains key , update the values under the key
|
//If dictioanry contains key , update the values under the key
|
||||||
if (DictionaryForInterfaceClassInstancesAttributes.ContainsKey(classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}"))
|
if (DictionaryForInterfaceClassInstancesAttributes.ContainsKey(classType.Name.ToString() + "{" + "Class:" + " " + classType.ReferencedClassName + "}"))
|
||||||
@ -386,7 +396,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method store nested attributes of each attribute of "Referenced CLASS name" in the dictionary.
|
/// This method store nested attributes of each attribute of "Referenced CLASS name" in the dictionary.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -537,7 +547,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
//This method check for the "Nested Attributes" inside the "Attribute" of "External Interface".
|
//This method check for the "Nested Attributes" inside the "Attribute" of "External Interface".
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -547,7 +557,7 @@ namespace Aml.Editor.Plugin
|
|||||||
//Initiate empty list of "Attributes values".....
|
//Initiate empty list of "Attributes values".....
|
||||||
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
||||||
|
|
||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@ -574,10 +584,10 @@ namespace Aml.Editor.Plugin
|
|||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is responsible to check "Nested ATtributes" of "External Interface's Attribute "
|
/// This method is responsible to check "Nested ATtributes" of "External Interface's Attribute "
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -598,7 +608,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
||||||
//This method is recursion of itself.
|
//This method is recursion of itself.
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attributeinattribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attributeinattribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -609,12 +619,12 @@ namespace Aml.Editor.Plugin
|
|||||||
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
List<List<ClassOfListsFromReferencefile>> list = new List<List<ClassOfListsFromReferencefile>>();
|
||||||
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
||||||
|
|
||||||
//Add sub list to list
|
//Add sub list to list
|
||||||
list.Add(sublist);
|
list.Add(sublist);
|
||||||
|
|
||||||
//IF dictionary is having the key, the update the values for the key.
|
//IF dictionary is having the key, the update the values for the key.
|
||||||
if (DictionaryForExternalInterfacesInstanceAttributesofInterfaceClassLib.ContainsKey(classType.Name.ToString()
|
if (DictionaryForExternalInterfacesInstanceAttributesofInterfaceClassLib.ContainsKey(classType.Name.ToString()
|
||||||
+ "{" + "Class:" + " " + classType.ReferencedClassName + "}" + externalInterface.Name.ToString()
|
+ "{" + "Class:" + " " + classType.ReferencedClassName + "}" + externalInterface.Name.ToString()
|
||||||
+ "{" + "Class:" + " " + externalInterface.BaseClass + "}"))
|
+ "{" + "Class:" + " " + externalInterface.BaseClass + "}"))
|
||||||
{
|
{
|
||||||
DictionaryForExternalInterfacesInstanceAttributesofInterfaceClassLib[classType.Name.ToString()
|
DictionaryForExternalInterfacesInstanceAttributesofInterfaceClassLib[classType.Name.ToString()
|
||||||
@ -653,7 +663,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, classType, attribute, externalInterface);
|
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, classType, attribute, externalInterface);
|
||||||
// This method is responsible to check the "Nested Attributes" of "Attributes" of"Interface Class's External interafce"
|
// This method is responsible to check the "Nested Attributes" of "Attributes" of"Interface Class's External interafce"
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -693,7 +703,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is responsible to check the "Nested Attributes" of "Attributes" of"Interface Class's External interafce"
|
/// This method is responsible to check the "Nested Attributes" of "Attributes" of"Interface Class's External interafce"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -715,7 +725,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
||||||
//This method is the recursion of itself....
|
//This method is the recursion of itself....
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attributeinattribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attributeinattribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -804,7 +814,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method stores "Attributes" of "Referenced Class's External Interface"
|
/// This method stores "Attributes" of "Referenced Class's External Interface"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -898,7 +908,7 @@ namespace Aml.Editor.Plugin
|
|||||||
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
||||||
// This function is responsible to search for "Attributes" inside the "Referencd Class Name" of "eXTERNAL iNTERFACE"
|
// This function is responsible to search for "Attributes" inside the "Referencd Class Name" of "eXTERNAL iNTERFACE"
|
||||||
CheckForAttributesOfReferencedClassNameofExternalIterface(classType, externalInterface);
|
CheckForAttributesOfReferencedClassNameofExternalIterface(classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -926,7 +936,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is responsible for checking "Attributes" under "Referenced Class Name"
|
/// This method is responsible for checking "Attributes" under "Referenced Class Name"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -946,7 +956,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
||||||
//This function check for nested attributes in the attributes of "Refernced Class Name"
|
//This function check for nested attributes in the attributes of "Refernced Class Name"
|
||||||
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -980,7 +990,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method check for nested attributes under attributes of "Referenced Class Name"
|
/// This method check for nested attributes under attributes of "Referenced Class Name"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1001,7 +1011,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
||||||
//This method is recursion of itself
|
//This method is recursion of itself
|
||||||
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attributeinattribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(classTypeSearchForReferencedClassName, attributeinattribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1039,7 +1049,7 @@ namespace Aml.Editor.Plugin
|
|||||||
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
||||||
ClassOfListsFromReferencefile attributeparameters = new ClassOfListsFromReferencefile();
|
ClassOfListsFromReferencefile attributeparameters = new ClassOfListsFromReferencefile();
|
||||||
|
|
||||||
//Store every parameter value....
|
//Store every parameter value....
|
||||||
|
|
||||||
attributeparameters.Name = attributeType.Name;
|
attributeparameters.Name = attributeType.Name;
|
||||||
attributeparameters.Value = attributeType.Value;
|
attributeparameters.Value = attributeType.Value;
|
||||||
@ -1098,8 +1108,8 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
// In the following parameters on right hand side "attributeType" has been changed to "AttributeInAttribute" this has been repeated to all
|
// In the following parameters on right hand side "attributeType" has been changed to "AttributeInAttribute" this has been repeated to all
|
||||||
// methods of name "StoreEachAttributeValuesInList" with four parameters.
|
// methods of name "StoreEachAttributeValuesInList" with four parameters.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
attributeparameters.Name = AttributeInAttribute.Name;
|
attributeparameters.Name = AttributeInAttribute.Name;
|
||||||
attributeparameters.Value = AttributeInAttribute.Value;
|
attributeparameters.Value = AttributeInAttribute.Value;
|
||||||
@ -1152,7 +1162,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
// This method look for nested attributes.
|
// This method look for nested attributes.
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1192,7 +1202,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This function is responsible for checking "nested attributes" under "attributes" of the "External Interface"
|
/// This function is responsible for checking "nested attributes" under "attributes" of the "External Interface"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1213,7 +1223,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
StoreEachAttributeValueInListOfReferencedClassNameofExternalIterface(attributelist, attributeinattribute, classType, attributeType, externalInterface);
|
||||||
// This method allows tocheck for nested attribute inside attributes i.e. recursion of this own method.
|
// This method allows tocheck for nested attribute inside attributes i.e. recursion of this own method.
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attributeinattribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(attributeinattribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1268,7 +1278,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
// This method looks for "nested attributes" under each "attribute"
|
// This method looks for "nested attributes" under each "attribute"
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1335,7 +1345,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
//Do recursion of this method untill the nested attributes were ended
|
//Do recursion of this method untill the nested attributes were ended
|
||||||
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attributeinattribute, classType, externalInterface);
|
CkeckForNestedAttributesOfReferencedClassNameofExternalIterface(classTypeSearchForReferencedClassName, attributeinattribute, classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1383,7 +1393,7 @@ namespace Aml.Editor.Plugin
|
|||||||
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
List<ClassOfListsFromReferencefile> sublist = new List<ClassOfListsFromReferencefile>();
|
||||||
ClassOfListsFromReferencefile attributeparameters = new ClassOfListsFromReferencefile();
|
ClassOfListsFromReferencefile attributeparameters = new ClassOfListsFromReferencefile();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
attributeparameters.Name = attributeType.Name;
|
attributeparameters.Name = attributeType.Name;
|
||||||
attributeparameters.Value = attributeType.Value;
|
attributeparameters.Value = attributeType.Value;
|
||||||
@ -1430,7 +1440,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method stores the nested attributes in "DictionaryForExternalInterfacesInstancesAttributesOfRoleClassLib"
|
/// This method stores the nested attributes in "DictionaryForExternalInterfacesInstancesAttributesOfRoleClassLib"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1449,7 +1459,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
// In the following parameters on right hand side "attributeType" has been changed to "AttributeInAttribute" this has been repeated to all
|
// In the following parameters on right hand side "attributeType" has been changed to "AttributeInAttribute" this has been repeated to all
|
||||||
// methods of name "StoreEachAttributeValuesInList" with four parameters.
|
// methods of name "StoreEachAttributeValuesInList" with four parameters.
|
||||||
|
|
||||||
|
|
||||||
attributeparameters.Name = AttributeInAttribute.Name;
|
attributeparameters.Name = AttributeInAttribute.Name;
|
||||||
attributeparameters.Value = AttributeInAttribute.Value;
|
attributeparameters.Value = AttributeInAttribute.Value;
|
||||||
@ -1567,7 +1577,7 @@ namespace Aml.Editor.Plugin
|
|||||||
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
SearchForReferencedClassNameofExternalIterface(doc, referencedClassName, classType, externalInterface);
|
||||||
//This Function is responsible to search attributes under the "Referenced Classs Name" i.e. in this part "RoleFamilyType"
|
//This Function is responsible to search attributes under the "Referenced Classs Name" i.e. in this part "RoleFamilyType"
|
||||||
CheckForAttributesOfReferencedClassNameofExternalIterface(classType, externalInterface);
|
CheckForAttributesOfReferencedClassNameofExternalIterface(classType, externalInterface);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1634,7 +1644,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is responsible for checking attributes under "Referenced Class Name"
|
/// This method is responsible for checking attributes under "Referenced Class Name"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1653,7 +1663,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, classType, attribute);
|
||||||
//This function check for nested attributes of referenced Class Name.
|
//This function check for nested attributes of referenced Class Name.
|
||||||
CkeckForNestedAttributesOfReferencedClassName(attribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(attribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1687,7 +1697,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method check for "nested attributes" of "referenced class name"
|
/// This method check for "nested attributes" of "referenced class name"
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1707,7 +1717,7 @@ namespace Aml.Editor.Plugin
|
|||||||
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
StoreEachAttributeValueInListOfReferencedClassName(attributelist, attributeinattribute, classType, attributeType);
|
||||||
//This method is recursion of itself...
|
//This method is recursion of itself...
|
||||||
CkeckForNestedAttributesOfReferencedClassName(attributeinattribute, classType);
|
CkeckForNestedAttributesOfReferencedClassName(attributeinattribute, classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1752,20 +1762,20 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
//This method is responsible for checking attributes under "Referenced Class Name"
|
//This method is responsible for checking attributes under "Referenced Class Name"
|
||||||
CheckForAttributesOfReferencedClassName(classType);
|
CheckForAttributesOfReferencedClassName(classType);
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString(), 1);
|
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString(), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (item.ExternalInterface.Exists)
|
if (item.ExternalInterface.Exists)
|
||||||
{
|
{
|
||||||
foreach (var externalinterfaces in item.ExternalInterface)
|
foreach (var externalinterfaces in item.ExternalInterface)
|
||||||
{
|
{
|
||||||
TreeNode externalinterafcenode;
|
TreeNode externalinterafcenode;
|
||||||
if (externalinterfaces.BaseClass != null && externalinterfaces.BaseClass.ToString() != externalinterfaces.Name.ToString())
|
if (externalinterfaces.BaseClass != null && externalinterfaces.BaseClass.ToString() != externalinterfaces.Name.ToString() )
|
||||||
{
|
{
|
||||||
referencedClassName = externalinterfaces.BaseClass.ToString();
|
referencedClassName = externalinterfaces.BaseClass.ToString();
|
||||||
externalinterafcenode = newnode.Nodes.Add(externalinterfaces.ToString(), externalinterfaces.ToString() + "{" + "Class:" + " " + referencedClassName + "}", 2);
|
externalinterafcenode = newnode.Nodes.Add(externalinterfaces.ToString(), externalinterfaces.ToString() + "{" + "Class:" + " " + referencedClassName + "}", 2);
|
||||||
@ -1776,7 +1786,7 @@ namespace Aml.Editor.Plugin
|
|||||||
|
|
||||||
//This Function is responsible to search attributes under the "Referenced Classs Name" i.e. in this part "RoleFamilyType"
|
//This Function is responsible to search attributes under the "Referenced Classs Name" i.e. in this part "RoleFamilyType"
|
||||||
CheckForAttributesOfReferencedClassNameofExternalIterface(item, externalinterfaces);
|
CheckForAttributesOfReferencedClassNameofExternalIterface(item, externalinterfaces);
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -1806,7 +1816,7 @@ namespace Aml.Editor.Plugin
|
|||||||
TreeNode newnode;
|
TreeNode newnode;
|
||||||
if (item.ReferencedClassName != "")
|
if (item.ReferencedClassName != "")
|
||||||
{
|
{
|
||||||
|
|
||||||
referencedclassName = item.ReferencedClassName;
|
referencedclassName = item.ReferencedClassName;
|
||||||
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString() + "{" + "Class:" + " " + referencedclassName + "}", 1);
|
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString() + "{" + "Class:" + " " + referencedclassName + "}", 1);
|
||||||
CheckForAttributesOfReferencedClassName(item);
|
CheckForAttributesOfReferencedClassName(item);
|
||||||
@ -1825,9 +1835,9 @@ namespace Aml.Editor.Plugin
|
|||||||
foreach (var externalinterfaces in item.ExternalInterface)
|
foreach (var externalinterfaces in item.ExternalInterface)
|
||||||
{
|
{
|
||||||
TreeNode externalinterafcenode;
|
TreeNode externalinterafcenode;
|
||||||
if (externalinterfaces.BaseClass != null)
|
if (externalinterfaces.BaseClass!= null)
|
||||||
{
|
{
|
||||||
|
|
||||||
referencedclassName = externalinterfaces.BaseClass.ToString();
|
referencedclassName = externalinterfaces.BaseClass.ToString();
|
||||||
externalinterafcenode = newnode.Nodes.Add(externalinterfaces.ToString(), externalinterfaces.ToString() + "{" + "Class:" + " " + referencedclassName + "}", 2);
|
externalinterafcenode = newnode.Nodes.Add(externalinterfaces.ToString(), externalinterfaces.ToString() + "{" + "Class:" + " " + referencedclassName + "}", 2);
|
||||||
externalinterafcenode.ForeColor = SystemColors.GrayText;
|
externalinterafcenode.ForeColor = SystemColors.GrayText;
|
||||||
@ -1842,7 +1852,7 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
PrintExternalInterfaceNodes(document, externalinterafcenode, externalinterfaces, classType);
|
PrintExternalInterfaceNodes(document,externalinterafcenode, externalinterfaces, classType);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1855,15 +1865,15 @@ namespace Aml.Editor.Plugin
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="oParentNode"></param>
|
/// <param name="oParentNode"></param>
|
||||||
/// <param name="classType"></param>
|
/// <param name="classType"></param>
|
||||||
public void PrintExternalInterfaceNodes(CAEXDocument document, TreeNode oParentNode, ExternalInterfaceType classType, InterfaceFamilyType InterafceclassType)
|
public void PrintExternalInterfaceNodes(CAEXDocument document,TreeNode oParentNode, ExternalInterfaceType classType, InterfaceFamilyType InterafceclassType)
|
||||||
{
|
{
|
||||||
if (classType.ExternalInterface.Exists)
|
if (classType.ExternalInterface.Exists)
|
||||||
{
|
{
|
||||||
|
|
||||||
foreach (var item in classType.ExternalInterface)
|
foreach (var item in classType.ExternalInterface)
|
||||||
{
|
{
|
||||||
TreeNode newnode;
|
TreeNode newnode;
|
||||||
if (item.BaseClass != null)
|
if (item.BaseClass!= null)
|
||||||
{
|
{
|
||||||
referencedClassName = item.BaseClass.ToString();
|
referencedClassName = item.BaseClass.ToString();
|
||||||
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString() + "{" + "Class:" + " " + referencedClassName + "}", 2);
|
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString() + "{" + "Class:" + " " + referencedClassName + "}", 2);
|
||||||
@ -1873,17 +1883,17 @@ namespace Aml.Editor.Plugin
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString(), 2);
|
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString() , 2);
|
||||||
newnode.ForeColor = SystemColors.GrayText;
|
newnode.ForeColor = SystemColors.GrayText;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
PrintExternalInterfaceNodes(document, newnode, item, InterafceclassType);
|
PrintExternalInterfaceNodes(document, newnode, item, InterafceclassType);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// This method is called to print "External Interfaces" in both "Role class Library and Interface Class Library" in the plugin.
|
/// This method is called to print "External Interfaces" in both "Role class Library and Interface Class Library" in the plugin.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -1897,7 +1907,7 @@ namespace Aml.Editor.Plugin
|
|||||||
foreach (var item in classType.ExternalInterface)
|
foreach (var item in classType.ExternalInterface)
|
||||||
{
|
{
|
||||||
TreeNode newnode;
|
TreeNode newnode;
|
||||||
|
|
||||||
|
|
||||||
if (item.BaseClass != null)
|
if (item.BaseClass != null)
|
||||||
{
|
{
|
||||||
@ -1915,9 +1925,9 @@ namespace Aml.Editor.Plugin
|
|||||||
{
|
{
|
||||||
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString(), 2);
|
newnode = oParentNode.Nodes.Add(item.ToString(), item.ToString(), 2);
|
||||||
newnode.ForeColor = SystemColors.GrayText;
|
newnode.ForeColor = SystemColors.GrayText;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//This is a recursion of this method itself...
|
//This is a recursion of this method itself...
|
||||||
PrintExternalInterfaceNodes(document, newnode, item, RoleclassType);
|
PrintExternalInterfaceNodes(document, newnode, item, RoleclassType);
|
||||||
}
|
}
|
||||||
|
@ -10,5 +10,3 @@ Um Änderungen an der Anwendung vorzunehmen muss zuerst Visual Studio 2019 insta
|
|||||||
In Visual Studio 2019 muss dann die Datei `Application.sln` aus dem `Application`-Ordner geöffnet werden.
|
In Visual Studio 2019 muss dann die Datei `Application.sln` aus dem `Application`-Ordner geöffnet werden.
|
||||||
|
|
||||||
In der Projektmappen-Ansicht ist dann zum einen die Applikation als auch das Plugin (ModellingWizard) zu sehen.
|
In der Projektmappen-Ansicht ist dann zum einen die Applikation als auch das Plugin (ModellingWizard) zu sehen.
|
||||||
|
|
||||||
Um die Anwendung kompilieren zu können, muss über den NuGet-Paketmanager eventuel noch das `AML.Engine`-Paket in der Version 1.5.8 installiert werden.
|
|
||||||
|
Loading…
Reference in New Issue
Block a user