@Override
	public void consume(Tweet msg) {
		/*
		 * Get the message content
		 */
		String msgContent = msg.getTweet();
		
		/*
		 * Find the pattern matches to tweet's content.
		 */
		Matcher m = null;
		int methodType = -1;
		for(Map.Entry<Pattern, Integer> entry: this.methodMap.entrySet()) {
			if(m == null)
				m = entry.getKey().matcher(msg.getTweet());
			else {
				m.usePattern(entry.getKey());
				m.reset(msg.getTweet());
			}
			
			if(m.matches()) {
				methodType = entry.getValue().intValue();
				break;
			}
		}

		/*
		 * Execute the method this pattern maps.
		 * If there is no match, print the message content.
		 */
		switch(methodType) {
		case 0:	
			this.respondToWhoIsIn(m, msg);
			break;
		case 1:
			this.respondToOpenDoor(m, msg);
			break;
		case 2:
			this.respondToIsIn(m, msg);
			break;
		case 3:
			this.respondToIsDoorOpen(m, msg);
			break;
		default: System.out.println(String.format("No pattern matches to --> %s", msgContent));
		}
	}