Merge branch 'develop' into KVARA

This commit is contained in:
Samuele Locatelli
2020-04-03 17:29:49 +02:00
166 changed files with 167203 additions and 38368 deletions
+25
View File
@@ -10,6 +10,31 @@ TestResults
Tests.VisualState.xml
TestResult.xml
*\.vs
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
build/
bld/
[Bb]in/
[Oo]bj/
# Visual Studio 2015 cache/options directory
.vs/
# # NuGet Packages
# *.nupkg
# # The packages folder can be ignored because of Package Restore
# **/packages/*
# # except build/, which is used as an MSBuild target.
# !**/packages/build/
# # Uncomment if necessary however generally it will be regenerated when needed
# #!**/packages/repositories.config
#MTC_Adapter/\.vs/MTC_Adapter/v15/sqlite3/storage\.ide
# -----------------------------------------------
+3
View File
@@ -0,0 +1,3 @@
{
"workbench.colorCustomizations": {}
}
+38
View File
@@ -0,0 +1,38 @@
Devices = ../DATA/CONF/Agent_ItemList.xml
AllowPut = true
ReconnectInterval = 1000
BufferSize = 17
SchemaVersion = 1.3
Adapters {
MTC-ADAPTER {
Host = localhost
Port = 7878
}
}
Files {
schemas {
Path = ../schemas
Location = /schemas/
}
styles {
Path = ../styles
Location = /styles/
}
Favicon {
Path = ../styles/favicon.ico
Location = /favicon.ico
}
}
StreamsStyle {
Location = /styles/Streams.xsl
}
# Logger Configuration
logger_config
{
logging_level = debug
output = cout
}
Binary file not shown.
File diff suppressed because it is too large Load Diff
+31
View File
@@ -0,0 +1,31 @@
@echo off
REM variabili accessorie
set baseDir="C:\CMS\MTC\AGENT\bin\"
REM calcolo timestamp x creare folders
for /f "delims=" %%a in ('wmic OS Get localdatetime ^| find "."') do set dt=%%a
set YYYY=%dt:~0,4%
set MM=%dt:~4,2%
set DD=%dt:~6,2%
set HH=%dt:~8,2%
set Min=%dt:~10,2%
set Sec=%dt:~12,2%
set stamp=%YYYY%%MM%%DD%_%HH%%Min%%Sec%
REM Fermo servizio
net stop "MTConnect Agent"
REM Attesa 3 secondi post stop
timeout /t 3
REM spostamento di tutti i files di log
mkdir "%baseDir%\logs\%stamp%"
move "%baseDir%\agent*.log" "%baseDir%\logs\%stamp%"
REM riavvio servizio
net start "MTConnect Agent"
REM log riavvio
echo %date% %time% - Service Restarted Successfully >> "%baseDir%\restart.log"
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 99 KiB

