 		{
 			var bytedata:ByteArray = new ByteArray();
 			// The default value of 0 causes all available data to be read.
-			socket.readBytes(bytedata);
-			
+			socket.readBytes( bytedata );
+			parseDataReceived( bytedata );
+		}
+		
+		/**
+		 * Parses the data which the socket just received.
+		 * Used to simplify the overrides from classes extending this one.
+		 * @param	bytedata
+		 */
+		protected function parseDataReceived( bytedata:ByteArray ):void
+		{
 			// Increase the incoming data counter.
 			_incomingBytes += bytedata.length;
 			

			{
				dispatchError("SASL missing", "The server is not configured to support any available SASL mechanisms", "SASL", -1);
			}
			else 
			{
				auth = new authClass(this);
			}

		}

		/**
		 *
		 * @param	resultIQ
		 */
		protected function getRegistrationFields_result( resultIQ:IQ ):void
