}
private Metadata readMetadata( File file )
throws ArtifactConversionException
{
MetadataXpp3Reader reader = new MetadataXpp3Reader();
try (Reader fileReader = Files.newBufferedReader( file.toPath(), Charset.defaultCharset() ))
{
return reader.read( fileReader );
}
catch ( IOException | XmlPullParserException e )
{
throw new ArtifactConversionException( Messages.getString( "error.reading.target.metadata" ),
e ); //$NON-NLS-1$