}
}
else
{
Object value;
Variable variable =
mExecutionState.getVariables().get(connection.mPE);
if (variable == null)
{
throw new UnresolvedVariableException(connection.mPE);
}
value = variable.getValue(connection.mArrayIndices);
if (value instanceof RequestNode)
{
RequestNode node = (RequestNode)value;
mConnection = node.getOutput(connection.mName, connection.mIndex.intValue());
}
else
{
throw new TypeMismatchException("ProcessingElement", value);
}
}
break;
}
case INPUT:
{
ConnectionStrategy connection = (ConnectionStrategy)strategy;
if (connection.mConnectionVar != null)
{
Connection c = (Connection) connection.mConnectionVar.getValue(connection.mArrayIndices);
if (c == null ||
!(c.getSource() instanceof LiteralValuesNode &&
mConnection.getSource() instanceof LiteralValuesNode))
{
connection.mConnectionVar.setValue(mConnection, connection.mArrayIndices);
}
else
{
LiteralValuesNode literal = (LiteralValuesNode) c.getSource();
LiteralValuesNode current = (LiteralValuesNode) mConnection.getSource();
literal.add(current.getValues());
}
}
else
{
Object value;
Variable variable =
mExecutionState.getVariables().get(connection.mPE);
if (variable == null)
{
throw new UnresolvedVariableException(connection.mPE);
}
value = variable.getValue(connection.mArrayIndices);
if (value instanceof RequestNode)
{
RequestNode node = (RequestNode)value;
if (node.getAllInputs().containsKey(connection.mName))
{