Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2013-04-08 09:40:24 -0400
committerHenrik Rentz-Reichert2013-04-08 09:40:24 -0400
commitf4333b09a2e4b1448b8de8c8b14fb22c12fd084d (patch)
tree7b50d6b444abf9c4be69cbfb55ecb01172007686 /plugins
parentea991e6da9650840de79381d5bf11a8cfe77689f (diff)
downloadorg.eclipse.etrice-f4333b09a2e4b1448b8de8c8b14fb22c12fd084d.tar.gz
org.eclipse.etrice-f4333b09a2e4b1448b8de8c8b14fb22c12fd084d.tar.xz
org.eclipse.etrice-f4333b09a2e4b1448b8de8c8b14fb22c12fd084d.zip
reduced warnings
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.etrice.doc/build.properties1
-rw-r--r--plugins/org.eclipse.etrice.generator.config/src/org/eclipse/etrice/generator/config/DataConfiguration.xtend6
-rw-r--r--plugins/org.eclipse.etrice.generator.config/xtend-gen/org/eclipse/etrice/generator/config/DataConfiguration.java19
-rw-r--r--plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/DocGen.xtend2
-rw-r--r--plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.xtend2
-rw-r--r--plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/DocGen.java10
-rw-r--r--plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.java10
-rw-r--r--plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/JavaExtensions.xtend2
-rw-r--r--plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/JavaExtensions.java2
-rw-r--r--plugins/org.eclipse.etrice.generator/src/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.xtend4
-rw-r--r--plugins/org.eclipse.etrice.generator/xtend-gen/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.java10
11 files changed, 41 insertions, 27 deletions
diff --git a/plugins/org.eclipse.etrice.doc/build.properties b/plugins/org.eclipse.etrice.doc/build.properties
index 54cc90820..4b28a31fa 100644
--- a/plugins/org.eclipse.etrice.doc/build.properties
+++ b/plugins/org.eclipse.etrice.doc/build.properties
@@ -4,7 +4,6 @@ bin.includes = plugin.xml,\
META-INF/,\
.,\
html/,\
- help/,\
reference-toc.xml,\
toc.xml,\
top-toc.xml
diff --git a/plugins/org.eclipse.etrice.generator.config/src/org/eclipse/etrice/generator/config/DataConfiguration.xtend b/plugins/org.eclipse.etrice.generator.config/src/org/eclipse/etrice/generator/config/DataConfiguration.xtend
index d61f50fc5..c23faec13 100644
--- a/plugins/org.eclipse.etrice.generator.config/src/org/eclipse/etrice/generator/config/DataConfiguration.xtend
+++ b/plugins/org.eclipse.etrice.generator.config/src/org/eclipse/etrice/generator/config/DataConfiguration.xtend
@@ -92,7 +92,11 @@ class DataConfiguration implements IDataConfiguration {
// dynamic
override getPollingTimerUser(SubSystemInstance subsystem) {
- subsystem.config?.dynConfig?.polling
+ val dynConf = subsystem.config?.dynConfig
+ if (dynConf==null)
+ 0
+ else
+ dynConf.polling
}
override getUserCode1(SubSystemInstance subsystem) {
diff --git a/plugins/org.eclipse.etrice.generator.config/xtend-gen/org/eclipse/etrice/generator/config/DataConfiguration.java b/plugins/org.eclipse.etrice.generator.config/xtend-gen/org/eclipse/etrice/generator/config/DataConfiguration.java
index 11faac3fc..07e9fa9c0 100644
--- a/plugins/org.eclipse.etrice.generator.config/xtend-gen/org/eclipse/etrice/generator/config/DataConfiguration.java
+++ b/plugins/org.eclipse.etrice.generator.config/xtend-gen/org/eclipse/etrice/generator/config/DataConfiguration.java
@@ -173,10 +173,21 @@ public class DataConfiguration implements IDataConfiguration {
}
public int getPollingTimerUser(final SubSystemInstance subsystem) {
- SubSystemConfig _config = this.getConfig(subsystem);
- DynamicConfig _dynConfig = _config==null?(DynamicConfig)null:_config.getDynConfig();
- int _polling = _dynConfig==null?0:_dynConfig.getPolling();
- return _polling;
+ int _xblockexpression = (int) 0;
+ {
+ SubSystemConfig _config = this.getConfig(subsystem);
+ final DynamicConfig dynConf = _config==null?(DynamicConfig)null:_config.getDynConfig();
+ int _xifexpression = (int) 0;
+ boolean _equals = Objects.equal(dynConf, null);
+ if (_equals) {
+ _xifexpression = 0;
+ } else {
+ int _polling = dynConf.getPolling();
+ _xifexpression = _polling;
+ }
+ _xblockexpression = (_xifexpression);
+ }
+ return _xblockexpression;
}
public String getUserCode1(final SubSystemInstance subsystem) {
diff --git a/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/DocGen.xtend b/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/DocGen.xtend
index 61aac3f1d..5a3131bf1 100644
--- a/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/DocGen.xtend
+++ b/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/DocGen.xtend
@@ -302,7 +302,7 @@ class DocGen implements IRoomGenerator {
'''
}
- def generateStateDoc(RoomModel model, ActorClass ac, State state){
+ def String generateStateDoc(RoomModel model, ActorClass ac, State state){
var filename = model.docGenerationTargetPath + "images\\" + ac.name + "_" + state.genStatePathName + "_behavior.jpg"
filename = filename.replaceAll("\\\\","/");
var latexFilename = filename.replaceAll("/","//");
diff --git a/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.xtend b/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.xtend
index b1a9f07bb..08aed24ab 100644
--- a/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.xtend
+++ b/plugins/org.eclipse.etrice.generator.doc/src/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.xtend
@@ -76,7 +76,7 @@ class InstanceDiagramGen implements IRoomGenerator {
'''
}
- def instance(ActorInstance ai) {
+ def String instance(ActorInstance ai) {
val parent = ai.eContainer as StructureInstance
val pthread = ETMapUtil::getPhysicalThread(ai)
val tname = if (pthread==null) "?" else pthread.name
diff --git a/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/DocGen.java b/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/DocGen.java
index 251a47b4c..852ec5028 100644
--- a/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/DocGen.java
+++ b/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/DocGen.java
@@ -726,7 +726,7 @@ public class DocGen implements IRoomGenerator {
boolean _isLeaf = RoomHelpers.isLeaf(s_1);
boolean _not = (!_isLeaf);
if (_not) {
- CharSequence _generateStateDoc = this.generateStateDoc(model, ac, s_1);
+ String _generateStateDoc = this.generateStateDoc(model, ac, s_1);
_builder.append(_generateStateDoc, "");
_builder.newLineIfNotEmpty();
}
@@ -738,8 +738,8 @@ public class DocGen implements IRoomGenerator {
return _xblockexpression;
}
- public CharSequence generateStateDoc(final RoomModel model, final ActorClass ac, final State state) {
- CharSequence _xblockexpression = null;
+ public String generateStateDoc(final RoomModel model, final ActorClass ac, final State state) {
+ String _xblockexpression = null;
{
String _docGenerationTargetPath = this.roomExt.getDocGenerationTargetPath(model);
String _plus = (_docGenerationTargetPath + "images\\");
@@ -841,14 +841,14 @@ public class DocGen implements IRoomGenerator {
boolean _isLeaf = RoomHelpers.isLeaf(s_1);
boolean _not = (!_isLeaf);
if (_not) {
- Object _generateStateDoc = this.generateStateDoc(model, ac, s_1);
+ String _generateStateDoc = this.generateStateDoc(model, ac, s_1);
_builder.append(_generateStateDoc, "");
_builder.newLineIfNotEmpty();
}
}
}
}
- _xblockexpression = (_builder);
+ _xblockexpression = (_builder.toString());
}
return _xblockexpression;
}
diff --git a/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.java b/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.java
index 65d3ed5af..107d50547 100644
--- a/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.java
+++ b/plugins/org.eclipse.etrice.generator.doc/xtend-gen/org/eclipse/etrice/generator/doc/gen/InstanceDiagramGen.java
@@ -151,7 +151,7 @@ public class InstanceDiagramGen implements IRoomGenerator {
EList<ActorInstance> _instances_1 = ssi.getInstances();
for(final ActorInstance ai : _instances_1) {
_builder.append("\t");
- CharSequence _instance = this.instance(ai);
+ String _instance = this.instance(ai);
_builder.append(_instance, " ");
_builder.newLineIfNotEmpty();
}
@@ -163,8 +163,8 @@ public class InstanceDiagramGen implements IRoomGenerator {
return _builder;
}
- public CharSequence instance(final ActorInstance ai) {
- CharSequence _xblockexpression = null;
+ public String instance(final ActorInstance ai) {
+ String _xblockexpression = null;
{
EObject _eContainer = ai.eContainer();
final StructureInstance parent = ((StructureInstance) _eContainer);
@@ -217,12 +217,12 @@ public class InstanceDiagramGen implements IRoomGenerator {
{
EList<ActorInstance> _instances = ai.getInstances();
for(final ActorInstance sub_ai : _instances) {
- Object _instance = this.instance(sub_ai);
+ String _instance = this.instance(sub_ai);
_builder.append(_instance, "");
_builder.newLineIfNotEmpty();
}
}
- _xblockexpression = (_builder);
+ _xblockexpression = (_builder.toString());
}
return _xblockexpression;
}
diff --git a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/JavaExtensions.xtend b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/JavaExtensions.xtend
index 4e6a81443..a6f721bcf 100644
--- a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/JavaExtensions.xtend
+++ b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/JavaExtensions.xtend
@@ -51,7 +51,7 @@ class JavaExtensions implements ILanguageExtension {
}
def boolean needsInitialization(Attribute a){
- a.size > 0 || !typeHelpers.isPrimitive(a.refType.type)|| typeHelpers.typeName(a.refType.type)?.equals("String")
+ a.size > 0 || !typeHelpers.isPrimitive(a.refType.type) || typeHelpers.typeName(a.refType.type).equals("String")
}
override String accessLevelPrivate() {"private "}
diff --git a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/JavaExtensions.java b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/JavaExtensions.java
index 834f9492f..ac410a9b1 100644
--- a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/JavaExtensions.java
+++ b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/JavaExtensions.java
@@ -91,7 +91,7 @@ public class JavaExtensions implements ILanguageExtension {
RefableType _refType_1 = a.getRefType();
DataType _type_1 = _refType_1.getType();
String _typeName = this.typeHelpers.typeName(_type_1);
- boolean _equals = _typeName==null?false:_typeName.equals("String");
+ boolean _equals = _typeName.equals("String");
_or = (_or_1 || _equals);
}
return _or;
diff --git a/plugins/org.eclipse.etrice.generator/src/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.xtend b/plugins/org.eclipse.etrice.generator/src/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.xtend
index 838cf1b74..dc86f191d 100644
--- a/plugins/org.eclipse.etrice.generator/src/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.xtend
+++ b/plugins/org.eclipse.etrice.generator/src/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.xtend
@@ -195,7 +195,7 @@ class GenericStateMachineGenerator {
/* Action Codes */
«FOR tr : xpac.stateMachine.allTransitionsRecursive»
«IF (!langExt.usesInheritance || xpac.isOwnObject(tr)) && tr.action.hasDetailCode»
- «var start = xpac.getChain(tr).transition»
+ «var start = xpac.getChain(tr)?.transition»
«var hasArgs = start instanceof NonInitialTransition && !(start instanceof GuardedTransition)»
«langExt.accessLevelProtected»void «opScopePriv»«tr.getActionCodeOperationName()»(«langExt.selfPointer(ac.name, hasArgs)»«IF hasArgs»«constIfItemPtr» ifitem«transitionChainGenerator.generateArgumentList(xpac, tr)»«ENDIF») {
«AbstractGenerator::getInstance().getTranslatedCode(tr.action)»
@@ -552,7 +552,7 @@ class GenericStateMachineGenerator {
* @param state the {@link State}
* @return the generated code
*/
- def protected genDoCodes(State state) {'''
+ def protected String genDoCodes(State state) {'''
«IF state.hasDoCode(true)»
«state.getDoCodeOperationName()»(«langExt.selfPointer(false)»);
«ENDIF»
diff --git a/plugins/org.eclipse.etrice.generator/xtend-gen/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.java b/plugins/org.eclipse.etrice.generator/xtend-gen/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.java
index e23f629e8..ee7e4374c 100644
--- a/plugins/org.eclipse.etrice.generator/xtend-gen/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.java
+++ b/plugins/org.eclipse.etrice.generator/xtend-gen/org/eclipse/etrice/generator/generic/GenericStateMachineGenerator.java
@@ -375,7 +375,7 @@ public class GenericStateMachineGenerator {
}
if (_and) {
TransitionChain _chain = xpac.getChain(tr);
- Transition start = _chain.getTransition();
+ Transition start = _chain==null?(Transition)null:_chain.getTransition();
_builder.newLineIfNotEmpty();
boolean _and_1 = false;
if (!(start instanceof NonInitialTransition)) {
@@ -1244,7 +1244,7 @@ public class GenericStateMachineGenerator {
*/
protected CharSequence genDataDrivenTriggers(final ExpandedActorClass xpac, final State state, final boolean usesHdlr) {
StringConcatenation _builder = new StringConcatenation();
- CharSequence _genDoCodes = this.genDoCodes(state);
+ String _genDoCodes = this.genDoCodes(state);
_builder.append(_genDoCodes, "");
_builder.newLineIfNotEmpty();
List<Transition> _outgoingTransitionsHierarchical = this._roomExtensions.getOutgoingTransitionsHierarchical(xpac, state);
@@ -1555,7 +1555,7 @@ public class GenericStateMachineGenerator {
* @param state the {@link State}
* @return the generated code
*/
- protected CharSequence genDoCodes(final State state) {
+ protected String genDoCodes(final State state) {
StringConcatenation _builder = new StringConcatenation();
{
boolean _hasDoCode = RoomHelpers.hasDoCode(state, true);
@@ -1575,12 +1575,12 @@ public class GenericStateMachineGenerator {
if ((_eContainer_1 instanceof State)) {
EObject _eContainer_2 = state.eContainer();
EObject _eContainer_3 = _eContainer_2.eContainer();
- Object _genDoCodes = this.genDoCodes(((State) _eContainer_3));
+ String _genDoCodes = this.genDoCodes(((State) _eContainer_3));
_builder.append(_genDoCodes, "");
_builder.newLineIfNotEmpty();
}
}
- return _builder;
+ return _builder.toString();
}
/**

Back to the top