public void emitEvent(EventObject event) {
		int eventType = ((Integer) event.getSource()).intValue();
		if (eventType == DataPortListener.DATA_PORT_FINISH_READING) {
			System.out.println("Data port read event...\nData port read:");

			ByteBuffer bb = dataPort.getReadBuffer();

			// debugging
			BufferUtil.debug(bb);

			dataPort.readyReadReadBufufer();
			byte[] barr = null;
			if (bb.hasArray() && bb.hasRemaining()) {
				barr = bb.array();
				bb.clear();
				dataPort.setReadBufferExpectWrite(true);
			}
			if (null != barr) {
				List<XmlTag> tags = parser.parser(barr);
				for (XmlTag tag : tags) {
					Package pkg = new Package(this);
					pkg.setXmlTag(tag);
					try {
						PackageQueue.getPackageQ().put(pkg);
					} catch (Exception e) {
						System.out.println(e);
					}
				}
			}
		} else if (eventType == DataPortListener.DATA_PORT_FINISH_WRITING) {

		} else if (eventType == DataPortListener.DATA_PORT_OPENED) {

		} else if (eventType == DataPortListener.DATA_PORT_CLOSED) {

		}
	}