public BeanDefinition parse(Element element, ParserContext parserContext) {
        String location = element.getAttribute("location");
        BeanDefinitionBuilder builder = null;

        if (location.endsWith(".wsdl")) {
            builder = BeanDefinitionBuilder.genericBeanDefinition(WsdlXsdSchema.class);
            BeanDefinitionParserUtils.setPropertyValue(builder, location, "wsdl");
        } else if (location.endsWith(".xsd")) {
            builder = BeanDefinitionBuilder.genericBeanDefinition(SimpleXsdSchema.class);
            BeanDefinitionParserUtils.setPropertyValue(builder, location, "xsd");
        } else if (location.endsWith(".json")) {
            builder = BeanDefinitionBuilder.genericBeanDefinition(SimpleJsonSchema.class);
            BeanDefinitionParserUtils.setPropertyValue(builder, location, "json");
        }

        if (builder != null) {
            parserContext.getRegistry().registerBeanDefinition(element.getAttribute("id"), builder.getBeanDefinition());
        }

        return null;
    }
public BeanDefinition parse ( Element element , ParserContext parserContext ) { String location = element . getAttribute ( "location" ) ; BeanDefinitionBuilder builder = null ; if ( location . endsWith ( ".wsdl" ) ) { builder = BeanDefinitionBuilder . genericBeanDefinition ( WsdlXsdSchema . class ) ; BeanDefinitionParserUtils . setPropertyValue ( builder , location , "wsdl" ) ; } else if ( location . endsWith ( ".xsd" ) ) { builder = BeanDefinitionBuilder . genericBeanDefinition ( SimpleXsdSchema . class ) ; BeanDefinitionParserUtils . setPropertyValue ( builder , location , "xsd" ) ; } else if ( location . endsWith ( ".json" ) ) { builder = BeanDefinitionBuilder . genericBeanDefinition ( SimpleJsonSchema . class ) ; BeanDefinitionParserUtils . setPropertyValue ( builder , location , "json" ) ; } if ( builder != null ) { parserContext . getRegistry ( ) . registerBeanDefinition ( element . getAttribute ( "id" ) , builder . getBeanDefinition ( ) ) ; } return null ; }
@see org.springframework.beans.factory.xml.BeanDefinitionParser#parse(org.w3c.dom.Element, org.springframework.beans.factory.xml.ParserContext)