Skip to content

Commit

Permalink
Merge pull request gtri#5 from gtri/master-synch
Browse files Browse the repository at this point in the history
Master synch
  • Loading branch information
shaneconnelly23 authored Aug 26, 2022
2 parents eac7803 + 3e417dc commit 4459924
Show file tree
Hide file tree
Showing 14 changed files with 640 additions and 6 deletions.
3 changes: 1 addition & 2 deletions ingrid/anaconda-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,7 @@ env_specs:
inherit_from:
- model-processing
packages:
- pip:
- gooey
- gooey <1.0.5
docs:
packages:
- sphinx
Expand Down
2 changes: 1 addition & 1 deletion ingrid/requirements-install.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
gooey
gooey <1.0.5
networkx >=2.3
openpyxl
pandas
Expand Down
2 changes: 2 additions & 0 deletions ingrid/src/model_processing/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,8 @@ def compare_md_model(inputs, input_patterns="", output_path=""):
pattern_path.name.split(".")[0].lower(): pattern_path
for pattern_path in PATTERNS.glob("*.json")
}
if not isinstance(input_patterns, list) and input_patterns:
input_patterns = [input_patterns]
if input_patterns:
for in_pat in map(Path, input_patterns):
if in_pat.is_dir():
Expand Down
4 changes: 3 additions & 1 deletion ingrid/src/model_processing/graph_creation.py
Original file line number Diff line number Diff line change
Expand Up @@ -770,7 +770,9 @@ def sheets_to_dataframe(self, excel_file=None):
]
if not excel_file and self.excel_file:
excel_file = self.excel_file
excel_sheets = pd.read_excel(excel_file, sheet_name=None, engine="openpyxl")
excel_sheets = pd.read_excel(
excel_file, sheet_name=None, engine="openpyxl"
)
# what if the pattern is zzzzzzz, ids, renames
for sheet in sorted(excel_sheets): # Alphabetical sort
# Find the Pattern Sheet
Expand Down
30 changes: 30 additions & 0 deletions ingrid/src/model_processing/patterns/Actions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"Columns to Navigation Map": {
"Activity": [
"activity"
],
"Action": [
"action"
]
},
"Pattern Graph Edges": [
[
"action",
"activity",
"owner"
]
],
"Root Node": "action",
"Vertex MetaTypes": {
"activity": "Activity",
"action": "Action"
},
"Vertex Settings": {
"activity": null,
"action": null
},
"Vertex Stereotypes": {
"activity": null,
"action": null
}
}
73 changes: 73 additions & 0 deletions ingrid/src/model_processing/patterns/ActorContext.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
{
"Columns to Navigation Map": {
"Context": [
"component",
"owner",
"Composite Thing"
],
"Actors": [
"component",
"type",
"Atomic Thing"
],
"Property": [
"component"
]
},
"Pattern Graph Edges": [
[
"composite owner",
"Composite Thing",
"type"
],
[
"component",
"Atomic Thing",
"type"
],
[
"A_composite owner_component",
"composite owner",
"memberEnd"
],
[
"A_composite owner_component",
"component",
"memberEnd"
],
[
"component",
"Composite Thing",
"owner"
],
[
"composite owner",
"A_composite owner_component",
"owner"
]
],
"Root Node": "component",
"Vertex MetaTypes": {
"A_composite owner_component": "Association",
"Atomic Thing": "Actor",
"Composite Thing": "Class",
"component": "Property",
"composite owner": "Property"
},
"Vertex Settings": {
"A_composite owner_component": null,
"Atomic Thing": null,
"Composite Thing": null,
"component": {
"aggregation": "shared"
},
"composite owner": null
},
"Vertex Stereotypes": {
"A_composite owner_component": null,
"Atomic Thing": null,
"Composite Thing": "Block",
"component": null,
"composite owner": null
}
}
38 changes: 38 additions & 0 deletions ingrid/src/model_processing/patterns/ActorRefiner.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"Columns to Navigation Map": {
"Block": [
"block"
],
"Actor": [
"actor"
]
},
"Pattern Graph Edges": [
[
"refiner",
"actor",
"supplier"
],
[
"refiner",
"block",
"client"
]
],
"Root Node": "refiner",
"Vertex MetaTypes": {
"block": "Class",
"refiner": "Abstraction",
"actor": "Actor"
},
"Vertex Settings": {
"block": null,
"refiner": null,
"actor": null
},
"Vertex Stereotypes": {
"block": "Block",
"refiner": "Refine",
"actor": null
}
}
41 changes: 41 additions & 0 deletions ingrid/src/model_processing/patterns/CBAInputs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"Columns to Navigation Map": {
"Action": [
"act"
],
"Input": [
"inp"
],
"Activity": [
"activity"
]
},
"Pattern Graph Edges": [
[
"act",
"activity",
"owner"
],
[
"inp",
"act",
"owner"
]
],
"Root Node": "act",
"Vertex MetaTypes": {
"activity": "Activity",
"act": "Action",
"inp": "InputPin"
},
"Vertex Settings": {
"activity": null,
"act": null,
"inp": null
},
"Vertex Stereotypes": {
"activity": null,
"act": null,
"inp": null
}
}
41 changes: 41 additions & 0 deletions ingrid/src/model_processing/patterns/CBAOutputs.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"Columns to Navigation Map": {
"Action": [
"act"
],
"Output": [
"out"
],
"Activity": [
"activity"
]
},
"Pattern Graph Edges": [
[
"act",
"activity",
"owner"
],
[
"out",
"act",
"owner"
]
],
"Root Node": "act",
"Vertex MetaTypes": {
"activity": "Activity",
"act": "Action",
"out": "OutputPin"
},
"Vertex Settings": {
"activity": null,
"act": null,
"out": null
},
"Vertex Stereotypes": {
"activity": null,
"act": null,
"out": null
}
}
63 changes: 63 additions & 0 deletions ingrid/src/model_processing/patterns/RelSys.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
"Columns to Navigation Map": {
"UseCase": [
"usecase"
],
"System": [
"relsys"
],
"UCPos": [
"ucend"
],
"SysPos": [
"relsysend"
],
"Assoc": [
"relation"
]
},
"Pattern Graph Edges": [
[
"relsysend",
"relsys",
"type"
],
[
"ucend",
"usecase",
"type"
],
[
"relsysend",
"relation",
"owner"
],
[
"ucend",
"relation",
"owner"
]
],
"Root Node": "usecase",
"Vertex MetaTypes": {
"usecase": "UseCase",
"relsys": "Class",
"relation": "Association",
"relsysend": "Property",
"ucend": "Property"
},
"Vertex Settings": {
"usecase": null,
"relsys": null,
"relation": null,
"relsysend": null,
"ucend": null
},
"Vertex Stereotypes": {
"usecase": "requirementUseCase",
"relsys": "Block",
"relation": null,
"relsysend": null,
"ucend": null
}
}
Loading

0 comments on commit 4459924

Please sign in to comment.