private void AddTextElementToRulesList(TranscriptionRulesElement textElement)
	{
		//At first we need to validate whether the rule element has the minimum required data.
		if (textElement!=null && textElement._text.length()>0)
		{
			if (_rules==null)
			{
				//If this is the first rule in the list:
				_rules = textElement;
			}
			else
			{//If there is at lest one rule in the list.
				TranscriptionRulesElement iterator = _rules;
				boolean attached = false;
				//We iterate through rules.
				do
				{
					if (iterator._text.charAt(0)==textElement._text.charAt(0))
					{
						//If we have found a rule with the same first character, we have to iterate through the second dimension (same character rules).
						if (iterator._next!=null)
						{//When we have found the last rule in the list, we attach the new rule at the end.
							iterator = iterator._next;
						}
						else
						{
							iterator._next = textElement;
							attached = true;
						}
					}
					else if (iterator._nextCharElement!=null)
					{
						//The current rule is with a different first character, so we have to iterate through the first dimension (different first character rules).
						iterator = iterator._nextCharElement;
					}
					else
					{
						//If there are no rules with the same first character as in the new rule, we attach the new rule at the end of the first dimension rules.
						iterator._nextCharElement = textElement;
						attached = true;
					}
				}
				while (!attached);
			}
		}
	}