BIN
View File
Binary file not shown.
Vendored
+29 -22
View File
@@ -15,9 +15,9 @@ pipeline {
/* calcolo numero versione... diverso x branch MASTER/DEVELOP */
script {
withEnv(['NEXT_BUILD_NUMBER=293']) {
// env.versionNumber = VersionNumber(versionNumberString : '2.0.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true)
env.versionNumber = VersionNumber(versionNumberString : '2.0.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
withEnv(['NEXT_BUILD_NUMBER=460']) {
// env.versionNumber = VersionNumber(versionNumberString : '2.2.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true)
env.versionNumber = VersionNumber(versionNumberString : '2.2.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}')
env.APP_NAME = 'SCMA'
}
}
@@ -31,7 +31,7 @@ pipeline {
}
}
// CAMBIO numero versione + checkout NuGet in file sorgente!!!
bat "e:\\fart.exe VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\fart.exe ${WORKSPACE}\\MTC_Adapter\\VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\nuget.exe restore ${WORKSPACE}\\MTC_Adapter\\SCMA.sln"
}
}
@@ -41,7 +41,7 @@ pipeline {
script {
properties([buildDiscarder(logRotator(artifactDaysToKeepStr: '180', artifactNumToKeepStr: '30', daysToKeepStr: '360', numToKeepStr: '30')), pipelineTriggers([])])
// CAMBIO numero versione + checkout NuGet in file sorgente!!!
bat "e:\\fart.exe VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\fart.exe ${WORKSPACE}\\MTC_Adapter\\VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\nuget.exe restore ${WORKSPACE}\\MTC_Adapter\\SCMA.sln"
}
script {
@@ -70,7 +70,7 @@ pipeline {
// in primis fix versione e recupero pacchetti...
script {
// CAMBIO numero versione + checkout NuGet in file sorgente!!!
bat "e:\\fart.exe VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\fart.exe ${WORKSPACE}\\MTC_Adapter\\VersGen\\VersGen.cs 1.0.0.0 ${env.versionNumber} || EXIT /B 0"
bat "e:\\nuget.exe restore ${WORKSPACE}\\MTC_Adapter\\SCMA.sln"
}
// poi compilo
@@ -105,12 +105,8 @@ pipeline {
else {
env.currConfig='Release'
}
// Build adapters MTC/OPC-UA-RED
bat "\"${tool 'MSBuild-15.0'}\" MTC_Adapter/SCMA/SCMA.csproj -target:Build /p:FS30D=1 /p:SIEMENS=1 /p:Configuration=${env.currConfig} /p:DebugSymbols=false /p:DebugType=None /p:OutputPath=bin/${env.versionNumber} /m"
// // Build adapters VERI
// // bat "\"${tool 'MSBuild-15.0'}\" MTC_Adapter/SCMA/SCMA.csproj -target:Build /p:FS30D=1 /p:SIEMENS=1 /p:Configuration=Release /p:Platform=\"Any CPU\" /p:OutputPath=bin/${env.versionNumber} /m"
// // bat "\"${tool 'MSBuild-15.0'}\" MTC_Adapter/SCMA/SCMA.csproj -target:Build /p:DefineConstants=\"FS30D=1,SIEMENS=1\" /p:Configuration=Release /p:Platform=\"Any CPU\" /p:OutputPath=bin/${env.versionNumber} /m"
// // bat "\"${tool 'MSBuild-15.0'}\" MTC_Adapter/SCMA/SCMA.csproj -target:Build /p:FS30D=1 /p:SIEMENS=1 /p:Configuration=${env.BRANCH_NAME} /p:VisualStudioVersion=15.0 /p:RunCodeAnalysis=false /p:Platform=\"Any CPU\" /p:DebugSymbols=false /p:DebugType=None /p:OutputPath=bin/${env.versionNumber} /m"
}
}
}
@@ -143,7 +139,7 @@ pipeline {
bat "e:\\7za.exe a -tzip ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\SCMA.zip ${WORKSPACE}\\MTC_Adapter\\MTC-ADB\\bin\\${env.versionNumber}\\*"
}
else {
// Compressione in .zip dell'installer x adapter MTC-OPC-UA-RED...
// Compressione in .zip dell'installer x adapter MTC/OPC-UA-RED...
bat "e:\\7za.exe a -tzip ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\SCMA.zip ${WORKSPACE}\\MTC_Adapter\\SCMA\\bin\\${env.versionNumber}\\*"
}
@@ -158,13 +154,13 @@ pipeline {
}
post {
success {
sendEmail("Successful")
sendSlack("Successful", "good")
}
failure {
sendEmail("Failed")
sendSlack("Failed", "danger")
}
unstable {
sendEmail("Unstable")
sendSlack("Unstable", "warning")
}
}
}
@@ -214,10 +210,21 @@ def getChangeString() {
}
return changeString
}
// Funzione x invio email
def sendEmail(status) {
mail (
to: "$EMAIL_RECIPIENTS",
subject: "Build $BUILD_NUMBER - " + status + " ($JOB_NAME)",
body: "Modifiche:\n " + getChangeString() + "\n\n Verifica console output: $BUILD_URL/console" + "\n")
}
// // Funzione x invio email
// def sendEmail(status) {
// mail (
// to: "$EMAIL_RECIPIENTS",
// subject: "Build $BUILD_NUMBER - " + status + " ($JOB_NAME)",
// body: "Modifiche:\n " + getChangeString() + "\n\n Verifica console output: $BUILD_URL/console" + "\n")
// }
// Funzione x invio slack
def sendSlack(status, colorCode) {
slackSend (
color: colorCode,
channel: "#scma-dev",
failOnError: false,
message: "${env.JOB_NAME} ${env.versionNumber} | " + status + ": Build ${env.BUILD_NUMBER}\n\n" +
"Modifiche:\n " + getChangeString() + "\n\n Verifica build: <${env.BUILD_URL}|Apri>" + "\n"
)
}
+110 -34
View File
@@ -1076,6 +1076,23 @@ Namespace CNC
Return bRet
End Function
''' <summary>
''' Legge o scrive Parametri Interi
''' </summary>
''' <param name="bWrite">Se True SCRIVE, se False LEGGE</param>
''' <param name="MemIndex">Indice di memoria</param>
''' <param name="Size">1 byte, 2 word, 3 dword</param>
''' <param name="Value">Valore da scrivere su scrittura o letto su lettura</param>
''' <returns>True se andata a buon fine</returns>
Public Overloads Function F_RW_ParamAllAxis_Integer(ByVal bWrite As Boolean, ByVal MemIndex As Integer, ByVal Size As Integer, ByRef Value As Object) As Boolean
Dim bRet As Boolean
Dim oValue(0) As Object
If bWrite Then oValue(0) = Value
bRet = F_RW_Param_Integer(bWrite, -1, MemIndex, Size, oValue)
If Not bWrite Then Value = oValue(0)
Return bRet
End Function
''' <summary>
@@ -1495,19 +1512,29 @@ Namespace CNC
#Region "Funzioni specifiche IOT"
Public Function getAllAxisPos() As Focas1.ODBPOS
''' <summary>
''' GCodes del path CORRENTE tipo MODALI (se nPAthIdx = 0 --> usa PATH ATTIVO)
'''
''' Optional nPathIdx As Integer = 0
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' <returns></returns>
Public Function getAllAxisPos(nPathIdx As Integer) As Focas1.ODBPOS
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Position\cnc_rdposition.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
Dim posizAssi As Focas1.ODBPOS
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1521,22 +1548,32 @@ Namespace CNC
End If
End If
' resize in base al num di assi...
Return posizAssi
End Function
Public Function getAllAxisLoad() As Focas1.ODBSVLOAD
''' <summary>
''' GCodes del path CORRENTE tipo MODALI (se nPAthIdx = 0 --> usa PATH ATTIVO)
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' <returns></returns>
Public Function getAllAxisLoad(nPathIdx As Integer) As Focas1.ODBSVLOAD
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Position\cnc_rdsvmeter.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
Dim caricoAssi As Focas1.ODBSVLOAD
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1617,11 +1654,11 @@ Namespace CNC
End Function
Public Function getAllDynData() As Focas1.ODBDY2_1
Public Function getAllDynData(Optional nPathIdx As Integer = 0) As Focas1.ODBDY2_1
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Position\cnc_rddynamic2.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
@@ -1629,8 +1666,12 @@ Namespace CNC
' inizializzo
allData = New Focas1.ODBDY2_1
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1690,12 +1731,16 @@ Namespace CNC
Return allData
End Function
Public Function getPathGCodeMod() As Focas1.ODBGCD
''' <summary>
''' GCodes del path CORRENTE tipo MODALI (se nPAthIdx = 0 --> usa PATH ATTIVO)
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' <returns></returns>
Public Function getPathGCodeMod(Optional nPathIdx As Integer = 0) As Focas1.ODBGCD
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Misc\cnc_rdgcode.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
@@ -1703,8 +1748,12 @@ Namespace CNC
' inizializzo
actGCode = New Focas1.ODBGCD
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1721,12 +1770,17 @@ Namespace CNC
Return actGCode
End Function
Public Function getPathGCode1Shot() As Focas1.ODBGCD
''' <summary>
''' GCodes del path CORRENTE tipo 1 shot (se nPAthIdx = 0 --> usa PATH ATTIVO)
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' </summary>
''' <returns></returns>
Public Function getPathGCode1Shot(Optional nPathIdx As Integer = 0) As Focas1.ODBGCD
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Misc\cnc_rdgcode.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
@@ -1734,8 +1788,12 @@ Namespace CNC
' inizializzo
actGCode = New Focas1.ODBGCD
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1752,12 +1810,17 @@ Namespace CNC
Return actGCode
End Function
Public Function getPathTTCoord() As Focas1.ODB5AXMAN
''' <summary>
''' Coordinate di lavoro (punta utensile) del path CORRENTE (se nPAthIdx = 0 --> usa PATH ATTIVO)
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' </summary>
''' <returns></returns>
Public Function getPathTTCoord(Optional nPathIdx As Integer = 0) As Focas1.ODB5AXMAN
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Position\cnc_rd5axmandt.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
@@ -1765,8 +1828,12 @@ Namespace CNC
' inizializzo
ttCoord = New Focas1.ODB5AXMAN
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1783,19 +1850,28 @@ Namespace CNC
Return ttCoord
End Function
Public Function getSpindleSpeed() As Focas1.ODBSPEED
''' <summary>
''' Velocità mandrino del path CORRENTE (se nPAthIdx = 0 --> usa PATH ATTIVO)
''' </summary>
''' <param name="nPathIdx">NumPath 1..n, se 0 = PATH ATTIVO</param>
''' </summary>
''' <returns></returns>
Public Function getSpindleSpeed(Optional nPathIdx As Integer = 0) As Focas1.ODBSPEED
' RIFERIMENTO:
' C:\Users\samuele\Documents\FOCAS A02B-0207-K737_04.20\Document\SpecE\Position\cnc_rdspeed.htm
Dim nPathIdx As Integer
'Dim nPathIdx As Integer
Dim nNumAxisRead As Integer
Dim nReturn As Integer
Dim speedAssi As Focas1.ODBSPEED
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
' se fosse 0 --> leggo path attivo...
If (nPathIdx = 0) Then
'leggo il numero del processo attivo
nPathIdx = GetActivePath()
End If
'leggo num max assi dal cn
nNumAxisRead = Focas1.MAX_AXIS
@@ -1060,10 +1060,12 @@ Namespace CNC
' txt Giuseppe
ReDim itemRead(4)
itemRead(0) = New Item("DB241.DBD0:[16]") 'Posizione attuale
'itemRead(0) = New Item("DB241.DBD0:[16]") 'Posizione attuale
itemRead(0) = New Item("/Channel/GeometricAxis/actToolEdgeCenterPos[u1,1,16]") 'Posizione attuale
itemRead(1) = New Item("/Channel/MachineAxis/actFeedRate[u1,1,16]") ' param manual NC, pg21 legge la feed... da salvare in valore assolulto...
itemRead(2) = New Item("/Channel/MachineAxis/feedRateOvr[u1,1,16]") ' param manual NC, pg215 legge la feedOver...
itemRead(3) = New Item("/Channel/MachineAxis/toolBaseDistToGo[u1,1,16]")
itemRead(2) = New Item("/Channel/MachineAxis/feedRateOvr[u1,1,16]") ' param manual NC, pg215 legge la feedOver...
'itemRead(3) = New Item("/Channel/MachineAxis/toolBaseDistToGo[u1,1,16]") ' posizione tgt...
itemRead(3) = New Item("/Channel/GeometricAxis/cmdProgPos[u1,1,16]") ' posizione tgt...
itemRead(4) = New Item("/Channel/MachineAxis/aaLoad[u1,1,16]") ' param manual NC, pg426 legge carico effettivo asse PRIFIdrive in %... da sempre zero
'/Channel/MachineAxis/speedOvr[u1,1,16] speed override asse NON VA - errore-eccezione
@@ -1088,8 +1090,8 @@ Namespace CNC
' faccio copia valori!
For i As Integer = 0 To 15
'datiAssi(i).PosAct = itemRead(0).Value(i)
datiAssi(i).PosAct = UIntegerToSingle(itemRead(0).Value(i))
'datiAssi(i).PosAct = UIntegerToSingle(itemRead(0).Value(i))
datiAssi(i).PosAct = Convert.ToSingle(itemRead(0).Value(i))
datiAssi(i).Feed = Math.Abs(Convert.ToSingle(itemRead(1).Value(i)))
datiAssi(i).FeedOver = Math.Abs(Convert.ToSingle(itemRead(2).Value(i)))
datiAssi(i).PosTgt = Convert.ToSingle(itemRead(3).Value(i))
@@ -1330,13 +1332,15 @@ Namespace CNC
Public Function getCncAlarm() As Alarm()
' RIFERIMENTO:
' SynumerikOperate_Net, pg 101 --> 110
' restituisco vettore allarmi...
Return currAlarms
End Function
#End Region
End Class
+4 -1
View File
@@ -51,8 +51,11 @@
<Reference Include="MySql.Data, Version=6.9.9.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL">
<HintPath>..\packages\MySql.Data.6.9.9\lib\net45\MySql.Data.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
<HintPath>..\packages\NLog.4.6.6\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.configuration" />
+1 -1
View File
@@ -384,7 +384,7 @@ namespace MTC_ADB
{
get
{
return string.Format(@"{0}\MTCA.ico", utils.resxDir);
return string.Format(@"{0}\Scma.ico", utils.resxDir);
}
}
/// <summary>
+470 -107
View File
@@ -37,12 +37,12 @@
</xs:attribute>
<xs:attribute name="globalThreshold" type="NLogLevel">
<xs:annotation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged..</xs:documentation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwExceptions" type="xs:boolean">
<xs:annotation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false.</xs:documentation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false. Not recommend to set to true in production!</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwConfigExceptions" type="xs:boolean">
@@ -72,7 +72,7 @@
</xs:attribute>
<xs:attribute name="parseMessageTemplates" type="xs:boolean">
<xs:annotation>
<xs:documentation>Perform mesage template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
<xs:documentation>Perform message template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -123,7 +123,7 @@
</xs:choice>
<xs:attribute name="name" use="optional">
<xs:annotation>
<xs:documentation>Name of the logger. May include '*' character which acts like a wildcard. Allowed forms are: *, Name, *Name, Name* and *Name*</xs:documentation>
<xs:documentation>Name of the logger. May include wildcard characters ('*' or '?').</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="levels" type="NLogLevelList">
@@ -156,9 +156,9 @@
<xs:documentation>Ignore further rules if this one matches.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enabled" type="xs:boolean" default="true">
<xs:attribute name="ruleName" type="xs:string" use="optional">
<xs:annotation>
<xs:documentation>Enable or disable logging rule. Disabled rules are ignored.</xs:documentation>
<xs:documentation>Rule identifier to allow rule lookup with Configuration.FindRuleByName and Configuration.RemoveRuleByName.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -171,6 +171,11 @@
<xs:element name="whenNotEqual" type="whenNotEqual" />
<xs:element name="whenRepeated" type="whenRepeated" />
</xs:choice>
<xs:attribute name="defaultAction" type="FilterResult">
<xs:annotation>
<xs:documentation>Default action if none of the filters match.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:simpleType name="NLogLevel">
<xs:restriction base="xs:string">
@@ -210,12 +215,19 @@
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLogVariable">
<xs:choice minOccurs="0" maxOccurs="1">
<xs:element name="value" minOccurs="0" maxOccurs="1" type="xs:string">
<xs:annotation>
<xs:documentation>Variable value. Note, the 'value' attribute has precedence over this one.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:choice>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Variable name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute" use="required">
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Variable value.</xs:documentation>
</xs:annotation>
@@ -276,6 +288,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="batchSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="forceLockingQueue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="fullBatchSizeWriteLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="overflowAction" minOccurs="0" maxOccurs="1" type="NLog.Targets.Wrappers.AsyncTargetWrapperOverflowAction" />
<xs:element name="queueLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
@@ -292,6 +305,11 @@
<xs:documentation>Number of log events that should be processed in a batch by the lazy writer thread.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="forceLockingQueue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether to use the locking queue, instead of a lock-free concurrent queue The locking queue is less concurrent when many logger threads, but reduces memory allocation</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="fullBatchSizeWriteLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>Limit of full s to write before yielding into Performance is better when writing many small batches, than writing a single large batch</xs:documentation>
@@ -309,7 +327,7 @@
</xs:attribute>
<xs:attribute name="timeToSleepBetweenBatches" type="xs:integer">
<xs:annotation>
<xs:documentation>Time in milliseconds to sleep between batches.</xs:documentation>
<xs:documentation>Time in milliseconds to sleep between batches. (1 or less means trigger on new activity)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -334,6 +352,7 @@
<xs:element name="asyncFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="flushOnConditionOnly" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="asyncFlush" type="xs:boolean">
@@ -351,6 +370,11 @@
<xs:documentation>Name of the target.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="flushOnConditionOnly" type="xs:boolean">
<xs:annotation>
<xs:documentation>Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -419,18 +443,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -438,7 +464,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -471,24 +497,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -496,9 +507,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -506,14 +527,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -521,11 +562,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -561,9 +597,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -588,14 +624,26 @@
<xs:enumeration value="Discard" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="System.Security.Authentication.SslProtocols">
<xs:restriction base="xs:string">
<xs:enumeration value="None" />
<xs:enumeration value="Ssl2" />
<xs:enumeration value="Ssl3" />
<xs:enumeration value="Tls" />
<xs:enumeration value="Tls11" />
<xs:enumeration value="Tls12" />
<xs:enumeration value="Default" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Targets.NLogViewerParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
@@ -603,6 +651,11 @@
<xs:documentation>Viewer parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="ColoredConsole">
<xs:complexContent>
@@ -613,11 +666,13 @@
<xs:element name="header" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="footer" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="enableAnsiOutput" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="errorStream" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="useDefaultRowHighlightingRules" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="highlight-row" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleRowHighlightingRule" />
<xs:element name="highlight-word" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleWordHighlightingRule" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -645,6 +700,11 @@
<xs:documentation>Indicates whether to auto-check if the console is available. - Disables console writing if Environment.UserInteractive = False (Windows Service) - Disables console writing if Console Standard Input is not available (Non-Console-App)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enableAnsiOutput" type="xs:boolean">
<xs:annotation>
<xs:documentation>Enables output using ANSI Color Codes</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encoding" type="xs:string">
<xs:annotation>
<xs:documentation>The encoding for writing messages to the .</xs:documentation>
@@ -660,6 +720,11 @@
<xs:documentation>Indicates whether to use default row highlighting rules.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -768,6 +833,7 @@
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="error" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -805,6 +871,11 @@
<xs:documentation>Indicates whether to send the log messages to the standard error instead of the standard output.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -946,22 +1017,36 @@
</xs:complexType>
<xs:complexType name="NLog.Targets.DatabaseParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="dbType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="precision" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="scale" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameterType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="format" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="culture" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="dbType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter DbType.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="precision" type="xs:byte">
<xs:annotation>
<xs:documentation>Database parameter precision.</xs:documentation>
@@ -972,9 +1057,19 @@
<xs:documentation>Database parameter scale.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:attribute name="parameterType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
<xs:documentation>Type of the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="format" type="xs:string">
<xs:annotation>
<xs:documentation>Convert format of the database parameter value .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="culture" type="xs:string">
<xs:annotation>
<xs:documentation>Culture used for parsing parameter string-value for type-conversion</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -1076,7 +1171,7 @@
</xs:attribute>
<xs:attribute name="entryType" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Optional entrytype. When not set, or when not convertable to then determined by </xs:documentation>
<xs:documentation>Optional entrytype. When not set, or when not convertible to then determined by </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="eventId" type="SimpleLayoutAttribute">
@@ -1096,7 +1191,7 @@
</xs:attribute>
<xs:attribute name="maxKilobytes" type="xs:long">
<xs:annotation>
<xs:documentation>Maximum Event log size in kilobytes. If null, the value won't be set. Default is 512 Kilobytes as specified by Eventlog API</xs:documentation>
<xs:documentation>Maximum Event log size in kilobytes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxMessageLength" type="xs:integer">
@@ -1287,7 +1382,7 @@
</xs:attribute>
<xs:attribute name="forceMutexConcurrentWrites" type="xs:boolean">
<xs:annotation>
<xs:documentation>Value indicationg whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
<xs:documentation>Indicates whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="replaceFileContentsOnEachWrite" type="xs:boolean">
@@ -1461,6 +1556,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="filter" minOccurs="0" maxOccurs="1" type="Filter" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1867,6 +1963,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="maxLogsCount" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1879,6 +1976,11 @@
<xs:documentation>Layout used to format log messages.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxLogsCount" type="xs:integer">
<xs:annotation>
<xs:documentation>Max number of items to have in memory</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -1937,6 +2039,8 @@
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2004,6 +2108,16 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -2022,18 +2136,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -2041,7 +2157,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2074,24 +2190,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -2099,9 +2200,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -2109,14 +2220,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -2124,11 +2255,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -2164,9 +2290,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -2709,6 +2835,13 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvColumnDelimiterMode">
<xs:restriction base="xs:string">
<xs:enumeration value="Auto" />
@@ -2720,17 +2853,11 @@
<xs:enumeration value="Custom" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Layouts.CsvColumn">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="quoting" minOccurs="0" maxOccurs="1" type="NLog.Layouts.CsvQuotingMode" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
@@ -2742,6 +2869,11 @@
<xs:documentation>Name of the column.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="quoting" type="NLog.Layouts.CsvQuotingMode">
<xs:annotation>
<xs:documentation>Override of Quoting mode</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="JsonLayout">
<xs:complexContent>
@@ -2750,11 +2882,12 @@
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.JsonAttribute" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeGdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="renderEmptyObject" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="suppressSpaces" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
@@ -2766,6 +2899,11 @@
<xs:documentation>Option to include all properties from the log event (as JSON)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeGdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2776,6 +2914,11 @@
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="renderEmptyObject" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to render the empty object value {}</xs:documentation>
@@ -2786,11 +2929,6 @@
<xs:documentation>Option to suppress the extra spaces in the output json</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2814,7 +2952,7 @@
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines wether or not this attribute will be Json encoded.</xs:documentation>
<xs:documentation>Determines whether or not this attribute will be Json encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="escapeUnicode" type="xs:boolean">
@@ -2859,16 +2997,24 @@
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
</xs:choice>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log events</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeCallSite" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include call site (class and method name) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2889,6 +3035,11 @@
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2906,6 +3057,218 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="XmlLayout">
<xs:complexContent>
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="elementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="elementValue" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="elementEncode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementName" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementValue" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementEncode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlAttribute">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that will be rendered as the attribute's value.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlElement">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="value" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="when">
<xs:complexContent>
<xs:extension base="Filter">
+3 -3
View File
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="MySql.Data" version="6.9.9" targetFramework="net452" />
<package id="NLog" version="4.5.8" targetFramework="net452" />
<package id="NLog.Config" version="4.5.8" targetFramework="net452" />
<package id="NLog.Schema" version="4.5.8" targetFramework="net452" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net452" />
<package id="NLog" version="4.6.6" targetFramework="net452" />
<package id="NLog.Schema" version="4.6.6" targetFramework="net452" />
<package id="PrettyBin" version="1.1.0" targetFramework="net452" />
<package id="SlowCheetah" version="2.5.48" targetFramework="net452" />
</packages>
+5 -3
View File
@@ -36,9 +36,11 @@
<Reference Include="AForge.Math, Version=2.2.5.0, Culture=neutral, PublicKeyToken=abba2e25397ee8c9, processorArchitecture=MSIL">
<HintPath>..\packages\AForge.Math.2.2.5\lib\AForge.Math.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
<Private>True</Private>
<HintPath>..\packages\NLog.4.6.6\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.configuration" />
@@ -57,11 +59,11 @@
</ItemGroup>
<ItemGroup>
<Compile Include="BinaryFormatter.cs" />
<Compile Include="enumerations.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="baseUtils.cs" />
</ItemGroup>
<ItemGroup>
<None Include="NLog.config" />
<None Include="NLog.xsd">
<SubType>Designer</SubType>
</None>
+470 -107
View File
@@ -37,12 +37,12 @@
</xs:attribute>
<xs:attribute name="globalThreshold" type="NLogLevel">
<xs:annotation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged..</xs:documentation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwExceptions" type="xs:boolean">
<xs:annotation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false.</xs:documentation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false. Not recommend to set to true in production!</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwConfigExceptions" type="xs:boolean">
@@ -72,7 +72,7 @@
</xs:attribute>
<xs:attribute name="parseMessageTemplates" type="xs:boolean">
<xs:annotation>
<xs:documentation>Perform mesage template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
<xs:documentation>Perform message template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -123,7 +123,7 @@
</xs:choice>
<xs:attribute name="name" use="optional">
<xs:annotation>
<xs:documentation>Name of the logger. May include '*' character which acts like a wildcard. Allowed forms are: *, Name, *Name, Name* and *Name*</xs:documentation>
<xs:documentation>Name of the logger. May include wildcard characters ('*' or '?').</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="levels" type="NLogLevelList">
@@ -156,9 +156,9 @@
<xs:documentation>Ignore further rules if this one matches.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enabled" type="xs:boolean" default="true">
<xs:attribute name="ruleName" type="xs:string" use="optional">
<xs:annotation>
<xs:documentation>Enable or disable logging rule. Disabled rules are ignored.</xs:documentation>
<xs:documentation>Rule identifier to allow rule lookup with Configuration.FindRuleByName and Configuration.RemoveRuleByName.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -171,6 +171,11 @@
<xs:element name="whenNotEqual" type="whenNotEqual" />
<xs:element name="whenRepeated" type="whenRepeated" />
</xs:choice>
<xs:attribute name="defaultAction" type="FilterResult">
<xs:annotation>
<xs:documentation>Default action if none of the filters match.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:simpleType name="NLogLevel">
<xs:restriction base="xs:string">
@@ -210,12 +215,19 @@
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLogVariable">
<xs:choice minOccurs="0" maxOccurs="1">
<xs:element name="value" minOccurs="0" maxOccurs="1" type="xs:string">
<xs:annotation>
<xs:documentation>Variable value. Note, the 'value' attribute has precedence over this one.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:choice>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Variable name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute" use="required">
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Variable value.</xs:documentation>
</xs:annotation>
@@ -276,6 +288,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="batchSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="forceLockingQueue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="fullBatchSizeWriteLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="overflowAction" minOccurs="0" maxOccurs="1" type="NLog.Targets.Wrappers.AsyncTargetWrapperOverflowAction" />
<xs:element name="queueLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
@@ -292,6 +305,11 @@
<xs:documentation>Number of log events that should be processed in a batch by the lazy writer thread.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="forceLockingQueue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether to use the locking queue, instead of a lock-free concurrent queue The locking queue is less concurrent when many logger threads, but reduces memory allocation</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="fullBatchSizeWriteLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>Limit of full s to write before yielding into Performance is better when writing many small batches, than writing a single large batch</xs:documentation>
@@ -309,7 +327,7 @@
</xs:attribute>
<xs:attribute name="timeToSleepBetweenBatches" type="xs:integer">
<xs:annotation>
<xs:documentation>Time in milliseconds to sleep between batches.</xs:documentation>
<xs:documentation>Time in milliseconds to sleep between batches. (1 or less means trigger on new activity)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -334,6 +352,7 @@
<xs:element name="asyncFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="flushOnConditionOnly" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="asyncFlush" type="xs:boolean">
@@ -351,6 +370,11 @@
<xs:documentation>Name of the target.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="flushOnConditionOnly" type="xs:boolean">
<xs:annotation>
<xs:documentation>Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -419,18 +443,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -438,7 +464,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -471,24 +497,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -496,9 +507,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -506,14 +527,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -521,11 +562,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -561,9 +597,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -588,14 +624,26 @@
<xs:enumeration value="Discard" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="System.Security.Authentication.SslProtocols">
<xs:restriction base="xs:string">
<xs:enumeration value="None" />
<xs:enumeration value="Ssl2" />
<xs:enumeration value="Ssl3" />
<xs:enumeration value="Tls" />
<xs:enumeration value="Tls11" />
<xs:enumeration value="Tls12" />
<xs:enumeration value="Default" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Targets.NLogViewerParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
@@ -603,6 +651,11 @@
<xs:documentation>Viewer parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="ColoredConsole">
<xs:complexContent>
@@ -613,11 +666,13 @@
<xs:element name="header" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="footer" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="enableAnsiOutput" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="errorStream" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="useDefaultRowHighlightingRules" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="highlight-row" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleRowHighlightingRule" />
<xs:element name="highlight-word" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleWordHighlightingRule" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -645,6 +700,11 @@
<xs:documentation>Indicates whether to auto-check if the console is available. - Disables console writing if Environment.UserInteractive = False (Windows Service) - Disables console writing if Console Standard Input is not available (Non-Console-App)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enableAnsiOutput" type="xs:boolean">
<xs:annotation>
<xs:documentation>Enables output using ANSI Color Codes</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encoding" type="xs:string">
<xs:annotation>
<xs:documentation>The encoding for writing messages to the .</xs:documentation>
@@ -660,6 +720,11 @@
<xs:documentation>Indicates whether to use default row highlighting rules.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -768,6 +833,7 @@
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="error" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -805,6 +871,11 @@
<xs:documentation>Indicates whether to send the log messages to the standard error instead of the standard output.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -946,22 +1017,36 @@
</xs:complexType>
<xs:complexType name="NLog.Targets.DatabaseParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="dbType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="precision" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="scale" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameterType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="format" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="culture" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="dbType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter DbType.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="precision" type="xs:byte">
<xs:annotation>
<xs:documentation>Database parameter precision.</xs:documentation>
@@ -972,9 +1057,19 @@
<xs:documentation>Database parameter scale.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:attribute name="parameterType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
<xs:documentation>Type of the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="format" type="xs:string">
<xs:annotation>
<xs:documentation>Convert format of the database parameter value .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="culture" type="xs:string">
<xs:annotation>
<xs:documentation>Culture used for parsing parameter string-value for type-conversion</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -1076,7 +1171,7 @@
</xs:attribute>
<xs:attribute name="entryType" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Optional entrytype. When not set, or when not convertable to then determined by </xs:documentation>
<xs:documentation>Optional entrytype. When not set, or when not convertible to then determined by </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="eventId" type="SimpleLayoutAttribute">
@@ -1096,7 +1191,7 @@
</xs:attribute>
<xs:attribute name="maxKilobytes" type="xs:long">
<xs:annotation>
<xs:documentation>Maximum Event log size in kilobytes. If null, the value won't be set. Default is 512 Kilobytes as specified by Eventlog API</xs:documentation>
<xs:documentation>Maximum Event log size in kilobytes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxMessageLength" type="xs:integer">
@@ -1287,7 +1382,7 @@
</xs:attribute>
<xs:attribute name="forceMutexConcurrentWrites" type="xs:boolean">
<xs:annotation>
<xs:documentation>Value indicationg whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
<xs:documentation>Indicates whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="replaceFileContentsOnEachWrite" type="xs:boolean">
@@ -1461,6 +1556,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="filter" minOccurs="0" maxOccurs="1" type="Filter" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1867,6 +1963,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="maxLogsCount" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1879,6 +1976,11 @@
<xs:documentation>Layout used to format log messages.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxLogsCount" type="xs:integer">
<xs:annotation>
<xs:documentation>Max number of items to have in memory</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -1937,6 +2039,8 @@
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2004,6 +2108,16 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -2022,18 +2136,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -2041,7 +2157,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2074,24 +2190,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -2099,9 +2200,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -2109,14 +2220,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -2124,11 +2255,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -2164,9 +2290,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -2709,6 +2835,13 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvColumnDelimiterMode">
<xs:restriction base="xs:string">
<xs:enumeration value="Auto" />
@@ -2720,17 +2853,11 @@
<xs:enumeration value="Custom" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Layouts.CsvColumn">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="quoting" minOccurs="0" maxOccurs="1" type="NLog.Layouts.CsvQuotingMode" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
@@ -2742,6 +2869,11 @@
<xs:documentation>Name of the column.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="quoting" type="NLog.Layouts.CsvQuotingMode">
<xs:annotation>
<xs:documentation>Override of Quoting mode</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="JsonLayout">
<xs:complexContent>
@@ -2750,11 +2882,12 @@
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.JsonAttribute" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeGdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="renderEmptyObject" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="suppressSpaces" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
@@ -2766,6 +2899,11 @@
<xs:documentation>Option to include all properties from the log event (as JSON)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeGdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2776,6 +2914,11 @@
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="renderEmptyObject" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to render the empty object value {}</xs:documentation>
@@ -2786,11 +2929,6 @@
<xs:documentation>Option to suppress the extra spaces in the output json</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2814,7 +2952,7 @@
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines wether or not this attribute will be Json encoded.</xs:documentation>
<xs:documentation>Determines whether or not this attribute will be Json encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="escapeUnicode" type="xs:boolean">
@@ -2859,16 +2997,24 @@
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
</xs:choice>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log events</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeCallSite" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include call site (class and method name) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2889,6 +3035,11 @@
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2906,6 +3057,218 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="XmlLayout">
<xs:complexContent>
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="elementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="elementValue" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="elementEncode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementName" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementValue" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementEncode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlAttribute">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that will be rendered as the attribute's value.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlElement">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="value" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="when">
<xs:complexContent>
<xs:extension base="Filter">
+103 -10
View File
@@ -1,12 +1,11 @@
using System;
using NLog;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.IO;
using System.Linq;
using NLog;
using AForge.Math;
namespace MTC
{
@@ -17,6 +16,8 @@ namespace MTC
/// </summary>
public static Logger lg;
#region area gestione conf file
/// <summary>
/// legge conf in formato char
/// </summary>
@@ -81,6 +82,33 @@ namespace MTC
{ }
return answ;
}
#endregion
#region area manipolazione bit/byte
/// <summary>
/// verifica se un dato bit sia alzato (come flag di strobe)
/// </summary>
/// <param name="currByte">valore da testare</param>
/// <param name="bitNum">valore cercato come INDICE base 0 del byte (b0..b7)</param>
/// <returns></returns>
public static bool IsSetBit(byte currByte, int bitNum)
{
return ((currByte & (1 << bitNum)) != 0);
}
/// <summary>
/// verifica se un dato bit sia alzato (come flag di strobe)
/// </summary>
/// <param name="currVal">valore da testare</param>
/// <param name="bitNum">valore cercato come INDICE base 0 del byte (b0..b7)</param>
/// <returns></returns>
public static bool IsSetBit(int currVal, int bitNum)
{
return ((currVal & (1 << bitNum)) != 0);
}
/// <summary>
/// verifica se un dato bit sia alzato (come flag di strobe)
/// </summary>
@@ -147,7 +175,10 @@ namespace MTC
public static byte[] setBitOnStFlag(byte[] original, bool bitBool, int bitIndex)
{
int bitVal = 0;
if (bitBool) bitVal = 1;
if (bitBool)
{
bitVal = 1;
}
// risposta è identica ad originale...
byte[] answ = original;
// verifico se il bit è 0/1b
@@ -176,7 +207,10 @@ namespace MTC
public static byte[] ToByteArray(BitArray bits)
{
int numBytes = bits.Count / 8;
if (bits.Count % 8 != 0) numBytes++;
if (bits.Count % 8 != 0)
{
numBytes++;
}
byte[] bytes = new byte[numBytes];
int byteIndex = 0, bitIndex = 0;
@@ -184,7 +218,9 @@ namespace MTC
for (int i = 0; i < bits.Count; i++)
{
if (bits[i])
{
bytes[byteIndex] |= (byte)(1 << (7 - bitIndex));
}
bitIndex++;
if (bitIndex == 8)
@@ -307,7 +343,7 @@ namespace MTC
}
return result;
}
#endregion
}
/// <summary>
/// Oggetto timing x archiviazione dati perfomances
@@ -518,7 +554,10 @@ namespace MTC
for (int i = 0; i < results.Count; i++)
{
// se il codice è quello cercato...
if (results[i].codCall == codice) indice = i;
if (results[i].codCall == codice)
{
indice = i;
}
}
// se c'è aggiorno...
if (indice >= 0)
@@ -563,10 +602,10 @@ namespace MTC
/// <returns></returns>
public static UInt32 SwapUInt32(UInt32 inValue)
{
return (UInt32)(((inValue & 0xff000000) >> 24) |
return ((inValue & 0xff000000) >> 24) |
((inValue & 0x00ff0000) >> 8) |
((inValue & 0x0000ff00) << 8) |
((inValue & 0x000000ff) << 24));
((inValue & 0x000000ff) << 24);
}
}
@@ -764,7 +803,10 @@ namespace MTC
stop = DateTime.Today.AddHours(Convert.ToInt16(valori[9])).AddMinutes(Convert.ToInt16(valori[10])).AddSeconds(Convert.ToInt16(valori[11]));
// se ore == 0 --> aggiungo 1 gg!!!
if (Convert.ToInt16(valori[9]) == 0) stop.AddDays(1);
if (Convert.ToInt16(valori[9]) == 0)
{
stop.AddDays(1);
}
tEff = new TimeSpan(Convert.ToInt16(valori[12]), Convert.ToInt16(valori[13]), Convert.ToInt16(valori[14]));
@@ -783,23 +825,74 @@ namespace MTC
/// </summary>
public class allarme
{
/// <summary>
/// Codice
/// </summary>
public string codNum;
/// <summary>
/// Gruppo (CNC/PLC/HMI)
/// </summary>
public string gruppo;
/// <summary>
/// Livello allarme
/// - numerico [001...999]
/// - enum: FAULT=Alarm=900, Warning=500, Info=200, Maintenance=100
/// </summary>
public string livello;
/// <summary>
/// Descrizione in lingua corrente
/// </summary>
public string descrizione;
/// <summary>
/// Descrizione in IT
/// </summary>
public string descrizioneIt;
/// <summary>
/// Descrizione in EN
/// </summary>
public string descrizioneEn;
public allarme()
{
codNum = "";
gruppo = "";
livello = "";
descrizione = "";
descrizioneIt = "";
descrizioneEn = "";
}
/// <summary>
/// Inizializzaizone allarme con tutti i valori della descrizione in 3 lingue...
/// </summary>
/// <param name="_codNum"></param>
/// <param name="_gruppo"></param>
/// <param name="_livello"></param>
/// <param name="_descrizione">Usato per lingua CORRENTE, IT, EN</param>
public allarme(string _codNum, string _gruppo, string _livello, string _descrizione)
{
codNum = _codNum;
gruppo = _gruppo;
livello = _livello;
descrizione = _descrizione;
descrizioneIt = _descrizione;
descrizioneEn = _descrizione;
}
/// <summary>
/// Inizializzaizone allarme con tutti i valori della descrizione in 3 lingue...
/// </summary>
/// <param name="_codNum"></param>
/// <param name="_gruppo"></param>
/// <param name="_livello"></param>
/// <param name="_descrizione"></param>
/// <param name="_descrizioneIt"></param>
/// <param name="_descrizioneEn"></param>
public allarme(string _codNum, string _gruppo, string _livello, string _descrizione, string _descrizioneIt, string _descrizioneEn)
{
codNum = _codNum;
gruppo = _gruppo;
livello = _livello;
descrizione = _descrizione;
descrizioneIt = _descrizioneIt;
descrizioneEn = _descrizioneEn;
}
}
+235
View File
@@ -0,0 +1,235 @@
namespace MTC
{
/// <summary>
/// Tipologia di ricerca ammessa
/// </summary>
public enum subsMode
{
/// ADD: includo
A,
/// X: ESCLUDO
X
}
/// <summary>
/// Tipologia di sostituzioni ammesse
/// </summary>
public enum substSearch
{
// CERCO BEGIN: inizia per
B,
// CERCO END: finisce per
E,
// CERCO CONTAINS: contiene
C,
// CERCO IDENTICAL: identica
I
}
/// <summary>
/// Classe utility dizionario per sostituzioni
/// </summary>
public class replDict
{
/// <summary>
/// Valore tradotto
/// </summary>
public string tradz;
/// <summary>
/// Tipologia di azione
/// </summary>
public subsMode modo;
/// <summary>
/// Modalità di ricerca
/// </summary>
public substSearch search;
}
/// <summary>
/// Classe item node (tipo/obj)
/// </summary>
public class itemNode
{
/// <summary>
/// Tipo oggetto (per cast)
/// </summary>
public itemType cType;
/// <summary>
/// Object specifico
/// </summary>
public object cObject;
/// <summary>
/// costruttore
/// </summary>
public itemNode()
{ }
/// <summary>
/// costruttore
/// </summary>
/// <param name="_tipo"></param>
/// <param name="_obj"></param>
public itemNode(itemType _tipo, object _obj)
{
cType = _tipo;
cObject = _obj;
}
}
/// <summary>
/// Tipologia di ITEM
/// </summary>
public enum itemType
{
/// <summary>
/// CONDIZION = ALLARME
/// </summary>
Condition,
/// <summary>
/// Evento = point in time data
/// </summary>
Event,
/// <summary>
/// Messaggio generico
/// </summary>
Message,
/// <summary>
/// Campionamento continuo
/// </summary>
Sample
}
/// <summary>
/// Varibili STATO ATTIVO (es attuatori, sistemi...)
/// </summary>
public enum actStatus
{
/// <summary>
/// Stato inattivo
/// </summary>
INACTIVE = 0,
/// <summary>
/// Stato Attivo
/// </summary>
ACTIVE
}
/// <summary>
/// Varibili STATO OnOff
/// </summary>
public enum onOffStatus
{
/// <summary>
/// Stato OFF
/// </summary>
OFF = 0,
/// <summary>
/// Stato ON
/// </summary>
ON
}
/// <summary>
/// Varibili STATO per EMERGENZA
/// </summary>
public enum emStatus
{
/// <summary>
/// Stato ARMATO
/// </summary>
ARMED = 0,
/// <summary>
/// Stato EMERGENZA PREMUTA
/// </summary>
TRIGGERED
}
/// <summary>
/// ENUM degli stati macchina(alto livello, OPC-UA)
/// </summary>
public enum macState
{
UNDEFINED = 0,
EXE = 1,
READY = 2,
FAIL = 3,
POWER_OFF = 4
}
/// <summary>
/// ENUM degli stati RUN del path MTC
/// </summary>
public enum MtcRunMode
{
UNDEFINED = 0,
AUTOMATIC,
EDIT,
MANUAL_DATA_INPUT,
MANUAL,
SEMI_AUTO
}
/// <summary>
/// ENUM dei MODE del path OPC-UA
/// </summary>
public enum OpcUaPathMode
{
UNDEFINED = 0,
AUTOMATIC,
EDIT,
SEMIAUTOMATIC,
MANUAL_JOG,
SEMIAUTOMATIC_MTC
}
/// <summary>
/// ENUM degli stati EXE del path MTC
/// </summary>
public enum MtcExeMode
{
UNDEFINED = 0,
ACTIVE,
READY,
STOPPED,
FEED_HOLD,
OPTIONAL_STOP,
PROGRAM_STOPPED,
PROGRAM_COMPLETED
}
/// <summary>
/// ENUM degli stati del path OPC-UA
/// </summary>
public enum OpcUaPathStatus
{
UNDEFINED = 0,
EXE,
READY,
HOLD,
FEED_HOLD,
OPTIONAL_STOP,
PROGRAM_STOPPED,
DONE
}
/// <summary>
/// Varibili STATO per AVAIL
/// </summary>
public enum availStatus
{
/// <summary>
/// Stato DISPONIBILE
/// </summary>
AVAILABLE = 0,
/// <summary>
/// Stato NON disponibile NULL/unavailable (era NULL, rimesso UNAVAILABLE su richiesta Nicola Carminati)
/// </summary>
UNAVAILABLE
}
/// <summary>
/// Varibili STATO per AVAIL
/// </summary>
public enum pathType
{
/// <summary>
/// Stato LAVORO
/// </summary>
LAVORO = 0,
/// <summary>
/// Stato ASSERV
/// </summary>
ASSERV
}
}
+3 -3
View File
@@ -2,7 +2,7 @@
<packages>
<package id="AForge" version="2.2.5" targetFramework="net452" />
<package id="AForge.Math" version="2.2.5" targetFramework="net452" />
<package id="NLog" version="4.5.8" targetFramework="net452" />
<package id="NLog.Config" version="4.5.8" targetFramework="net452" />
<package id="NLog.Schema" version="4.5.8" targetFramework="net452" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net452" />
<package id="NLog" version="4.6.6" targetFramework="net452" />
<package id="NLog.Schema" version="4.6.6" targetFramework="net452" />
</packages>
+16
View File
@@ -0,0 +1,16 @@
G1128 ed F1343
leggo bit, se in AND sono 1 --> processo migrato
parametro 981 --> assegno a
1
1
1
2
2
2
1
1
1
devo guardare dove ho 2 (processo predisposto) e se i bit sono 1 --> sono spostati di PROCESSO, e devo guardare quelli...
+707
View File
@@ -0,0 +1,707 @@
using MTC;
using NLog;
using System;
using System.Collections;
using System.Collections.Generic;
namespace OPC_UA_REDIS
{
public class AdapterRed
{
/// <summary>
/// wrapper di log
/// </summary>
public static Logger lg;
/// <summary>
/// Determina se il server redis sia attivo e connesso (check periodico...)
/// </summary>
public bool redServAlive;
/// <summary>
/// DataOra ultimo controllo stato server REDIS
/// </summary>
protected DateTime lastRedSrvCheck;
/// <summary>
/// Bool x verifica SE SIANO DA INVIARE info in fase di START (no se REDIS non attivo...)
/// </summary>
protected bool startData2Send = false;
/// <summary>
/// Bool x verifica SE SIANO DA INVIARE info in fase di STOP (no se REDIS non attivo...)
/// </summary>
protected bool stopData2Send = false;
/// <summary>
/// Bool x verifica SE SIANO DA INVIARE info in fase di REFRESH (no se REDIS non attivo...)
/// </summary>
protected bool refreshData2Send = false;
/// <summary>
/// Metodo send changed iniziato e stiamo inviando conditions.
/// </summary>
bool mBegun = false;
/// <summary>
/// DataModel di riferimento
/// </summary>
public string DataModel;
/// <summary>
/// Oggetto elenco allarmi (in + lingue...)
/// </summary>
public allarme[] elencoAllarmi { get; set; }
/// <summary>
/// Dizionario REGOLE conversione nome variabili con replace "like" (per gestione REDIS "_" --> ":")
/// </summary>
public Dictionary<string, replDict> nameRepRoles { get; set; }
/// <summary>
/// Dizionario di TUTTE le conversioni variabili (MTC-->OPC-UA) applicate
/// </summary>
public Dictionary<string, string> nameReplaced = new Dictionary<string, string>();
/// <summary>
/// Dizionario di TUTTE le conversioni variabili (OPC-UA-->MTC) applicate
/// </summary>
public Dictionary<string, string> nameReplacedInvert = new Dictionary<string, string>();
/// <summary>
/// Dizionario di TUTTE le variabili ESCLUSE (filtrate)
/// </summary>
public Dictionary<string, string> nameExcluded = new Dictionary<string, string>();
/// <summary>
/// Elenco di TUTTI i NODI ITEMS gestiti dal gateway (item/variabile)...
/// </summary>
public Dictionary<string, itemNode> itemNodes { get; set; }
/// <summary>
/// Elenco di TUTTI i NODI CONDITIONS gestiti dal gateway (allarme/condizione)...
/// </summary>
public Dictionary<string, itemNode> conditionNodes { get; set; }
/// <summary>
/// All the data items we're tracking.
/// </summary>
private ArrayList mDataItems = new ArrayList();
/// <summary>
/// Classe adapter verso REDIS
/// </summary>
/// <param name="sPort"></param>
/// <param name="sAddress"></param>
/// <param name="verbose"></param>
public AdapterRed(int sPort = 6379, string sAddress = "127.0.0.1", bool verbose = false)
{
lg = LogManager.GetCurrentClassLogger();
ServerPort = sPort;
ServerAddr = sAddress;
Verbose = verbose;
nameRepRoles = new Dictionary<string, replDict>();
itemNodes = new Dictionary<string, itemNode>();
conditionNodes = new Dictionary<string, itemNode>();
// aggiungo controllo server...
checkAlive();
lastRedSrvCheck = DateTime.Now;
}
/// <summary>
/// Controlla stato server alive
/// </summary>
private void checkAlive()
{
bool newStatus = redUtil.connRedis.IsConnected;
// controllo se cambia lo stato...
string message = "";
if (redServAlive != newStatus)
{
message = newStatus ? "Server REDIS tornato ONLINE! salvo aggiornamento di stato" : "Server REDIS offline, impossibile inviare aggiornamenti.";
lg.Info(message);
redServAlive = newStatus;
if (newStatus)
{
checkRedisStatusAndSend();
}
}
}
public int Heartbeat { get; set; }
public bool Running { get; }
public int ServerPort { get; set; }
public string ServerAddr { get; set; }
public bool Verbose { get; set; }
#region metodi esposti
/// <summary>
/// The asks all data items to begin themselves for collection. Only
/// required for conditions and should not be called if you are not
/// planning on adding all the conditions before you send. If you skip this
/// the adapter will not perform the mark and sweep.
/// </summary>
public void Begin()
{
mBegun = true;
foreach (DataItemRed di in mDataItems)
{
di.Begin();
}
}
/// <summary>
/// Aggiunta di un DataItem (generico)
/// </summary>
/// <param name="aDI"></param>
public void AddDataItem(DataItemRed aDI)
{
// controllo se ci sia già (sennò NON duplico...)
if (!mDataItems.Contains(aDI))
{
mDataItems.Add(aDI);
}
}
/// <summary>
/// Remove all data items.
/// </summary>
public void RemoveAllDataItems()
{
mDataItems.Clear();
}
/// <summary>
/// Remove a data item from the adapter.
/// </summary>
/// <param name="aItem"></param>
public void RemoveDataItem(DataItemRed aItem)
{
int ind = mDataItems.IndexOf(aItem);
if (ind >= 0)
{
mDataItems.RemoveAt(ind);
}
}
/// <summary>
/// Make all data items unavailable
/// </summary>
public void Unavailable()
{
foreach (DataItemRed di in mDataItems)
{
di.Unavailable();
}
}
/// <summary>
/// Effettua invio di tutte le variabili modificate...
/// </summary>
/// <param name="timestamp"></param>
public void SendChanged()
{
// registro che necessito invio dati STOP
refreshData2Send = true;
if (redServAlive)
{
sendChangedData(false);
}
else
{
// controllo se sia scaduto timeout 5 sec prima di scrivere errore...
if (DateTime.Now.AddSeconds(-baseUtils.CRI("logRedConnWaitTime")) > lastRedSrvCheck)
{
lg.Error("Attenzione! server REDIS non disponibile (SendChanged)");
lastRedSrvCheck = DateTime.Now;
}
}
// forzo controllo stato
checkAlive();
}
/// <summary>
/// Invio dati modificati
/// </summary>
/// <param name="forceSend">forza invio di TUTTO comunque...</param>
/// <returns></returns>
private string sendChangedData(bool forceSend = false)
{
string timestamp = null;
// var accessorie
string hashKey = "";
string hashVal = "";
if (mBegun)
{
foreach (DataItemRed di in mDataItems)
{
di.Prepare();
}
}
// Separate out the data items into those that are on one line and those
// need separate lines.
List<DataItemRed> together = new List<DataItemRed>();
foreach (DataItemRed di in mDataItems)
{
List<DataItemRed> list = di.ItemList(forceSend);
together.AddRange(list);
}
if (timestamp == null)
{
timestamp = DateTime.UtcNow.ToString("yyyy-MM-dd\\THH:mm:ss.fffK");
}
if (redServAlive)
{
if (together.Count > 0)
{
// salvo su REDIS!!!
foreach (DataItemRed di in together)
{
hashKey = machineHash(di.Name);
hashVal = di.Value.ToString();
saveHashKeyVal(hashKey, hashVal);
}
}
// salvo anche heartbeat e running...
hashKey = redUtil.man.redHash("Adp:Heartbeat");
saveHashKeyVal(hashKey, timestamp);
hashKey = redUtil.man.redHash("Adp:Status");
hashVal = "running";
saveHashKeyVal(hashKey, hashVal);
}
else
{
lg.Error("Attenzione! server REDIS non disponibile (SendChanged:toghether)");
checkAlive();
}
// Cleanup
foreach (DataItemRed di in mDataItems)
{
di.Cleanup();
}
// finito
mBegun = false;
return timestamp;
}
/// <summary>
/// Salva hask KeyVal in REDIS
/// </summary>
/// <param name="hashKey"></param>
/// <param name="hashVal"></param>
private static void saveHashKeyVal(string hashKey, string hashVal)
{
if (!hashKey.EndsWith("NONE"))
{
redUtil.man.setRSV(hashKey, hashVal);
}
}
/// <summary>
/// Arresto adapter
/// </summary>
public void Stop()
{
// registro che necessito invio dati STOP
stopData2Send = true;
if (redServAlive)
{
sendStopData();
}
else
{
lg.Error("Attenzione! server REDIS non disponibile (STOP)");
// forzo controllo stato
checkAlive();
}
}
/// <summary>
/// Invio dati in fase di CHIUSURA
/// </summary>
private void sendStopData()
{
// var accessorie
string hashKey = "";
string hashVal = "";
// Imposto CONF
hashKey = redUtil.man.redHash("Adp:Status");
hashVal = string.Format("stopped");
saveHashKeyVal(hashKey, hashVal);
hashKey = redUtil.man.redHash("Adp:Heartbeat");
hashVal = DateTime.UtcNow.ToString("yyyy-MM-dd\\THH:mm:ss.fffK");
saveHashKeyVal(hashKey, hashVal);
// SOLO se richiesto FULL RESET...
if (baseUtils.CRB("fullReset"))
{
// ora il valore delle chaivi diventa unavailable...
hashVal = availStatus.UNAVAILABLE.ToString();
// percorro tutto l'albero nodi item ed allarmi e SCRIVO!!!!
foreach (var item in itemNodes)
{
hashKey = machineHash(item.Key);
saveHashKeyVal(hashKey, hashVal);
}
}
stopData2Send = false;
}
/// <summary>
/// Aggiorna stato redis server + invio dati pending
/// </summary>
private void checkRedisStatusAndSend()
{
// verifico eventuali invii pending... SE connesso...
if (redServAlive)
{
if (startData2Send)
{
sendStartData();
lg.Info("Reinviati dati sendStartData");
}
if (refreshData2Send)
{
sendChangedData(true);
lg.Info("Reinviati dati sendChangedData");
}
if (stopData2Send)
{
sendStopData();
lg.Info("Reinviati dati sendStopData");
}
}
// aggiorno stato redis
checkAlive();
}
/// <summary>
/// Avvio adapter (popolamento iniziale su redis...)
/// </summary>
public void Start()
{
// registro che necessito invio dati START
startData2Send = true;
stopData2Send = false;
if (redServAlive)
{
sendStartData();
}
else
{
lg.Error("Attenzione! server REDIS non disponibile (START)");
// forzo controllo stato
checkAlive();
}
}
/// <summary>
/// Decodifica il livello di severiti da testo a numerico:
/// 900 Alarm
/// 500 Warning
/// 200 Info
/// 100 Maintenance
/// </summary>
/// <param name="livello"></param>
/// <returns></returns>
public static string condLevel(string livello)
{
string answ = "0";
switch (livello.ToLower())
{
case "alarm":
case "fault":
answ = "900";
break;
case "warning":
answ = "500";
break;
case "info":
answ = "200";
break;
case "maintenance":
answ = "100";
break;
default:
// verifico sia una stringa
int lev = 0;
int.TryParse(livello, out lev);
answ = lev.ToString("000");
break;
}
return answ;
}
/// <summary>
/// Invio dati in fase di AVVIO
/// </summary>
private void sendStartData()
{
// var accessorie
string hashKey = "";
string hashVal = "";
string nLevel = "";
var listCNC_curr = new List<KeyValuePair<string, string>>();
var listPLC_curr = new List<KeyValuePair<string, string>>();
var listHMI_curr = new List<KeyValuePair<string, string>>();
var listCNC_it = new List<KeyValuePair<string, string>>();
var listPLC_it = new List<KeyValuePair<string, string>>();
var listHMI_it = new List<KeyValuePair<string, string>>();
var listCNC_en = new List<KeyValuePair<string, string>>();
var listPLC_en = new List<KeyValuePair<string, string>>();
var listHMI_en = new List<KeyValuePair<string, string>>();
// resetto TUTTE le aree di competenza
redUtil.man.redFlushKey(redUtil.man.redHash("AdpVeto*"));
redUtil.man.redFlushKey(redUtil.man.redHash("AdpConf*"));
redUtil.man.redFlushKey(redUtil.man.redHash("Adp*"));
redUtil.man.redFlushKey(redUtil.man.redHash("Machine*"));
// imposto valori "empty" di default....
listCNC_curr.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listCNC_en.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listCNC_it.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listHMI_curr.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listHMI_en.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listHMI_it.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listPLC_curr.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listPLC_en.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
listPLC_it.Add(new KeyValuePair<string, string>("000000000000|000", "NONE"));
// Imposto CONF
hashKey = redUtil.man.redHash("Adp:Vers");
hashVal = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version.ToString();
saveHashKeyVal(hashKey, hashVal);
hashKey = redUtil.man.redHash("Adp:Status");
hashVal = "started";
saveHashKeyVal(hashKey, hashVal);
hashKey = redUtil.man.redHash("Adp:Heartbeat");
hashVal = DateTime.UtcNow.ToString("yyyy-MM-dd\\THH:mm:ss.fffK");
saveHashKeyVal(hashKey, hashVal);
// allarmi CNC, aggiungo Curr (rif SOURS 2018.11.14)
foreach (var item in elencoAllarmi)
{
// aggiungo secondo gruppo
if (item.gruppo.ToUpper().Contains("CNC"))
{
nLevel = condLevel(item.livello);
listCNC_curr.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizione));
listCNC_en.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneEn));
listCNC_it.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneIt));
}
else if (item.gruppo.ToUpper().Contains("HMI"))
{
nLevel = condLevel(item.livello);
listHMI_curr.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizione));
listHMI_en.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneEn));
listHMI_it.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneIt));
}
else if (item.gruppo.ToUpper().Contains("PLC"))
{
nLevel = condLevel(item.livello);
listPLC_curr.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizione));
listPLC_en.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneEn));
listPLC_it.Add(new KeyValuePair<string, string>(item.codNum + "|" + nLevel, item.descrizioneIt));
}
}
// salvo vettori lingua CURR
hashKey = confHash("Cnc:Condition:Curr");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listCNC_curr);
hashKey = confHash("Hmi:Condition:Curr");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listHMI_curr);
hashKey = confHash("Plc:Condition:Curr");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listPLC_curr);
// salvo vettori lingua EN
hashKey = confHash("Cnc:Condition:En");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listCNC_en);
hashKey = confHash("Hmi:Condition:En");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listHMI_en);
hashKey = confHash("Plc:Condition:En");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listPLC_en);
// salvo vettori lingua IT
hashKey = confHash("Cnc:Condition:It");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listCNC_it);
hashKey = confHash("Hmi:Condition:It");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listHMI_it);
hashKey = confHash("Plc:Condition:It");
redUtil.man.redFlushKey(hashKey);
redUtil.man.redSaveHashList(hashKey, listPLC_it);
// DataModel --> salvo in redis!
hashKey = confHash("DataModel");
hashVal = DataModel;
saveHashKeyVal(hashKey, hashVal);
// imposto VETO
hashKey = vetoHash("Cnc:Condition");
hashVal = "0,0|000";
redUtil.man.redFlushKey(hashKey);
saveHashKeyVal(hashKey, hashVal);
hashKey = vetoHash("Hmi:Condition");
hashVal = "0,0|000";
redUtil.man.redFlushKey(hashKey);
saveHashKeyVal(hashKey, hashVal);
hashKey = vetoHash("Plc:Condition");
hashVal = "0,0|000";
redUtil.man.redFlushKey(hashKey);
saveHashKeyVal(hashKey, hashVal);
// Imposto DATI: percorro tutto l'albero nodi item ed allarmi e SCRIVO!!!!
foreach (var item in itemNodes)
{
hashKey = machineHash(item.Key);
hashVal = availStatus.UNAVAILABLE.ToString(); // item.Value.cObject.ToString();
saveHashKeyVal(hashKey, hashVal);
}
}
#endregion
#region helper gestione REDIS
public string getOrigKey(string redKey)
{
string answ = redKey;
if (nameReplacedInvert.ContainsKey(redKey))
{
answ = nameReplacedInvert[redKey];
}
return answ;
}
/// <summary>
/// Fix KEY x standard redis ("_" --> ":")
/// </summary>
/// <param name="origKey"></param>
/// <returns></returns>
public string fixRedKey(string origKey)
{
// parto da variabile dichiarata
string answ = origKey;
// se la trovo nel dizionario restituisco...
if (nameReplaced != null && nameReplaced.ContainsKey(origKey))
{
answ = nameReplaced[origKey];
}
// altrimenti controllo tra esclusi
else if (nameExcluded != null && nameExcluded.ContainsKey(origKey))
{
answ = nameExcluded[origKey];
}
// altrimenti calcolo e salvo in dizionario...
else
{
bool trovato = false;
bool keyExcluded = false;
string txt2find = "";
// se NON HO un MATCH processo il replace e se trovo corrispondenza processo
foreach (var item in nameRepRoles)
{
// SE NON trovato procedo...
if (!trovato)
{
// cerco se escluso o aggiunto...
keyExcluded = item.Value.modo == subsMode.X;
// testo cercato
txt2find = item.Key;
// B --> cerco inizio
if (item.Value.search == substSearch.B)
{
trovato = answ.StartsWith(txt2find);
}
// E --> cerco fine
else if (item.Value.search == substSearch.E)
{
trovato = answ.EndsWith(txt2find);
}
// I --> cerco IDENTICO
else if (item.Value.search == substSearch.I)
{
trovato = (answ == txt2find);
}
// C --> cerco OVUNQUE contenuto
else if (item.Value.search == substSearch.C)
{
trovato = answ.IndexOf(txt2find) >= 0;
}
// se trovato SOSTITUISCO...
if (trovato)
{
// effetuo sostituzione chiave/valore
answ = answ.Replace(txt2find, item.Value.tradz);
}
}
}
// se è escluso --> salvo in escluso e restituisco NONE
if (keyExcluded && trovato)
{
answ = "NONE";
// salvo in dizionario
if (nameExcluded != null && nameExcluded.ContainsKey(origKey))
{
nameExcluded.Remove(origKey);
}
// salvo in dizionario
nameExcluded.Add(origKey, "NONE");
}
else
{
// altrimenti continuo: sostituzione "_" --> ":"
try
{
answ = answ.Replace("_", ":");
}
catch
{ }
// SOLO SE DIFFERISCONO SALVO...
if (answ != origKey)
{
if (nameReplaced != null && !nameReplaced.ContainsKey(origKey))
{
// salvo in dizionario
nameReplaced.Add(origKey, answ);
}
if (nameReplacedInvert != null && !nameReplacedInvert.ContainsKey(answ))
{
// salvo in dizionario INVERSO (SE C'E' conversione...)
nameReplacedInvert.Add(answ, origKey);
}
}
}
}
return answ;
}
/// <summary>
/// HASH x la parte MACHINE del server REDIS
/// </summary>
/// <param name="keyName"></param>
/// <returns></returns>
public string machineHash(string keyName)
{
return redUtil.man.redHash("Machine:" + fixRedKey(keyName));
}
/// <summary>
/// HASH x la parte ADAPTER CONF del server REDIS
/// </summary>
/// <param name="keyName"></param>
/// <returns></returns>
public string confHash(string keyName)
{
return redUtil.man.redHash("AdpConf:" + fixRedKey(keyName));
}
/// <summary>
/// HASH x la parte ADAPTER ERRORS del server REDIS
/// </summary>
/// <param name="keyName"></param>
/// <returns></returns>
public string adpErHash(string keyName)
{
return redUtil.man.redHash("AdpError:" + fixRedKey(keyName));
}
/// <summary>
/// HASH x la parte VETO del server REDIS
/// </summary>
/// <param name="keyName"></param>
/// <returns></returns>
public string vetoHash(string keyName)
{
return redUtil.man.redHash("AdpVeto:" + fixRedKey(keyName));
}
#endregion
}
}
+510
View File
@@ -0,0 +1,510 @@
using System;
using System.Collections.Generic;
using System.Linq;
namespace OPC_UA_REDIS
{
/// <summary>
/// Classe dataitem x REDIS:
/// - classe base x dataItem
/// - possiede valore e nome astratti
/// - tiene traccia di modifica dall'ultimo reset
/// </summary>
public class DataItemRed
{
/// <summary>
/// NOME del data item
/// </summary>
protected String mName;
/// <summary>
/// VALORE del data item, può essere ogni type.
/// </summary>
protected object mValue = "UNAVAILABLE";
/// <summary>
/// A flag to indicate if the data item's value has changed since it
/// has last been set.
/// </summary>
protected bool mChanged = true;
/// <summary>
/// Prefisso (opzionale)
/// </summary>
public string DevicePrefix = null;
public DataItemRed(string name)
{
mName = name;
}
public string Name { get { return mName; } }
/// <summary>
/// Get/set del valore
/// </summary>
public object Value
{
get
{
return mValue;
}
set
{
if (!mValue.Equals(value))
{
mValue = value;
mChanged = true;
}
}
}
/// <summary>
/// Rende data item unavailable.
/// </summary>
public virtual void Unavailable() { Value = "NULL"; }
/// <summary>
/// Controlla se data item sia unavailable.
/// </summary>
/// <returns>true if Unavailable</returns>
public bool IsUnavailable() { return mValue.Equals("NULL"); }
/// <summary>
/// Getter x la proprietà mChanged
/// </summary>
public bool Changed { get { return mChanged; } }
public void ForceChanged()
{
mChanged = true;
}
/// <summary>
/// These methods are mainly for conditions. They allow for
/// mark and sweep of the condition activations.
/// </summary>
public virtual void Begin() { }
public virtual void Prepare() { }
/// <summary>
/// Reset the Changed flag.
/// </summary>
public virtual void Cleanup() { mChanged = false; }
/// <summary>
/// Get a list of all the changed data items. Since this is a
/// single value, just return a list with one item if it has
/// changed
/// </summary>
/// <param name="onlyChanged">true means to return this data item regardless of the
/// changed flag. This is used to send initial data back to a new client.</param>
/// <returns>The changed data item</returns>
public virtual List<DataItemRed> ItemList(bool all = false)
{
List<DataItemRed> list = new List<DataItemRed>();
if (all || mChanged)
{
list.Add(this);
}
return list;
}
}
/// <summary>
/// A condition handles the fact that a single condition can have multiple
/// activations and needs to check when the are present and are cleared.
/// </summary>
public class ConditionRed : DataItemRed
{
/// <summary>
/// The four values for the condition.
/// </summary>
public enum Level
{
UNAVAILABLE,
NORMAL,
WARNING,
FAULT
}
/// <summary>
/// The Activation is itself a data item. This is so it can be cleared
/// and treated like other data items when generating text.
/// </summary>
public class Active : DataItemRed
{
// The pieces of the activation are only used by the condition.
public Level mLevel;
public string mText;
public string mNativeCode;
public string mNativeSeverity;
public string mQualifier;
/// <summary>
/// The marked flag tells if this alarm has been reasserted.
/// </summary>
public bool mMarked = true;
/// <summary>
/// A placeholder activation is just a normal or unavailable.
/// </summary>
public bool mPlaceholder = false;
/// <summary>
/// Create a new activation
/// </summary>
/// <param name="name">The name of the condition, passed from the parent</param>
/// <param name="level">The condition level</param>
/// <param name="text">The descriptive text for the condition</param>
/// <param name="code">The native code of the alarm or warning</param>
/// <param name="qualifier">A high/low qualifier</param>
/// <param name="severity">The native severity of the condition</param>
public Active(string name, Level level, string text = "", string code = "",
string qualifier = "", string severity = "")
: base(name)
{
mLevel = level;
mText = text;
mNativeCode = code;
mQualifier = qualifier;
mNativeSeverity = severity;
if (mNativeCode.Length == 0 && (mLevel == Level.NORMAL || mLevel == Level.UNAVAILABLE))
{
mPlaceholder = true;
}
}
/// <summary>
/// Update the values of the activation. Also marks this activation.
/// </summary>
/// <param name="level">The condition level</param>
/// <param name="text">The descriptive text for the condition</param>
/// <param name="qualifier">A high/low qualifier</param>
/// <param name="severity">The native severity of the condition</param>
/// <returns>true if the condition has changed</returns>
public bool Set(Level level, string text = "",
string qualifier = "", string severity = "")
{
mChanged = level != mLevel || text != mText || qualifier != mQualifier ||
severity != mNativeSeverity;
if (mChanged)
{
mLevel = level;
mQualifier = qualifier;
mText = text;
mNativeSeverity = severity;
}
mMarked = true;
return mChanged;
}
public override string ToString()
{
return mName + "|" + Enum.GetName(mLevel.GetType(), mLevel) + "|" + mNativeCode + "|" + mNativeSeverity + "|" + mQualifier + "|" + mText;
}
/// <summary>
/// Resets the marked flag.
/// </summary>
public void Clear()
{
mMarked = false;
}
}
/// <summary>
/// A flag to indicate that the mark and sweep has begun.
/// </summary>
bool mBegun = false;
/// <summary>
/// A flag indicating the second phase of the mark and sweep has completed.
/// </summary>
bool mPrepared = false;
/// <summary>
/// true means this is a simple condition and does not require
/// mark and sweep processing.
/// </summary>
bool mSimple;
List<Active> mActiveList = new List<Active>();
/// <summary>
/// Create a new condition
/// </summary>
/// <param name="name">The name of the data item</param>
/// <param name="simple">If this is a simple condition or if it uses
/// mark and sweep</param>
public ConditionRed(String name, bool simple = false) : base(name)
{
mSimple = simple;
Add(new Active(mName, Level.UNAVAILABLE));
}
/// <summary>
/// Make this condition unavailable
/// </summary>
public override void Unavailable()
{
Add(Level.UNAVAILABLE);
}
/// <summary>
/// This clears all the marks and begins so we can tell which
/// conditions were not added during this pass. This is not
/// required for simple conditions.
/// </summary>
public override void Begin()
{
if (!mSimple)
{
foreach (Active active in mActiveList)
{
active.Clear();
}
mBegun = true;
}
mPrepared = mChanged = false;
}
/// <summary>
/// This is called before we send the actual changed data. It
/// does the diff from the previous state and finds all the
/// activations that need to be removed. This also check to see
/// if all the activations have been removed because we only
/// need to do a single normal with no native code to clear all.
///
/// This is not required for simple conditions.
/// </summary>
public override void Prepare()
{
if (mBegun)
{
bool marked = false;
// Check to see if we have any active marked conditions
foreach (Active active in mActiveList)
{
if (active.mPlaceholder || active.mMarked)
{
marked = true;
break;
}
}
// If they've all been cleared, then go back to normal.
if (!marked)
{
Normal();
}
// Sweep the old conditions and if they are not marked
// set them to normal.
foreach (Active active in mActiveList)
{
if (!active.mPlaceholder && !active.mMarked)
{
active.Set(Level.NORMAL, "");
active.mMarked = false;
}
if (active.Changed)
{
mChanged = true;
}
}
mPrepared = true;
}
}
/// <summary>
/// This is the sweep phase where we removed the changed flags
/// and remove all the stale activations.
/// </summary>
public override void Cleanup()
{
base.Cleanup();
mBegun = mPrepared = false;
foreach (Active active in mActiveList.ToList())
{
// It is assumed that if the activations are no longer needed, they will
// be removed here after they are returned.
if (!active.mPlaceholder && !active.mMarked)
{
mActiveList.Remove(active);
}
active.Cleanup();
}
// Remvoe stale items from the active list that are not marked
}
/// <summary>
/// Add a new activation.
/// </summary>
/// <param name="active"></param>
private void Add(Active active)
{
mActiveList.Add(active);
}
/// <summary>
/// Adds a new activation to the condition or if normal or unavailable, removes the
/// activation.
/// </summary>
/// <param name="level">The level</param>
/// <param name="text">The descriptive text for the condition</param>
/// <param name="code">The native code</param>
/// <param name="qualifier">The qualifier</param>
/// <param name="severity">The native severity</param>
/// <returns>true if the activation is modified</returns>
public bool Add(Level level, string text = "", string code = "", string qualifier = "", string severity = "")
{
bool result = false;
// Get the first activation
Active first = null;
if (mActiveList.Count > 0)
{
first = mActiveList.First();
}
// Check for a reset of all conditions for a normal or an unavailable
if ((level == Level.NORMAL || level == Level.UNAVAILABLE) && code.Length == 0)
{
// If we haven't changed.
if (mActiveList.Count == 1 && first.mLevel == level)
{
first.mMarked = true;
}
else
{
// Create a new placeholder activation. We don't need to remember the
// old activations because the global normal will reset everything.
mActiveList.Clear();
Add(new Active(mName, level));
result = mChanged = true;
}
}
else
{
// If the first entry is a normal or unavailable and we are entering
// into a warning or fault, remove the normal or unavailable
if (mActiveList.Count() == 1 && first.mPlaceholder)
{
mActiveList.Clear();
}
// See if we can find the activation with the same native code.
Active found = mActiveList.Find(delegate (Active ak) { return ak.mNativeCode == code; });
if (found != null)
{
// If we found it, update all the properties and see if it has changed.
// This will mark this activation
result = found.Set(level, text, qualifier, severity);
mChanged = mChanged || result;
}
else
{
// Otherwise, we have a new activation and we should create a new one.
Add(new Active(mName, level, text, code, qualifier, severity));
result = mChanged = true;
}
}
return result;
}
/// <summary>
/// Clear a condition from the active list - Used only for simple Conditions.
/// </summary>
/// <param name="code">The native code</param>
/// <returns>true if the activation is found</returns>
public bool Clear(string code)
{
// Find the activation.
Active found = mActiveList.Find(delegate (Active ak) { return ak.mNativeCode == code; });
if (found != null)
{
// If we've removed the last activation, go back to normal.
if (mActiveList.Count() == 1)
{
Add(Level.NORMAL);
}
else
{
// Otherwise, just clear this one.
found.Set(Level.NORMAL);
// Clear makes the activation be removed next sweep.
found.Clear();
}
mChanged = true;
return true;
}
else
{
return false;
}
}
// Cover to set everything to normal.
public bool Normal()
{
return Add(Level.NORMAL);
}
/// <summary>
/// Used to get a list of the active conditions for writing out to
/// the clients.
/// </summary>
/// <param name="all">This flag is used to get all activations, regardless
/// of their changed state. This is used to deliver initial state to the client</param>
/// <returns>A list of activations (also DataItems)</returns>
public override List<DataItemRed> ItemList(bool all = false)
{
List<DataItemRed> list = new List<DataItemRed>();
if (all)
{
// Just grab all the activations.
foreach (Active active in mActiveList)
{
list.Add(active);
}
}
else if (mSimple)
{
// For a simple condition, we are only looking for the changed set.
// Since we don't care about the mark and sweep, this is similar to
// all other data items.
foreach (Active active in mActiveList)
{
if (active.Changed)
{
list.Add(active);
}
}
}
else if (mBegun && mPrepared)
{
if (mChanged)
{
// Find all the changed activations and add them to the list
foreach (Active active in mActiveList)
{
if (active.Changed)
{
list.Add(active);
}
}
}
}
return list;
}
}
}
+26 -11
View File
@@ -4,38 +4,53 @@
xsi:schemaLocation="http://www.nlog-project.org/schemas/NLog.xsd NLog.xsd"
autoReload="true"
throwExceptions="false"
internalLogLevel="Off" internalLogFile="c:\temp\nlog-internal.log">
internalLogLevel="Off" internalLogFile="c:\temp\nlog-internal.log" >
<!-- optional, add some variables
<!-- optional, add some variabeles
https://github.com/nlog/NLog/wiki/Configuration-file#variables
-->
<variable name="myvar" value="myvalue"/>
<!--
See https://github.com/nlog/nlog/wiki/Configuration-file
<!--
See https://github.com/nlog/nlog/wiki/Configuration-file
for information on customizing logging rules and outputs.
-->
<targets>
<!--
add your targets here
<targets async="true">
<!--
add your targets here
See https://github.com/nlog/NLog/wiki/Targets for possible targets.
See https://github.com/nlog/NLog/wiki/Layout-Renderers for the possible layout renderers.
-->
<!--
Write events to a file with the date in the filename.
Write events to a file with the date in the filename.
<target xsi:type="File" name="f" fileName="${basedir}/logs/${shortdate}.log"
layout="${longdate} ${uppercase:${level}} ${message}" />
-->
<target xsi:type="File"
name="f"
fileName="${basedir}/logs/${shortdate}.log"
layout="${longdate} ${uppercase:${level}} ${message}"
/>
<!--<target xsi:type="File"
name="default"
layout="${longdate} - ${level:uppercase=true}: ${message}${onexception:${newline}EXCEPTION\: ${exception:format=ToString}}"
fileName="${specialfolder:ApplicationData}\${appName}\Debug.log"
keepFileOpen="false"
archiveFileName="${specialfolder:ApplicationData}\${appName}\Debug_${shortdate}.{##}.log"
archiveNumbering="Sequence"
archiveEvery="Day"
maxArchiveFiles="30"
/>-->
</targets>
<rules>
<!-- add your logging rules here -->
<!--
Write all events with minimal level of Debug (So Debug, Info, Warn, Error and Fatal, but not Trace) to "f"
<logger name="*" minlevel="Debug" writeTo="f" />
-->
<logger name="*" minlevel="Debug" writeTo="f" />
</rules>
</nlog>
</nlog>
+470 -107
View File
@@ -37,12 +37,12 @@
</xs:attribute>
<xs:attribute name="globalThreshold" type="NLogLevel">
<xs:annotation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged..</xs:documentation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwExceptions" type="xs:boolean">
<xs:annotation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false.</xs:documentation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false. Not recommend to set to true in production!</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwConfigExceptions" type="xs:boolean">
@@ -72,7 +72,7 @@
</xs:attribute>
<xs:attribute name="parseMessageTemplates" type="xs:boolean">
<xs:annotation>
<xs:documentation>Perform mesage template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
<xs:documentation>Perform message template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -123,7 +123,7 @@
</xs:choice>
<xs:attribute name="name" use="optional">
<xs:annotation>
<xs:documentation>Name of the logger. May include '*' character which acts like a wildcard. Allowed forms are: *, Name, *Name, Name* and *Name*</xs:documentation>
<xs:documentation>Name of the logger. May include wildcard characters ('*' or '?').</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="levels" type="NLogLevelList">
@@ -156,9 +156,9 @@
<xs:documentation>Ignore further rules if this one matches.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enabled" type="xs:boolean" default="true">
<xs:attribute name="ruleName" type="xs:string" use="optional">
<xs:annotation>
<xs:documentation>Enable or disable logging rule. Disabled rules are ignored.</xs:documentation>
<xs:documentation>Rule identifier to allow rule lookup with Configuration.FindRuleByName and Configuration.RemoveRuleByName.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -171,6 +171,11 @@
<xs:element name="whenNotEqual" type="whenNotEqual" />
<xs:element name="whenRepeated" type="whenRepeated" />
</xs:choice>
<xs:attribute name="defaultAction" type="FilterResult">
<xs:annotation>
<xs:documentation>Default action if none of the filters match.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:simpleType name="NLogLevel">
<xs:restriction base="xs:string">
@@ -210,12 +215,19 @@
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLogVariable">
<xs:choice minOccurs="0" maxOccurs="1">
<xs:element name="value" minOccurs="0" maxOccurs="1" type="xs:string">
<xs:annotation>
<xs:documentation>Variable value. Note, the 'value' attribute has precedence over this one.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:choice>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Variable name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute" use="required">
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Variable value.</xs:documentation>
</xs:annotation>
@@ -276,6 +288,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="batchSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="forceLockingQueue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="fullBatchSizeWriteLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="overflowAction" minOccurs="0" maxOccurs="1" type="NLog.Targets.Wrappers.AsyncTargetWrapperOverflowAction" />
<xs:element name="queueLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
@@ -292,6 +305,11 @@
<xs:documentation>Number of log events that should be processed in a batch by the lazy writer thread.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="forceLockingQueue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether to use the locking queue, instead of a lock-free concurrent queue The locking queue is less concurrent when many logger threads, but reduces memory allocation</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="fullBatchSizeWriteLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>Limit of full s to write before yielding into Performance is better when writing many small batches, than writing a single large batch</xs:documentation>
@@ -309,7 +327,7 @@
</xs:attribute>
<xs:attribute name="timeToSleepBetweenBatches" type="xs:integer">
<xs:annotation>
<xs:documentation>Time in milliseconds to sleep between batches.</xs:documentation>
<xs:documentation>Time in milliseconds to sleep between batches. (1 or less means trigger on new activity)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -334,6 +352,7 @@
<xs:element name="asyncFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="flushOnConditionOnly" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="asyncFlush" type="xs:boolean">
@@ -351,6 +370,11 @@
<xs:documentation>Name of the target.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="flushOnConditionOnly" type="xs:boolean">
<xs:annotation>
<xs:documentation>Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -419,18 +443,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -438,7 +464,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -471,24 +497,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -496,9 +507,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -506,14 +527,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -521,11 +562,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -561,9 +597,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -588,14 +624,26 @@
<xs:enumeration value="Discard" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="System.Security.Authentication.SslProtocols">
<xs:restriction base="xs:string">
<xs:enumeration value="None" />
<xs:enumeration value="Ssl2" />
<xs:enumeration value="Ssl3" />
<xs:enumeration value="Tls" />
<xs:enumeration value="Tls11" />
<xs:enumeration value="Tls12" />
<xs:enumeration value="Default" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Targets.NLogViewerParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
@@ -603,6 +651,11 @@
<xs:documentation>Viewer parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="ColoredConsole">
<xs:complexContent>
@@ -613,11 +666,13 @@
<xs:element name="header" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="footer" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="enableAnsiOutput" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="errorStream" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="useDefaultRowHighlightingRules" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="highlight-row" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleRowHighlightingRule" />
<xs:element name="highlight-word" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleWordHighlightingRule" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -645,6 +700,11 @@
<xs:documentation>Indicates whether to auto-check if the console is available. - Disables console writing if Environment.UserInteractive = False (Windows Service) - Disables console writing if Console Standard Input is not available (Non-Console-App)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enableAnsiOutput" type="xs:boolean">
<xs:annotation>
<xs:documentation>Enables output using ANSI Color Codes</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encoding" type="xs:string">
<xs:annotation>
<xs:documentation>The encoding for writing messages to the .</xs:documentation>
@@ -660,6 +720,11 @@
<xs:documentation>Indicates whether to use default row highlighting rules.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -768,6 +833,7 @@
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="error" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -805,6 +871,11 @@
<xs:documentation>Indicates whether to send the log messages to the standard error instead of the standard output.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -946,22 +1017,36 @@
</xs:complexType>
<xs:complexType name="NLog.Targets.DatabaseParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="dbType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="precision" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="scale" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameterType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="format" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="culture" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="dbType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter DbType.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="precision" type="xs:byte">
<xs:annotation>
<xs:documentation>Database parameter precision.</xs:documentation>
@@ -972,9 +1057,19 @@
<xs:documentation>Database parameter scale.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:attribute name="parameterType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
<xs:documentation>Type of the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="format" type="xs:string">
<xs:annotation>
<xs:documentation>Convert format of the database parameter value .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="culture" type="xs:string">
<xs:annotation>
<xs:documentation>Culture used for parsing parameter string-value for type-conversion</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -1076,7 +1171,7 @@
</xs:attribute>
<xs:attribute name="entryType" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Optional entrytype. When not set, or when not convertable to then determined by </xs:documentation>
<xs:documentation>Optional entrytype. When not set, or when not convertible to then determined by </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="eventId" type="SimpleLayoutAttribute">
@@ -1096,7 +1191,7 @@
</xs:attribute>
<xs:attribute name="maxKilobytes" type="xs:long">
<xs:annotation>
<xs:documentation>Maximum Event log size in kilobytes. If null, the value won't be set. Default is 512 Kilobytes as specified by Eventlog API</xs:documentation>
<xs:documentation>Maximum Event log size in kilobytes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxMessageLength" type="xs:integer">
@@ -1287,7 +1382,7 @@
</xs:attribute>
<xs:attribute name="forceMutexConcurrentWrites" type="xs:boolean">
<xs:annotation>
<xs:documentation>Value indicationg whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
<xs:documentation>Indicates whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="replaceFileContentsOnEachWrite" type="xs:boolean">
@@ -1461,6 +1556,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="filter" minOccurs="0" maxOccurs="1" type="Filter" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1867,6 +1963,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="maxLogsCount" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1879,6 +1976,11 @@
<xs:documentation>Layout used to format log messages.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxLogsCount" type="xs:integer">
<xs:annotation>
<xs:documentation>Max number of items to have in memory</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -1937,6 +2039,8 @@
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2004,6 +2108,16 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -2022,18 +2136,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -2041,7 +2157,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2074,24 +2190,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -2099,9 +2200,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -2109,14 +2220,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -2124,11 +2255,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -2164,9 +2290,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -2709,6 +2835,13 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvColumnDelimiterMode">
<xs:restriction base="xs:string">
<xs:enumeration value="Auto" />
@@ -2720,17 +2853,11 @@
<xs:enumeration value="Custom" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Layouts.CsvColumn">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="quoting" minOccurs="0" maxOccurs="1" type="NLog.Layouts.CsvQuotingMode" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
@@ -2742,6 +2869,11 @@
<xs:documentation>Name of the column.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="quoting" type="NLog.Layouts.CsvQuotingMode">
<xs:annotation>
<xs:documentation>Override of Quoting mode</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="JsonLayout">
<xs:complexContent>
@@ -2750,11 +2882,12 @@
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.JsonAttribute" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeGdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="renderEmptyObject" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="suppressSpaces" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
@@ -2766,6 +2899,11 @@
<xs:documentation>Option to include all properties from the log event (as JSON)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeGdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2776,6 +2914,11 @@
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="renderEmptyObject" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to render the empty object value {}</xs:documentation>
@@ -2786,11 +2929,6 @@
<xs:documentation>Option to suppress the extra spaces in the output json</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2814,7 +2952,7 @@
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines wether or not this attribute will be Json encoded.</xs:documentation>
<xs:documentation>Determines whether or not this attribute will be Json encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="escapeUnicode" type="xs:boolean">
@@ -2859,16 +2997,24 @@
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
</xs:choice>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log events</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeCallSite" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include call site (class and method name) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2889,6 +3035,11 @@
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2906,6 +3057,218 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="XmlLayout">
<xs:complexContent>
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="elementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="elementValue" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="elementEncode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementName" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementValue" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementEncode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlAttribute">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that will be rendered as the attribute's value.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlElement">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="value" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="when">
<xs:complexContent>
<xs:extension base="Filter">
+17 -4
View File
@@ -9,9 +9,10 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>OPC_UA_REDIS</RootNamespace>
<AssemblyName>OPC-UA-REDIS</AssemblyName>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<Deterministic>true</Deterministic>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
@@ -31,11 +32,15 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
<HintPath>..\packages\NLog.4.6.6\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="StackExchange.Redis, Version=1.2.6.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\StackExchange.Redis.1.2.6\lib\net46\StackExchange.Redis.dll</HintPath>
<HintPath>..\packages\StackExchange.Redis.1.2.6\lib\net45\StackExchange.Redis.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
@@ -52,8 +57,10 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="AdapterRed.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="SOUR-IO.cs" />
<Compile Include="DataItemRed.cs" />
<Compile Include="redUtil.cs" />
</ItemGroup>
<ItemGroup>
<Content Include="NLog.config">
@@ -64,5 +71,11 @@
</None>
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\MTC\MTC.csproj">
<Project>{ec83d80e-9f3b-4de9-b16a-ca216543b7ec}</Project>
<Name>MTC</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>
-15
View File
@@ -1,15 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace OPC_UA_REDIS
{
/// <summary>
/// Classe utilità per Input/Output su SERVER REDIS
/// </summary>
public class SOUR_IO
{
}
}
+4 -4
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="NLog" version="4.5.8" targetFramework="net461" />
<package id="NLog.Config" version="4.5.8" targetFramework="net461" />
<package id="NLog.Schema" version="4.5.8" targetFramework="net461" />
<package id="StackExchange.Redis" version="1.2.6" targetFramework="net461" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net452" />
<package id="NLog" version="4.6.6" targetFramework="net452" />
<package id="NLog.Schema" version="4.6.6" targetFramework="net452" />
<package id="StackExchange.Redis" version="1.2.6" targetFramework="net452" />
</packages>
+803
View File
@@ -0,0 +1,803 @@
using MTC;
using NLog;
using StackExchange.Redis;
using System;
using System.Collections.Generic;
namespace OPC_UA_REDIS
{
public class redUtil
{
/// <summary>
/// wrapper di log
/// </summary>
public static Logger lg;
public redUtil()
{
lg = LogManager.GetCurrentClassLogger();
}
/// <summary>
/// Metodo accesso statico
/// </summary>
public static redUtil man = new redUtil();
#region gestione valori in RedisCache
/// <summary>
/// Nome della variabile HASH da utilizzare (dato CodModulo / Server / DB impiegato da funzionalita' DbConfig) + keyName richiesto...
/// </summary>
public string redHash(string keyName)
{
string answ = keyName;
try
{
answ = string.Format("{0}:{1}", baseUtils.CRS("SOURS_baseHash"), keyName);
}
catch
{ }
return answ;
}
/// <summary>
/// Connessione lazy a redis...
/// </summary>
private static Lazy<ConnectionMultiplexer> lazyConnection = new Lazy<ConnectionMultiplexer>(() =>
{
return ConnectionMultiplexer.Connect("127.0.0.1,abortConnect=false,ssl=false");
});
/// <summary>
/// Connessione lazy a redis...
/// </summary>
private static Lazy<ConnectionMultiplexer> lazyConnectionAdmin = new Lazy<ConnectionMultiplexer>(() =>
{
return ConnectionMultiplexer.Connect("127.0.0.1,abortConnect=false,ssl=false,allowAdmin=true");
});
/// <summary>
/// Oggetto statico connessione redis
/// </summary>
public static ConnectionMultiplexer connRedis
{
get
{
return lazyConnection.Value;
}
}
/// <summary>
/// Oggetto statico connessione redis
/// </summary>
public static ConnectionMultiplexer connRedisAdmin
{
get
{
return lazyConnectionAdmin.Value;
}
}
/// <summary>
/// Restituisce info dei server connessi...
/// </summary>
/// <returns></returns>
public IServer[] redServInfo()
{
IServer[] answ = new IServer[1];
if (connRedisAdmin.IsConnected)
{
try
{
answ = new IServer[connRedisAdmin.GetEndPoints().Length];
int i = 0;
foreach (var ep in connRedisAdmin.GetEndPoints())
{
var server = connRedisAdmin.GetServer(ep);
answ[i] = server;
i++;
}
}
catch (Exception exc)
{
lg.Error("Eccezione in redServInfo: " + exc.ToString());
}
}
else
{
lg.Error("Server REDIS Admin non disponibile");
}
return answ;
}
/// <summary>
/// Restituisce una chiave salvata in RedisCache
/// </summary>
/// <param name="chiave"></param>
/// <returns></returns>
public string getRSV(string chiave)
{
string answ = "";
if (connRedis.IsConnected)
{
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.StringGet(chiave);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in getRSV:{0}{1}", Environment.NewLine, exc));
}
}
else
{
lg.Error("Server REDIS non disponibile per getRSV");
}
return answ;
}
/// <summary>
/// Salva una chiave in RedisCache
/// </summary>
/// <param name="chiave"></param>
/// <param name="valore"></param>
/// <returns></returns>
public bool setRSV(string chiave, string valore)
{
bool answ = false;
if (connRedis.IsConnected)
{
try
{
IDatabase cache = connRedis.GetDatabase();
cache.StringSet(chiave, valore);
answ = true;
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in setRSV:{0}{1}", Environment.NewLine, exc));
}
}
else
{
lg.Error("Server REDIS non disponibile (setRSV)");
}
return answ;
}
/// <summary>
/// Salva una chiave in RedisCache
/// </summary>
/// <param name="chiave"></param>
/// <param name="valore"></param>
/// <param name="TTL_sec">in secondi</param>
/// <returns></returns>
public bool setRSV(string chiave, string valore, int TTL_sec)
{
bool answ = false;
if (connRedis.IsConnected)
{
try
{
IDatabase cache = connRedis.GetDatabase();
TimeSpan expT = new TimeSpan(0, 0, TTL_sec);
// salvo con expyry...
cache.StringSet(chiave, valore, expT);
answ = true;
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in setRSV:{0}{1}", Environment.NewLine, exc));
}
}
else
{
lg.Error("Server REDIS non disponibile (setRSV:TTL)");
}
return answ;
}
/// <summary>
/// Incrementa un contatore in Redis
/// </summary>
/// <param name="chiave"></param>
/// <returns></returns>
public long setRCntI(string chiave)
{
long answ = 0;
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.StringIncrement(chiave, 1);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in setRCI:{0}{1}", Environment.NewLine, exc));
}
return answ;
}
/// <summary>
/// Decrementa un contatore in Redis
/// </summary>
/// <param name="chiave"></param>
/// <returns></returns>
public long setRCntD(string chiave)
{
long answ = 0;
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.StringDecrement(chiave, 1);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in setRCD:{0}{1}", Environment.NewLine, exc));
}
return answ;
}
/// <summary>
/// Restituisce una chiave COUNTER in RedisCache
/// </summary>
/// <param name="chiave"></param>
/// <returns></returns>
public int getRCnt(string chiave)
{
int answInt = 0;
string answ = "";
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.StringGet(chiave);
answInt = Convert.ToInt32(answ);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in getRSV:{0}{1}", Environment.NewLine, exc));
}
return answInt;
}
/// <summary>
/// Resetta (elimina) un contatore in Redis
/// </summary>
/// <param name="chiave"></param>
/// <returns></returns>
public bool resetRCnt(string chiave)
{
bool answ = false;
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.KeyDelete(chiave);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in resetRCnt:{0}{1}", Environment.NewLine, exc));
}
return answ;
}
/// <summary>
/// Restituisce un set KVP (Key Value Pair) salvati in RedisCache
/// </summary>
/// <param name="chiavi"></param>
/// <returns></returns>
public RedisValue[] getRKeys(RedisKey[] chiavi)
{
RedisValue[] answ = null;
try
{
IDatabase cache = connRedis.GetDatabase();
answ = cache.StringGet(chiavi);
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in getRKeys:{0}{1}", Environment.NewLine, exc));
}
return answ;
}
/// <summary>
/// Salva un set KVP (Key Value Pair) in RedisCache
/// </summary>
/// <param name="valori">Set KVP chiave-valore da salvare</param>
/// <returns></returns>
public bool setRKeys(KeyValuePair<RedisKey, RedisValue>[] valori)
{
bool answ = false;
try
{
IDatabase cache = connRedis.GetDatabase();
cache.StringSet(valori);
answ = true;
}
catch (Exception exc)
{
lg.Info(string.Format("Errore in setRKeys:{0}{1}", Environment.NewLine, exc));
}
return answ;
}
/// <summary>
/// Verifica se ci siano valori nella hash indicata...
/// </summary>
/// <param name="key"></param>
/// <returns></returns>
public bool redHashPresent(RedisKey key)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
answ = cache.HashGetAll(key).Length > 0;
}
catch
{ }
return answ;
}
/// <summary>
/// Verifica se ci siano valori nella hash indicata (string)
/// </summary>
/// <param name="key"></param>
/// <returns></returns>
public bool redHashPresentSz(string key)
{
bool answ = false;
try
{
RedisKey chiave = key;
answ = redHashPresent(chiave);
}
catch
{ }
return answ;
}
/// <summary>
/// Recupera tutti i valori dalla hash
/// </summary>
/// <param name="hashKey"></param>
/// <returns></returns>
public KeyValuePair<string, string>[] redGetHash(string hashKey)
{
KeyValuePair<string, string>[] answ = new KeyValuePair<string, string>[1];
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
HashEntry[] valori = cache.HashGetAll(chiave);
answ = new KeyValuePair<string, string>[valori.Length];
int i = 0;
foreach (HashEntry item in valori)
{
answ[i] = new KeyValuePair<string, string>(item.Name, item.Value);
i++;
}
}
catch
{ }
return answ;
}
/// <summary>
/// Recupera tutti i valori dalla hash in formato Dictionary
/// </summary>
/// <param name="hashKey"></param>
/// <returns></returns>
public Dictionary<string, string> redGetHashDict(string hashKey)
{
Dictionary<string, string> answ = new Dictionary<string, string>();
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
HashEntry[] valori = cache.HashGetAll(chiave);
foreach (HashEntry item in valori)
{
answ.Add(item.Name, item.Value);
}
}
catch
{ }
return answ;
}
/// <summary>
/// Recupera UN SINGOLO VALORE dalla hash per un dato field
/// </summary>
/// <param name="hashKey"></param>
/// <param name="hashField"></param>
/// <returns></returns>
public string redGetHashField(string hashKey, string hashField)
{
string answ = "";
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
RedisValue campo = hashField;
RedisValue valOut = cache.HashGet(chiave, campo);
answ = valOut.ToString();
}
catch
{ }
return answ;
}
/// <summary>
/// Salvataggio di una hash di valori
/// </summary>
/// <param name="hashKey">chiave</param>
/// <param name="hashFields">valori</param>
/// <returns></returns>
public bool redSaveHash(string hashKey, KeyValuePair<string, string>[] hashFields)
{
bool answ = false;
if (connRedis.IsConnected)
{
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
HashEntry[] valori = new HashEntry[hashFields.Length];
int i = 0;
foreach (KeyValuePair<string, string> kvp in hashFields)
{
valori[i] = new HashEntry(kvp.Key, kvp.Value);
i++;
}
cache.HashSet(chiave, valori);
answ = true;
}
catch
{ }
}
else
{
lg.Error("Server REDIS non disponibile (redSaveHash)");
}
return answ;
}
/// <summary>
/// Salvataggio di una hash di valori
/// </summary>
/// <param name="hashKey">chiave</param>
/// <param name="hashListKVP">valori come lista KVP</param>
/// <returns></returns>
public bool redSaveHashList(string hashKey, List<KeyValuePair<string, string>> hashListKVP)
{
bool answ = false;
if (connRedis.IsConnected)
{
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
HashEntry[] valori = new HashEntry[hashListKVP.Count];
int i = 0;
foreach (KeyValuePair<string, string> kvp in hashListKVP)
{
valori[i] = new HashEntry(kvp.Key, kvp.Value);
i++;
}
cache.HashSet(chiave, valori);
answ = true;
}
catch
{ }
}
else
{
lg.Error("Server REDIS non disponibile (redSaveHashList)");
}
return answ;
}
/// <summary>
/// Salvataggio di una hash di valori in formato Dictionary
/// </summary>
/// <param name="hashKey">chiave</param>
/// <param name="hashFields">valori</param>
/// <returns></returns>
public bool redSaveHashDict(string hashKey, Dictionary<string, string> hashFields)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
HashEntry[] valori = new HashEntry[hashFields.Count];
int i = 0;
foreach (KeyValuePair<string, string> kvp in hashFields)
{
valori[i] = new HashEntry(kvp.Key, kvp.Value);
i++;
}
cache.HashSet(chiave, valori);
answ = true;
}
catch
{ }
return answ;
}
/// <summary>
/// Salvataggio di una hash di valori
/// </summary>
/// <param name="hashKey">chiave</param>
/// <param name="hashFields">valori</param>
/// <param name="expireSeconds">scadenza preimpostata hash (secondi) | defaoult = -1 (non scade)</param>
/// <returns></returns>
public bool redSaveHash(string hashKey, KeyValuePair<string, string>[] hashFields, double expireSeconds = -1)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
answ = redSaveHash(hashKey, hashFields);
if (expireSeconds > 0)
{
cache.KeyExpire(chiave, DateTime.Now.AddSeconds(expireSeconds));
}
//answ = true;
}
catch
{ }
return answ;
}
/// <summary>
/// Salvataggio di una hash di valori in formato Dictionary
/// </summary>
/// <param name="hashKey">chiave</param>
/// <param name="hashFields">valori</param>
/// <param name="expireSeconds">scadenza preimpostata hash (secondi) | defaoult = -1 (non scade)</param>
/// <returns></returns>
public bool redSaveHashDict(string hashKey, Dictionary<string, string> hashFields, double expireSeconds = -1)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = hashKey;
answ = redSaveHashDict(hashKey, hashFields);
if (expireSeconds > 0)
{
cache.KeyExpire(chiave, DateTime.Now.AddSeconds(expireSeconds));
}
//answ = true;
}
catch
{ }
return answ;
}
/// <summary>
/// Elimina una key (hash, string)
/// </summary>
/// <param name="key"></param>
/// <returns></returns>
public bool redDelKey(string key)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
try
{
RedisKey chiave = key;
cache.KeyDelete(chiave);
answ = true;
}
catch
{ }
return answ;
}
/// <summary>
/// Flush completo cache redis
/// </summary>
/// <param name="keyPattern">** = tutti</param>
/// <returns></returns>
public bool redFlushKey(string keyPattern)
{
bool answ = false;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
// se vuoto = ALL...
keyPattern = keyPattern == "" ? "**" : keyPattern;
try
{
foreach (var ep in connRedis.GetEndPoints())
{
var server = connRedis.GetServer(ep);
foreach (var key in server.Keys(pattern: keyPattern))
{
cache.KeyDelete(key);
}
}
answ = true;
}
catch (Exception exc)
{
lg.Error(string.Format("Eccezione: {0}", exc));
}
return answ;
}
/// <summary>
/// Conta num oggetti cache redis che rispondono a pattern
/// </summary>
/// <param name="keyPattern">** = tutti</param>
/// <returns></returns>
public int redCountKey(string keyPattern)
{
int answ = 0;
// cerco se ci sia valore in redis...
IDatabase cache = connRedis.GetDatabase();
// se vuoto = ALL...
keyPattern = keyPattern == "" ? "**" : keyPattern;
try
{
foreach (var ep in connRedis.GetEndPoints())
{
var server = connRedis.GetServer(ep);
foreach (var key in server.Keys(pattern: keyPattern))
{
answ++;
}
}
}
catch (Exception exc)
{
lg.Error(string.Format("Eccezione: {0}", exc));
}
return answ;
}
/// <summary>
/// Restituisce numero record in Redis DB
/// </summary>
public long numRecRedis
{
get
{
long answ = 0;
try
{
foreach (var ep in connRedis.GetEndPoints())
{
var server = connRedis.GetServer(ep);
answ += server.DatabaseSize();
}
}
catch
{ }
return answ;
}
}
/// <summary>
/// Restituisce oggetti cache redis che rispondono a pattern
/// </summary>
/// <param name="keyPattern">** = tutti</param>
/// <param name="orderBy">Tipo di ordinamento per kvp</param>
/// <returns></returns>
public List<KeyValuePair<string, int>> redGetCounterByKey(string keyPattern, kvpOrderBy orderBy)
{
int numAnsw = redCountKey(keyPattern);
RedisKey[] chiavi = new RedisKey[numAnsw];
List<KeyValuePair<string, int>> answ = new List<KeyValuePair<string, int>>();
// se vuoto = ALL...
keyPattern = keyPattern == "" ? "**" : keyPattern;
// recupero in primis elenco chiavi
try
{
int i = 0;
foreach (var ep in connRedis.GetEndPoints())
{
var server = connRedis.GetServer(ep);
foreach (var key in server.Keys(pattern: keyPattern))
{
chiavi[i] = key;
i++;
}
}
}
catch (Exception exc)
{
lg.Error(string.Format("Eccezione: {0}", exc));
}
// ora recupero valori!
var valori = getRKeys(chiavi);
int currVal = 0;
// popolo rispsota
try
{
for (int i = 0; i < numAnsw; i++)
{
Int32.TryParse(valori[i], out currVal);
answ.Add(new KeyValuePair<string, int>(chiavi[i], currVal));
}
}
catch
{ }
// se richiesto riordino...
switch (orderBy)
{
case kvpOrderBy.KeyAsc:
answ.Sort(CompareKey);
break;
case kvpOrderBy.KeyDesc:
answ.Sort(CompareKeyDesc);
break;
case kvpOrderBy.ValAsc:
answ.Sort(CompareVal);
break;
case kvpOrderBy.ValDesc:
answ.Sort(CompareValDesc);
break;
default:
break;
}
return answ;
}
/// <summary>
/// Effettua comaprazione x CHIAVE in KVP ASC
/// </summary>
/// <param name="x"></param>
/// <param name="y"></param>
/// <returns></returns>
private int CompareKey(KeyValuePair<string, int> x, KeyValuePair<string, int> y)
{
return x.Key.CompareTo(y.Key);
}
/// <summary>
/// Effettua comaprazione x VALORE in KVP ASC
/// </summary>
/// <param name="x"></param>
/// <param name="y"></param>
/// <returns></returns>
public int CompareVal(KeyValuePair<string, int> x, KeyValuePair<string, int> y)
{
return x.Value.CompareTo(y.Value);
}
/// <summary>
/// Effettua comaprazione x CHIAVE in KVP DESC
/// </summary>
/// <param name="x"></param>
/// <param name="y"></param>
/// <returns></returns>
private int CompareKeyDesc(KeyValuePair<string, int> x, KeyValuePair<string, int> y)
{
return y.Key.CompareTo(x.Key);
}
/// <summary>
/// Effettua comaprazione x VALORE in KVP DESC
/// </summary>
/// <param name="x"></param>
/// <param name="y"></param>
/// <returns></returns>
public int CompareValDesc(KeyValuePair<string, int> x, KeyValuePair<string, int> y)
{
return y.Value.CompareTo(x.Value);
}
/// <summary>
/// Tipologia di ordinamento x liste KVP
/// </summary>
public enum kvpOrderBy
{
/// <summary>
/// Ordinamento ASCending per KEY
/// </summary>
KeyAsc,
/// <summary>
/// Ordinamento DESCending per KEY
/// </summary>
KeyDesc,
/// <summary>
/// Ordinamento ASCending per VAL
/// </summary>
ValAsc,
/// <summary>
/// Ordinamento DESCending per VAL
/// </summary>
ValDesc
}
#endregion
}
}
+241 -262
View File
@@ -1,9 +1,13 @@
using MTC;
using NLog;
using OPC_UA_REDIS;
using System;
using System.Collections.Generic;
using System.Net;
namespace SCMA.AdapterCom
{
/// <summary>
/// Gateway di comunicazione secondo diversi standard, partendo da oggetti BASE MTC
/// </summary>
@@ -12,6 +16,14 @@ namespace SCMA.AdapterCom
#region oggetti base
/// <summary>
/// Dictionary degli errori item ricorrenti
/// </summary>
protected Dictionary<string, int> itemErrors;
/// <summary>
/// wrapper di log
/// </summary>
public static Logger lg;
/// <summary>
/// Protocollo attivo per la comunicazione dell'adapter
/// </summary>
@@ -26,6 +38,18 @@ namespace SCMA.AdapterCom
/// </summary>
public allarme[] elencoAllarmi;
/// <summary>
/// DataModel di riferimento
/// </summary>
public string DataModel;
/// <summary>
/// Dizionario conversione nome variabili con replace "like" (per gestione REDIS "_" --> ":")
/// </summary>
public Dictionary<string, replDict> nameRepRoles = new Dictionary<string, replDict>();
/// <summary>
/// Dizionario conversione nome variabiliin memoria REDIS
/// </summary>
public Dictionary<string, string> memCopyList = new Dictionary<string, string>();
/// <summary>
/// Porta comunicazione standard oggetto
/// </summary>
public int port;
@@ -53,6 +77,14 @@ namespace SCMA.AdapterCom
/// Elenco di TUTTI i NODI CONDITIONS gestiti dal gateway (allarme/condizione)...
/// </summary>
public Dictionary<string, itemNode> conditionNodes = new Dictionary<string, itemNode>();
/// <summary>
/// Elenco ultimi allarmi riportati...
/// </summary>
protected Dictionary<string, string> lastAlarmList;
/// <summary>
/// Bool di allarmi presenti
/// </summary>
public bool alarmPresent = false;
#endregion
@@ -63,9 +95,12 @@ namespace SCMA.AdapterCom
/// </summary>
public Gateway()
{
lg = LogManager.GetCurrentClassLogger();
itemErrors = new Dictionary<string, int>();
port = 0;
connConfig = "";
protocollo = gwProtocol.LOGFILE;
lastAlarmList = new Dictionary<string, string>();
}
/// <summary>
/// Inizia la raccolta dati per confronto modifica da precedente...
@@ -92,52 +127,6 @@ namespace SCMA.AdapterCom
}
}
#if false
// Separate out the data items into those that are on one line and those
// need separate lines.
List<SimpleDataItem> together = new List<SimpleDataItem>();
List<SimpleDataItem> separate = new List<SimpleDataItem>();
foreach (object di in trackItems)
{
List<SimpleDataItem> list = di.ItemList();
if (di.NewLine)
separate.AddRange(list);
else
together.AddRange(list);
}
// Compone all the same line data items onto one line.
string line;
if (timestamp == null)
{
DateTime now = DateTime.UtcNow;
timestamp = now.ToString("yyyy-MM-dd\\THH:mm:ss.fffffffK");
}
if (together.Count > 0)
{
line = timestamp;
foreach (SimpleDataItem di in together)
line += "|" + di.ToString();
line += "\n";
SendToAll(line);
}
// Now write out all the separate lines
if (separate.Count > 0)
{
foreach (SimpleDataItem di in separate)
{
line = timestamp;
line += "|" + di.ToString() + "\n";
SendToAll(line);
}
}
// Flush the output
FlushAll();
#endif
// Cleanup
foreach (object di in itemNodes)
{
@@ -147,7 +136,7 @@ namespace SCMA.AdapterCom
myBegun = false;
}
/// <summary>
/// Imposta TUTTI i data items unavailable
/// Imposta TUTTI i data items null/unavailable
/// </summary>
public virtual void setAllUnavailable()
{
@@ -162,40 +151,49 @@ namespace SCMA.AdapterCom
/// </summary>
public virtual void start()
{
#if false
if (!mRunning)
{
mListener = new TcpListener(IPAddress.Any, mPort);
mListener.Start();
mListenThread = new Thread(new ThreadStart(ListenForClients));
mListenThread.Start();
}
#endif
}
/// <summary>
/// FERMA processo lettura CNC e invio dati a client
/// </summary>
public virtual void stop()
{
#if false
if (mRunning)
}
#endregion
#region gestione controllo stato catena applicativi e messaggi da piattaforma
/// <summary>
/// Effettua chiamata URL e restituisce risultato
/// </summary>
/// <param name="URL"></param>
/// <returns></returns>
public string callUrl(string URL)
{
string answ = "";
try
{
mRunning = false;
mListener.Stop();
foreach (Object obj in mClients)
{
Stream client = (Stream)obj;
client.Close();
}
mClients.Clear();
// Wait 5 seconds for the thread to exit.
mListenThread.Join(2000);
// Wait for all client threads to exit.
mActiveClients.Wait(2000);
}
#endif
var client = new WebClient();
client.Headers.Add("user-agent", utils.CRS("appName"));
answ = client.DownloadString(URL);
}
catch (Exception exc)
{
lg.Error(exc, "Errore in chiamata URL {0}{1}{2}", URL, Environment.NewLine, exc);
}
// restituisco valore!
return answ;
}
/// <summary>
/// Verifica lo stato di un servizio indicato per via numerica (differente x MTC / OPC-UA-REDIS)
/// </summary>
/// <param name="numServ"></param>
/// <returns></returns>
public virtual bool checkStatus(int numServ)
{
bool answ = false;
return answ;
}
#endregion
@@ -211,12 +209,7 @@ namespace SCMA.AdapterCom
{
if (!itemNodes.ContainsKey(key))
{
itemNode currItem = new itemNode(tipo, availStatus.UNAVAILABLE.ToString());
#if false
// di base salvo tipo/valore come KVP nell'item...
Dictionary<itemType, object> currObj = new Dictionary<itemType, object>();
currObj.Add(tipo, "UNAVAILABLE");
#endif
itemNode currItem = new itemNode(tipo, availStatus.UNAVAILABLE.ToString().ToLower());
itemNodes.Add(key, currItem);
}
}
@@ -228,7 +221,11 @@ namespace SCMA.AdapterCom
public virtual void addItemNodeAndSet(string key, itemType tipo, object value)
{
addItemNodeByType(key, tipo);
updateItemNodeValue(key, value);
// SOLO se richiesto FULL RESET...
if (baseUtils.CRB("fullReset"))
{
updateItemNodeValue(key, value);
}
}
/// <summary>
/// Aggiunge un generico item all'elenco di quelli tracciati (NON STRONGLY TYPED!!! occhio!!!)
@@ -275,7 +272,45 @@ namespace SCMA.AdapterCom
/// <param name="key"></param>
public virtual object getItemNode(string key)
{
return itemNodes[key].cObject;
object answ = null;
// controllos e ci sia chiave...
if (itemNodes.ContainsKey(key))
{
try
{
answ = itemNodes[key].cObject;
}
catch (Exception exc)
{
lg.Error($"Eccezione in getItemNode per la chiave {key}:{Environment.NewLine}{exc}");
}
}
else
{
answ = "";
try
{
// salvo in memoria nelle chiavi non trovate
if (itemErrors.ContainsKey(key))
{
itemErrors[key]++;
}
else
{
itemErrors.Add(key, 1);
}
// ...se > 100 volte --> log...
if (itemErrors[key] > 100)
{
lg.Error($"Errore: è stato richiesto 100 volte in getItemNode la chiave {key} NON ESISTENTE");
itemErrors[key] = 1;
}
}
catch
{ }
}
return answ;
}
/// <summary>
/// AGGIORNA un generico item all'elenco di quelli tracciati (NON STRONGLY TYPED!!! occhio!!!)
@@ -337,27 +372,142 @@ namespace SCMA.AdapterCom
/// </summary>
public virtual void processAlarm()
{
if (AlarmFlags != null)
// continuo controllo
if (AlarmFlags != null && AlarmFlags.Length > 0)
{
// variabili helper
StFlag32 AlarmBlock = 0;
allarme currAllarm;
Dictionary<string, string> grpAlarmList = new Dictionary<string, string>();
string alarmChannel = "";
// controllo TUTTI i bit della variabile COMPLETA degli status allarmi: se ce ne sono di alzati DEVO processare...
for (int i = 0; i < AlarmFlags.Length / 4; i++)
{
// leggo 32bit alla volta...
AlarmBlock = (StFlag32)BitConverter.ToUInt32(AlarmFlags, i * 4);
for (int j = 0; j < 32; j++)
if (AlarmBlock != StFlag32.NONE)
{
// converto! e aggiungo allarmi sollevati al corretto controller allarmi...
if (AlarmBlock.HasFlag((StFlag32)Math.Pow(2, j)))
alarmPresent = true;
for (int j = 0; j < 32; j++)
{
// recupero allarme da oggetto in memoria...
currAllarm = elencoAllarmi[i * 32 + j];
addAlarm(currAllarm);
// converto! e aggiungo allarmi sollevati al corretto controller allarmi...
if (AlarmBlock.HasFlag((StFlag32)Math.Pow(2, j)))
{
// recupero allarme da oggetto in memoria...
currAllarm = elencoAllarmi[i * 32 + j];
addAlarm(currAllarm);
// ora in base al TIPO di gateway determino il canale allarme...
alarmChannel = currAllarm.gruppo;
// se sono in SOURS
if (protocollo == gwProtocol.SOURS)
{
// sostituisco gruppo con nome esatto...
switch (alarmChannel.ToUpper())
{
case "CNC":
alarmChannel = nCncConditions;
break;
case "HMI":
alarmChannel = nHmiConditions;
break;
case "PLC":
alarmChannel = nPlcConditions;
break;
}
// sostituisco livello allarme
// aggiorno stringa...
if (!grpAlarmList.ContainsKey(alarmChannel))
{
grpAlarmList.Add(alarmChannel, "");
}
grpAlarmList[alarmChannel] += string.Format("{0}|{1},", currAllarm.codNum, AdapterRed.condLevel(currAllarm.livello));
}
}
}
}
}
// se in modalità SOUR riporto variabile alarmState
if (protocollo == gwProtocol.SOURS)
{
foreach (var item in grpAlarmList)
{
// tolgo ultima stringa
string elenco = item.Value.Substring(0, item.Value.Length - 1);
// salvo...
updateItemNodeValue(item.Key, elenco);
}
// se ho ALMENO un allarme attivo, altrimenti procedo che resetta da solo
if (grpAlarmList.Count > 0)
{
// salvo i LAST alarm...
lastAlarmList = grpAlarmList;
}
}
}
if (!alarmPresent)
{
// devo resettare gli allarmi notificati...
foreach (var item in lastAlarmList)
{
// tolgo ultima stringa
string elenco = "0|000";
// salvo...
updateItemNodeValue(item.Key, elenco);
}
// resetto
lastAlarmList = new Dictionary<string, string>();
}
// se in modalità SOUR riporto variabile alarmState
if (protocollo == gwProtocol.SOURS && alarmPresent)
{
updateItemNodeValue("Alarm", AlarmFlags != null);
}
}
/// <summary>
/// Nome del channel allarmi CNC
/// </summary>
public string nCncConditions
{
get
{
string answ = "CNC";
if (protocollo == gwProtocol.SOURS)
{
answ = "Cnc:Condition";
}
return answ;
}
}
/// <summary>
/// Nome del channel allarmi HMI
/// </summary>
public string nHmiConditions
{
get
{
string answ = "HMI";
if (protocollo == gwProtocol.SOURS)
{
answ = "Hmi:Condition";
}
return answ;
}
}
/// <summary>
/// Nome del channel allarmi PLC
/// </summary>
public string nPlcConditions
{
get
{
string answ = "PLC";
if (protocollo == gwProtocol.SOURS)
{
answ = "Plc:Condition";
}
return answ;
}
}
/// <summary>
@@ -366,8 +516,8 @@ namespace SCMA.AdapterCom
public virtual void addAlarmNodes()
{
// minimo sempre PLC/CNC
addConditionNode("CNC", "CNC");
addConditionNode("PLC", "PLC");
addConditionNode(nCncConditions, "CNC");
addConditionNode(nPlcConditions, "PLC");
}
/// <summary>
/// INIT allarmi a normal
@@ -388,31 +538,6 @@ namespace SCMA.AdapterCom
/// <param name="currAllarm">Allarme da riportare al nodo</param>
public virtual void addAlarm(allarme currAllarm)
{
#if false
// in base al tipo di allarme decodifico condizione...
Condition.Level livello = Condition.Level.NORMAL;
switch (currAllarm.livello)
{
case "WARNING":
livello = Condition.Level.WARNING;
break;
case "FAULT":
default:
livello = Condition.Level.FAULT;
break;
}
// in base al gruppo decido dove assegnare come CONDITION...
switch (currAllarm.gruppo)
{
case "PLC":
mAlarmPLC.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
break;
case "CNC":
default:
mAlarmCNC.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
break;
}
#endif
}
/// <summary>
/// Aggiunta SINGOLO allarme su SPECIFICO nodo
@@ -421,31 +546,6 @@ namespace SCMA.AdapterCom
/// <param name="currAllarm">Allarme da riportare al nodo</param>
public virtual void addAlarm(itemNode alarmNode, allarme currAllarm)
{
#if false
// in base al tipo di allarme decodifico condizione...
Condition.Level livello = Condition.Level.NORMAL;
switch (currAllarm.livello)
{
case "WARNING":
livello = Condition.Level.WARNING;
break;
case "FAULT":
default:
livello = Condition.Level.FAULT;
break;
}
// in base al gruppo decido dove assegnare come CONDITION...
switch (currAllarm.gruppo)
{
case "PLC":
mAlarmPLC.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
break;
case "CNC":
default:
mAlarmCNC.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
break;
}
#endif
}
/// <summary>
/// RESTITUISCE un nodo CONDITION da KEY
@@ -459,35 +559,6 @@ namespace SCMA.AdapterCom
#endregion
}
/// <summary>
/// Classe item node (tipo/obj)
/// </summary>
public class itemNode
{
/// <summary>
/// Tipo oggetto (per cast)
/// </summary>
public itemType cType;
/// <summary>
/// Object specifico
/// </summary>
public object cObject;
/// <summary>
/// costruttore
/// </summary>
public itemNode()
{ }
/// <summary>
/// costruttore
/// </summary>
/// <param name="_tipo"></param>
/// <param name="_obj"></param>
public itemNode(itemType _tipo, object _obj)
{
cType = _tipo;
cObject = _obj;
}
}
/// <summary>
/// Tipologia protocolli di comunicazione ammessi
@@ -507,96 +578,4 @@ namespace SCMA.AdapterCom
/// </summary>
SOURS
}
/// <summary>
/// Tipologia di ITEM
/// </summary>
public enum itemType
{
/// <summary>
/// CONDIZION = ALLARME
/// </summary>
Condition,
/// <summary>
/// Evento = point in time data
/// </summary>
Event,
/// <summary>
/// Messaggio generico
/// </summary>
Message,
/// <summary>
/// Campionamento continuo
/// </summary>
Sample
}
/// <summary>
/// Varibili STATO ATTIVO (es attuatori, sistemi...)
/// </summary>
public enum actStatus
{
/// <summary>
/// Stato inattivo
/// </summary>
INACTIVE = 0,
/// <summary>
/// Stato Attivo
/// </summary>
ACTIVE
}
/// <summary>
/// Varibili STATO OnOff
/// </summary>
public enum onOffStatus
{
/// <summary>
/// Stato OFF
/// </summary>
OFF = 0,
/// <summary>
/// Stato ON
/// </summary>
ON
}
/// <summary>
/// Varibili STATO per EMERGENZA
/// </summary>
public enum emStatus
{
/// <summary>
/// Stato ARMATO
/// </summary>
ARMED = 0,
/// <summary>
/// Stato EMERGENZA PREMUTA
/// </summary>
TRIGGERED
}
/// <summary>
/// Varibili STATO per AVAIL
/// </summary>
public enum availStatus
{
/// <summary>
/// Stato DISPONIBILE
/// </summary>
AVAILABLE = 0,
/// <summary>
/// Stato NON disponibile
/// </summary>
UNAVAILABLE
}
/// <summary>
/// Varibili STATO per AVAIL
/// </summary>
public enum pathType
{
/// <summary>
/// Stato LAVORO
/// </summary>
LAVORO = 0,
/// <summary>
/// Stato ASSERV
/// </summary>
ASSERV
}
}
+98 -29
View File
@@ -1,11 +1,6 @@
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;
//using System.Threading.Tasks;
//using MTC;
using MTC;
using MTC;
using MTConnect;
using System;
namespace SCMA.AdapterCom
{
@@ -65,6 +60,83 @@ namespace SCMA.AdapterCom
#endregion
#region gestione controllo stato catena applicativi e messaggi da piattaforma
/// <summary>
/// Data-Ora ultima risposta AGENT x testing PROBE
/// </summary>
protected DateTime lastCurrProbe;
/// <summary>
/// Valore testuale ultima risposta agent (currentProbe)
/// </summary>
protected string currProbe;
/// <summary>
/// Valore testuale ultima risposta agent (StatusCurrent)
/// </summary>
protected string currStatus;
/// <summary>
/// Verifica lo stato di un servizio indicato per via numerica:
/// 1: verifica che l'AGENT sia attivo (risponde a porta 5000 con qualcosa)
/// 2: verifica risposta AGENT: deve essere XML e deve contenere stringa "MTConnectDevices"
/// 3: verifica che lo status (localhost:5000/current) contenga qualcosa
/// </summary>
/// <param name="numServ"></param>
/// <returns></returns>
public override bool checkStatus(int numServ)
{
// in primis verifico se ho una risposta recente (< 2 sec) dall'agent...
if (lastCurrProbe == null || lastCurrProbe.AddSeconds(2) < DateTime.Now)
{
// altrimenti carico la risposta
refreshAgentResp();
}
// ora so x certo che ho caricato dati recenti...
bool answ = false;
switch (numServ)
{
case 1:
answ = (currProbe != "");
break;
case 2:
answ = (currProbe.IndexOf("MTConnectDevices") >= 0 && currProbe.IndexOf("xml") >= 0);
break;
case 3:
answ = (currStatus != "");
break;
default:
break;
}
return answ;
}
/// <summary>
/// Effettua una chiamata all'agent e salva valore e data chiamata...
/// </summary>
private void refreshAgentResp()
{
// controllo catena AGENT: cerco di scaricare il PROBE alla porta 5000
try
{
currProbe = callUrl("http://localhost:5000");
}
catch
{
currProbe = "";
}
// controllo catena AGENT x CURRENT STATUS: cerco di scaricare /current alla porta 5000
try
{
currStatus = callUrl("http://localhost:5000/current");
}
catch
{
currStatus = "";
}
lastCurrProbe = DateTime.Now;
}
#endregion
#region gestione nodi (dataItems, conditions)
public override void addItemNodeByType(string key, itemType tipo)
@@ -112,6 +184,7 @@ namespace SCMA.AdapterCom
{
base.addItemNode(key, value);
// aggiungo ad adapter
mAdapter.RemoveDataItem((DataItem)value);
mAdapter.AddDataItem((DataItem)value);
}
}
@@ -162,7 +235,12 @@ namespace SCMA.AdapterCom
}
public override void updateItemNodeValue(string key, object value)
{
((DataItem)getItemNode(key)).Value = value;
// aggiorno SE cambiato...
DataItem currDataItem = (DataItem)getItemNode(key);
if (!currDataItem.Value.Equals(value))
{
((DataItem)getItemNode(key)).Value = value;
}
}
public override void updateItemNodeCodeValue(string key, string code, object value)
{
@@ -178,7 +256,9 @@ namespace SCMA.AdapterCom
public override void addConditionNode(string key, object value)
{
base.addConditionNode(key, value);
// aggiungo ad adapter
// aggiungo ad adapter
mAdapter.RemoveDataItem((Condition)value);
mAdapter.AddDataItem((Condition)value);
}
public override void removeAllConditionNodes()
@@ -203,31 +283,20 @@ namespace SCMA.AdapterCom
#region gestione allarmi
/// <summary>
/// Speciofica implementazione x formattazione ALLARMI
/// Specifica implementazione x formattazione ALLARMI
/// </summary>
/// <param name="currAllarm"></param>
public override void addAlarm(allarme currAllarm)
{
// in base al tipo di allarme decodifico condizione...
Condition.Level livello = Condition.Level.NORMAL;
switch (currAllarm.livello)
{
case "WARNING":
livello = Condition.Level.WARNING;
break;
case "FAULT":
default:
livello = Condition.Level.FAULT;
break;
}
// implemento chiamata specifica...
if (conditionNodes.ContainsKey(currAllarm.gruppo))
{
Condition mAlarm = (Condition)conditionNodes[currAllarm.gruppo].cObject;
mAlarm.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
itemNode nodo = conditionNodes[currAllarm.gruppo];
addAlarm(nodo, currAllarm);
}
}
/// <summary>
/// Speciofica implementazione x formattazione ALLARMI
/// Specifica implementazione x formattazione ALLARMI
/// </summary>
/// <param name="currAllarm"></param>
/// <param name="alarmNode">Generico nodo di tipo condition</param>
@@ -255,10 +324,10 @@ namespace SCMA.AdapterCom
{
// registro
Condition newCondNode;
newCondNode = new Condition("CNC");
addConditionNode("CNC", newCondNode);
newCondNode = new Condition("PLC");
addConditionNode("PLC", newCondNode);
newCondNode = new Condition(nCncConditions);
addConditionNode(nCncConditions, newCondNode);
newCondNode = new Condition(nPlcConditions);
addConditionNode(nPlcConditions, newCondNode);
}
/// <summary>
/// Wrapper inizializzazione allarmi
+309 -5
View File
@@ -1,16 +1,320 @@
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;
//using System.Threading.Tasks;
using MTC;
using OPC_UA_REDIS;
namespace SCMA.AdapterCom
{
public class GatewaySOURS : Gateway
{
/// <summary>
/// adapter globale REDIS
/// </summary>
/// <summary>
public AdapterRed mAdapter = new AdapterRed();
#region gestione globale oggetto
/// <summary>
/// Gateway SOUR
/// </summary>
public GatewaySOURS()
{
protocollo = gwProtocol.SOURS;
}
/// <summary>
/// Wrapper metodo Begin
/// </summary>
public override void beginDataCollect()
{
mAdapter.Begin();
}
/// <summary>
/// Wrapper metodo SendChanged
/// </summary>
public override void sendChanged()
{
mAdapter.SendChanged();
}
/// <summary>
/// Wrapper metodo imposta tutto a UNAVAILABLE
/// </summary>
public override void setAllUnavailable()
{
mAdapter.Unavailable();
}
/// <summary>
/// Wrapper metodo START
/// </summary>
public override void start()
{
// passo le tabelle di remap/replace
mAdapter.ServerPort = 6379; // !!! port hard coded
mAdapter.ServerAddr = "127.0.0.1"; // !!! IP hard coded
mAdapter.nameRepRoles = nameRepRoles;
mAdapter.DataModel = DataModel;
// aggiunge il set di allarmi (che è NATIVAMENTE già su 3 lingue... )
mAdapter.elencoAllarmi = elencoAllarmi;
mAdapter.itemNodes = itemNodes;
mAdapter.conditionNodes = conditionNodes;
// avvio oggetto
mAdapter.Start();
}
/// <summary>
/// Wrapper metodo STOP
/// </summary>
public override void stop()
{
mAdapter.Stop();
}
#endregion
#region gestione controllo stato catena applicativi e messaggi da piattaforma
/// <summary>
/// Verifica lo stato di un servizio indicato per via numerica:
/// 1: verifica che servizio REDIS sia OK
/// 2: verifica OPC-UA-SERVER sia ALIVE
/// 3: verifica gateway sia OK (attivo)
/// 4: verifica gateway abbia accesso internet
/// </summary>
/// <param name="numServ"></param>
/// <returns></returns>
public override bool checkStatus(int numServ)
{
bool answ = false;
switch (numServ)
{
case 1:
answ = mAdapter.redServAlive;
break;
case 2:
break;
case 3:
break;
case 4:
break;
default:
break;
}
return answ;
}
#endregion
#region gestione nodi (dataItems, conditions)
public override void addItemNodeByType(string key, itemType tipo)
{
if (!itemNodes.ContainsKey(key))
{
// in base al TIPO genero l'oggetto corretto...
DataItemRed currObj;
switch (tipo)
{
case itemType.Condition:
currObj = new DataItemRed(key);
//currObj = new ConditionRed(key);
break;
default:
currObj = new DataItemRed(key);
break;
}
mAdapter.AddDataItem(currObj);
if (tipo == itemType.Condition)
{
addConditionNode(key, currObj);
addItemNode(key, currObj);
}
else
{
addItemNode(key, currObj);
}
}
}
/// Effettua chiamata VERA su adapter MTConnect...
/// </summary>
/// <param name="value"></param>
public override void addItemNode(string key, object value)
{
if (!itemNodes.ContainsKey(key))
{
base.addItemNode(key, value);
// aggiungo ad adapter
mAdapter.AddDataItem((DataItemRed)value);
}
}
/// <summary>
/// Effettua chiamata VERA su adapter MTConnect...
/// </summary>
/// <param name="value"></param>
public override void addItemNode(object value)
{
DataItemRed currObj = (DataItemRed)value;
string key = currObj.Name;
if (!itemNodes.ContainsKey(key))
{
base.addItemNode(key, value);
// aggiungo ad adapter
mAdapter.AddDataItem((DataItemRed)value);
}
}
/// <summary>
/// Wrapper metodo rimozione di TUTTI gli ITEMS
/// </summary>
public override void removeAllItemNodes()
{
foreach (var item in itemNodes)
{
// rimuovo da SCMA
mAdapter.RemoveDataItem((DataItemRed)item.Value.cObject);
}
base.removeAllItemNodes();
}
/// <summary>
/// Wrapper metodo rimozione ITEMS
/// </summary>
/// <param name="anItem"></param>
public override void removeItemNode(string key)
{
// rimuovo da MTC
mAdapter.RemoveDataItem((DataItemRed)itemNodes[key].cObject);
// rimuovo da vett interno
base.removeItemNode(key);
}
public override void updateItemNodeValue(string key, object value)
{
((DataItemRed)getItemNode(key)).Value = value;
}
public override void updateItemNodeCodeValue(string key, string code, object value)
{
}
/// <summary>
/// wrapper aggiunta condizione
/// </summary>
/// <param name="key"></param>
/// <param name="value"></param>
public override void addConditionNode(string key, object value)
{
if (!conditionNodes.ContainsKey(key))
{
base.addConditionNode(key, value);
// aggiungo ad adapter
mAdapter.AddDataItem((DataItemRed)value);
//mAdapter.AddDataItem((ConditionRed)value);
}
// aggiungo itemnode (se non c'è)
addItemNode(key, value);
}
public override void removeAllConditionNodes()
{
foreach (var item in conditionNodes)
{
// rimuovo da MTC
mAdapter.RemoveDataItem((DataItemRed)item.Value.cObject);
//mAdapter.RemoveDataItem((ConditionRed)item.Value.cObject);
}
base.removeAllConditionNodes();
}
public override void removeConditionNode(string key)
{
// rimuovo da oggetti specifici
mAdapter.RemoveDataItem((DataItemRed)conditionNodes[key].cObject);
//mAdapter.RemoveDataItem((ConditionRed)conditionNodes[key].cObject);
// rimuovo da vett interno
base.removeConditionNode(key);
}
#endregion
#region gestione allarmi
/// <summary>
/// Speciofica implementazione x formattazione ALLARMI
/// </summary>
/// <param name="currAllarm"></param>
public override void addAlarm(allarme currAllarm)
{
//// in base al tipo di allarme decodifico condizione...
//ConditionRed.Level livello = ConditionRed.Level.NORMAL;
//switch (currAllarm.livello)
//{
// case "WARNING":
// livello = ConditionRed.Level.WARNING;
// break;
// case "FAULT":
// default:
// livello = ConditionRed.Level.FAULT;
// break;
//}
//if (conditionNodes.ContainsKey(currAllarm.gruppo))
//{
// ConditionRed mAlarm = (ConditionRed)conditionNodes[currAllarm.gruppo].cObject;
// mAlarm.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
//}
}
/// <summary>
/// Specifica implementazione x formattazione ALLARMI
/// </summary>
/// <param name="currAllarm"></param>
/// <param name="alarmNode">Generico nodo di tipo condition</param>
public override void addAlarm(itemNode alarmNode, allarme currAllarm)
{
//// in base al tipo di allarme decodifico condizione...
//ConditionRed.Level livello = ConditionRed.Level.NORMAL;
//switch (currAllarm.livello)
//{
// case "WARNING":
// livello = ConditionRed.Level.WARNING;
// break;
// case "FAULT":
// default:
// livello = ConditionRed.Level.FAULT;
// break;
//}
//ConditionRed mAlarm = (ConditionRed)alarmNode.cObject;
//mAlarm.Add(livello, currAllarm.descrizione, currAllarm.codNum, "", "");
}
/// <summary>
/// Wrapper setup obj allarmi
/// </summary>
public override void addAlarmNodes()
{
// registro
DataItemRed newCondNode;
newCondNode = new DataItemRed(nCncConditions);
addConditionNode(nCncConditions, newCondNode);
newCondNode = new DataItemRed(nPlcConditions);
addConditionNode(nPlcConditions, newCondNode);
newCondNode = new DataItemRed(nHmiConditions);
addConditionNode(nHmiConditions, newCondNode);
}
/// <summary>
/// Wrapper inizializzazione allarmi
/// </summary>
public override void initAlarms()
{
//// trasformo i nodi in elenchi conditions e li aggiungo...
//foreach (var item in conditionNodes)
//{
// ((ConditionRed)item.Value.cObject).Normal();
//}
}
/// <summary>
/// inizializazione allarme a normal
/// </summary>
/// <param name="alarmNode"></param>
public override void initAlarm(itemNode alarmNode)
{
//ConditionRed mAlarm = (ConditionRed)alarmNode.cObject;
//mAlarm.Normal();
}
#endregion
}
}
+23
View File
@@ -32,6 +32,7 @@ namespace SCMA
element[] _VacuumAct;
element[] _Lubro;
element[] _SlittaMag;
element[] _SlittaTas;
element[] _ProtMag;
element[] _Cooler;
element[] _Press;
@@ -117,6 +118,23 @@ namespace SCMA
return answ;
}
}
public int nSlittaTas
{
get
{
int answ = 0;
if (SlittaTas != null)
{
try
{
answ = Convert.ToInt32(SlittaTas.Length);
}
catch
{ }
}
return answ;
}
}
public int nProtMag
{
get
@@ -366,6 +384,11 @@ namespace SCMA
get { return _SlittaMag; }
set { _SlittaMag = value; }
}
public element[] SlittaTas
{
get { return _SlittaTas; }
set { _SlittaTas = value; }
}
public element[] ProtMag
{
get { return _ProtMag; }
+49 -49
View File
@@ -7,9 +7,7 @@ namespace SCMA
{
public class AdapterDemo : AdapterGeneric
{
public Condition mTemp;
public Condition mFillLevel;
DateTime nextChange;
/// <summary>
/// estende l'init della classe base...
/// </summary>
@@ -18,25 +16,39 @@ namespace SCMA
/// <param name="gatewayObj">OGGETTO gestione comunicazione OUT (tipologia e metodi)</param>
public AdapterDemo(MainForm caller, AdapterConf adpConf, Gateway gatewayObj) : base(caller, adpConf, gatewayObj)
{
if (utils.CRB("verbose"))
{
lg.Info("Start init Adapter DEMO");
}
// IMPLICITO: carica da metodo base tutte le specifiche del conf...
// !!!HARD CODED!!! aggiunto banco STATUS del 2 processo IN CODA... (4+1)DW=20byte x strobes...!!!
Strobes = new byte[20];
// fix dimensione memorie MST: 52 Byte = 26 short(16bit) x (12+7+7) aree (attenzione: secondo set di 2 bit è VUOTO...)
MemBlock_MST = new byte[52];
saltoMST = 0;
mTemp = new Condition("temp");
mFillLevel = new Condition("cool_low", true);
// aggiungo specifiche del demo: allarmi gestiti a buttons!!!
currGateway.addItemNode("temp", mTemp);
currGateway.addItemNode("cool_low", mFillLevel);
// è little endian (NON serve conversione)
hasBigEndian = false;
lg.Info("Start init Adapter DEMO all'IP {0}", utils.CRS("ipPLC"));
// inizializzo posizioni assi...
prevPosAxis = new double[adpConf.nAxis];
prevDirAxis = new int[adpConf.nAxis];
nextChange = DateTime.Now.AddSeconds(10);
}
/// <summary>
/// Connessione sempre OK...
/// </summary>
/// <returns></returns>
public override bool connectionOk
{
get
{
return true;
}
}
public override void startAdapter()
{
lg.Info("Start DEMO adapter");
base.startAdapter();
// aggiungo altre condizioni specifiche...
mTemp.Normal();
mFillLevel.Normal();
}
public override void getSlowChangingData()
@@ -53,6 +65,27 @@ namespace SCMA
{
base.getStrobeAndAckStatus();
byte[] newStrobes = new byte[20];
// per 50 sec/min (circa) simulo LAVORO...
if (nextChange > DateTime.Now)
{
newStrobes[4] = 8;
newStrobes[8] = 16;
newStrobes[9] = 2;
}
else
{
// imposto cambio
newStrobes[4] = 4;
newStrobes[8] = 8;
newStrobes[9] = 4;
Random rand = new Random();
int numSec = rand.Next(7, 16);
nextChange = DateTime.Now.AddSeconds(numSec);
}
Buffer.BlockCopy(newStrobes, 0, Strobes, 0, 20);
// controllo bool allarmi...
if (parentForm.datiProd.EmrStop)
{
@@ -101,27 +134,6 @@ namespace SCMA
base.getPath();
PathData PtData = parentForm.CurrPath;
if (PtData.PathSel >= 0)
{
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].feedKey, PtData.PathFeedrate);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].feedOverKey, PtData.PathFeedrateOver);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].rapidOverKey, PtData.PathRapidOver);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_X_Key, PtData.PathPosAct.x);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_Y_Key, PtData.PathPosAct.y);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_Z_Key, PtData.PathPosAct.z);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_I_Key, PtData.PathPosAct.i);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_J_Key, PtData.PathPosAct.j);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].posAct_K_Key, PtData.PathPosAct.k);
// aggiunta x revisione 2016.05.05
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].pathTypeKey, PtData.PathType);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].partIdKey, PtData.PartId);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].partCountKey, PtData.pzTot);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].runModeKey, PtData.RunMode);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].exeModeKey, PtData.ExeMode);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].currProgKey, PtData.ProgramName);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].currProgRowNumKey, PtData.ProgrRow);
currGateway.updateItemNodeValue(vettPath[PtData.PathSel].activeAxesKey, PtData.ActiveAxes);
}
}
public override void getUnOp()
@@ -149,18 +161,6 @@ namespace SCMA
{
// USO asse selezionato + dati visualizzati e di conseguenza aggiorno...
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisMainProc);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisIsMaster);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisMastId);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisType);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisDir);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisLoad);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisPosAct);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisPosTgt);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisFeedAct);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisFeedOver);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisAccel);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisAccTime);
currGateway.updateItemNodeValue(vettAxis[AxData.AxisSel].mainProcKey, AxData.AxisBattery);
}
}
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+62 -39
View File
@@ -393,10 +393,14 @@ namespace SCMA
procPathStrobes(1, currStrobe, currAck, 19126, 19021, ref UserAction);
}
// 2017.01.16 INVIO vettore azioni (1 o +)... SE CE NE SONO!
if (UserAction.Trim() != "")
//2019.07.22 NON RIPORTO USER_ACTION x SOUR
if (currGateway.protocollo != gwProtocol.SOURS)
{
currGateway.updateItemNodeValue("USER_ACTION", UserAction.Trim());
// 2017.01.16 INVIO vettore azioni (1 o +)... SE CE NE SONO!
if (UserAction.Trim() != "")
{
currGateway.updateItemNodeValue("USER_ACTION", UserAction.Trim());
}
}
// verifico strobe dell'auto-test
@@ -680,7 +684,8 @@ namespace SCMA
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 1000;
uint[] tabDatiMtz = new uint[maintData.Length];
// calcolo indice max scorrendo...
uint[] tabDatiMtz = new uint[maintDataMaxNum];
inizio = DateTime.Now;
OsaiMemRW_DWord(R, OSAI.MemTypeWord.GW_CODE, memIndex, ref tabDatiMtz);
if (utils.CRB("recTime"))
@@ -689,6 +694,11 @@ namespace SCMA
}
// decodifico aree memoria secondo tab configurazione
processMaintData(tabDatiMtz, maintData);
// se log verboso 10+ --> scrivo tutti!
if (utils.CRI("loglevel") > 9)
{
lg.Info($" Lettura di {maintDataMaxNum} variabili maintData");
}
}
fatto = true;
}
@@ -710,9 +720,9 @@ namespace SCMA
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 19434;
uint[] tabDatiAnalog = new uint[analogData.Length];
int[] tabDatiAnalog = new int[analogDataMaxNum];
inizio = DateTime.Now;
OsaiMemRW_DWord(R, OSAI.MemTypeWord.MW_CODE, memIndex, ref tabDatiAnalog);
OsaiMemRW_Integer(R, OSAI.MemTypeWord.MW_CODE, memIndex, ref tabDatiAnalog);
if (utils.CRB("recTime"))
{
TimingData.addResult(string.Format("R{0}-DatiAnalog", tabDatiAnalog.Length * 4), DateTime.Now.Subtract(inizio).Ticks);
@@ -736,11 +746,11 @@ namespace SCMA
bool fatto = false;
try
{
if (statusData.Length > 0)
if (statusDataMaxNum > 0)
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 19426;
int numByte = 1 + (statusData.Length / 8);
int numByte = 1 + (statusDataMaxNum / 8);
byte[] tabDatiStatus = new byte[numByte];
inizio = DateTime.Now;
OsaiMemRW_Byte(R, OSAI.MemTypeWord.MW_CODE, memIndex, 0, ref tabDatiStatus);
@@ -815,7 +825,7 @@ namespace SCMA
lg.Info(string.Format("Allarme CNC: {0}", alarmText));
}
// predispongo allarme
allarme currAllarm = new allarme(item.Key, "CNC", "FAULT", alarmText);
allarme currAllarm = new allarme(item.Key, currGateway.nCncConditions, "FAULT", alarmText);
currGateway.addAlarm(currAllarm);
// mostro in form!
sb.AppendLine(alarmText);
@@ -1012,11 +1022,14 @@ namespace SCMA
}
currGateway.updateItemNodeValue(vettPath[i].gCodeAct_Key, GCodAttivi);
// 2017.01.16 da rivedere
currGateway.updateItemNodeValue(vettPath[i].currProgRowNumKey, "");
currGateway.updateItemNodeValue(vettPath[i].activeAxesKey, "");
if (currGateway.protocollo != gwProtocol.SOURS)
{
// 2017.01.16 da rivedere
currGateway.updateItemNodeValue(vettPath[i].currProgRowNumKey, "");
currGateway.updateItemNodeValue(vettPath[i].activeAxesKey, "");
sb_2.AppendLine(string.Format("Path {0}, PROG: {1}", i + 1, currGateway.getItemNode(vettPath[i].currProgKey)));
}
sb_2.AppendLine(string.Format("Path {0}, PROG: {1}", i + 1, currGateway.getItemNode(vettPath[i].currProgKey)));
sb_3.AppendLine(string.Format("Path {0}, GCodes: {1}", i + 1, GCodAttivi));
parentForm.dataMonitor_2 += sb_2.ToString();
@@ -1035,11 +1048,11 @@ namespace SCMA
* 2018.01.16 modifica per gestione doppio processo e nome assi duplicato
* ------------------------------------------------------------------------
*
* E' risultato (marco.negri, amcchian OSAI con 2 processi in cui glia ssi di ogni processoa vevano lo stesso nome) ceh OSAI NON restituisce ID univoco asse ma nome etichetta asegnato
* in questo modo glia ssi verso agent (e seguenti) si sovrappongono/sovrascrivono
* E' risultato (Marco Negri, macchina OSAI con 2 processi in cui gli assi di ogni processo avevano lo stesso nome) che OSAI NON restituisce ID univoco asse ma nome etichetta asegnato
* in questo modo gli assi verso agent (e seguenti) si sovrappongono/sovrascrivono
*
* E' quindi necessario procedere in + step
* - verificare numero processia ttivi
* - verificare numero processi attivi
* - chiedere x ogni processo quali assi ci siano (AsixTable (con Id UNIVOCO e consistente e NOME)
* - chiedere x ogni processo le posizioni assi in modo che processo + nome --> Id Univoco --> possiamo popolare la tabella da invaire poi all'agent
*/
@@ -1049,10 +1062,18 @@ namespace SCMA
CMSCncLib.OPENcontrol.GETINTDATA[] tmpPosAssi = new CMSCncLib.OPENcontrol.GETINTDATA[currAdpConf.nAxis];
CMSCncLib.OPENcontrol.GETINTDATA[] posAssiTgt = new CMSCncLib.OPENcontrol.GETINTDATA[currAdpConf.nAxis];
CMSCncLib.OPENcontrol.GETINTDATA[] posAssi = new CMSCncLib.OPENcontrol.GETINTDATA[currAdpConf.nAxis];
Dictionary<int, int> axisMap = new Dictionary<int, int>();
Dictionary<string, int> axisDict = new Dictionary<string, int>();
char[] axisTable = new char[currAdpConf.nAxis];
short[] axisIdTable = new short[currAdpConf.nAxis];
int currId = 0;
int axCounter = 0;
// inizializzo TUTTI a path 0 così se sparissero risultano NON attestati su un path...
for (int j = 0; j < currAdpConf.nAxis; j++)
{
currGateway.updateItemNodeValue(vettAxis[j].mainProcKey, 0);
}
// verifico quanti path ho... e recupero le info sugli assi (se id > 0 è PRESENTE...)
for (short i = 1; i <= currAdpConf.nPath; i++)
{
@@ -1079,9 +1100,9 @@ namespace SCMA
try
{
// salvo (per ID) descr asse e processo corrente!
currGateway.updateItemNodeValue(vettAxis[currId - 1].descriptionKey, axisTable[j]);
currGateway.updateItemNodeValue(vettAxis[currId - 1].mainProcKey, i);
currGateway.updateItemNodeValue(vettAxis[axCounter].descriptionKey, axisTable[j]);
currGateway.updateItemNodeValue(vettAxis[axCounter].mainProcKey, i);
axCounter++;
}
catch (Exception exc)
{
@@ -1095,6 +1116,7 @@ namespace SCMA
char axName;
int reIdx = 0;
axCounter = 0;
// ora processo i dati PER PATH delle posizioni assi...
for (short i = 1; i <= currAdpConf.nPath; i++)
{
@@ -1120,14 +1142,22 @@ namespace SCMA
// salvo nella posizione DECODIFICATA da dictionary x path/nome...
if (axName != '\0' && axName != '-')
{
// problema: ho 6° asse con ID INTERNO 7
// calcolo ID REALE
reIdx = axisDict[string.Format("{0}#{1}", i, axName)];
posAssiTgt[reIdx - 1] = tmpPosAssiTgt[j];
posAssi[reIdx - 1] = tmpPosAssi[j];
// salvo la mappatura tra id univoco asse e indice interno
axisMap.Add(reIdx, axCounter);
// salvo comunque dati completi
posAssiTgt[axCounter] = tmpPosAssiTgt[j];
posAssi[axCounter] = tmpPosAssi[j];
// incremento
axCounter++;
}
}
catch
{ }
catch (Exception exc)
{
lg.Error(exc, $"Eccezione in processing dati PER PATH delel posizioni assi: j:{j}");
}
}
}
@@ -1136,7 +1166,6 @@ namespace SCMA
double newPosTgt = 0;
double distPerc = 0;
int newDir = 0;
string tipoAsse = "";
string direzione = "";
// ORA ho tutto in posizione corretta, PROCESSO!!!
for (int i = 0; i < currAdpConf.nAxis; i++)
@@ -1145,7 +1174,7 @@ namespace SCMA
try
{
//string axName = System.Text.Encoding.ASCII.GetString(posAssi[i].AxisName);
if (posAssiTgt[i].AxisName == 0)
if (posAssiTgt[i] == null || posAssiTgt[i].AxisName == 0)
{
axName = '-';
}
@@ -1166,7 +1195,9 @@ namespace SCMA
newPosTgt = 0;
}
// popolo valori... LOAD gestito da vettore letto con area memoria AnalogData.map
currGateway.updateItemNodeValue(vettAxis[i].loadKey, Convert.ToUInt32(istLoadAssi[i].vcMedian));
#if false
currGateway.updateItemNodeValue(vettAxis[i].loadKey, Convert.ToUInt32(istLoadAssi[i].vcMedian));
#endif
currGateway.updateItemNodeValue(vettAxis[i].posActKey, newPos);
currGateway.updateItemNodeValue(vettAxis[i].posTgtKey, newPosTgt);
currGateway.updateItemNodeValue(vettAxis[i].feedrateKey, FeedRate);
@@ -1182,19 +1213,9 @@ namespace SCMA
{
newDir = prevDirAxis[i];
}
// verifico tipo direzione da tipo asse...
tipoAsse = currGateway.getItemNode(vettAxis[i].typeKey).ToString();
if (tipoAsse == "LINEAR")
{
// ?: conditional operator.
direzione = (newDir > 0) ? "POSITIVE" : "NEGATIVE";
}
else if (tipoAsse == "ROTARY")
{
direzione = (newDir > 0) ? "CLOCKWISE" : "COUNTER_CLOCKWISE";
}
// calcolo direzione
direzione = calculateDirection(newDir, i);
// imposto direzione
currGateway.updateItemNodeValue(vettAxis[i].directionKey, direzione);
if (utils.CRB("verbose"))
@@ -1222,5 +1243,7 @@ namespace SCMA
parentForm.commPlcActive = false;
parentForm.dataMonitor_3 += sb.ToString();
}
}
}
@@ -7,9 +7,9 @@ using System.Linq;
using System.Text;
using System.Threading;
namespace SCMA
namespace SCMA.AdapterPLC.SCM
{
public class AdapterESA : AdapterGeneric
public class ESA : AdapterGeneric
{
/// <summary>
/// Configurazione valori da leggere IOT_Byte
@@ -119,7 +119,7 @@ namespace SCMA
// ora creo un vettore di allarmi VUOTI...
for (int i = 1; i <= totRighe; i++)
{
elencoAllarmiCNC[i - 1] = new allarme(i.ToString(), "CNC", "WARNING", string.Format("[{0}] MISSING", i));
elencoAllarmiCNC[i - 1] = new allarme(i.ToString(), "CNC", "WARNING", string.Format("[{0}] MISSING", i), string.Format("[{0}] MISSING", i), string.Format("[{0}] MISSING", i));
}
// carica da file...
System.IO.StreamReader file = new System.IO.StreamReader(fileName);
@@ -245,7 +245,7 @@ namespace SCMA
/// <param name="caller">FORM chaimante</param>
/// <param name="adpConf">CONFIGURAZIONE adapter</param>
/// <param name="gatewayObj">OGGETTO gestione comunicazione OUT (tipologia e metodi)</param>
public AdapterESA(MainForm caller, AdapterConf adpConf, Gateway gatewayObj) : base(caller, adpConf, gatewayObj)
public ESA(MainForm caller, AdapterConf adpConf, Gateway gatewayObj) : base(caller, adpConf, gatewayObj)
{
string iniPath = string.Format(@"{0}\{1}", utils.confDir, utils.CRS("defaultEsaFile"));
@@ -643,7 +643,7 @@ namespace SCMA
{
allarme currAllarm = elencoAllarmiCNC[numAlarmCNC - 1];
// forzo a CNC x siocurezza...
currAllarm.gruppo = "CNC";
currAllarm.gruppo = currGateway.nCncConditions;
currGateway.addAlarm(currAllarm);
}
}
+15 -21
View File
@@ -3,6 +3,7 @@ using MTC;
using SCMA.AdapterCom;
using Siemens.Sinumerik.Operate.Services;
using System;
using System.Collections.Generic;
using System.Text;
namespace SCMA
@@ -376,10 +377,14 @@ namespace SCMA
procPathStrobes(1, currStrobe, currAck, 210, 6, ref UserAction);
}
// 2017.01.16 INVIO vettore azioni (1 o +)... SE CE NE SONO!
if (UserAction.Trim() != "")
//2019.07.22 NON RIPORTO USER_ACTION x SOUR
if (currGateway.protocollo != gwProtocol.SOURS)
{
currGateway.updateItemNodeValue("USER_ACTION", UserAction.Trim());
// 2017.01.16 INVIO vettore azioni (1 o +)... SE CE NE SONO!
if (UserAction.Trim() != "")
{
currGateway.updateItemNodeValue("USER_ACTION", UserAction.Trim());
}
}
// verifico strobe dell'auto-test
@@ -676,7 +681,7 @@ namespace SCMA
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 536;
uint[] tabDatiMtz = new uint[maintData.Length];
uint[] tabDatiMtz = new uint[maintDataMaxNum];
inizio = DateTime.Now;
SIEMENSMemRW_DWord(R, baseMemDb, memIndex, ref tabDatiMtz);
if (utils.CRB("recTime"))
@@ -700,11 +705,11 @@ namespace SCMA
bool fatto = false;
try
{
if (statusData.Length > 0)
if (statusDataMaxNum > 0)
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 1048;
int numByte = 1 + (statusData.Length / 8);
int numByte = 1 + (statusDataMaxNum / 8);
byte[] tabDatiStatus = new byte[numByte];
inizio = DateTime.Now;
SIEMENSMemRW_Byte(R, baseMemDb, memIndex, ref tabDatiStatus);
@@ -733,7 +738,7 @@ namespace SCMA
{
// recupero i dati di manutenzione dall'area di memoria IN BLOCCO
int memIndex = 1064;
uint[] tabDatiAnalog = new uint[analogData.Length];
uint[] tabDatiAnalog = new uint[analogDataMaxNum];
inizio = DateTime.Now;
SIEMENSMemRW_DWord(R, baseMemDb, memIndex, ref tabDatiAnalog);
if (utils.CRB("recTime"))
@@ -819,7 +824,7 @@ namespace SCMA
parentForm.dataMonitor_1 += sb.ToString();
}
// predispongo allarme
allarme currAllarm = new allarme(codAllarme, "CNC", "FAULT", allarmeSiemens.Message);
allarme currAllarm = new allarme(codAllarme, currGateway.nCncConditions, "FAULT", allarmeSiemens.Message);
currGateway.addAlarm(currAllarm);
}
catch (Exception exc)
@@ -986,7 +991,6 @@ namespace SCMA
double newPos = 0;
double distPerc = 0;
int newDir = 0;
string tipoAsse = "";
string direzione = "";
// recupero in blocco dati assi...
@@ -1023,18 +1027,8 @@ namespace SCMA
{
newDir = prevDirAxis[i];
}
// verifico tipo direzione da tipo asse...
tipoAsse = currGateway.getItemNode(vettAxis[i].typeKey).ToString();
if (tipoAsse == "LINEAR")
{
// ?: conditional operator.
direzione = (newDir > 0) ? "POSITIVE" : "NEGATIVE";
}
else if (tipoAsse == "ROTARY")
{
direzione = (newDir > 0) ? "CLOCKWISE" : "COUNTER_CLOCKWISE";
}
// calcolo direzione
direzione = calculateDirection(newDir, i);
// imposto direzione
currGateway.updateItemNodeValue(vettAxis[i].directionKey, direzione);
+102 -77
View File
@@ -1,39 +1,52 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<startup useLegacyV2RuntimeActivationPolicy="true">
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2"/>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
</startup>
<appSettings>
<!--MAIN CONF-->
<add key="appName" value="MTConnect Adapter"/>
<add key="appName" value="SCMA" />
<!--parametri protocollo comunicazione-->
<add key="adpProto" value="MTC"/>
<add key="MTC_port" value="7878"/>
<add key="SOURS_IP" value="localhost"/>
<add key="SOURS_port" value="6379"/>
<!--<add key="adpProto" value="MTC" />-->
<!--<add key="adpProto" value="SOURS" />-->
<add key="adpProto" value="MTC" />
<add key="MTC_port" value="7878" />
<add key="SOURS_IP" value="localhost" />
<add key="SOURS_port" value="6379" />
<add key="SOURS_baseHash" value="SOUR" />
<add key="stChkEnabled" value="true"/>
<add key="logRedConnWaitTime" value="5"/>
<add key="fullReset" value="false"/>
<!--gestione TIMERS e periodi multipli x thread lenti-->
<add key="startTimerMs" value="250"/>
<add key="timerIntMs" value="5"/><!--invio da adapter ad agent: 5ms-->
<add key="fastCount" value="20"/><!--100ms-->
<add key="normCount" value="100"/><!--500ms-->
<add key="slowCount" value="1000"/><!--5 sec-->
<add key="alarmSyncCount" value="6000"/><!--30 sec-->
<add key="waitEndCycle" value="0"/><!--ms attesa dopo ogni ciclo lettura...--><!--30 sec-->
<add key="startTimerMs" value="250" />
<add key="timerIntMs" value="5" />
<!--invio da adapter ad agent: 5ms-->
<add key="fastCount" value="20" />
<!--100ms-->
<add key="normCount" value="100" />
<!--500ms-->
<add key="slowCount" value="1000" />
<!--5 sec-->
<add key="alarmSyncCount" value="6000" />
<!--30 sec-->
<add key="waitEndCycle" value="0" />
<!--ms attesa dopo ogni ciclo lettura...-->
<!--30 sec-->
<!--num cicli PRIMA di leggere davvero GCode x rallentare-->
<add key="contChkGCod" value="2"/>
<add key="contChkGCod" value="2" />
<!--gestione FINESTRA campionamento x counter in secondi (dati validi dati DOPO che è piena la coda x la finestra richiesta, mantenuta a quella durata...)-->
<add key="countWindSize" value="30"/>
<add key="countWindSize" value="10" />
<!--parametri gestione watchdog-->
<add key="maxAdapterLockSec" value="5"/>
<add key="maxAdapterLockSec" value="5" />
<!--disabilito letture avanzate che UCCIDONO il programma (x ora SOLO allarmi CNC x FANUC-->
<add key="disableAdvRead" value="true"/>
<add key="disableAdvRead" value="true" />
<!--gestione x abilitare/disabilitare lettura nome asse e path di controllo (OSAI)-->
<add key="enableAxNamePath" value="true"/>
<add key="enableAxNamePath" value="true" />
<!--AREA CONF IP FANUC-->
<!--SIMULATORE LOCALE
IP LOOPBACK: 192.168.211.5/255.255.255.0
ipPLC = "192.168.211.5"-->
<!--<add key ="ipPLC" value="192.168.211.5" />-->
<!--<add key="ipPLC" value="192.168.211.5" />-->
<!--SIM PC
IP ETH: 192.168.139.201/255.255.255.0
ipPLC = "192.168.139.100"-->
@@ -48,97 +61,109 @@
ipPLC = "192.168.139.1"-->
<!--<add key="ipPLC" value="192.168.157.2"/>-->
<!--OSAI DEV-->
<!--<add key ="ipPLC" value="192.168.157.2" />-->
<!--<add key="ipPLC" value="192.168.157.2" />-->
<!--SIEMENS DEV-->
<!--<add key ="ipPLC" value="192.168.214.1" />-->
<!--CMS PROD-->
<!--<add key ="ipPLC" value="192.168.139.1" />-->
<add key ="ipPLC" value="192.168.157.2" />
<add key="recTime" value="true"/>
<add key="verbose" value="true"/>
<add key="loglevel" value="5"/>
<add key="mode" value="prod"/>
<!--<add key="ipPLC" value="192.168.214.1" />-->
<!--CMS PROD-->
<!--<add key="ipPLC" value="192.168.139.1" />-->
<add key="ipPLC" value="192.168.139.1" />
<add key="recTime" value="true" />
<add key="verbose" value="true" />
<add key="loglevel" value="5" />
<add key="mode" value="prod" />
<!--Definizione avvio Adapter-->
<add key="autoLoadConf" value="false"/>
<add key="autoStartOnLoad" value="true"/>
<add key="openDumpOnStart" value="true"/>
<add key="startMinimized" value="false"/>
<add key="windowCanMax" value="true"/>
<add key="trayClose" value="true"/>
<add key="autoSaveSec" value="60"/>
<add key="waitRecMSec" value="5000"/>
<add key="testCharSep" value="|"/>
<add key="fattdecimale" value="1000"/>
<add key="fattConvDistAssi" value="1000"/>
<add key="fattDecVA" value="1000"/>
<add key="autoLoadConf" value="false" />
<add key="autoStartOnLoad" value="true" />
<add key="openDumpOnStart" value="true" />
<add key="startMinimized" value="false" />
<add key="windowCanMax" value="true" />
<add key="trayClose" value="true" />
<add key="autoSaveSec" value="60" />
<add key="waitRecMSec" value="5000" />
<add key="testCharSep" value="|" />
<add key="fattdecimale" value="1000" />
<add key="fattConvDistAssi" value="1000" />
<add key="fattDecVA" value="1" />
<!--<add key="fattDecVA" value="1000" />-->
<add key="fattFeedFanuc" value="10" />
<!--pre-filtraggio XML-->
<add key="xmlSanitize" value="true" />
<!--conf file-->
<add key="dataPath" value="DATA"/>
<add key="dataConfPath" value="DATA\CONF"/>
<add key="dataDatPath" value="DATA\DAT"/>
<add key="resxPath" value="Resources"/>
<add key="AlarmList" value="AlarmList.map"/>
<add key="AlarmListCNC" value="AlarmListCNC.map"/>
<add key="defaultConfFile" value="Adapter_ItemList.xml"/>
<add key="defaultPersLayerFile" value="PersistData.dat"/>
<add key="maxNumDD" value="30"/>
<add key="defaultEsaFile" value="EsaKvara.ini"/>
<add key="CounterListFilePath" value="CounterList.map"/>
<add key="AnalogDataFilePath" value="AnalogData.map"/>
<add key="StatusListFilePath" value="StatusList.map"/>
<add key="SubModeListFilePath" value="SubModeList.map"/>
<add key="dataPath" value="DATA" />
<add key="dataConfPath" value="DATA\CONF" />
<add key="dataDatPath" value="DATA\DAT" />
<add key="resxPath" value="Resources" />
<add key="AlarmList" value="AlarmList.map" />
<add key="NameRepRolesList" value="NameRepRolesList.map" />
<add key="MemCopyList" value="MemCopyList.map" />
<add key="DataModel" value="DataModel.xml" />
<add key="AlarmListCNC" value="AlarmListCNC.map" />
<add key="defaultConfFile" value="DataModel.xml" />
<!--<add key="defaultConfFile" value="Adapter_ItemList.xml" />-->
<add key="defaultPersLayerFile" value="PersistData.dat" />
<add key="maxNumDD" value="30" />
<add key="defaultEsaFile" value="EsaKvara.ini" />
<add key="CounterListFilePath" value="CounterList.map" />
<add key="AnalogDataFilePath" value="AnalogData.map" />
<add key="StatusListFilePath" value="StatusList.map" />
<add key="SubModeListFilePath" value="SubModeList.map" />
<!--Gestione pathFanuc-->
<add key="FanucPathComb" value="true"/>
<add key="FanucAxPathAssign" value="1,1,1,2,2,2"/>
<!--Gestione path siemens-->
<add key="SiemensBaseCountPath" value="0"/>
<add key="SiemensBaseCountPath" value="0" />
<!--gestione FANUC con assi limitati-->
<add key="FanucLimit3D" value="false"/>
<add key="FanucLimit3D" value="true" />
<!--conf gestione "semplificata" accesso a tutta la memoria ogni volta-->
<!--conf x CMS-->
<add key="procIotMem" value="false"/>
<add key="procIotMem" value="false" />
<!--conf x ESA-KVARA-->
<!--<add key="procIotMem" value="true"/>-->
<!--file configurazione IotMem (ESA KVARA)-->
<add key="IOTByteFilePath" value="IOT_ByteList.map"/>
<add key="IOTWordFilePath" value="IOT_WordList.map"/>
<add key="IOTDWordFilePath" value="IOT_DWordList.map"/>
<add key="IOTStringFilePath" value="IOT_StringList.map"/>
<add key="IOTByteFilePath" value="IOT_ByteList.map" />
<add key="IOTWordFilePath" value="IOT_WordList.map" />
<add key="IOTDWordFilePath" value="IOT_DWordList.map" />
<add key="IOTStringFilePath" value="IOT_StringList.map" />
<!--percorso file scambio dati "lenti" e conf MaintData memory area -->
<add key="GeneralStatusFilePath" value="CmsGeneralStatus.mtc"/>
<add key="GeneralStatusFilePath" value="CmsGeneralStatus.mtc" />
<!--gestione trigger eventi da allarmi-->
<add key="eStopCode" value="152"/>
<add key="eStopCode" value="152" />
<!--gestione watchdog CMS-->
<add key="sendWatchDog" value="true"/>
<add key="cycleWatchDog" value="3"/>
<add key="readAllTop" value="true"/>
<add key="fastCopy" value="true"/>
<add key="ClientSettingsProvider.ServiceUri" value=""/>
<add key="sendWatchDog" value="true" />
<add key="cycleWatchDog" value="3" />
<add key="readAllTop" value="true" />
<add key="fastCopy" value="true" />
<add key="ClientSettingsProvider.ServiceUri" value="" />
<!--gestione spindle override gobale forzato da max valori letti...-->
<add key="getMaxSpOver" value="true"/>
<add key="getMaxSpOver" value="true" />
<!--gestione decodifica status-->
<add key="ouStatusByPlc" value="true" />
</appSettings>
<system.web>
<membership defaultProvider="ClientAuthenticationMembershipProvider">
<providers>
<add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri=""/>
<add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
</providers>
</membership>
<roleManager defaultProvider="ClientRoleProvider" enabled="true">
<providers>
<add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400"/>
<add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
</providers>
</roleManager>
</system.web>
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="OPENcontrol"/>
<binding name="OPENcontrol" />
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://192.168.20.2:8080" binding="basicHttpBinding" bindingConfiguration="OPENcontrol" contract="OPENcontrol.OPENcontrolPortType" name="OPENcontrol"/>
<endpoint address="http://192.168.20.2:8080" binding="basicHttpBinding" bindingConfiguration="OPENcontrol" contract="OPENcontrol.OPENcontrolPortType" name="OPENcontrol" />
</client>
</system.serviceModel>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<probing privatePath="lib;libs"/>
<probing privatePath="lib;libs" />
</assemblyBinding>
</runtime>
</configuration>
</configuration>
@@ -0,0 +1,181 @@
<?xml version="1.0" encoding="utf-8"?>
<AdapterConf xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Version>1</Version>
<NomeAdapt>ADAPTER_SIM</NomeAdapt>
<TipoAdapt>DEMO</TipoAdapt>
<ContOreMaccOn>0</ContOreMaccOn>
<ContOreMaccLav>0</ContOreMaccLav>
<ContSlittaTast>0</ContSlittaTast>
<VacuumPump>
<element>
<ident>VacPump_01</ident>
<dataRefList />
</element>
<element>
<ident>VacPump_02</ident>
<dataRefList />
</element>
</VacuumPump>
<VacuumAct>
<element>
<ident>VacAct_01</ident>
<dataRefList />
</element>
<element>
<ident>VacAct_02</ident>
<dataRefList />
</element>
</VacuumAct>
<Lubro>
<element>
<ident>Lubro_01</ident>
<dataRefList />
</element>
<element>
<ident>Lubro_02</ident>
<dataRefList />
</element>
</Lubro>
<SlittaMag>
<element>
<ident>SlittaMagazzino_01</ident>
<dataRefList />
</element>
</SlittaMag>
<ProtMag>
<element>
<ident>ProtMagazzino_01</ident>
<dataRefList />
</element>
</ProtMag>
<Cooler>
<element>
<ident>Cooler_01</ident>
<dataRefList />
</element>
<element>
<ident>Cooler_02</ident>
<dataRefList />
</element>
</Cooler>
<Press>
<element>
<ident>Press_01</ident>
<dataRefList />
</element>
<element>
<ident>Press_02</ident>
<dataRefList />
</element>
</Press>
<Temp>
<element>
<ident>Temp_01</ident>
<dataRefList />
</element>
<element>
<ident>Temp_02</ident>
<dataRefList />
</element>
</Temp>
<Path>
<element>
<ident>Path_01</ident>
<dataRefList />
</element>
<element>
<ident>Path_02</ident>
<dataRefList />
</element>
</Path>
<UnOp>
<element>
<ident>UnOp_01</ident>
<dataRefList />
</element>
<element>
<ident>UnOp_02</ident>
<dataRefList />
</element>
</UnOp>
<Axis>
<element>
<ident>Axis_01</ident>
<dataRefList>
<dataRef>
<Key>Axis_01_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_01_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
<element>
<ident>Axis_02</ident>
<dataRefList>
<dataRef>
<Key>Axis_02_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_02_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
<element>
<ident>Axis_03</ident>
<dataRefList>
<dataRef>
<Key>Axis_03_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_03_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
<element>
<ident>Axis_04</ident>
<dataRefList>
<dataRef>
<Key>Axis_04_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_04_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
<element>
<ident>Axis_05</ident>
<dataRefList>
<dataRef>
<Key>Axis_05_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_05_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
<element>
<ident>Axis_06</ident>
<dataRefList>
<dataRef>
<Key>Axis_06_Type</Key>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_06_Grp</Key>
<Value>00</Value>
</dataRef>
</dataRefList>
</element>
</Axis>
</AdapterConf>
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<AdapterConf xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Version>1</Version>
<NomeAdapt>ADAPTER_OSAI</NomeAdapt>
<TipoAdapt>OSAI</TipoAdapt>
<NomeAdapt>ADAPTER_FANUC</NomeAdapt>
<TipoAdapt>FANUC</TipoAdapt>
<ContOreMaccOn>0</ContOreMaccOn>
<ContOreMaccLav>0</ContOreMaccLav>
<ContSlittaTast>0</ContSlittaTast>
@@ -83,15 +83,19 @@
<ident>Path_01</ident>
<dataRefList />
</element>
<!--<element>
<element>
<ident>Path_02</ident>
<dataRefList />
</element>-->
</element>
</Path>
<UnOp>
<element>
<ident>UnOp_01</ident>
<dataRefList />
</element>
<element>
<ident>UnOp_02</ident>
<dataRefList />
</element>
</UnOp>
<Axis>
@@ -139,7 +143,7 @@
<dataRefList>
<dataRef>
<Key>Axis_04_Type</Key>
<Value>ROTARY</Value>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_04_Grp</Key>
@@ -152,7 +156,7 @@
<dataRefList>
<dataRef>
<Key>Axis_05_Type</Key>
<Value>ROTARY</Value>
<Value>LINEAR</Value>
</dataRef>
<dataRef>
<Key>Axis_05_Grp</Key>
File diff suppressed because it is too large Load Diff
+1 -7
View File
@@ -1,7 +1 @@
# Commenti con cancelletto, struttura un variabile per riga, tipo chiave|valore (occhio che il separatore è configurato da .cofig come "testCharSep"); spazi e tabulazioni dovrei trimmarli in acquisizione (qui inseriti per comodità di lettura)
001|Axis_01_Load |NUM
002|Axis_02_Load |NUM
003|Axis_03_Load |NUM
004|Axis_04_Load |NUM
005|Axis_05_Load |NUM
006|Axis_06_Load |NUM
# Commenti con cancelletto, struttura un variabile per riga, tipo chiave|valore (occhio che il separatore è configurato da .cofig come "testCharSep"); spazi e tabulazioni dovrei trimmarli in acquisizione (qui inseriti per comodità di lettura)
+2 -2
View File
@@ -21,8 +21,8 @@
020|VacAct_02_Count |COUNT
021|Lubro_01_Num |COUNT
022|SlittaTastatore_Count |COUNT
023|ProtMagazzino_01_Count |COUNT
024|ProtMagazzino_02_Count |COUNT
023|SlittaMagazzino_01_Count |COUNT
024|ProtMagazzino_01_Count |COUNT
025|UnOp_01_NumCambiUT |COUNT
026|Axis_01_AccTime |COUNT
027|Axis_02_AccTime |COUNT
+199
View File
@@ -0,0 +1,199 @@
<ModelDesign>
<Machine>
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="ANTARES26/15-PX5" />
<Property SymbolicName="Manufacturer" BrowseName="Manufacturer" DataType="ua:String" ValueRank="Scalar" Value="CMS Industries" />
<Property SymbolicName="Serial" BrowseName="Serial" DataType="ua:String" ValueRank="Scalar" Value="9206" />
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CNC_MACHINE" />
<Property SymbolicName="BuildYear" BrowseName="BuildYear" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Alarm" BrowseName="Alarm" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="Emergency" BrowseName="Emergency" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="Power" BrowseName="Power" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="001" CmsDataOpt="HOURS" />
<Variable SymbolicName="ActiveWorkingTime" BrowseName="ActiveWorkingTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="002" CmsDataOpt="HOURS" />
<Component Name="Cnc">
<!--<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="SIEMENS" />-->
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="OSAI" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
<Component Name="CncProcesses">
<Component Name="01">
<Variable SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="CodG" BrowseName="CodG" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodM" BrowseName="CodM" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodS" BrowseName="CodS" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodT" BrowseName="CodT" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:String" ValueRank="Scalar" Units="m/min" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Mode" BrowseName="Mode" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="SubMode" BrowseName="SubMode" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
</Component>
</Component>
</Component>
<Component Name="Plc">
<!--<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="SIEMENS" />-->
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="OSAI" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
</Component>
<Component Name="Hmi">
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="CMS Active" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="1.00.02" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
<Variable SymbolicName="User" BrowseName="User" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Language" BrowseName="Language" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="ActiveSection" BrowseName="ActiveSection" DataType="ua:String" ValueRank="Scalar" Units="h" />
<Variable SymbolicName="ActiveTimeSession" BrowseName="ActiveTimeSession" DataType="ua:String" ValueRank="Scalar" Units="" />
</Component>
<Component Name="Axes">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="X" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="026" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="001" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="005" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="004" CmsDataOpt="METER"/>
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="02">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="Y" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="027" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="002" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="007" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" CmsDataType="CounterList" CmsDataIndex="006" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="03">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="Z" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="028" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="003" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="009" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="008" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="04">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="B" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="029" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="004" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="011" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="010" CmsDataOpt="NUM" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="05">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="C" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="030" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="005" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="013" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="012" CmsDataOpt="NUM"/>
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="06">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="V" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="SLAVE" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="031" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="006" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="015" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="014" CmsDataOpt="METER"/>
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
</Component>
<Component Name="OperatingGroups">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SPINDLE" />
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="CMS-SPINDLE-01" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="006" CmsDataOpt="BIT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Krev" CmsDataType="CounterList" CmsDataIndex="016" CmsDataOpt="NUM" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="016" CmsDataOpt="HOURS" />
<Variable SymbolicName="SpeedRate" BrowseName="SpeedRate" DataType="ua:UInt32" ValueRank="Scalar" Units="rpm" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="ToolChanges" BrowseName="ToolChanges" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="025" CmsDataOpt="NUM" />
<Variable SymbolicName="ToolId" BrowseName="ToolId" DataType="ua:Float" ValueRank="Scalar" Units="" />
<Variable SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Units="" />
</Component>
</Component>
<Component Name="AuxiliaryGroups">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LUBRO" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="021" CmsDataOpt="NUM" />
</Component>
<Component Name="02">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_PUMP" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="002" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="017" CmsDataOpt="HOURS" />
</Component>
<Component Name="03">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="019" CmsDataOpt="NUM" />
<Variable SymbolicName="TestData" BrowseName="TestData" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="017" CmsDataOpt="RTV" />
</Component>
</Component>
<Component Name="ProductionProcesses">
<Component Name="01">
<Component Name="Programs">
<Component Name="01">
<Variable SymbolicName="RepsDone" BrowseName="RepsDone" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="003" CmsDataOpt="NUM" />
</Component>
</Component>
</Component>
</Component>
</Machine>
</ModelDesign>
+537
View File
@@ -0,0 +1,537 @@
<ModelDesign>
<Machine>
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="POWER 200/150-Z1000" />
<Property SymbolicName="Manufacturer" BrowseName="Manufacturer" DataType="ua:String" ValueRank="Scalar" Value="CMS Industries" />
<Property SymbolicName="Serial" BrowseName="Serial" DataType="ua:String" ValueRank="Scalar" Value="CMS08618" />
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CNC_MACHINE" />
<Property SymbolicName="BuildYear" BrowseName="BuildYear" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Alarm" BrowseName="Alarm" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="Emergency" BrowseName="Emergency" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="Power" BrowseName="Power" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="001" CmsDataOpt="HOURS" />
<Variable SymbolicName="ActiveWorkingTime" BrowseName="ActiveWorkingTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="002" CmsDataOpt="HOURS" />
<Variable SymbolicName="RTCounter_001" BrowseName="ContaPzTav1" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="060" CmsDataOpt="NUM" />
<Variable SymbolicName="RTCounter_002" BrowseName="ContaPzTav2" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="061" CmsDataOpt="NUM" />
<Variable SymbolicName="RTCounter_003" BrowseName="ContaPzTav3" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="062" CmsDataOpt="NUM" />
<Component Name="Cnc">
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="OSAI" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
<Component Name="CncProcesses">
<Component Name="01">
<Variable SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="CodG" BrowseName="CodG" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodM" BrowseName="CodM" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodS" BrowseName="CodS" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodT" BrowseName="CodT" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:String" ValueRank="Scalar" Units="m/min" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Mode" BrowseName="Mode" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="SubMode" BrowseName="SubMode" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
</Component>
<Component Name="02">
<Variable SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="CodG" BrowseName="CodG" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodM" BrowseName="CodM" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodS" BrowseName="CodS" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodT" BrowseName="CodT" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:String" ValueRank="Scalar" Units="m/min" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Mode" BrowseName="Mode" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="SubMode" BrowseName="SubMode" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
</Component>
<Component Name="03">
<Variable SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="CodG" BrowseName="CodG" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodM" BrowseName="CodM" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodS" BrowseName="CodS" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodT" BrowseName="CodT" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:String" ValueRank="Scalar" Units="m/min" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Mode" BrowseName="Mode" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="SubMode" BrowseName="SubMode" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
</Component>
<Component Name="04">
<Variable SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="CodG" BrowseName="CodG" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodM" BrowseName="CodM" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodS" BrowseName="CodS" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CodT" BrowseName="CodT" DataType="ua:String" ValueRank="Scalar" Units="" SGroup="2" VGroup="P" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:String" ValueRank="Scalar" Units="m/min" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:String" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Mode" BrowseName="Mode" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="SubMode" BrowseName="SubMode" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
</Component>
</Component>
</Component>
<Component Name="Plc">
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="OSAI" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="2019" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
</Component>
<Component Name="Hmi">
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="CMS Active" />
<Property SymbolicName="Version" BrowseName="Version" DataType="ua:String" ValueRank="Scalar" Value="1.02.02" />
<Condition SymbolicName="Condition" BrowseName="Condition" DataType="ua:String" ValueRank="Scalar" Type="OffNormalAlarmState" Units="" />
<Variable SymbolicName="User" BrowseName="User" DataType="ua:String" ValueRank="Scalar" Units="" />
<Variable SymbolicName="Language" BrowseName="Language" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="ActiveSection" BrowseName="ActiveSection" DataType="ua:String" ValueRank="Scalar" Units="h" />
<Variable SymbolicName="ActiveTimeSession" BrowseName="ActiveTimeSession" DataType="ua:String" ValueRank="Scalar" Units="" />
</Component>
<Component Name="Axes">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="X" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="026" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="011" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="005" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="004" CmsDataOpt="METER"/>
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="02">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="Y" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="027" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="012" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="007" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" CmsDataType="CounterList" CmsDataIndex="006" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="03">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="Z" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="028" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="013" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="009" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="008" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="04">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="B" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="029" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="014" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="011" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="010" CmsDataOpt="NUM" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<Component Name="05">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="C" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="030" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="015" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="013" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="012" CmsDataOpt="NUM"/>
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<!--<Component Name="06">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="U" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="016" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>-->
<Component Name="07">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="V" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="017" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component>
<!-- <Component Name="08">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LINEAR" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="W" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="018" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="mm" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="Km" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="m/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component> -->
<!-- <Component Name="09">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="A" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="019" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component> -->
<!-- <Component Name="10">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="D" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="020" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component> -->
<!-- <Component Name="11">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="P" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="021" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component> -->
<!-- <Component Name="12">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="ROTATIONAL" />
<Property SymbolicName="Name" BrowseName="Name" DataType="ua:String" ValueRank="Scalar" Value="Q" />
<Property SymbolicName="Role" BrowseName="Role" DataType="ua:String" ValueRank="Scalar" Value="MASTER" />
<Property SymbolicName="MasterId" BrowseName="MasterId" DataType="ua:String" ValueRank="Scalar" Value="0" />
<Property SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Value="1" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="h" CmsDataType="CounterList" CmsDataIndex="056" CmsDataOpt="HOURS" />
<Variable SymbolicName="Direction" BrowseName="Direction" DataType="ua:String" ValueRank="Scalar" Units="Enum" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" CmsDataType="AnalogData" CmsDataIndex="022" CmsDataOpt="NUM" />
<Variable SymbolicName="CurrentPos" BrowseName="CurrentPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="2" DBand="1" VGroup="P" />
<Variable SymbolicName="TargetPos" BrowseName="TargetPos" DataType="ua:Float" ValueRank="Scalar" Units="Deg" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="Inversions" BrowseName="Inversions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="055" CmsDataOpt="COUNT" />
<Variable SymbolicName="Distance" BrowseName="Distance" DataType="ua:Float" ValueRank="Scalar" Units="KRev" SGroup="4" DBand="1" VGroup="P" CmsDataType="CounterList" CmsDataIndex="054" CmsDataOpt="METER" />
<Variable SymbolicName="FeedRate" BrowseName="FeedRate" DataType="ua:Float" ValueRank="Scalar" Units="Rpm/min" SGroup="4" DBand="1" VGroup="P" />
<Variable SymbolicName="FeedOverride" BrowseName="FeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="RapidOverride" BrowseName="RapidOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
</Component> -->
</Component>
<Component Name="OperatingGroups">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SPINDLE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Head 1" />
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="CS33" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="006" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Krev" CmsDataType="CounterList" CmsDataIndex="016" CmsDataOpt="NUM" />
<Variable SymbolicName="SpeedRate" BrowseName="SpeedRate" DataType="ua:UInt32" ValueRank="Scalar" Units="rpm" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="ToolChanges" BrowseName="ToolChanges" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="024" CmsDataOpt="NUM" />
<Variable SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Units="" />
</Component>
<!-- <Component Name="02">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SPINDLE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Head 2" />
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="CS33" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="007" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Krev" CmsDataType="CounterList" CmsDataIndex="034" CmsDataOpt="NUM" />
<Variable SymbolicName="SpeedRate" BrowseName="SpeedRate" DataType="ua:UInt32" ValueRank="Scalar" Units="rpm" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="ToolChanges" BrowseName="ToolChanges" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="025" CmsDataOpt="NUM" />
<Variable SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Units="" />
</Component> -->
<!-- <Component Name="03">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SPINDLE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Head 3" />
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="CS33" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="008" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Krev" CmsDataType="CounterList" CmsDataIndex="035" CmsDataOpt="NUM" />
<Variable SymbolicName="SpeedRate" BrowseName="SpeedRate" DataType="ua:UInt32" ValueRank="Scalar" Units="rpm" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="ToolChanges" BrowseName="ToolChanges" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="037" CmsDataOpt="NUM" />
<Variable SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Units="" />
</Component> -->
<!-- <Component Name="04">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SPINDLE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Head 4" />
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="CS33" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Enum" CmsDataType="StatusList" CmsDataIndex="009" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Krev" CmsDataType="CounterList" CmsDataIndex="036" CmsDataOpt="NUM" />
<Variable SymbolicName="SpeedRate" BrowseName="SpeedRate" DataType="ua:UInt32" ValueRank="Scalar" Units="rpm" />
<Variable SymbolicName="SpeedOverride" BrowseName="SpeedOverride" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="Load" BrowseName="Load" DataType="ua:Float" ValueRank="Scalar" Units="Perc" />
<Variable SymbolicName="ToolChanges" BrowseName="ToolChanges" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="038" CmsDataOpt="NUM" />
<Variable SymbolicName="ParentProc" BrowseName="ParentProc" DataType="ua:UInt32" ValueRank="Scalar" Units="" />
</Component> -->
</Component>
<Component Name="AuxiliaryGroups">
<Component Name="01">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="LUBRO" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Lubro_1" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="021" CmsDataOpt="RTV" />
</Component>
<Component Name="02">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_PUMP" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Vac_Pump_01" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="002" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="017" CmsDataOpt="RTV" />
</Component>
<Component Name="03">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumDx01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="019" CmsDataOpt="RTV" />
</Component>
<!-- <Component Name="04">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumDxMitr" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="048" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="05">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumDx02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="050" CmsDataOpt="RTV" />
</Component> -->
<Component Name="04">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_PUMP" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Vac_Pump_02" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="003" CmsDataOpt="BIT" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="018" CmsDataOpt="RTV" />
</Component>
<Component Name="05">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumSx01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="020" CmsDataOpt="RTV" />
</Component>
<!-- <Component Name="08">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumSxMitr" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="049" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="09">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="VACUUM_ACT" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="VacuumSx02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="051" CmsDataOpt="RTV" />
</Component> -->
<Component Name="06">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="COOLER" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Cooler_01" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="004" CmsDataOpt="BIT" />
</Component>
<Component Name="07">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PRESSURE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="PressAria" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="010" CmsDataOpt="BIT" />
</Component>
<Component Name="08">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PRESSURE01" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="PressureDx01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="046" CmsDataOpt="RTV" />
</Component>
<Component Name="09">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PRESSURE01" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="PressureSx01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="047" CmsDataOpt="RTV" />
</Component>
<!-- <Component Name="10">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv01Spindle01" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="011" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="11">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv01Spindle02" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="012" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="12">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv01Spindle03" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="013" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="13">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv01Spindle04" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="014" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="13">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv02Spindle01" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="015" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="14">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv02Spindle02" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="016" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="15">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv02Spindle03" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="017" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="16">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="CONTACTOR" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ContactorInv02Spindle04" />
<Variable SymbolicName="Status" BrowseName="Status" DataType="ua:String" ValueRank="Scalar" Units="Count" CmsDataType="StatusList" CmsDataIndex="018" CmsDataOpt="BIT" />
</Component> -->
<!-- <Component Name="16">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SLITTA_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="SlittaMag01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="023" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="17">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PROT_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ProtMag01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="044" CmsDataOpt="RTV" />
</Component> -->
<Component Name="10">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SLITTA_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="SlittaMag02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="043" CmsDataOpt="RTV" />
</Component>
<!-- <Component Name="19">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PROT_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="ProtMag02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="045" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="20">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SLITTA_TAST" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="SlittaTastatore01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="022" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="21">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SLITTA_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Pickup01" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="063" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="22">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="SLITTA_MAG" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Pickup02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="064" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="23">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="BRAKE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="FrenoAsseB" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="040" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="24">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="BRAKE" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="FrenoAsseC" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="041" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="25">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="DRILLER" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="Driller" />
<Variable SymbolicName="ActiveTime" BrowseName="ActiveTime" DataType="ua:Float" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="042" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="26">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PRESSURE01" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="PressureDx02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="052" CmsDataOpt="RTV" />
</Component> -->
<!-- <Component Name="27">
<Property SymbolicName="Type" BrowseName="Type" DataType="ua:String" ValueRank="Scalar" Value="PRESSURE01" />
<Property SymbolicName="Location" BrowseName="Location" DataType="ua:String" ValueRank="Scalar" Value="PressureSx02" />
<Variable SymbolicName="Repetitions" BrowseName="Repetitions" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="053" CmsDataOpt="RTV" />
</Component> -->
</Component>
<Component Name="ProductionProcesses">
<Component Name="01">
<Component Name="Programs">
<Component Name="01">
<Variable SymbolicName="RepsDone" BrowseName="RepsDone" DataType="ua:UInt32" ValueRank="Scalar" Units="Count" CmsDataType="CounterList" CmsDataIndex="003" CmsDataOpt="NUM" />
</Component>
</Component>
</Component>
</Component>
</Machine>
</ModelDesign>
+1 -1
View File
@@ -6,4 +6,4 @@
004:[COD 004] - MANUTENZIONE
005:[COD 005] - PULIZIA
006:[COD 006] - REGOLAZIONI
007:[COD 007] - PIPPO
007:[COD 007] - PIPPO
@@ -0,0 +1,15 @@
#------------------------------------------------------------
# CONFIGURAZIONE per funzionalità di copia dati tra are di memoria REDIS
#------------------------------------------------------------
# - commenti con "#"
# - elenco tipo NOME_ORIGINALE | NomeReplaced
#------------------------------------------------------------
# Elenco
#------------------------------------------------------------
ACTIVE:ProductionProcesses:01:Name|SOUR:ProductionProcesses:01:Name
ACTIVE:ProductionProcesses:01:RepsTarget|SOUR:ProductionProcesses:01:RepsTarget
ACTIVE:ProductionProcesses:01:RepsDone|SOUR:ProductionProcesses:01:RepsDone
ACTIVE:ProductionProcesses:01:ProgramName|SOUR:ProductionProcesses:01:Programs:01:Name
ACTIVE:ProductionProcesses:01:Notification|SOUR:ProductionProcesses:01:Notification
@@ -0,0 +1,75 @@
#------------------------------------------------------------
# CONFIGURAZIONE SOSTITUZIONE CHIAVI per OPC-UA-REDIS
#------------------------------------------------------------
# - commenti con "#"
# - elenco tipo MODO | RICERCA | NOME_ORIGINALE | NomeReplaced
# - se MODO = A --> INCLUDO
# - se MODO = X --> ESCLUDO
# - se RICERCA= I --> cerco INTERA STRINGA (regexp: VAR)
# - se RICERCA= B --> cerco INIZIO (regexp: ^VAR)
# - se RICERCA= E --> cerco FINE (regexp: VAR$)
# - se RICERCA= C --> cerco NELLA STRINGA(regexp: %VAR%)
#------------------------------------------------------------
# I: Ricerca stringa COMPLETA (IDENTICAL, regexp: VAR)
#------------------------------------------------------------
A|I|STATUS|Status
A|I|E_STOP|Emergency
A|I|POWER|Power
A|I|ACC_TIME|ActiveTime
A|I|ACC_TIME_WORK|ActiveWorkingTime
A|I|PROC_SEL|ProcSel
A|I|CodG_ACT|CodGAct
A|I|USER_ACTION|UserAction
#------------------------------------------------------------
# B: Ricerca dall'INIZIO stringa (BEGIN, regexp: ^VAR)
#------------------------------------------------------------
A|B|AV_|
A|B|ST_|
A|B|UNK_|Unk
A|B|Path|Cnc:CncProcesses
A|B|Axis|Axes
#------------------------------------------------------------
# E: Ricerca dalla FINE stringa (END, regexp: VAR$)
#------------------------------------------------------------
A|E|RUN_MODE|RunMode
A|E|EXE_MODE|ExeMode
A|E|COD_M|CodM
A|E|COD_S|CodS
A|E|COD_T|CodT
A|E|Cod_M|CodM
A|E|Cod_S|CodS
A|E|Cod_T|CodT
A|E|CodG_Act|CodGAct
A|E|PZ_TOT|PzTot
A|E|CurrProg_RowNum|CurrProgRowNum
#------------------------------------------------------------
# C: Ricerca NELLA stringa (CONTAINS, regexp: %VAR%)
#------------------------------------------------------------
A|C|SpindleOver_|SpindleOver
#------------------------------------------------------------
# X: Rimuovo valori NON OPC/UA
#------------------------------------------------------------
X|B|UNK_|Unk
X|B|MTC_asset|MTCAsset
X|B|TESTING|TESTING
X|E|VitaRes|VitaRes
X|E|VitaResType|VitaResType
X|E|PosActX|PosActX
X|E|PosActY|PosActY
X|E|PosActZ|PosActZ
X|E|PosActI|PosActI
X|E|PosActJ|PosActJ
X|E|PosActK|PosActK
X|E|PartId|PartId
X|E|PZ_TOT|PZ_TOT
X|E|CurrArea|CurrArea
# elimino counter/RTCounter di cui ignoro impiego...
X|B|RTCounter|RTCounter
X|B|Counter|Counter
+2 -1
View File
@@ -4,4 +4,5 @@
003|VacPump_02_Status |BIT
004|Cooler_01_Status |BIT
005|Cooler_02_Status |BIT
006|UnOp_01_Status |BIT
006|UnOp_01_Status |BIT
007|UnOp_02_Status |BIT
+3 -3
View File
@@ -4,7 +4,7 @@
2:BlkDel
3:OpStop
4:Teach
5:Prg Test
5:PrgTest
6:MLock
7:DryRun
8:Restart
@@ -16,8 +16,8 @@
14:MANUAL_REF
15:MANUAL_JOGINC
16:MANUAL_HANDLE
17:
18:
17:IncPlane
18:MAN_HANDLE_INTERRUPT
19:
20:Asse selezionato 1
21:Asse selezionato 2
+7
View File
@@ -0,0 +1,7 @@
<ModelDesign>
<Machine>
<Property SymbolicName="Model" BrowseName="Model" DataType="ua:String" ValueRank="Scalar" Value="ANTARES26/15-PX5" />
<Property SymbolicName="Manufacturer" BrowseName="Manufacturer" DataType="ua:String" ValueRank="Scalar" Value="CMS Industries" />
<Variable SymbolicName="Emergency" BrowseName="Emergency" DataType="ua:Boolean" ValueRank="Scalar" Units="Bool" />
</Machine>
</ModelDesign>
+229
View File
@@ -0,0 +1,229 @@
using System.Collections.Generic;
using System.Xml;
namespace SCMA
{
public class DataModel
{
#region oggetti di base
public class ouData
{
public string SymbolicName { get; set; }
public string BrowseName { get; set; }
public string DataType { get; set; }
public string ValueRank { get; set; }
}
public class Property : ouData
{
public string Value { get; set; }
}
public class Variable : ouData
{
public string Units { get; set; }
public string CmsDataType { get; set; } = "";
public string CmsDataIndex { get; set; } = "";
public string CmsDataOpt { get; set; } = "";
}
public class Condition : ouData
{
public string Type { get; set; }
public string Units { get; set; }
}
public class Component
{
public string Name { get; set; }
public string BrowseName { get; set; }
}
public List<Property> Properties;
public List<Variable> Variables;
public List<Component> Components;
public List<Condition> Conditions;
#endregion
/// <summary>
/// init base
/// </summary>
/// <param name="file"></param>
public DataModel()
{
Properties = new List<Property>();
Variables = new List<Variable>();
Components = new List<Component>();
Conditions = new List<Condition>();
}
/// <summary>
/// Deserializza modello a partire da classe base
/// </summary>
/// <param name="xmlOrig"></param>
public DataModel Deserialize(string xmlOrig)
{
DataModel answ = new DataModel();
var xmlDocument = new XmlDocument();
xmlDocument.LoadXml(xmlOrig);
string baseNS = "Machine";
var itemRef = xmlDocument.GetElementsByTagName(baseNS);
// aggiungo i child...
var xmlNodeList = itemRef[0]?.ChildNodes;
addNodes(baseNS, xmlNodeList);
// salvo proprietà, variabili, condizioni, ...
answ.Properties = Properties;
answ.Variables = Variables;
answ.Components = Components;
answ.Conditions = Conditions;
return answ;
}
/// <summary>
/// Deserializza modello a partire da classe base
/// </summary>
/// <param name="fileName"></param>
public DataModel DeserializeFile(string fileName)
{
DataModel answ = new DataModel();
var xmlDocument = new XmlDocument();
xmlDocument.Load(fileName);
string baseNS = "Machine";
var itemRef = xmlDocument.GetElementsByTagName(baseNS);
// aggiungo i child...
var xmlNodeList = itemRef[0]?.ChildNodes;
addNodes(baseNS, xmlNodeList);
return answ;
}
private void addNodes(string baseNS, XmlNodeList xmlNodeList)
{
// se ho child processo---
if (xmlNodeList.Count > 0)
{
foreach (XmlElement xmlElement in xmlNodeList)
{
saveMemItem(xmlElement, baseNS);
}
}
}
/// <summary>
/// Verifica elemento e lo inserisce in memoria
/// </summary>
/// <param name="currElement"></param>
private void saveMemItem(XmlElement currElement, string baseNS)
{
if (currElement.Name != "Component" && currElement.Name != "Conditions")
{
switch (currElement.Name)
{
case "Property":
AddProperty(currElement, baseNS);
break;
case "Condition":
AddCondition(currElement, baseNS);
break;
default:
AddVariable(currElement, baseNS);
break;
}
}
else
{
var varName = currElement.Attributes["Name"].Value;
if (currElement.Name == "Conditions")
{
// CreateConditions(folder, stringFolderName + "/" + varName, varName, xmlElement, stringFolderName, folderInstanceState, nameSpaceIndex);
}
else
{
AddComponent(currElement, baseNS);
}
}
}
private void AddComponent(XmlElement currElement, string baseNS)
{
Component newItem = new Component
{
Name = currElement.Attributes["Name"].Value,
BrowseName = string.Format(baseNS + ":" + currElement.Attributes["Name"].Value)
};
Components.Add(newItem);
// controllo se ha dei child... nel caso aggiungo i child...
var xmlNodeList = currElement?.ChildNodes;
if (xmlNodeList.Count > 0)
{
addNodes(newItem.BrowseName, xmlNodeList);
}
}
private void AddProperty(XmlElement currElement, string baseNS)
{
Property newItem = new Property
{
SymbolicName = currElement.Attributes["SymbolicName"].Value,
BrowseName = string.Format(baseNS + ":" + currElement.Attributes["SymbolicName"].Value),
DataType = currElement.Attributes["DataType"].Value,
ValueRank = currElement.Attributes["ValueRank"].Value,
Value = currElement.Attributes["Value"].Value
};
Properties.Add(newItem);
// controllo se ha dei child... nel caso aggiungo i child...
var xmlNodeList = currElement?.ChildNodes;
if (xmlNodeList.Count > 0)
{
addNodes(newItem.BrowseName, xmlNodeList);
}
}
private void AddVariable(XmlElement currElement, string baseNS)
{
Variable newItem = new Variable
{
SymbolicName = currElement.Attributes["SymbolicName"].Value,
BrowseName = string.Format(baseNS + ":" + currElement.Attributes["SymbolicName"].Value),
DataType = currElement.Attributes["DataType"].Value,
ValueRank = currElement.Attributes["ValueRank"].Value,
Units = currElement.Attributes["Units"].Value,
CmsDataIndex = currElement.Attributes["CmsDataIndex"] == null ? "" : currElement.Attributes["CmsDataIndex"].Value,
CmsDataOpt = currElement.Attributes["CmsDataOpt"] == null ? "" : currElement.Attributes["CmsDataOpt"].Value,
CmsDataType = currElement.Attributes["CmsDataType"] == null ? "" : currElement.Attributes["CmsDataType"].Value
};
Variables.Add(newItem);
// controllo se ha dei child... nel caso aggiungo i child...
var xmlNodeList = currElement?.ChildNodes;
if (xmlNodeList.Count > 0)
{
addNodes(newItem.BrowseName, xmlNodeList);
}
}
private void AddCondition(XmlElement currElement, string baseNS)
{
Condition newItem = new Condition
{
SymbolicName = currElement.Attributes["SymbolicName"].Value,
BrowseName = string.Format(baseNS + ":" + currElement.Attributes["SymbolicName"].Value),
DataType = currElement.Attributes["DataType"].Value,
ValueRank = currElement.Attributes["ValueRank"].Value,
Type = currElement.Attributes["Type"].Value,
Units = currElement.Attributes["Units"].Value
};
Conditions.Add(newItem);
// controllo se ha dei child... nel caso aggiungo i child...
var xmlNodeList = currElement?.ChildNodes;
if (xmlNodeList.Count > 0)
{
addNodes(newItem.BrowseName, xmlNodeList);
}
}
}
}
+172
View File
@@ -0,0 +1,172 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Xml.Serialization;
namespace SCMA
{
/// <summary>
/// Classe per serializzazione / deserializzazione del datamodel x le informazioni necessarie x ADAPTER OPC-UA 2.1+
///
/// ref:
/// - https://stackoverflow.com/questions/37198689/deserialization-of-complex-object-c-sharp
/// - https://stackoverflow.com/questions/15907357/deserialization-of-xml-file-by-using-xmlarray
/// - http://www.cambiaresearch.com/articles/33/how-can-i-easily-manage-an-xml-configuration-file-in-dotnet
/// </summary>
[Serializable]
[XmlRoot("ModelDesign")]
public class DataModelXML
{
// rivedere con
// - https://docs.microsoft.com/it-it/dotnet/standard/serialization/controlling-xml-serialization-using-attributes
// - https://www.jonasjohn.de/snippets/csharp/xmlserializer-example.htm
// RIPENSARE OBJ GERARCHICO IN TOTO...
// ModelDesign > MAchine > List<Property> + List<Array> + List<Component> ognuno coi suoi attributi...
[XmlArray("Machine")]
[XmlArrayItem("Property", Type = typeof(Property))]
[XmlArrayItem("Variable", Type = typeof(Variable))]
[XmlArrayItem("Component", Type = typeof(Component))]
public ouData[] PVData { get; set; }
//[XmlArray("Machine")]
//[XmlArrayItem("Property")]
//[XmlArrayItem("Property", Type = typeof(Property))]
//[XmlArrayItem("Variable", Type = typeof(Variable))]
//[XmlArrayItem("Component", Type = typeof(Component))]
//public cData[] CData { get; set; }
/// <summary>
/// Serializzazione XML dell'oggetto conf dell'adapter
/// </summary>
/// <param name="file"></param>
/// <param name="c"></param>
public static void Serialize(string file, DataModelXML c)
{
// prima provo a creare il file vuoto...
if (!File.Exists(file))
{
string dirPath = file.Substring(0, file.LastIndexOf('\\'));
// verifico directory
if (!Directory.Exists(dirPath))
{
Directory.CreateDirectory(dirPath);
}
}
// salvo effettivamente file...
XmlSerializer xs = new XmlSerializer(c.GetType());
StreamWriter writer = File.CreateText(file);
xs.Serialize(writer, c);
writer.Flush();
writer.Close();
}
/// <summary>
/// deserializzazione oggetto conf adapter
/// </summary>
/// <param name="file"></param>
/// <returns></returns>
public static DataModelXML Deserialize(string file)
{
XmlSerializer xs = new XmlSerializer(typeof(DataModelXML));
StreamReader reader = File.OpenText(file);
DataModelXML c = (DataModelXML)xs.Deserialize(reader);
reader.Close();
return c;
}
/// <summary>
/// restitusice forma XML grezza del file
/// </summary>
/// <param name="file"></param>
/// <returns></returns>
public static string rawXml(string file)
{
string answ = "";
XmlSerializer xs = new XmlSerializer(typeof(DataModelXML));
StreamReader reader = File.OpenText(file);
answ = reader.ReadToEnd();
reader.Close();
return answ;
}
}
[Serializable]
public class Modules
{
[XmlElement]
public Channel channel { get; set; }
[XmlArray("Machine")]
//[XmlArrayItem("Property")]
//[XmlArrayItem("Property", Type = typeof(Property))]
//[XmlArrayItem("Variable", Type = typeof(Variable))]
//[XmlArrayItem("Component", Type = typeof(Component))]
public ouData[] PVData { get; set; }
//public List<Property> Properties { get; set; }
}
[Serializable]
[XmlInclude(typeof(Property))]
[XmlInclude(typeof(Variable))]
[XmlInclude(typeof(Component))]
public class ouData
{
[XmlAttribute]
public string Name { get; set; }
[XmlAttribute]
public string SymbolicName { get; set; }
[XmlAttribute]
public string BrowseName { get; set; }
[XmlAttribute]
public string DataType { get; set; }
[XmlAttribute]
public string ValueRank { get; set; }
[XmlAttribute]
public string Value { get; set; }
[XmlAttribute]
public string Units { get; set; }
}
[Serializable]
public class Property : ouData { }
[Serializable]
public class Variable : ouData { }
[Serializable]
public class Component : ouData { }
[Serializable]
public class Channel
{
[XmlArray("resources")]
[XmlArrayItem("resource")]
public List<Resources> resources { get; set; }
}
[Serializable]
public class Resources
{
[XmlAttribute]
public string name { get; set; }
[XmlAttribute]
public string url { get; set; }
[XmlAttribute]
public string refresh_interval { get; set; }
[XmlText]
public string someText { get; set; }
}
}
+583 -760
View File
File diff suppressed because it is too large Load Diff
+592 -45
View File
@@ -69,6 +69,10 @@ namespace SCMA
/// </summary>
AdapterConf adpConf;
/// <summary>
/// DataModel caricato
/// </summary>
DataModel currDataModel;
/// <summary>
/// tipo di adapter prescelto...
/// </summary>
public tipoAdapter tipoScelto = tipoAdapter.DEMO;
@@ -135,7 +139,7 @@ namespace SCMA
lastStartTry = DateTime.Now;
// fix icon!
notifyIcon1.Text = string.Format("MTC Adapter | {0}", System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
notifyIcon1.Text = string.Format("SCMA | {0}", System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
Icon = Icon.ExtractAssociatedIcon(defIconFilePath);
notifyIcon1.Icon = Icon.ExtractAssociatedIcon(defIconFilePath);
@@ -233,12 +237,12 @@ namespace SCMA
// SE permessa massimizzazione...
if (utils.CRB("windowCanMax"))
{
trayMenu.Items.Add("Show MTC Adapter");
trayMenu.Items.Add("Show SCMA");
}
// se è permesso tray close...
if (utils.CRB("trayClose"))
{
trayMenu.Items.Add("Close MTC Adapter");
trayMenu.Items.Add("Close SCMA");
}
}
@@ -349,7 +353,7 @@ namespace SCMA
{
get
{
return string.Format(@"{0}\MTCA.ico", utils.resxDir);
return string.Format(@"{0}\Scma.ico", utils.resxDir);
}
}
@@ -358,7 +362,7 @@ namespace SCMA
/// </summary>
private void loadAdapterType()
{
Gateway currGateway;// = new Gateway();
Gateway currGateway;
switch (utils.CRS("adpProto"))
{
case "MTC":
@@ -382,7 +386,7 @@ namespace SCMA
start.Enabled = true;
break;
case tipoAdapter.ESAGV:
agObj = new AdapterESA(this, adpConf, currGateway);
agObj = new AdapterPLC.SCM.ESA(this, adpConf, currGateway);
EnableTab(tabCtrlMain.TabPages[1], true);
EnableTab(tabCtrlMain.TabPages[2], false);
start.Enabled = true;
@@ -485,21 +489,28 @@ namespace SCMA
{
cbPathSel.Items.Insert(i, adpConf.Path[i].ident);
}
if (adpConf.nPath > 0) cbPathSel.SelectedIndex = 0;
if (adpConf.nPath > 0)
{
cbPathSel.SelectedIndex = 0;
}
for (int i = 0; i < adpConf.nUnOp; i++)
{
cbUnOpSel.Items.Insert(i, adpConf.UnOp[i].ident);
}
if (adpConf.nUnOp > 0) cbUnOpSel.SelectedIndex = 0;
if (adpConf.nUnOp > 0)
{
cbUnOpSel.SelectedIndex = 0;
}
for (int i = 0; i < adpConf.nAxis; i++)
{
cbAxNum.Items.Insert(i, adpConf.Axis[i].ident);
}
if (adpConf.nAxis > 0) cbAxNum.SelectedIndex = 0;
if (adpConf.nAxis > 0)
{
cbAxNum.SelectedIndex = 0;
}
}
/// <summary>
@@ -773,14 +784,18 @@ namespace SCMA
/// </summary>
private static void apriDumpAgent()
{
string path = Application.StartupPath;
try
// solo se sono in modalità MTC...
if (utils.CRS("adpProto") == "MTC")
{
Process.Start(string.Format(@"{0}\..\..\dump\dump.exe", path));
}
catch
{
Process.Start(string.Format(@"{0}\dump\dump.exe", path));
string path = Application.StartupPath;
try
{
Process.Start(string.Format(@"{0}\..\..\dump\dump.exe", path));
}
catch
{
Process.Start(string.Format(@"{0}\dump\dump.exe", path));
}
}
}
@@ -968,37 +983,58 @@ namespace SCMA
// controllo se ci sia il flag di lettura di un evento M/S/T nel qual caso lo abbasso...
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.M_CODE))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.M_CODE)) agObj.STROBE_PLC -= Strobe.M_CODE;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.M_CODE))
{
agObj.STROBE_PLC -= Strobe.M_CODE;
}
}
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.S_CODE))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.S_CODE)) agObj.STROBE_PLC -= Strobe.S_CODE;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.S_CODE))
{
agObj.STROBE_PLC -= Strobe.S_CODE;
}
}
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.T_CODE))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.T_CODE)) agObj.STROBE_PLC -= Strobe.T_CODE;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.T_CODE))
{
agObj.STROBE_PLC -= Strobe.T_CODE;
}
}
// controllo se ci sia il flag di lettura di un evento pz ok/ko nel qual caso lo abbasso...
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.PZ_OK))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.PZ_OK)) agObj.STROBE_PLC -= Strobe.PZ_OK;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.PZ_OK))
{
agObj.STROBE_PLC -= Strobe.PZ_OK;
}
}
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.PZ_KO))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.PZ_KO)) agObj.STROBE_PLC -= Strobe.PZ_KO;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.PZ_KO))
{
agObj.STROBE_PLC -= Strobe.PZ_KO;
}
}
// controllo se ci sia il flag di lettura di un evento FEED_SPEED nel qual caso lo abbasso...
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.FEED_SPEED))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.FEED_SPEED)) agObj.STROBE_PLC -= Strobe.FEED_SPEED;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.FEED_SPEED))
{
agObj.STROBE_PLC -= Strobe.FEED_SPEED;
}
}
// controllo se ci sia il flag di lettura di un evento POS_ACT nel qual caso lo abbasso...
if (utils.IsSetAll(agObj.STROBE_ADP, Strobe.POS_ACT))
{
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.POS_ACT)) agObj.STROBE_PLC -= Strobe.POS_ACT;
if (utils.IsSetAll(agObj.STROBE_PLC, Strobe.POS_ACT))
{
agObj.STROBE_PLC -= Strobe.POS_ACT;
}
}
refreshVisualStrobes();
@@ -1204,8 +1240,463 @@ namespace SCMA
{
displayTaskAndWait(string.Format("Loading XML: {0}", XmlConfFile));
// Read the configuration object from a file
adpConf = AdapterConf.Deserialize(XmlConfFile);
// 2019.07.13: cambiata procedura SE ci trociamo nel caso OPC-UA / SOUR che aprte da DataModel.xml...
if (utils.CRS("adpProto") == "SOURS" && XmlConfFile.EndsWith("DataModel.xml"))
{
if (utils.CRB("verbose"))
{
lg.Info("Inizio caricamento DataModel per OPC-UA REDIS server");
}
StreamReader file;
// carica da file...
file = new StreamReader(XmlConfFile);
// leggo file...
string rawDataModel = file.ReadToEnd();
// faccio un primo passaggio di pulizia commenti...
string sanitizedXml = utils.xmlSanitize(rawDataModel);
// chiudo file
file.Close();
// effettuo deserializzazione...
DataModel dm = new DataModel();
currDataModel = dm.Deserialize(sanitizedXml);
// avvio oggetto conf
tipoScelto = tipoAdapter.ND;
adpConf = new AdapterConf();
// salvo i dati "specifici" in base a quanto recuperato da DataModel...
// cerco da plc/Name il tipo di PLC...
string plcName = "";
var trovatoCnc = currDataModel.Properties.Find(x => x.BrowseName.Contains("Machine:Cnc:Name"));
var trovatoPlc = currDataModel.Properties.Find(x => x.BrowseName.Contains("Machine:Plc:Name"));
if (trovatoCnc != null)
{
plcName = trovatoCnc.Value;
}
else if (trovatoPlc != null)
{
plcName = trovatoPlc.Value;
}
Enum.TryParse<tipoAdapter>(plcName, true, out tipoScelto);
adpConf.NomeAdapt = plcName;
adpConf.TipoAdapt = tipoScelto;
adpConf.Version = 2;
// preparo file temp x generazione regole
StreamWriter fileOut;
// apro in scrittura il file x mettere le regole...
fileOut = new StreamWriter(utils.nameRepRoleFileSOUR);
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("# AUTO GENERATED Replacement Conf File");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("");
// altre variabili
element newElement;
int numRules = 0;
string replString = "";
// cerco ASSI come componenti...
List<DataRefItem<string, string>> dataRefList;
int numAx = 0;
List<element> listaAx = new List<element>();
List<DataModel.Component> selAxes = currDataModel.Components.FindAll(x => x.BrowseName.Contains("Machine:Axes:"));
string axBaseName = "";
string axType = "LINEAR";
foreach (var item in selAxes)
{
numAx++;
axBaseName = $"Axis_{numAx.ToString("00")}";
// preparo la datarefList x TIPO assi e gruppo...
dataRefList = new List<DataRefItem<string, string>>();
// calcolo TIPO DI ASSE
DataModel.Property tipoAsse = currDataModel.Properties.Find(x => x.BrowseName.Contains($"{item.BrowseName}:Type"));
if (tipoAsse != null)
{
axType = tipoAsse.Value;
}
else
{
axType = "LINEAR";
}
// aggiungo conf specifiche...
dataRefList.Add(new DataRefItem<string, string>($"Axis_{ numAx.ToString("00") }_Grp", "00"));
dataRefList.Add(new DataRefItem<string, string>($"Axis_{ numAx.ToString("00") }_Type", axType));
newElement = new element()
{
ident = axBaseName,
dataRefList = dataRefList
};
listaAx.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "");
fileOut.WriteLine($"A|I|{newElement.ident}_PosAct|{replString}:CurrentPos");
fileOut.WriteLine($"A|I|{newElement.ident}_PosTgt|{replString}:TargetPos");
fileOut.WriteLine($"A|I|{newElement.ident}_InvDDone|{replString}:Inversions");
fileOut.WriteLine($"A|I|{newElement.ident}_DistDone|{replString}:Distance");
fileOut.WriteLine($"A|I|{newElement.ident}_FeedAct|{replString}:FeedRate");
fileOut.WriteLine($"A|I|{newElement.ident}_FeedOver|{replString}:FeedOverride");
fileOut.WriteLine($"A|I|{newElement.ident}_MainProc|{replString}:ParentProc");
fileOut.WriteLine($"A|I|{newElement.ident}_Descr|{replString}:Name");
fileOut.WriteLine($"A|I|AV_{newElement.ident}_Load|{replString}:Load");
fileOut.WriteLine($"A|I|{newElement.ident}_AccTime|{replString}:ActiveTime");
fileOut.WriteLine($"A|I|{newElement.ident}_Dir|{replString}:Direction");
fileOut.WriteLine($"A|I|{newElement.ident}_MastId|{replString}:MasterId");
fileOut.WriteLine($"A|I|{newElement.ident}_Type|{replString}:Type");
numRules += 13;
}
fileOut.WriteLine("");
// cerco PATH/Processi come componenti...
int numProc = 0;
List<element> listaProc = new List<element>();
List<DataModel.Component> selProc = currDataModel.Components.FindAll(x => x.BrowseName.Contains("Machine:Cnc:CncProcesses:"));
string procBaseName = "";
foreach (var item in selProc)
{
numProc++;
procBaseName = $"Path_{numProc.ToString("00")}";
newElement = new element()
{
ident = procBaseName
};
listaProc.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "");
fileOut.WriteLine($"A|I|{newElement.ident}_CodG_Act|{replString}:CodG");
fileOut.WriteLine($"A|I|{newElement.ident}_Cod_M|{replString}:CodM");
fileOut.WriteLine($"A|I|{newElement.ident}_Cod_S|{replString}:CodS");
fileOut.WriteLine($"A|I|{newElement.ident}_Cod_T|{replString}:CodT");
fileOut.WriteLine($"A|I|{newElement.ident}_EXE_MODE|{replString}:Status");
fileOut.WriteLine($"A|I|{newElement.ident}_RUN_MODE|{replString}:Mode");
fileOut.WriteLine($"A|I|{newElement.ident}_RapidOverr|{replString}:RapidOverride");
fileOut.WriteLine($"A|I|{newElement.ident}_FeedOverr|{replString}:FeedOverride");
numRules += 8;
}
fileOut.WriteLine("");
// cerco UnOp / Gruppi operatori come componenti...
int numUnOp = 0;
List<element> listaUnOp = new List<element>();
List<DataModel.Component> selUnOp = currDataModel.Components.FindAll(x => x.BrowseName.Contains("Machine:OperatingGroups:"));
string procUnOp = "";
foreach (var item in selUnOp)
{
numUnOp++;
procUnOp = $"UnOp_{numUnOp.ToString("00")}";
newElement = new element()
{
ident = procUnOp
};
listaUnOp.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Speed|{replString}:SpeedRate");
fileOut.WriteLine($"A|I|{newElement.ident}_KRev|{replString}:Distance");
fileOut.WriteLine($"A|I|{newElement.ident}_AccTime|{replString}:ActiveTime");
fileOut.WriteLine($"A|I|{newElement.ident}_ToolId|{replString}:ToolId");
fileOut.WriteLine($"A|I|{newElement.ident}_NumCU|{replString}:ToolChanges");
fileOut.WriteLine($"A|I|{newElement.ident}_Load|{replString}:Load");
fileOut.WriteLine($"A|I|{newElement.ident}_SpeedOverr|{replString}:SpeedOverride");
fileOut.WriteLine($"A|I|{newElement.ident}_Status|{replString}:Status");
numRules += 8;
}
fileOut.WriteLine("");
// cerco nei gruppi ausiliari...
// VacuumPump...
int numVP = 0;
List<element> listaVP = new List<element>();
// VacuumAct
int numVA = 0;
List<element> listaVA = new List<element>();
// SlittaMag
int numSlMag = 0;
List<element> listaSlMag = new List<element>();
// ProtMag
int numProtMag = 0;
List<element> listaProtMag = new List<element>();
// SlittaTast
int numSlTas = 0;
List<element> listaSlTas = new List<element>();
// Cooler...
int numCool = 0;
List<element> listaCool = new List<element>();
// Lubro...
int numLub = 0;
List<element> listaLub = new List<element>();
// Press...
int numPres = 0;
List<element> listaPress = new List<element>();
// Temperature...
int numTemp = 0;
List<element> listaTemp = new List<element>();
// ricerca gruppi AUX
List<DataModel.Property> selAux = currDataModel.Properties.FindAll(x => x.BrowseName.Contains("Machine:AuxiliaryGroups"));
foreach (var item in selAux)
{
if (item.Value == "COOLER")
{
numCool++;
newElement = new element()
{
ident = $"Cooler_{numCool.ToString("00")}"
};
listaCool.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Status|{replString}:Status");
numRules++;
}
if (item.Value == "LUBRO")
{
numLub++;
newElement = new element()
{
ident = $"Lubro_{numLub.ToString("00")}"
};
listaLub.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
numRules++;
}
if (item.Value == "VACUUM_PUMP")
{
numVP++;
newElement = new element()
{
ident = $"VacPump_{numVP.ToString("00")}"
};
listaVP.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Status|{replString}:Status");
fileOut.WriteLine($"A|I|{newElement.ident}_WrkTime|{replString}:ActiveTime");
numRules += 2;
}
if (item.Value == "VACUUM_ACT")
{
numVA++;
newElement = new element()
{
ident = $"VacAct_{numVA.ToString("00")}"
};
listaVA.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
fileOut.WriteLine($"A|I|{newElement.ident}_Value|{replString}:Value");
numRules++;
}
if (item.Value == "SLITTA_MAG")
{
numSlMag++;
newElement = new element()
{
ident = $"SlittaMagazzino_{numSlMag.ToString("00")}"
};
listaSlMag.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
numRules++;
}
if (item.Value == "PROT_MAG")
{
numProtMag++;
newElement = new element()
{
ident = $"ProtezioneMagazzino_{numProtMag.ToString("00")}"
};
listaProtMag.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
numRules++;
}
if (item.Value == "SLITTA_TAST")
{
numSlTas++;
newElement = new element()
{
ident = $"SlittaTastatore_{numPres.ToString("00")}"
};
listaSlTas.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
numRules++;
}
if (item.Value == "PRESSURE")
{
numPres++;
newElement = new element()
{
ident = $"Press_{numPres.ToString("00")}"
};
listaPress.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Value|{replString}:Value");
fileOut.WriteLine($"A|I|{newElement.ident}_Status|{replString}:Status");
fileOut.WriteLine($"A|I|{newElement.ident}_Count|{replString}:Repetitions");
numRules += 1;
}
if (item.Value == "TEMPERATURE")
{
numTemp++;
newElement = new element()
{
ident = $"Temp_{numTemp.ToString("00")}"
};
listaTemp.Add(newElement);
// aggiungo su file...
replString = item.BrowseName.Replace("Machine:", "").Replace(":Type", "");
fileOut.WriteLine($"A|I|{newElement.ident}_Value|{replString}:Value");
numRules += 1;
}
}
// aggiungo elementi trovati...
if (numAx > 0)
{
element[] elencoAx = listaAx.ToArray();
adpConf.Axis = elencoAx;
}
if (numProc > 0)
{
element[] elencoProc = listaProc.ToArray();
adpConf.Path = elencoProc;
}
if (numUnOp > 0)
{
element[] elencoUnOp = listaUnOp.ToArray();
adpConf.UnOp = elencoUnOp;
}
if (numCool > 0)
{
element[] elencoCool = listaCool.ToArray();
adpConf.Cooler = elencoCool;
}
if (numLub > 0)
{
element[] elencoLub = listaLub.ToArray();
adpConf.Lubro = elencoLub;
}
if (numVP > 0)
{
element[] elencoVP = listaVP.ToArray();
adpConf.VacuumPump = elencoVP;
}
if (numVA > 0)
{
element[] elencoVA = listaVA.ToArray();
adpConf.VacuumAct = elencoVA;
}
if (numSlMag > 0)
{
element[] elencoSlMag = listaSlMag.ToArray();
adpConf.SlittaMag = elencoSlMag;
}
if (numSlTas > 0)
{
element[] elencoSlTas = listaSlTas.ToArray();
adpConf.SlittaTas = elencoSlTas;
}
if (numPres > 0)
{
element[] elencoPress = listaPress.ToArray();
adpConf.Press = elencoPress;
}
if (numTemp > 0)
{
element[] elencoTemp = listaTemp.ToArray();
adpConf.Temp = elencoTemp;
}
fileOut.WriteLine("");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine($"# EOF: {numRules} rules added");
fileOut.WriteLine("#------------------------------------------------------------");
// chiudo file regole!
fileOut.Close();
// compilo il file StatusList.SOUR.map
fileOut = new StreamWriter(utils.StatusListFileSOUR);
int numStatus = 0;
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("# AUTO GENERATED StatusList File");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("");
// ricerca in variabili
List<DataModel.Variable> selStatus = currDataModel.Variables.FindAll(x => x.CmsDataType.Equals("StatusList"));
foreach (var item in selStatus)
{
// compilo il file di conf...
fileOut.WriteLine($"{item.CmsDataIndex}|{item.BrowseName.Replace("Machine:", "")}|{item.CmsDataOpt}");
numStatus++;
}
fileOut.WriteLine("");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine($"# EOF: {numStatus} status added");
fileOut.WriteLine("#------------------------------------------------------------");
// chiudo file regole!
fileOut.Close();
// compilo il file CounterList.SOUR.map
fileOut = new StreamWriter(utils.CounterListFileSOUR);
int numCounter = 0;
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("# AUTO GENERATED CounterList File");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("");
// ricerca in variabili
List<DataModel.Variable> selCounter = currDataModel.Variables.FindAll(x => x.CmsDataType.Equals("CounterList"));
foreach (var item in selCounter)
{
// compilo il file di conf... se è RTV aggiungo la parte RTV..
fileOut.WriteLine($"{item.CmsDataIndex}|{item.BrowseName.Replace("Machine:", "")}|{item.CmsDataOpt}");
numCounter++;
}
fileOut.WriteLine("");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine($"# EOF: {numCounter} counters added");
fileOut.WriteLine("#------------------------------------------------------------");
// chiudo file regole!
fileOut.Close();
// compilo il file StatusList.SOUR.map
fileOut = new StreamWriter(utils.AnalogListFileSOUR);
int numAnalog = 0;
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("# AUTO GENERATED AnalogData File");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine("");
// ricerca in variabili
List<DataModel.Variable> selAnalog = currDataModel.Variables.FindAll(x => x.CmsDataType.Equals("AnalogData"));
foreach (var item in selAnalog)
{
// compilo il file di conf...
fileOut.WriteLine($"{item.CmsDataIndex}|{item.BrowseName.Replace("Machine:", "")}|{item.CmsDataOpt}");
numAnalog++;
}
fileOut.WriteLine("");
fileOut.WriteLine("#------------------------------------------------------------");
fileOut.WriteLine($"# EOF: {numAnalog} analog added");
fileOut.WriteLine("#------------------------------------------------------------");
// chiudo file regole!
fileOut.Close();
}
else
{
// legge obj configurazione "legacy"
adpConf = AdapterConf.Deserialize(XmlConfFile);
}
// indico quale sia il tipo di adapter
tipoScelto = adpConf.TipoAdapt;
@@ -1325,17 +1816,49 @@ namespace SCMA
// parto vuoto con StatusBitMap...
agObj.STATUS_FLAG = 0;
// aggiorno status flag in base a valori...
if (answ.EmrStop) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.ESTOP;
if (automatic.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_AUTO;
else if (mdi.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_MDI;
else if (edit.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_EDIT;
else agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_MANUAL;
if (answ.EmrStop)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.ESTOP;
}
if (running.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_RUN;
else if (feedhold.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_FEEDHOLD;
else if (stopped.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_STOP;
else if (ready.Checked) agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_READY;
if (answ.FuncMode != "1") agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.HM;
if (automatic.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_AUTO;
}
else if (mdi.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_MDI;
}
else if (edit.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_EDIT;
}
else
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.RM_MANUAL;
}
if (running.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_RUN;
}
else if (feedhold.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_FEEDHOLD;
}
else if (stopped.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_STOP;
}
else if (ready.Checked)
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.EM_READY;
}
if (answ.FuncMode != "1")
{
agObj.STATUS_FLAG = agObj.STATUS_FLAG | StatusBitMap.HM;
}
// ritorno oggetto!
return answ;
@@ -1465,15 +1988,39 @@ namespace SCMA
// pezzi
answ.pzTot = pzOk + pzKo;
if (automatic.Checked) answ.RunMode = "AUTOMATIC";
else if (mdi.Checked) answ.RunMode = "MANUAL_DATA_INPUT";
else if (edit.Checked) answ.RunMode = "EDIT";
else answ.RunMode = "MANUAL";
if (automatic.Checked)
{
answ.RunMode = "AUTOMATIC";
}
else if (mdi.Checked)
{
answ.RunMode = "MANUAL_DATA_INPUT";
}
else if (edit.Checked)
{
answ.RunMode = "EDIT";
}
else
{
answ.RunMode = "MANUAL";
}
if (running.Checked) answ.ExeMode = "ACTIVE";
else if (feedhold.Checked) answ.ExeMode = "FEED_HOLD";
else if (stopped.Checked) answ.ExeMode = "STOPPED";
else if (ready.Checked) answ.ExeMode = "READY";
if (running.Checked)
{
answ.ExeMode = "ACTIVE";
}
else if (feedhold.Checked)
{
answ.ExeMode = "FEED_HOLD";
}
else if (stopped.Checked)
{
answ.ExeMode = "STOPPED";
}
else if (ready.Checked)
{
answ.ExeMode = "READY";
}
answ.ActiveAxes = "1 2 3 4 5 6"; // lascio sempre tutti attivi...
+134
View File
@@ -0,0 +1,134 @@
using System;
using System.IO;
using System.Xml.Serialization;
namespace SCMA
{
#region -- ModelDesign Class --
/// <summary>
/// Classe per serializzazione / deserializzazione del datamodel x le informazioni necessarie x ADAPTER OPC-UA 2.1+
///
/// ref: http://www.cambiaresearch.com/articles/33/how-can-i-easily-manage-an-xml-configuration-file-in-dotnet
/// </summary>
[Serializable]
[XmlRoot("ModelDesign")]
public class ModelDesign
{
cMachine mMachine;
/// <summary>
/// init conf adapter
/// </summary>
public ModelDesign()
{
}
/// <summary>
/// Classe di base oggetti OPC-UA in Datamodel da deserializzare
/// </summary>
public class ouBaseObj
{
//[XmlAttribute("SymbolicName")]
[XmlAttribute]
public string SymbolicName { get; set; }
[XmlAttribute("BrowseName")]
public string BrowseName { get; set; }
[XmlAttribute("DataType")]
public string DataType { get; set; }
[XmlAttribute("ValueRank")]
public string ValueRank { get; set; }
}
public class Property : ouBaseObj
{
[XmlAttribute("Value")]
public string Value { get; set; }
}
public class ouVariable : ouBaseObj
{
[XmlAttribute("Units")]
public string Units { get; set; }
}
/// <summary>
/// Oggetto più esterno Machine
/// </summary>
[Serializable]
public class cMachine
{
public Property Model { get; set; }
}
public cMachine Machine
{
get
{
return mMachine;
}
set
{
mMachine = value;
}
}
/// <summary>
/// Serializzazione XML dell'oggetto conf dell'adapter
/// </summary>
/// <param name="file"></param>
/// <param name="c"></param>
public static void Serialize(string file, ModelDesign c)
{
// prima provo a creare il file vuoto...
if (!File.Exists(file))
{
string dirPath = file.Substring(0, file.LastIndexOf('\\'));
// verifico directory
if (!Directory.Exists(dirPath))
{
Directory.CreateDirectory(dirPath);
}
}
// salvo effettivamente file...
XmlSerializer xs = new XmlSerializer(c.GetType());
StreamWriter writer = File.CreateText(file);
xs.Serialize(writer, c);
writer.Flush();
writer.Close();
}
/// <summary>
/// deserializzazione oggetto conf adapter
/// </summary>
/// <param name="file"></param>
/// <returns></returns>
public static ModelDesign Deserialize(string file)
{
XmlSerializer xs = new XmlSerializer(typeof(ModelDesign));
StreamReader reader = File.OpenText(file);
ModelDesign c = (ModelDesign)xs.Deserialize(reader);
reader.Close();
return c;
}
/// <summary>
/// restitusice forma XML grezza del file
/// </summary>
/// <param name="file"></param>
/// <returns></returns>
public static string rawXml(string file)
{
string answ = "";
XmlSerializer xs = new XmlSerializer(typeof(ModelDesign));
StreamReader reader = File.OpenText(file);
answ = reader.ReadToEnd();
reader.Close();
return answ;
}
}
#endregion
}
+470 -107
View File
@@ -37,12 +37,12 @@
</xs:attribute>
<xs:attribute name="globalThreshold" type="NLogLevel">
<xs:annotation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged..</xs:documentation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwExceptions" type="xs:boolean">
<xs:annotation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false.</xs:documentation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false. Not recommend to set to true in production!</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwConfigExceptions" type="xs:boolean">
@@ -72,7 +72,7 @@
</xs:attribute>
<xs:attribute name="parseMessageTemplates" type="xs:boolean">
<xs:annotation>
<xs:documentation>Perform mesage template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
<xs:documentation>Perform message template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -123,7 +123,7 @@
</xs:choice>
<xs:attribute name="name" use="optional">
<xs:annotation>
<xs:documentation>Name of the logger. May include '*' character which acts like a wildcard. Allowed forms are: *, Name, *Name, Name* and *Name*</xs:documentation>
<xs:documentation>Name of the logger. May include wildcard characters ('*' or '?').</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="levels" type="NLogLevelList">
@@ -156,9 +156,9 @@
<xs:documentation>Ignore further rules if this one matches.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enabled" type="xs:boolean" default="true">
<xs:attribute name="ruleName" type="xs:string" use="optional">
<xs:annotation>
<xs:documentation>Enable or disable logging rule. Disabled rules are ignored.</xs:documentation>
<xs:documentation>Rule identifier to allow rule lookup with Configuration.FindRuleByName and Configuration.RemoveRuleByName.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -171,6 +171,11 @@
<xs:element name="whenNotEqual" type="whenNotEqual" />
<xs:element name="whenRepeated" type="whenRepeated" />
</xs:choice>
<xs:attribute name="defaultAction" type="FilterResult">
<xs:annotation>
<xs:documentation>Default action if none of the filters match.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:simpleType name="NLogLevel">
<xs:restriction base="xs:string">
@@ -210,12 +215,19 @@
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLogVariable">
<xs:choice minOccurs="0" maxOccurs="1">
<xs:element name="value" minOccurs="0" maxOccurs="1" type="xs:string">
<xs:annotation>
<xs:documentation>Variable value. Note, the 'value' attribute has precedence over this one.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:choice>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Variable name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute" use="required">
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Variable value.</xs:documentation>
</xs:annotation>
@@ -276,6 +288,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="batchSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="forceLockingQueue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="fullBatchSizeWriteLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="overflowAction" minOccurs="0" maxOccurs="1" type="NLog.Targets.Wrappers.AsyncTargetWrapperOverflowAction" />
<xs:element name="queueLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
@@ -292,6 +305,11 @@
<xs:documentation>Number of log events that should be processed in a batch by the lazy writer thread.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="forceLockingQueue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether to use the locking queue, instead of a lock-free concurrent queue The locking queue is less concurrent when many logger threads, but reduces memory allocation</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="fullBatchSizeWriteLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>Limit of full s to write before yielding into Performance is better when writing many small batches, than writing a single large batch</xs:documentation>
@@ -309,7 +327,7 @@
</xs:attribute>
<xs:attribute name="timeToSleepBetweenBatches" type="xs:integer">
<xs:annotation>
<xs:documentation>Time in milliseconds to sleep between batches.</xs:documentation>
<xs:documentation>Time in milliseconds to sleep between batches. (1 or less means trigger on new activity)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -334,6 +352,7 @@
<xs:element name="asyncFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="flushOnConditionOnly" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="asyncFlush" type="xs:boolean">
@@ -351,6 +370,11 @@
<xs:documentation>Name of the target.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="flushOnConditionOnly" type="xs:boolean">
<xs:annotation>
<xs:documentation>Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -419,18 +443,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -438,7 +464,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -471,24 +497,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -496,9 +507,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -506,14 +527,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -521,11 +562,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -561,9 +597,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -588,14 +624,26 @@
<xs:enumeration value="Discard" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="System.Security.Authentication.SslProtocols">
<xs:restriction base="xs:string">
<xs:enumeration value="None" />
<xs:enumeration value="Ssl2" />
<xs:enumeration value="Ssl3" />
<xs:enumeration value="Tls" />
<xs:enumeration value="Tls11" />
<xs:enumeration value="Tls12" />
<xs:enumeration value="Default" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Targets.NLogViewerParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
@@ -603,6 +651,11 @@
<xs:documentation>Viewer parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="ColoredConsole">
<xs:complexContent>
@@ -613,11 +666,13 @@
<xs:element name="header" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="footer" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="enableAnsiOutput" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="errorStream" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="useDefaultRowHighlightingRules" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="highlight-row" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleRowHighlightingRule" />
<xs:element name="highlight-word" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleWordHighlightingRule" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -645,6 +700,11 @@
<xs:documentation>Indicates whether to auto-check if the console is available. - Disables console writing if Environment.UserInteractive = False (Windows Service) - Disables console writing if Console Standard Input is not available (Non-Console-App)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enableAnsiOutput" type="xs:boolean">
<xs:annotation>
<xs:documentation>Enables output using ANSI Color Codes</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encoding" type="xs:string">
<xs:annotation>
<xs:documentation>The encoding for writing messages to the .</xs:documentation>
@@ -660,6 +720,11 @@
<xs:documentation>Indicates whether to use default row highlighting rules.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -768,6 +833,7 @@
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="error" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -805,6 +871,11 @@
<xs:documentation>Indicates whether to send the log messages to the standard error instead of the standard output.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -946,22 +1017,36 @@
</xs:complexType>
<xs:complexType name="NLog.Targets.DatabaseParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="dbType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="precision" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="scale" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameterType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="format" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="culture" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="dbType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter DbType.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="precision" type="xs:byte">
<xs:annotation>
<xs:documentation>Database parameter precision.</xs:documentation>
@@ -972,9 +1057,19 @@
<xs:documentation>Database parameter scale.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:attribute name="parameterType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
<xs:documentation>Type of the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="format" type="xs:string">
<xs:annotation>
<xs:documentation>Convert format of the database parameter value .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="culture" type="xs:string">
<xs:annotation>
<xs:documentation>Culture used for parsing parameter string-value for type-conversion</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -1076,7 +1171,7 @@
</xs:attribute>
<xs:attribute name="entryType" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Optional entrytype. When not set, or when not convertable to then determined by </xs:documentation>
<xs:documentation>Optional entrytype. When not set, or when not convertible to then determined by </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="eventId" type="SimpleLayoutAttribute">
@@ -1096,7 +1191,7 @@
</xs:attribute>
<xs:attribute name="maxKilobytes" type="xs:long">
<xs:annotation>
<xs:documentation>Maximum Event log size in kilobytes. If null, the value won't be set. Default is 512 Kilobytes as specified by Eventlog API</xs:documentation>
<xs:documentation>Maximum Event log size in kilobytes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxMessageLength" type="xs:integer">
@@ -1287,7 +1382,7 @@
</xs:attribute>
<xs:attribute name="forceMutexConcurrentWrites" type="xs:boolean">
<xs:annotation>
<xs:documentation>Value indicationg whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
<xs:documentation>Indicates whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="replaceFileContentsOnEachWrite" type="xs:boolean">
@@ -1461,6 +1556,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="filter" minOccurs="0" maxOccurs="1" type="Filter" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1867,6 +1963,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="maxLogsCount" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1879,6 +1976,11 @@
<xs:documentation>Layout used to format log messages.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxLogsCount" type="xs:integer">
<xs:annotation>
<xs:documentation>Max number of items to have in memory</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -1937,6 +2039,8 @@
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2004,6 +2108,16 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -2022,18 +2136,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -2041,7 +2157,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2074,24 +2190,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -2099,9 +2200,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -2109,14 +2220,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -2124,11 +2255,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -2164,9 +2290,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -2709,6 +2835,13 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvColumnDelimiterMode">
<xs:restriction base="xs:string">
<xs:enumeration value="Auto" />
@@ -2720,17 +2853,11 @@
<xs:enumeration value="Custom" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Layouts.CsvColumn">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="quoting" minOccurs="0" maxOccurs="1" type="NLog.Layouts.CsvQuotingMode" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
@@ -2742,6 +2869,11 @@
<xs:documentation>Name of the column.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="quoting" type="NLog.Layouts.CsvQuotingMode">
<xs:annotation>
<xs:documentation>Override of Quoting mode</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="JsonLayout">
<xs:complexContent>
@@ -2750,11 +2882,12 @@
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.JsonAttribute" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeGdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="renderEmptyObject" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="suppressSpaces" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
@@ -2766,6 +2899,11 @@
<xs:documentation>Option to include all properties from the log event (as JSON)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeGdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2776,6 +2914,11 @@
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="renderEmptyObject" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to render the empty object value {}</xs:documentation>
@@ -2786,11 +2929,6 @@
<xs:documentation>Option to suppress the extra spaces in the output json</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2814,7 +2952,7 @@
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines wether or not this attribute will be Json encoded.</xs:documentation>
<xs:documentation>Determines whether or not this attribute will be Json encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="escapeUnicode" type="xs:boolean">
@@ -2859,16 +2997,24 @@
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
</xs:choice>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log events</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeCallSite" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include call site (class and method name) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2889,6 +3035,11 @@
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2906,6 +3057,218 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="XmlLayout">
<xs:complexContent>
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="elementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="elementValue" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="elementEncode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementName" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementValue" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementEncode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlAttribute">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that will be rendered as the attribute's value.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlElement">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="value" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="when">
<xs:complexContent>
<xs:extension base="Filter">
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

@@ -3,7 +3,7 @@
# Script conversione alarm list
#
# parte da file di input (tipicamente C:\Kvara\Xilog Plus Default\Country\Ita\app.msg)
# e genera un file di output nel formato necessario per MTConnect Adapter
# e genera un file di output nel formato necessario per Adapter
#----------------------------------------------
#
# abilitazione script:
Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

+58 -15
View File
@@ -54,7 +54,8 @@
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>Resources\MTCA.ico</ApplicationIcon>
<ApplicationIcon>
</ApplicationIcon>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'CMS-FANUC|AnyCPU' ">
<OutputPath>bin\CMS-FANUC\</OutputPath>
@@ -100,8 +101,11 @@
<Reference Include="DotNetAdapterSDK">
<HintPath>..\..\ExtLib\DotNetAdapterSDK.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
<HintPath>..\packages\NLog.4.6.6\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="Siemens.Sinumerik.Operate.Services, Version=4.7.3.2, Culture=neutral, PublicKeyToken=bdd90fa02fd1c4ee, processorArchitecture=x86">
<SpecificVersion>False</SpecificVersion>
@@ -137,12 +141,15 @@
<Compile Include="AdapterCom\GatewayMTC.cs" />
<Compile Include="AdapterCom\GatewaySOURS.cs" />
<Compile Include="AdapterConf.cs" />
<Compile Include="AdapterESA.cs" />
<Compile Include="AdapterPLC\SCM\ESA.cs" />
<Compile Include="AdapterOsai.cs" />
<Compile Include="AdapterSiemens.cs" />
<Compile Include="AdapterGeneric.cs" />
<Compile Include="AdapterDemo.cs" />
<Compile Include="AdapterFanuc.cs" />
<Compile Include="DataModel.cs" />
<Compile Include="DataModelXML.cs" />
<Compile Include="ModelDesignConf.cs" />
<Compile Include="MainForm.cs">
<SubType>Form</SubType>
</Compile>
@@ -158,6 +165,24 @@
<DependentUpon>SetupAdapter.cs</DependentUpon>
</Compile>
<Compile Include="utils.cs" />
<Content Include="DATA\CONF\Adapter_ItemList.DEMO.xml">
<SubType>Designer</SubType>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="DATA\CONF\DataModel.OK.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="DATA\CONF\DataModel.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="DATA\CONF\TestData.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="Resources\CMS\Scma.ico" />
<Content Include="Resources\Scma.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="Resources\SteamWare.ico" />
<EmbeddedResource Include="MainForm.resx">
<DependentUpon>MainForm.cs</DependentUpon>
</EmbeddedResource>
@@ -174,6 +199,12 @@
<EmbeddedResource Include="SetupAdapter.resx">
<DependentUpon>SetupAdapter.cs</DependentUpon>
</EmbeddedResource>
<None Include="DATA\CONF\NameRepRolesList.map">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="DATA\CONF\MemCopyList.map">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="DATA\CONF\AnalogData.map">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
@@ -196,6 +227,9 @@
<Content Include="ExtLib\Siemens.Sinumerik.Operate.Services.dll" />
<Content Include="ExtLib\Siemens.Sinumerik.Operate.Services.Wrapper.dll" />
<Content Include="Readme\ToDos_Siemens.txt" />
<Content Include="Resources\ChangeLog.html" />
<Content Include="Resources\logoSteamware.png" />
<Content Include="Resources\manifest.xml" />
<Content Include="Resources\SCM\SCM_ESA.xml" />
<Content Include="Readme\Analisi tempi.txt" />
<None Include="App.CMS-OSAI.config">
@@ -279,14 +313,11 @@
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<Content Include="Resources\SCM\SCM.ico" />
<Content Include="Resources\MTCA.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
<None Include="DATA\CONF\SubModeList.map">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<Content Include="NLog.config">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<None Include="App.Debug.config">
<DependentUpon>App.config</DependentUpon>
@@ -332,6 +363,10 @@
<Project>{ec83d80e-9f3b-4de9-b16a-ca216543b7ec}</Project>
<Name>MTC</Name>
</ProjectReference>
<ProjectReference Include="..\OPC-UA-REDIS\OPC-UA-REDIS.csproj">
<Project>{5afccd6a-3758-44c8-96ed-84e809fca8a1}</Project>
<Name>OPC-UA-REDIS</Name>
</ProjectReference>
<ProjectReference Include="..\SCMCncLib\SCMCncLib.csproj">
<Project>{7a12fe26-9c58-4630-973d-d4872374dbaf}</Project>
<Name>SCMCncLib</Name>
@@ -363,7 +398,7 @@
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<Folder Include="AdapterCNC\" />
<Folder Include="AdapterPLC\CMS\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
@@ -373,7 +408,7 @@
<Target Name="AfterBuild">
</Target>
-->
<UsingTask TaskName="TransformXml" AssemblyFile="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\Web\Microsoft.Web.Publishing.Tasks.dll" />
<!-- <UsingTask TaskName="TransformXml" AssemblyFile="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\Web\Microsoft.Web.Publishing.Tasks.dll" /> -->
<Target Name="AfterCompile" Condition="Exists('App.$(Configuration).config')">
<!--Generate transformed app config in the intermediate directory-->
<TransformXml Source="App.config" Destination="$(IntermediateOutputPath)$(TargetFileName).config" Transform="App.$(Configuration).config" />
@@ -396,12 +431,23 @@
<!--Publish copies the untransformed App.config to deployment directory so overwrite it-->
<Copy Condition="Exists('$(DeployedConfig)')" SourceFiles="$(IntermediateOutputPath)$(TargetFileName).config" DestinationFiles="$(DeployedConfig)" />
</Target>
<Target Name="AfterBuild">
<Target Name="MyTask" AfterTargets="Build">
<ItemGroup>
<MoveToLibFolder Include="$(OutputPath)*.dll ; $(OutputPath)*.pdb ; $(OutputPath)*.xml" />
<MoveToLibFolder Include="$(OutputPath)\*.dll ; $(OutputPath)\*.pdb ; $(OutputPath)\*.xml" />
</ItemGroup>
<Move SourceFiles="@(MoveToLibFolder)" DestinationFolder="$(OutputPath)lib" OverwriteReadOnlyFiles="true" />
<Move SourceFiles="@(MoveToLibFolder)" DestinationFolder="$(OutputPath)\lib" OverwriteReadOnlyFiles="true" />
<Message Text="Files dll, pdb ed xml spostati in libs folder!" Importance="High" />
</Target>
<PropertyGroup>
<PostBuildEvent>"$(ProjectDir)postBuildTgt.bat" "$(ConfigurationName)" "$(TargetDir)"</PostBuildEvent>
</PropertyGroup>
<PropertyGroup Label="SlowCheetah">
<SlowCheetahToolsPath>$([System.IO.Path]::GetFullPath( $(MSBuildProjectDirectory)\..\packages\SlowCheetah.2.5.15\tools\))</SlowCheetahToolsPath>
<SlowCheetah_EnableImportFromNuGet Condition=" '$(SlowCheetah_EnableImportFromNuGet)'=='' ">true</SlowCheetah_EnableImportFromNuGet>
<SlowCheetah_NuGetImportPath Condition=" '$(SlowCheetah_NuGetImportPath)'=='' ">$([System.IO.Path]::GetFullPath( $(MSBuildProjectDirectory)\Properties\SlowCheetah\SlowCheetah.Transforms.targets ))</SlowCheetah_NuGetImportPath>
<SlowCheetahTargets Condition=" '$(SlowCheetah_EnableImportFromNuGet)'=='true' and Exists('$(SlowCheetah_NuGetImportPath)') ">$(SlowCheetah_NuGetImportPath)</SlowCheetahTargets>
</PropertyGroup>
<Import Project="$(SlowCheetahTargets)" Condition="Exists('$(SlowCheetahTargets)')" Label="SlowCheetah" />
<Import Project="..\packages\SlowCheetah.2.5.48\build\SlowCheetah.targets" Condition="Exists('..\packages\SlowCheetah.2.5.48\build\SlowCheetah.targets')" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
@@ -409,7 +455,4 @@
</PropertyGroup>
<Error Condition="!Exists('..\packages\SlowCheetah.2.5.48\build\SlowCheetah.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\SlowCheetah.2.5.48\build\SlowCheetah.targets'))" />
</Target>
<PropertyGroup>
<PostBuildEvent>"$(ProjectDir)postBuildTgt.bat" "$(ConfigurationName)" "$(TargetDir)"</PostBuildEvent>
</PropertyGroup>
</Project>
+1 -1
View File
@@ -19,7 +19,7 @@ namespace SCMA
{
get
{
return string.Format(@"{0}\MTCA.ico", utils.resxDir);
return string.Format(@"{0}\Scma.ico", utils.resxDir);
}
}
/// <summary>
+3 -3
View File
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="NLog" version="4.5.8" targetFramework="net452" />
<package id="NLog.Config" version="4.5.8" targetFramework="net452" />
<package id="NLog.Schema" version="4.5.8" targetFramework="net452" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net452" />
<package id="NLog" version="4.6.6" targetFramework="net452" />
<package id="NLog.Schema" version="4.6.6" targetFramework="net452" />
<package id="PrettyBin" version="1.1.0" targetFramework="net452" />
<package id="SlowCheetah" version="2.5.48" targetFramework="net452" />
<package id="StackExchange.Redis" version="1.2.6" targetFramework="net452" />
+1 -1
View File
@@ -31,7 +31,7 @@ del %2"DATA\CONF\IOT_StringList.map"
del %2"DATA\CONF\EsaKvara.ini"
del /S %2"SCMCncLib.dll"
del /S %2"SCMCncLib.xml"
ora verifico tipo controllo esatto...
REM ora verifico tipo controllo esatto...
if %1 == "CMS-FANUC" goto FANUC
if %1 == "CMS-SIEMENS" goto SIEMENS
if %1 == "CMS-OSAI" goto OSAI
+4 -4
View File
@@ -22,7 +22,7 @@ goto END
:CMS
echo CMS: copio files CMS - Zogno
del %2"Resources\MTCA.ico"
del %2"Resources\Scma.ico"
del %2"DATA\CONF\Adapter_ItemList.xml"
del %2"DATA\CONF\AlarmList.map"
del %2"DATA\CONF\AlarmListCNC.map"
@@ -30,7 +30,7 @@ del %2"DATA\CONF\AnalogData.map"
del %2"DATA\CONF\CounterList.map"
del %2"DATA\CONF\StatusList.map"
REM del /F /Q %2"DATA\CONF\*.*"
copy %2"Resources\CMS\CMS.ico" %2"Resources\MTCA.ico"
copy %2"Resources\CMS\CMS.ico" %2"Resources\Scma.ico"
copy %2"Resources\CMS\AlarmListEmpty.map" %2"DATA\CONF\AlarmListCNC.map"
REM ora verifico tipo controllo esatto...
if %1 == "CMS-FANUC" goto FANUC
@@ -39,7 +39,7 @@ if %1 == "CMS-OSAI" goto OSAI
:SCM
echo SCM: copio files SCM - Rimini
del %2"Resources\MTCA.ico"
del %2"Resources\Scma.ico"
del %2"DATA\CONF\Adapter_ItemList.xml"
del %2"DATA\CONF\AlarmList.map"
REM del %2"DATA\CONF\EsaKvara.ini"
@@ -48,7 +48,7 @@ del %2"DATA\CONF\IOT_WordList.map"
del %2"DATA\CONF\IOT_DWordList.map"
del %2"DATA\CONF\IOT_StringList.map"
REM del /F /Q %2"DATA\CONF\*.*"
copy %2"Resources\SCM\SCM.ico" %2"Resources\MTCA.ico"
copy %2"Resources\SCM\SCM.ico" %2"Resources\Scma.ico"
copy %2"Resources\SCM\SCM_ESA.xml" %2"DATA\CONF\Adapter_ItemList.xml"
copy %2"Resources\SCM\AlarmListEsaGv.map" %2"DATA\CONF\AlarmList.map"
copy %2"Resources\SCM\AlarmListEsaGvCNC.map" %2"DATA\CONF\AlarmListCNC.map"
+121 -1
View File
@@ -1,4 +1,6 @@
using System.Windows.Forms;
using System.IO;
using System.Windows.Forms;
using System.Xml;
namespace SCMA
{
@@ -44,5 +46,123 @@ namespace SCMA
return string.Format(@"{0}\{1}", Application.StartupPath, CRS("dataPath"));
}
}
/// <summary>
/// File x regole di replacement USER DEFINED
/// </summary>
public static string nameRepRoleFile
{
get
{
return string.Format(@"{0}\{1}", utils.confDir, utils.CRS("NameRepRolesList"));
}
}
/// <summary>
/// File x regole di replacement generato ad hoc x SOUR / OPC-UA
/// </summary>
public static string nameRepRoleFileSOUR
{
get
{
return nameRepRoleFile.Replace(".map", ".SOUR.map");
}
}
/// <summary>
/// File StatusList
/// </summary>
public static string StatusListFile
{
get
{
return string.Format(@"{0}\{1}", utils.confDir, utils.CRS("StatusListFilePath"));
}
}
/// <summary>
/// File StatusList generato ad hoc x SOUR / OPC-UA
///
/// </summary>
public static string StatusListFileSOUR
{
get
{
return StatusListFile.Replace(".map", ".SOUR.map");
}
}
/// <summary>
/// File CounterList
/// </summary>
public static string CounterListFile
{
get
{
return string.Format(@"{0}\{1}", utils.confDir, utils.CRS("CounterListFilePath"));
}
}
/// <summary>
/// File CounterList generato ad hoc x SOUR / OPC-UA
///
/// </summary>
public static string CounterListFileSOUR
{
get
{
return CounterListFile.Replace(".map", ".SOUR.map");
}
}
/// <summary>
/// File AnalogList
/// </summary>
public static string AnalogListFile
{
get
{
return string.Format(@"{0}\{1}", utils.confDir, utils.CRS("AnalogDataFilePath"));
}
}
/// <summary>
/// File AnalogList generato ad hoc x SOUR / OPC-UA
///
/// </summary>
public static string AnalogListFileSOUR
{
get
{
return AnalogListFile.Replace(".map", ".SOUR.map");
}
}
/// <summary>
/// Metodo di sanitizzazione XML
/// - elimina commenti
/// - formatta
/// </summary>
/// <param name="xmlOrig"></param>
/// <returns></returns>
public static string xmlSanitize(string xmlOrig)
{
string sXml = xmlOrig;
bool xmlSanitize = utils.CRB("xmlSanitize");
// se richeisto faccio sanitize xml (pulizia commenti...)
if (xmlSanitize)
{
// primo step: converto stringa in dox XML
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.PreserveWhitespace = false;
xmlDoc.LoadXml(sXml);
// ora lo parso come lista eliminando i commenti
XmlNodeList list = xmlDoc.SelectNodes("//comment()");
foreach (XmlNode node in list)
{
node.ParentNode.RemoveChild(node);
}
// fix formattazione "riscrivendo" indentazione...
StringWriter string_writer = new StringWriter();
XmlTextWriter xml_text_writer = new XmlTextWriter(string_writer);
xml_text_writer.Formatting = Formatting.Indented;
xmlDoc.WriteTo(xml_text_writer);
sXml = string_writer.ToString();
}
// restituisco
return sXml;
}
}
}
+470 -107
View File
@@ -37,12 +37,12 @@
</xs:attribute>
<xs:attribute name="globalThreshold" type="NLogLevel">
<xs:annotation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged..</xs:documentation>
<xs:documentation>Global log level threshold for application log messages. Messages below this level won't be logged.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwExceptions" type="xs:boolean">
<xs:annotation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false.</xs:documentation>
<xs:documentation>Throw an exception when there is an internal error. Default value is: false. Not recommend to set to true in production!</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="throwConfigExceptions" type="xs:boolean">
@@ -72,7 +72,7 @@
</xs:attribute>
<xs:attribute name="parseMessageTemplates" type="xs:boolean">
<xs:annotation>
<xs:documentation>Perform mesage template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
<xs:documentation>Perform message template parsing and formatting of LogEvent messages (true = Always, false = Never, empty = Auto Detect). Default value is: empty.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -123,7 +123,7 @@
</xs:choice>
<xs:attribute name="name" use="optional">
<xs:annotation>
<xs:documentation>Name of the logger. May include '*' character which acts like a wildcard. Allowed forms are: *, Name, *Name, Name* and *Name*</xs:documentation>
<xs:documentation>Name of the logger. May include wildcard characters ('*' or '?').</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="levels" type="NLogLevelList">
@@ -156,9 +156,9 @@
<xs:documentation>Ignore further rules if this one matches.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enabled" type="xs:boolean" default="true">
<xs:attribute name="ruleName" type="xs:string" use="optional">
<xs:annotation>
<xs:documentation>Enable or disable logging rule. Disabled rules are ignored.</xs:documentation>
<xs:documentation>Rule identifier to allow rule lookup with Configuration.FindRuleByName and Configuration.RemoveRuleByName.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -171,6 +171,11 @@
<xs:element name="whenNotEqual" type="whenNotEqual" />
<xs:element name="whenRepeated" type="whenRepeated" />
</xs:choice>
<xs:attribute name="defaultAction" type="FilterResult">
<xs:annotation>
<xs:documentation>Default action if none of the filters match.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:simpleType name="NLogLevel">
<xs:restriction base="xs:string">
@@ -210,12 +215,19 @@
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLogVariable">
<xs:choice minOccurs="0" maxOccurs="1">
<xs:element name="value" minOccurs="0" maxOccurs="1" type="xs:string">
<xs:annotation>
<xs:documentation>Variable value. Note, the 'value' attribute has precedence over this one.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:choice>
<xs:attribute name="name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Variable name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute" use="required">
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Variable value.</xs:documentation>
</xs:annotation>
@@ -276,6 +288,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="batchSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="forceLockingQueue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="fullBatchSizeWriteLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="overflowAction" minOccurs="0" maxOccurs="1" type="NLog.Targets.Wrappers.AsyncTargetWrapperOverflowAction" />
<xs:element name="queueLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
@@ -292,6 +305,11 @@
<xs:documentation>Number of log events that should be processed in a batch by the lazy writer thread.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="forceLockingQueue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether to use the locking queue, instead of a lock-free concurrent queue The locking queue is less concurrent when many logger threads, but reduces memory allocation</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="fullBatchSizeWriteLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>Limit of full s to write before yielding into Performance is better when writing many small batches, than writing a single large batch</xs:documentation>
@@ -309,7 +327,7 @@
</xs:attribute>
<xs:attribute name="timeToSleepBetweenBatches" type="xs:integer">
<xs:annotation>
<xs:documentation>Time in milliseconds to sleep between batches.</xs:documentation>
<xs:documentation>Time in milliseconds to sleep between batches. (1 or less means trigger on new activity)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -334,6 +352,7 @@
<xs:element name="asyncFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="flushOnConditionOnly" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="asyncFlush" type="xs:boolean">
@@ -351,6 +370,11 @@
<xs:documentation>Name of the target.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="flushOnConditionOnly" type="xs:boolean">
<xs:annotation>
<xs:documentation>Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -419,18 +443,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -438,7 +464,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -471,24 +497,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -496,9 +507,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -506,14 +527,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -521,11 +562,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -561,9 +597,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -588,14 +624,26 @@
<xs:enumeration value="Discard" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="System.Security.Authentication.SslProtocols">
<xs:restriction base="xs:string">
<xs:enumeration value="None" />
<xs:enumeration value="Ssl2" />
<xs:enumeration value="Ssl3" />
<xs:enumeration value="Tls" />
<xs:enumeration value="Tls11" />
<xs:enumeration value="Tls12" />
<xs:enumeration value="Default" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Targets.NLogViewerParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
@@ -603,6 +651,11 @@
<xs:documentation>Viewer parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="ColoredConsole">
<xs:complexContent>
@@ -613,11 +666,13 @@
<xs:element name="header" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="footer" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="enableAnsiOutput" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="errorStream" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="useDefaultRowHighlightingRules" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="highlight-row" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleRowHighlightingRule" />
<xs:element name="highlight-word" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.ConsoleWordHighlightingRule" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -645,6 +700,11 @@
<xs:documentation>Indicates whether to auto-check if the console is available. - Disables console writing if Environment.UserInteractive = False (Windows Service) - Disables console writing if Console Standard Input is not available (Non-Console-App)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="enableAnsiOutput" type="xs:boolean">
<xs:annotation>
<xs:documentation>Enables output using ANSI Color Codes</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encoding" type="xs:string">
<xs:annotation>
<xs:documentation>The encoding for writing messages to the .</xs:documentation>
@@ -660,6 +720,11 @@
<xs:documentation>Indicates whether to use default row highlighting rules.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -768,6 +833,7 @@
<xs:element name="detectConsoleAvailable" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="encoding" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="error" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="autoFlush" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -805,6 +871,11 @@
<xs:documentation>Indicates whether to send the log messages to the standard error instead of the standard output.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="autoFlush" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to auto-flush after </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -946,22 +1017,36 @@
</xs:complexType>
<xs:complexType name="NLog.Targets.DatabaseParameterInfo">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="dbType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="precision" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="scale" minOccurs="0" maxOccurs="1" type="xs:byte" />
<xs:element name="size" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameterType" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="format" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="culture" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calcuate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter name.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that should be use to calculate the value for the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="dbType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter DbType.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="precision" type="xs:byte">
<xs:annotation>
<xs:documentation>Database parameter precision.</xs:documentation>
@@ -972,9 +1057,19 @@
<xs:documentation>Database parameter scale.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="size" type="xs:integer">
<xs:attribute name="parameterType" type="xs:string">
<xs:annotation>
<xs:documentation>Database parameter size.</xs:documentation>
<xs:documentation>Type of the parameter.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="format" type="xs:string">
<xs:annotation>
<xs:documentation>Convert format of the database parameter value .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="culture" type="xs:string">
<xs:annotation>
<xs:documentation>Culture used for parsing parameter string-value for type-conversion</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
@@ -1076,7 +1171,7 @@
</xs:attribute>
<xs:attribute name="entryType" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Optional entrytype. When not set, or when not convertable to then determined by </xs:documentation>
<xs:documentation>Optional entrytype. When not set, or when not convertible to then determined by </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="eventId" type="SimpleLayoutAttribute">
@@ -1096,7 +1191,7 @@
</xs:attribute>
<xs:attribute name="maxKilobytes" type="xs:long">
<xs:annotation>
<xs:documentation>Maximum Event log size in kilobytes. If null, the value won't be set. Default is 512 Kilobytes as specified by Eventlog API</xs:documentation>
<xs:documentation>Maximum Event log size in kilobytes.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxMessageLength" type="xs:integer">
@@ -1287,7 +1382,7 @@
</xs:attribute>
<xs:attribute name="forceMutexConcurrentWrites" type="xs:boolean">
<xs:annotation>
<xs:documentation>Value indicationg whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
<xs:documentation>Indicates whether file creation calls should be synchronized by a system global mutex.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="replaceFileContentsOnEachWrite" type="xs:boolean">
@@ -1461,6 +1556,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="condition" minOccurs="0" maxOccurs="1" type="Condition" />
<xs:element name="filter" minOccurs="0" maxOccurs="1" type="Filter" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1867,6 +1963,7 @@
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="maxLogsCount" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -1879,6 +1976,11 @@
<xs:documentation>Layout used to format log messages.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxLogsCount" type="xs:integer">
<xs:annotation>
<xs:documentation>Max number of items to have in memory</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -1937,6 +2039,8 @@
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2004,6 +2108,16 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
<xs:annotation>
<xs:documentation>Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit</xs:documentation>
@@ -2022,18 +2136,20 @@
<xs:element name="lineEnding" minOccurs="0" maxOccurs="1" type="LineEndingMode" />
<xs:element name="maxMessageSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="newLine" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="address" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="connectionCacheSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepConnection" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxConnections" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="onConnectionOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetConnectionsOverflowAction" />
<xs:element name="onOverflow" minOccurs="0" maxOccurs="1" type="NLog.Targets.NetworkTargetOverflowAction" />
<xs:element name="sslProtocols" minOccurs="0" maxOccurs="1" type="System.Security.Authentication.SslProtocols" />
<xs:element name="maxQueueSize" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="keepAliveTimeSeconds" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
<xs:element name="ndlcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeNLogData" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
@@ -2041,7 +2157,7 @@
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="appInfo" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="loggerName" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="ndcItemSeparator" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="optimizeBufferReuse" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="name" type="xs:string">
@@ -2074,24 +2190,9 @@
<xs:documentation>Indicates whether to append newline at the end of log message.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
<xs:documentation>Network address.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="connectionCacheSize" type="xs:integer">
@@ -2099,9 +2200,19 @@
<xs:documentation>Size of the connection cache (number of connections which are kept alive).</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="address" type="SimpleLayoutAttribute">
<xs:attribute name="keepConnection" type="xs:boolean">
<xs:annotation>
<xs:documentation>Network address.</xs:documentation>
<xs:documentation>Indicates whether to keep connection open whenever possible.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxConnections" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum current connections. 0 = no maximum.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onConnectionOverflow" type="NLog.Targets.NetworkTargetConnectionsOverflowAction">
<xs:annotation>
<xs:documentation>Action that should be taken if the will be more connections than .</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="onOverflow" type="NLog.Targets.NetworkTargetOverflowAction">
@@ -2109,14 +2220,34 @@
<xs:documentation>Action that should be taken if the message is larger than maxMessageSize.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="sslProtocols" type="System.Security.Authentication.SslProtocols">
<xs:annotation>
<xs:documentation>Get or set the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxQueueSize" type="xs:integer">
<xs:annotation>
<xs:documentation>Maximum queue size.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="keepAliveTimeSeconds" type="xs:integer">
<xs:annotation>
<xs:documentation>The number of seconds a connection will remain idle before the first keep-alive probe is sent</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndlcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>NDLC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>NDC item separator.</xs:documentation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNLogData" type="xs:boolean">
@@ -2124,11 +2255,6 @@
<xs:documentation>Indicates whether to include NLog-specific extensions to log4j schema.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeNdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
@@ -2164,9 +2290,9 @@
<xs:documentation>AppInfo field. By default it's the friendly name of the current AppDomain.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="loggerName" type="SimpleLayoutAttribute">
<xs:attribute name="ndcItemSeparator" type="xs:string">
<xs:annotation>
<xs:documentation>Renderer for log4j:event logger-xml-attribute (Default ${logger})</xs:documentation>
<xs:documentation>NDC item separator.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="optimizeBufferReuse" type="xs:boolean">
@@ -2709,6 +2835,13 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvColumnDelimiterMode">
<xs:restriction base="xs:string">
<xs:enumeration value="Auto" />
@@ -2720,17 +2853,11 @@
<xs:enumeration value="Custom" />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="NLog.Layouts.CsvQuotingMode">
<xs:restriction base="xs:string">
<xs:enumeration value="All" />
<xs:enumeration value="Nothing" />
<xs:enumeration value="Auto" />
</xs:restriction>
</xs:simpleType>
<xs:complexType name="NLog.Layouts.CsvColumn">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="quoting" minOccurs="0" maxOccurs="1" type="NLog.Layouts.CsvQuotingMode" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
@@ -2742,6 +2869,11 @@
<xs:documentation>Name of the column.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="quoting" type="NLog.Layouts.CsvQuotingMode">
<xs:annotation>
<xs:documentation>Override of Quoting mode</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="JsonLayout">
<xs:complexContent>
@@ -2750,11 +2882,12 @@
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.JsonAttribute" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeGdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="renderEmptyObject" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="suppressSpaces" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
@@ -2766,6 +2899,11 @@
<xs:documentation>Option to include all properties from the log event (as JSON)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeGdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2776,6 +2914,11 @@
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="renderEmptyObject" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to render the empty object value {}</xs:documentation>
@@ -2786,11 +2929,6 @@
<xs:documentation>Option to suppress the extra spaces in the output json</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the JSON serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2814,7 +2952,7 @@
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines wether or not this attribute will be Json encoded.</xs:documentation>
<xs:documentation>Determines whether or not this attribute will be Json encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="escapeUnicode" type="xs:boolean">
@@ -2859,16 +2997,24 @@
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeCallSite" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeNdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeSourceInfo" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="parameter" minOccurs="0" maxOccurs="unbounded" type="NLog.Targets.NLogViewerParameterInfo" />
</xs:choice>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log events</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeCallSite" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include call site (class and method name) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
@@ -2889,6 +3035,11 @@
<xs:documentation>Indicates whether to include contents of the stack.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeSourceInfo" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include source info (file name and line number) in the information sent over the network.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
@@ -2906,6 +3057,218 @@
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="XmlLayout">
<xs:complexContent>
<xs:extension base="Layout">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="elementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="elementValue" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="elementEncode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementName" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementValue" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the root XML element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="elementEncode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlAttribute">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="layout" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
</xs:choice>
<xs:attribute name="layout" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Layout that will be rendered as the attribute's value.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether an attribute with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="NLog.Layouts.XmlElement">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="encode" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="name" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="value" minOccurs="0" maxOccurs="1" type="Layout" />
<xs:element name="attribute" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlAttribute" />
<xs:element name="element" minOccurs="0" maxOccurs="unbounded" type="NLog.Layouts.XmlElement" />
<xs:element name="includeEmptyValue" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="indentXml" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="excludeProperties" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="includeAllProperties" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="includeMdlc" minOccurs="0" maxOccurs="1" type="xs:boolean" />
<xs:element name="maxRecursionLimit" minOccurs="0" maxOccurs="1" type="xs:integer" />
<xs:element name="propertiesCollectionItemName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementKeyAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementName" minOccurs="0" maxOccurs="1" type="xs:string" />
<xs:element name="propertiesElementValueAttribute" minOccurs="0" maxOccurs="1" type="xs:string" />
</xs:choice>
<xs:attribute name="encode" type="xs:boolean">
<xs:annotation>
<xs:documentation>Determines whether or not this attribute will be Xml encoded.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="name" type="xs:string">
<xs:annotation>
<xs:documentation>Name of the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="value" type="SimpleLayoutAttribute">
<xs:annotation>
<xs:documentation>Value inside the element</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeEmptyValue" type="xs:boolean">
<xs:annotation>
<xs:documentation>Whether a ElementValue with empty value should be included in the output</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="indentXml" type="xs:boolean">
<xs:annotation>
<xs:documentation>Auto indent and create new lines</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="excludeProperties" type="xs:string">
<xs:annotation>
<xs:documentation>List of property names to exclude when is true</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeAllProperties" type="xs:boolean">
<xs:annotation>
<xs:documentation>Option to include all properties from the log event (as XML)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="includeMdlc" type="xs:boolean">
<xs:annotation>
<xs:documentation>Indicates whether to include contents of the dictionary.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="maxRecursionLimit" type="xs:integer">
<xs:annotation>
<xs:documentation>How far should the XML serializer follow object references before backing off</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesCollectionItemName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use for rendering IList-collections items</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementKeyAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-key When null (or empty) then key-attribute is not included</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementName" type="xs:string">
<xs:annotation>
<xs:documentation>XML element name to use when rendering properties</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="propertiesElementValueAttribute" type="xs:string">
<xs:annotation>
<xs:documentation>XML attribute name to use when rendering property-value When null (or empty) then value-attribute is not included and value is formatted as XML-element-value</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
<xs:complexType name="when">
<xs:complexContent>
<xs:extension base="Filter">
+4 -1
View File
@@ -35,8 +35,11 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
<HintPath>..\packages\NLog.4.6.6\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
+3 -3
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="NLog" version="4.5.8" targetFramework="net452" />
<package id="NLog.Config" version="4.5.8" targetFramework="net452" />
<package id="NLog.Schema" version="4.5.8" targetFramework="net452" />
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net452" />
<package id="NLog" version="4.6.6" targetFramework="net452" />
<package id="NLog.Schema" version="4.6.6" targetFramework="net452" />
</packages>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.

Some files were not shown because too many files have changed in this diff Show More