Commit d1ae8739 authored by Jerome Legrand's avatar Jerome Legrand
parents 5218ebb4 eb2c2da6
No preview for this file type
version 2.0.22
* ticket 0000658 : Error in skeleton generation when selecting a connection
* ticket 0000659 : Repair inconsistency wrongly called
* ticket 0000660 : Exporting function to an unexisting directory raise a tcl error
* ticket 0000656 : All imports of function are refused for dataview compatibility reasons (corection added)
* ticket 0000588 : Error in external tools menu status (correction added)
* ticket 0000664 : Add possibility to export function under a specific name
* ticket 0000665 : Call save all instead of save when launching external tools
* ticket 0000666 : ConcurrencyView generation does not work
version 2.0.21 version 2.0.21
* ticket 0000656 : All imports of function are refused for dataview compatibility reasons * ticket 0000656 : All imports of function are refused for dataview compatibility reasons
* ticket 0000657 : Instantiating incompatible function raise a Tcl error * ticket 0000657 : Instantiating incompatible function raise a Tcl error
......
...@@ -15,6 +15,7 @@ namespace eval TasteConfig { ...@@ -15,6 +15,7 @@ namespace eval TasteConfig {
"asn2aadlPath" "asn2aadlPlus" \ "asn2aadlPath" "asn2aadlPlus" \
"mscEditor" "taste-edit-msc" \ "mscEditor" "taste-edit-msc" \
"mscCreator" "taste-create-msc" \ "mscCreator" "taste-create-msc" \
"check-deployment-target" "false" \
} }
variable accelerators { \ variable accelerators { \
......
...@@ -21,6 +21,7 @@ The getApplyTo function shall return a list defining the kind of TASTE element t ...@@ -21,6 +21,7 @@ The getApplyTo function shall return a list defining the kind of TASTE element t
tool can be used on tool can be used on
The list is of the form { { "objecttype" { "atribute1" "value1" }* }* } The list is of the form { { "objecttype" { "atribute1" "value1" }* }* }
If the list is [list "alwayson" ] then the external tool will be active all the time. If the list is [list "alwayson" ] then the external tool will be active all the time.
If the list is [list "allContext" ] then the external tool will be active all the time in all context.
The getOutputManagement function shall return a list defining the way output result of The getOutputManagement function shall return a list defining the way output result of
external tool is to be managed: external tool is to be managed:
......
...@@ -17,7 +17,7 @@ namespace eval build_c { ...@@ -17,7 +17,7 @@ namespace eval build_c {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -16,7 +16,7 @@ namespace eval cleanup { ...@@ -16,7 +16,7 @@ namespace eval cleanup {
# Names of the object this script can be used on # Names of the object this script can be used on
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -105,99 +105,48 @@ namespace eval concurrencyview { ...@@ -105,99 +105,48 @@ namespace eval concurrencyview {
# synchronous call # synchronous call
proc concurrencyview_internal { } { proc concurrencyview_internal { } {
## Ticket mantis 0000665
set generationDir "[LogManager::getLogDirectory]/buildCV" set ivFilename [ lindex [::Object::getAttribute "interfaceview" "filenames" ] 0]
set ivFilename "$generationDir/interfaceview.aadl" set dvFilename [ lindex [::Object::getAttribute "deploymentview" "filenames" ] 0]
set dvFilename "$generationDir/deployment.aadl"
set dtFilename [lindex [Object::getAttribute "dataview" "filenames" ] 0 ] set dtFilename [lindex [Object::getAttribute "dataview" "filenames" ] 0 ]
#~ set hwFilenames [Object::getAttribute "hwlibrary" "filenames" ] set cvFilename "[LogManager::getLogDirectory]/concurrencyview.aadl"
file delete -force "$generationDir"
file mkdir $generationDir
::API::Taste::exportIV [list "backend" "1_3" "dirname" $generationDir "selection" "all" ]
::API::Taste::exportDV [list "backend" "1_3" "dirname" $generationDir] set res [catch { exec taste-config --prefix } tasteConfigDir ]
if { $res != 0 } {
#~ an error happend
if { [file exists $ivFilename ] && [file exists $dvFilename ] && [file exists $dtFilename ] } { return [list 1 [list "taste-config error: $tasteConfigDir"] ]
}
#~ taste-edit-concurrency-view "$dtFilename" "$ivFilename" "$dvFilename"
set concatFilename "[LogManager::getLogDirectory]/concatenatedFile.aadl"
set cvFilename "[LogManager::getLogDirectory]/concurrencyview.aadl"
set fout [ open $concatFilename w ]
fconfigure $fout -translation lf
set fin [ open $ivFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
puts $fout "\n\n"
set fin [ open $dvFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
puts $fout "\n\n"
if { [file exists $dtFilename ] } {
set fin [ open $dtFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
#~ puts $fout "\n\n"
}
#~ foreach hwFilename $hwFilenames {
#~ if { [file exists $hwFilename ] } {
#~ set fin [ open $hwFilename r ]
#~ set content [read -nonewline $fin]
#~ close $fin
#~ puts $fout $content
#~ puts $fout "\n\n"
#~ }
#~ }
close $fout
set res [catch { exec taste-config --prefix } tasteConfigDir ]
if { $res != 0 } {
#~ an error happend
return [list 1 [list "taste-config error: $tasteConfigDir"] ]
} else {
set AADL_IV_PROPERTIES "$tasteConfigDir/share/config_ellidiss/TASTE_IV_Properties.aadl"
set AADL_DV_PROPERTIES "$tasteConfigDir/share/config_ellidiss/TASTE_DV_Properties.aadl"
set OCARINA_COMPONENTS "$tasteConfigDir/share/ocarina/AADLv2/ocarina_components.aadl"
set tempdir "$generationDir/tmpConcu" set res [ catch { exec taste-edit-concurrency-view ${ivFilename} ${dvFilename} ${dtFilename} 2>@1 } errMsg ]
file delete -force $tempdir
file mkdir $tempdir if { $res == 0 } {
if { [file exists "ConcurrencyView/process.aadl" ] } {
set res [ catch { exec buildsupport -i ${ivFilename} -c ${dvFilename} -d ${dtFilename} ${AADL_IV_PROPERTIES} ${AADL_DV_PROPERTIES} ${OCARINA_COMPONENTS} -glue -gw -o ${tempdir} 2>@1 } errMsg ] file delete -force "$cvFilename"
file copy -force "ConcurrencyView/process.aadl" "$cvFilename"
if { [file exists "$tempdir/ConcurrencyView/process.aadl" ] } { set chan [open "$cvFilename" a+ ]
file delete -force "$cvFilename" fconfigure $chan -translation lf
file copy -force "$tempdir/ConcurrencyView/process.aadl" "$cvFilename" foreach threadFile [glob -nocomplain -type f -directory "ConcurrencyView" *_Thread.aadl ] {
set chan [open "$cvFilename" a+ ] set fin [ open $threadFile r ]
fconfigure $chan -translation lf
foreach threadFile [glob -nocomplain -type f -directory "$tempdir/ConcurrencyView" *_Thread.aadl ] {
set fin [ open $threadFile r ]
set content [read -nonewline $fin]
close $fin
puts $chan $content
puts $chan "\n\n"
}
set fin [ open $OCARINA_COMPONENTS r ]
set content [read -nonewline $fin] set content [read -nonewline $fin]
close $fin close $fin
puts $chan $content puts $chan $content
close $chan puts $chan "\n\n"
} else {
return [list 1 [list "buildsupport error:\n$errMsg" ] ]
} }
set OCARINA_COMPONENTS "$tasteConfigDir/share/ocarina/AADLv2/ocarina_components.aadl"
set fin [ open $OCARINA_COMPONENTS r ]
set content [read -nonewline $fin]
close $fin
puts $chan $content
close $chan
::API::HMI::loadUI "$cvFilename" "concurrencyview" ::API::HMI::loadUI "$cvFilename" "concurrencyview"
return [list 0 ""]
} }
return [list 0 ""]
} else { } else {
return [ list -1 [list "Dataview, Interfaceview and Deploymentview shall be loaded." ] ] return [list 1 [list "taste-edit-concurrency-view error:\n$errMsg" ] ]
} }
} }
} }
...@@ -17,7 +17,7 @@ namespace eval generate_database { ...@@ -17,7 +17,7 @@ namespace eval generate_database {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -17,7 +17,7 @@ namespace eval generate_skeletons { ...@@ -17,7 +17,7 @@ namespace eval generate_skeletons {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
package provide micropython_kate 0.1
# C code editor (using Kate)
lappend auto_path .
namespace eval micropython_kate {
# Graphical name of the operation
proc getLabel {} {
return "Edit Micropython source code"
}
# Name of the application this script can be used with
# shall be either InterfaceView or DeploymentView
proc getApplication {} {
return "InterfaceView"
}
# Names of the object this script can be used on
proc getApplyTo {} {
return [list { "Function" {"Source_Language" "Micropython"} } ]
}
# List of way to manage output in the Framework
# Could be an empty list or one or both of 'dialogBox' and 'statusBar'
proc getOutputManagement {} {
## Ticket mantis 0000625
return [list statusBar dialogBoxOnError]
}
proc micropython_kate { args } {
set params [lindex $args 0]
set aadlFilePath [Parameter::getParameter $params aadlFilePath]
set aadlId [Parameter::getParameter $params id]
return [c_internal $aadlFilePath $aadlId]
}
# the line "exec {*}[auto_execok $::installationPath/config/externalTools/test.bat]"
# ask the current OS which software is to be used to open the file test.bat
# to launch using the absolute path, read the template2.tcl_
# synchronous call
proc c_internal { aadlFilePath aadlId } {
## Ticket mantis 0000625
set initialPath [pwd]
cd [file dirname $aadlFilePath]
set msg ""
set scriptPath [auto_execok "taste-generate-skeletons"]
if { $scriptPath != "" } {
set errNumb [catch { exec -ignorestderr {*}$scriptPath 2>@1 } errMsg ]
} else {
set errNumb -1
set errMsg "Unknown command taste-generate-skeletons."
}
## Ticket mantis 0000632
set aadlId [string tolower $aadlId 0 end]
set fileBaseName [file normalize "[pwd]/$aadlId" ]
if { $errNumb == 0 && [file exists $fileBaseName ] } {
if { [auto_execok kate] == "" } {
set errNumb -1
set msg [list "Error in execution of \"kate ${fileBaseName}/${aadlId}.py: unknown file kate" ]
} else {
ToolsOthers::execAsynchronouslyWithResponse [list "[auto_execok kate] ${fileBaseName}/${aadlId}.py" ] \
"::micropython_kateres" "Kate error report" "The execution of kate stopped with error"
}
} elseif { $errNumb != 0 } {
set errNumb -1
set msg [list "Error in execution of \"taste-generate-skeletons $aadlFilePath\":\n$errMsg" ]
} else {
set errNumb -1
set msg [list "Cannot find files:\n-${fileBaseName}/${aadlId}.py" ]
}
cd $initialPath
return [list $errNumb $msg]
}
# asynchronous call
#proc template_internal { aadlFilePath aadlId } {
# exec {*}[auto_execok $::installationPath/config/externalTools/test.bat] $aadlFilePath $aadlId &
# return ""
#}
}
No preview for this file type
version 2.0.22
* ticket 0000658 : Error in skeleton generation when selecting a connection
* ticket 0000659 : Repair inconsistency wrongly called
* ticket 0000660 : Exporting function to an unexisting directory raise a tcl error
* ticket 0000656 : All imports of function are refused for dataview compatibility reasons (corection added)
* ticket 0000588 : Error in external tools menu status (correction added)
* ticket 0000664 : Add possibility to export function under a specific name
* ticket 0000665 : Call save all instead of save when launching external tools
* ticket 0000666 : ConcurrencyView generation does not work
version 2.0.21 version 2.0.21
* ticket 0000656 : All imports of function are refused for dataview compatibility reasons * ticket 0000656 : All imports of function are refused for dataview compatibility reasons
* ticket 0000657 : Instantiating incompatible function raise a Tcl error * ticket 0000657 : Instantiating incompatible function raise a Tcl error
......
...@@ -15,6 +15,7 @@ namespace eval TasteConfig { ...@@ -15,6 +15,7 @@ namespace eval TasteConfig {
"asn2aadlPath" "asn2aadlPlus" \ "asn2aadlPath" "asn2aadlPlus" \
"mscEditor" "taste-edit-msc" \ "mscEditor" "taste-edit-msc" \
"mscCreator" "taste-create-msc" \ "mscCreator" "taste-create-msc" \
"check-deployment-target" "false" \
} }
variable accelerators { \ variable accelerators { \
......
...@@ -21,6 +21,7 @@ The getApplyTo function shall return a list defining the kind of TASTE element t ...@@ -21,6 +21,7 @@ The getApplyTo function shall return a list defining the kind of TASTE element t
tool can be used on tool can be used on
The list is of the form { { "objecttype" { "atribute1" "value1" }* }* } The list is of the form { { "objecttype" { "atribute1" "value1" }* }* }
If the list is [list "alwayson" ] then the external tool will be active all the time. If the list is [list "alwayson" ] then the external tool will be active all the time.
If the list is [list "allContext" ] then the external tool will be active all the time in all context.
The getOutputManagement function shall return a list defining the way output result of The getOutputManagement function shall return a list defining the way output result of
external tool is to be managed: external tool is to be managed:
......
...@@ -17,7 +17,7 @@ namespace eval build_c { ...@@ -17,7 +17,7 @@ namespace eval build_c {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -16,7 +16,7 @@ namespace eval cleanup { ...@@ -16,7 +16,7 @@ namespace eval cleanup {
# Names of the object this script can be used on # Names of the object this script can be used on
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -105,99 +105,48 @@ namespace eval concurrencyview { ...@@ -105,99 +105,48 @@ namespace eval concurrencyview {
# synchronous call # synchronous call
proc concurrencyview_internal { } { proc concurrencyview_internal { } {
## Ticket mantis 0000665
set generationDir "[LogManager::getLogDirectory]/buildCV" set ivFilename [ lindex [::Object::getAttribute "interfaceview" "filenames" ] 0]
set ivFilename "$generationDir/interfaceview.aadl" set dvFilename [ lindex [::Object::getAttribute "deploymentview" "filenames" ] 0]
set dvFilename "$generationDir/deployment.aadl"
set dtFilename [lindex [Object::getAttribute "dataview" "filenames" ] 0 ] set dtFilename [lindex [Object::getAttribute "dataview" "filenames" ] 0 ]
#~ set hwFilenames [Object::getAttribute "hwlibrary" "filenames" ] set cvFilename "[LogManager::getLogDirectory]/concurrencyview.aadl"
file delete -force "$generationDir"
file mkdir $generationDir
::API::Taste::exportIV [list "backend" "1_3" "dirname" $generationDir "selection" "all" ]
::API::Taste::exportDV [list "backend" "1_3" "dirname" $generationDir] set res [catch { exec taste-config --prefix } tasteConfigDir ]
if { $res != 0 } {
#~ an error happend
if { [file exists $ivFilename ] && [file exists $dvFilename ] && [file exists $dtFilename ] } { return [list 1 [list "taste-config error: $tasteConfigDir"] ]
}
#~ taste-edit-concurrency-view "$dtFilename" "$ivFilename" "$dvFilename"
set concatFilename "[LogManager::getLogDirectory]/concatenatedFile.aadl"
set cvFilename "[LogManager::getLogDirectory]/concurrencyview.aadl"
set fout [ open $concatFilename w ]
fconfigure $fout -translation lf
set fin [ open $ivFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
puts $fout "\n\n"
set fin [ open $dvFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
puts $fout "\n\n"
if { [file exists $dtFilename ] } {
set fin [ open $dtFilename r ]
set content [read -nonewline $fin]
close $fin
puts $fout $content
#~ puts $fout "\n\n"
}
#~ foreach hwFilename $hwFilenames {
#~ if { [file exists $hwFilename ] } {
#~ set fin [ open $hwFilename r ]
#~ set content [read -nonewline $fin]
#~ close $fin
#~ puts $fout $content
#~ puts $fout "\n\n"
#~ }
#~ }
close $fout
set res [catch { exec taste-config --prefix } tasteConfigDir ]
if { $res != 0 } {
#~ an error happend
return [list 1 [list "taste-config error: $tasteConfigDir"] ]
} else {
set AADL_IV_PROPERTIES "$tasteConfigDir/share/config_ellidiss/TASTE_IV_Properties.aadl"
set AADL_DV_PROPERTIES "$tasteConfigDir/share/config_ellidiss/TASTE_DV_Properties.aadl"
set OCARINA_COMPONENTS "$tasteConfigDir/share/ocarina/AADLv2/ocarina_components.aadl"
set tempdir "$generationDir/tmpConcu" set res [ catch { exec taste-edit-concurrency-view ${ivFilename} ${dvFilename} ${dtFilename} 2>@1 } errMsg ]
file delete -force $tempdir
file mkdir $tempdir if { $res == 0 } {
if { [file exists "ConcurrencyView/process.aadl" ] } {
set res [ catch { exec buildsupport -i ${ivFilename} -c ${dvFilename} -d ${dtFilename} ${AADL_IV_PROPERTIES} ${AADL_DV_PROPERTIES} ${OCARINA_COMPONENTS} -glue -gw -o ${tempdir} 2>@1 } errMsg ] file delete -force "$cvFilename"
file copy -force "ConcurrencyView/process.aadl" "$cvFilename"
if { [file exists "$tempdir/ConcurrencyView/process.aadl" ] } { set chan [open "$cvFilename" a+ ]
file delete -force "$cvFilename" fconfigure $chan -translation lf
file copy -force "$tempdir/ConcurrencyView/process.aadl" "$cvFilename" foreach threadFile [glob -nocomplain -type f -directory "ConcurrencyView" *_Thread.aadl ] {
set chan [open "$cvFilename" a+ ] set fin [ open $threadFile r ]
fconfigure $chan -translation lf
foreach threadFile [glob -nocomplain -type f -directory "$tempdir/ConcurrencyView" *_Thread.aadl ] {
set fin [ open $threadFile r ]
set content [read -nonewline $fin]
close $fin
puts $chan $content
puts $chan "\n\n"
}
set fin [ open $OCARINA_COMPONENTS r ]
set content [read -nonewline $fin] set content [read -nonewline $fin]
close $fin close $fin
puts $chan $content puts $chan $content
close $chan puts $chan "\n\n"
} else {
return [list 1 [list "buildsupport error:\n$errMsg" ] ]
} }
set OCARINA_COMPONENTS "$tasteConfigDir/share/ocarina/AADLv2/ocarina_components.aadl"
set fin [ open $OCARINA_COMPONENTS r ]
set content [read -nonewline $fin]
close $fin
puts $chan $content
close $chan
::API::HMI::loadUI "$cvFilename" "concurrencyview" ::API::HMI::loadUI "$cvFilename" "concurrencyview"
return [list 0 ""]
} }
return [list 0 ""]
} else { } else {
return [ list -1 [list "Dataview, Interfaceview and Deploymentview shall be loaded." ] ] return [list 1 [list "taste-edit-concurrency-view error:\n$errMsg" ] ]
} }
} }
} }
...@@ -17,7 +17,7 @@ namespace eval generate_database { ...@@ -17,7 +17,7 @@ namespace eval generate_database {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
...@@ -17,7 +17,7 @@ namespace eval generate_skeletons { ...@@ -17,7 +17,7 @@ namespace eval generate_skeletons {
# Names of the object this script can be used on # Names of the object this script can be used on
# FIXME - it should be active all the time # FIXME - it should be active all the time
proc getApplyTo {} { proc getApplyTo {} {
return [list "alwayson" ] return [list "allContext" ]
} }
# List of way to manage output in the Framework # List of way to manage output in the Framework
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment