package mildo.wiwo.parser;

import org.eclipse.mylyn.wikitext.core.parser.MarkupParser;
import org.eclipse.mylyn.wikitext.mediawiki.core.MediaWikiLanguage;

import com.webobjects.appserver.WOContext;

public class MediaWikiParser 
	implements IParser
{

	public MediaWikiParser(WOContext aContext) {
		context = aContext;
	}
	
	private WOContext context;
	
	public WOContext getContext() {
		return context;
	}
	
	public String parse2Html(String aValue2Parse) {
		MarkupParser theParser = new MarkupParser();
		theParser.setMarkupLanguage(new WiwoMediaWikiLang(context));
		return theParser.parseToHtml(aValue2Parse);
	}

}
