it.setVisibility(JvmVisibility.PRIVATE);
boolean _isStatic = method.isStatic();
it.setStatic(_isStatic);
EList<Parameter> _parameters = method.getParameters();
JexTestJvmModelInferrer.this.initParameters(it, _parameters);
XExpression _body = method.getBody();
JexTestJvmModelInferrer.this._jvmTypesBuilder.setBody(it, _body);
}
};
JvmOperation _method_1 = JexTestJvmModelInferrer.this._jvmTypesBuilder.toMethod(method, methodName, _returnType, _function_2);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_2, _method_1);
}
}
}
EList<StateFunction> _stateFunctions = testCase.getStateFunctions();
for (final StateFunction stateFunction : _stateFunctions) {
String _name = stateFunction.getName();
boolean _notEquals = (!Objects.equal(_name, null));
if (_notEquals) {
String _name_1 = stateFunction.getName();
JvmTypeReference _newTypeRef_1 = JexTestJvmModelInferrer.this._jvmTypesBuilder.newTypeRef(stateFunction, void.class);
final Procedure1<JvmOperation> _function_2 = new Procedure1<JvmOperation>() {
public void apply(final JvmOperation it) {
it.setVisibility(JvmVisibility.PRIVATE);
EList<JvmFormalParameter> _parameters = it.getParameters();
String _string = XbaseScopeProvider.IT.toString();
JvmParameterizedTypeReference _elvis = null;
JvmParameterizedTypeReference _type = stateFunction.getType();
if (_type != null) {
_elvis = _type;
} else {
JvmParameterizedTypeReference _testedClass = testCase.getTestedClass();
_elvis = ObjectExtensions.<JvmParameterizedTypeReference>operator_elvis(_type, _testedClass);
}
JvmFormalParameter _parameter = JexTestJvmModelInferrer.this._jvmTypesBuilder.toParameter(stateFunction, _string, _elvis);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmFormalParameter>operator_add(_parameters, _parameter);
EList<Parameter> _parameters_1 = stateFunction.getParameters();
JexTestJvmModelInferrer.this.initParameters(it, _parameters_1);
final Procedure1<ITreeAppendable> _function = new Procedure1<ITreeAppendable>() {
public void apply(final ITreeAppendable it) {
XBlockExpression _test = stateFunction.getTest();
JexTestJvmModelInferrer.this.generateTestHelperMethodCall("_test_", ((PropertiesTest) _test), it);
}
};
JexTestJvmModelInferrer.this._jvmTypesBuilder.setBody(it, _function);
}
};
final JvmOperation stateMethod = JexTestJvmModelInferrer.this._jvmTypesBuilder.toMethod(stateFunction, _name_1, _newTypeRef_1, _function_2);
EList<JvmMember> _members_2 = it.getMembers();
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_2, stateMethod);
XBlockExpression _test = stateFunction.getTest();
boolean _notEquals_1 = (!Objects.equal(_test, null));
if (_notEquals_1) {
XBlockExpression _test_1 = stateFunction.getTest();
JexTestJvmModelInferrer.this.inferPropertiesTestMethods(((PropertiesTest) _test_1), jvmClass);
}
}
}
final ArrayList<Pair<JexTestSequence,JvmOperation>> testMethods = CollectionLiterals.<Pair<JexTestSequence,JvmOperation>>newArrayList();
EList<JexTestSequence> _testSequences = testCase.getTestSequences();
for (final JexTestSequence sequence : _testSequences) {
String _name_2 = sequence.getName();
boolean _notEquals_2 = (!Objects.equal(_name_2, null));
if (_notEquals_2) {
String _name_3 = sequence.getName();
String _firstUpper = StringExtensions.toFirstUpper(_name_3);
String _plus = ("test" + _firstUpper);
JvmTypeReference _newTypeRef_2 = JexTestJvmModelInferrer.this._jvmTypesBuilder.newTypeRef(sequence, void.class);
final Procedure1<JvmOperation> _function_3 = new Procedure1<JvmOperation>() {
public void apply(final JvmOperation it) {
it.setVisibility(JvmVisibility.PUBLIC);
final Procedure1<ITreeAppendable> _function = new Procedure1<ITreeAppendable>() {
public void apply(final ITreeAppendable it) {
EList<Instance> _instances = sequence.getInstances();
for (final Instance instance : _instances) {
JexTestJvmModelInferrer.this.generateLocalInstance(instance, it);
}
EList<Transition> _transitions = sequence.getTransitions();
for (final Transition transition : _transitions) {
JexTestJvmModelInferrer.this.generateTransition(transition, it);
}
}
};
JexTestJvmModelInferrer.this._jvmTypesBuilder.setBody(it, _function);
}
};
final JvmOperation testMethod = JexTestJvmModelInferrer.this._jvmTypesBuilder.toMethod(sequence, _plus, _newTypeRef_2, _function_3);
Pair<JexTestSequence,JvmOperation> _mappedTo = Pair.<JexTestSequence, JvmOperation>of(sequence, testMethod);
testMethods.add(_mappedTo);
EList<JvmMember> _members_3 = it.getMembers();
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_3, testMethod);
}
}
EList<JvmMember> _members_4 = it.getMembers();
final Function1<Pair<JexTestSequence,JvmOperation>,JvmOperation> _function_4 = new Function1<Pair<JexTestSequence,JvmOperation>,JvmOperation>() {
public JvmOperation apply(final Pair<JexTestSequence,JvmOperation> it) {
JvmOperation _value = it.getValue();
return _value;
}
};
List<JvmMember> _map = ListExtensions.<Pair<JexTestSequence,JvmOperation>, JvmMember>map(testMethods, _function_4);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmMember>operator_add(_members_4, _map);
EList<JexTestSequence> _testSequences_1 = testCase.getTestSequences();
for (final JexTestSequence sequence_1 : _testSequences_1) {
{
EList<Instance> _instances_1 = sequence_1.getInstances();
for (final Instance instance_1 : _instances_1) {
EList<JvmMember> _members_5 = it.getMembers();
String _relativeName = JexTestJvmModelInferrer.this._util.<JexTestSequence>relativeName(instance_1, JexTestSequence.class);
String _plus_1 = ("_init_" + _relativeName);
JvmOperation _inferTestInstanceInitMethod = JexTestJvmModelInferrer.this.inferTestInstanceInitMethod(_plus_1, instance_1);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_5, _inferTestInstanceInitMethod);
}
EList<Transition> _transitions = sequence_1.getTransitions();
for (final Transition transition : _transitions) {
{
boolean _and = false;
TransitionSource _source = transition.getSource();
boolean _notEquals_3 = (!Objects.equal(_source, null));
if (!_notEquals_3) {
_and = false;
} else {
TransitionSource _source_1 = transition.getSource();
State _state = _source_1.getState();
boolean _notEquals_4 = (!Objects.equal(_state, null));
_and = (_notEquals_3 && _notEquals_4);
}
if (_and) {
TransitionSource _source_2 = transition.getSource();
State _state_1 = _source_2.getState();
JexTestJvmModelInferrer.this.inferStateTestMethods(sequence_1, _state_1, jvmClass);
}
EList<TransitionAction> _actions = transition.getActions();
Iterable<TransitionExpressionAction> _filter = Iterables.<TransitionExpressionAction>filter(_actions, TransitionExpressionAction.class);
for (final TransitionExpressionAction action : _filter) {
{
EList<JvmMember> _members_6 = it.getMembers();
JvmOperation _inferActionMethod = JexTestJvmModelInferrer.this.inferActionMethod(sequence_1, action);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_6, _inferActionMethod);
XExpression _times = action.getTimes();
boolean _notEquals_5 = (!Objects.equal(_times, null));
if (_notEquals_5) {
EList<JvmMember> _members_7 = it.getMembers();
XExpression _times_1 = action.getTimes();
JvmOperation _inferTestHelperMethod = JexTestJvmModelInferrer.this.inferTestHelperMethod(sequence_1, "_transition_exprAction_times_", action, _times_1, null);
JexTestJvmModelInferrer.this._jvmTypesBuilder.<JvmOperation>operator_add(_members_7, _inferTestHelperMethod);
}
}
}