public String getAtIndex(byte type, int index)
			{
				if (index < 0 || index >= getText().length())
					{
						return null;
					}
				switch (type)
					{
					case CHARACTER:
						return getText().substring(index, index + 1);
					case WORD:
						{
							String s = getText();
							BreakIterator words = BreakIterator.getWordInstance();
							words.setText(s);
							int end = words.following(index);
							return s.substring(words.previous(), end);
						}
					case SENTENCE:
						{
							String s = getText();
							BreakIterator sentence = BreakIterator.getSentenceInstance();
							sentence.setText(s);
							int end = sentence.following(index);
							return s.substring(sentence.previous(), end);
						}
					default:
						return "";
					}
			}