Skip to content
Snippets Groups Projects
Commit ca978b00 authored by srosse's avatar srosse
Browse files

OO-2247: replace label with span by import

parent ab1ebed4
No related branches found
No related tags found
No related merge requests found
......@@ -40,7 +40,7 @@ import org.xml.sax.ext.DefaultHandler2;
* @author srosse, stephane.rosse@frentix.com, http://www.frentix.com
*
*/
public class OnyxToQtiWorksHandler extends DefaultHandler2 {
public class OnyxToQtiWorksHandler extends DefaultHandler2 {
private final XMLStreamWriter xtw;
......@@ -105,8 +105,13 @@ public class OnyxToQtiWorksHandler extends DefaultHandler2 {
rubricBlock = false;
rubricCharacterBuffer = null;
}
if("label".equals(qName)) {//convert label which are not part of QTI 2.1 standard to span
xtw.writeStartElement("span");
} else {
xtw.writeStartElement(qName);
}
xtw.writeStartElement(qName);
if("imscp:resource".equals(qName)) {
int numOfAttributes = attributes.getLength();
for(int i=0;i<numOfAttributes; i++) {
......@@ -136,6 +141,8 @@ public class OnyxToQtiWorksHandler extends DefaultHandler2 {
} else if("prompt".equals(qName)) {
prompt = true;
}
} catch (XMLStreamException e) {
throw new SAXException(e);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment