Code example for Matcher

Methods: end, find, start

0
			String tagName = startMatcher.group(1);
			int start_end=startMatcher.end();
			int end_start=0;
			endPattern = Pattern.compile("</(" + tagName + ")>");
			endMatcher = endPattern.matcher(str);
			if (endMatcher.find()) {
				int end_end = endMatcher.end();
				System.out.println("TagName :"+tagName);
				end_start=endMatcher.start();
				tags.get(tags.size()-1).get(tags.get(tags.size()-1).size()-1).add(tagName);
				stringToElement(str.substring(start_end, end_start));
				//tags.add(new Vector<Vector<String>>()); 
				tags.get(tags.size()-1).add(new Vector<String>());
				stringToElement(str.substring(end_end, str.length()));
			} 
			//System.out.println("Content: "+str.substring(start_end, end_start)); 
			 
			 
		} 
		 
		return tags;