Package org.openmrs.module.drawing.handlers

Source Code of org.openmrs.module.drawing.handlers.DrawingTagHandler

package org.openmrs.module.drawing.handlers;

import java.util.Map;

import org.openmrs.module.drawing.elements.DrawingSubmissionElement;
import org.openmrs.module.htmlformentry.BadFormDesignException;
import org.openmrs.module.htmlformentry.FormEntrySession;
import org.openmrs.module.htmlformentry.FormSubmissionController;
import org.openmrs.module.htmlformentry.handler.SubstitutionTagHandler;

public class DrawingTagHandler extends SubstitutionTagHandler {
 
  //public class DrawingTagHandler{
 
  @Override
  protected String getSubstitution(FormEntrySession session, FormSubmissionController controllerActions,
                                   Map<String, String> parameters) throws BadFormDesignException {
    DrawingSubmissionElement element = new DrawingSubmissionElement(session.getContext(), parameters);
    session.getSubmissionController().addAction(element);
    return element.generateHtml(session.getContext());
  }
 
}
TOP

Related Classes of org.openmrs.module.drawing.handlers.DrawingTagHandler

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.