public static ParameterizedTemplateModel create ( final File file ) { try { final JaxbHelper helper = new JaxbHelper ( ) ; final ParameterizedTemplateModel pc = helper . create ( file , createJaxbContext ( ) ) ; pc . setFile ( file ) ; Contract . requireValid ( pc ) ; return pc ; } catch ( final UnmarshalObjectException ex ) { throw new RuntimeException ( ex ) ; } }
Creates an instance by reading the XML from a file .