Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
monticore
EmbeddedMontiArc
languages
CNNArchLang
Commits
cf976dfa
Commit
cf976dfa
authored
Jan 31, 2019
by
Hoda Anvari Kazemabad
Browse files
New DataPathConfigParse
parent
30e5b9dd
Pipeline
#101556
failed with stages
in 10 minutes and 54 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/de/monticore/lang/monticar/cnnarch/DataPathConfigParsernew.java
0 → 100644
View file @
cf976dfa
package
de.monticore.lang.monticar.cnnarch.mxnetgenerator
;
import
de.monticore.lang.monticar.cnntrain._symboltable.*
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
public
class
DataPathConfigParser
{
private
String
configTargetPath
;
ConfigurationSymbol
configuration
;
private
String
configFileName
;
public
DataPathConfigParser
(
ConfigurationSymbol
configuration
)
{
this
.
configuration
=
configuration
;
setConfigPath
(
"./target/"
);
setConfigFileName
(
"ConfigChainAutomation"
);
}
public
String
getConfigFileName
()
{
return
configFileName
;
}
public
void
setConfigFileName
(
String
configFileName
){
this
.
configFileName
=
configFileName
+
".cnnt"
;
}
public
String
getConfigPath
()
{
if
(
configTargetPath
.
charAt
(
configTargetPath
.
length
()
-
1
)
!=
'/'
)
{
this
.
configTargetPath
=
configTargetPath
+
"/"
;
}
return
configTargetPath
;
}
public
void
setConfigPath
(
String
configTargetPath
){
this
.
configTargetPath
=
configTargetPath
+
getConfigFileName
;
}
public
ConfigurationSymbol
getConfiguration
()
{
return
configuration
;
}
public
String
getDataPath
(
String
componentName
)
{
if
(!
getConfiguration
().
getEntryMap
().
containsKey
(
componentName
))
{
return
null
;
}
return
String
.
valueOf
(
getConfiguration
().
getEntry
(
componentName
).
getValue
());
}
}
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment