private StreamNode eatStream() {
		String streamName = maybeEatStreamName();
		SourceChannelNode sourceChannelNode = maybeEatSourceChannel();
		// This construct: queue:foo > topic:bar is a source then a sink channel
		// with no module. Special handling for that is right here:
		boolean bridge = false;
		if (sourceChannelNode != null) { // so if we are just after a '>'
			if (looksLikeChannel() && noMorePipes()) {
				bridge = true;
			}
		}

		List<ModuleNode> moduleNodes = null;
		if (bridge) {
			// Create a bridge module to hang the source/sink channels off
			tokenStreamPointer--; // Rewind so we can nicely eat the sink channel
			moduleNodes = new ArrayList<ModuleNode>();
			moduleNodes.add(new ModuleNode(null, "bridge", peekToken().startpos, peekToken().endpos, null));
		}
		else {
			moduleNodes = eatModuleList();
		}
		SinkChannelNode sinkChannelNode = maybeEatSinkChannel();

		// Further data is an error
		if (moreTokens()) {
			Token t = peekToken();
			raiseException(t.startpos, XDDSLMessages.UNEXPECTED_DATA_AFTER_STREAMDEF, toString(t));
		}

		StreamNode streamNode = new StreamNode(expressionString, streamName, moduleNodes, sourceChannelNode,
				sinkChannelNode);
		return streamNode;
	}
Parse a stream definition.

@return the AST for the parsed stream
@throws StreamDefinitionException
spring-xd-dirt/src/main/java/org/springframework/xd/dirt/stream/dsl/StreamConfigParser.java