protected void setUp() throws Exception { // TODO Auto-generated method stub super.setUp(); qname = getQName(); if (qname != null) { typeDef = xsdSimple(qname.getLocalPart()); strategy = (SimpleBinding) stratagy(qname); } }
public ElementInstance element(String text, QName qname) { // create a fake element declaration and element instance XSDElementDeclaration declaration = XSDFactory.eINSTANCE.createXSDElementDeclaration(); declaration.setTypeDefinition(xsdSimple(qname.getLocalPart())); ElementInstance element = new ElementImpl(declaration); element.setText(text); return element; }