You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ti...@apache.org on 2019/07/29 07:49:24 UTC
[maven-archetype] branch buildfix updated: deleted unnecessary
calls ".flush()"
This is an automated email from the ASF dual-hosted git repository.
tibordigana pushed a commit to branch buildfix
in repository https://gitbox.apache.org/repos/asf/maven-archetype.git
The following commit(s) were added to refs/heads/buildfix by this push:
new 7995ddb deleted unnecessary calls ".flush()"
7995ddb is described below
commit 7995ddbc1a85ded8d3bd65622df6712d23605aac
Author: tibordigana <ti...@apache.org>
AuthorDate: Mon Jul 29 09:49:10 2019 +0200
deleted unnecessary calls ".flush()"
---
.../org/apache/maven/archetype/DefaultArchetypeManager.java | 2 --
.../org/apache/maven/archetype/common/util/XMLOutputter.java | 12 ------------
.../generator/DefaultFilesetArchetypeGenerator.java | 2 --
.../org/apache/maven/archetype/old/DefaultOldArchetype.java | 2 --
.../apache/maven/archetype/mojos/IntegrationTestMojo.java | 1 -
5 files changed, 19 deletions(-)
diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/DefaultArchetypeManager.java b/archetype-common/src/main/java/org/apache/maven/archetype/DefaultArchetypeManager.java
index e6dbbd5..51119a1 100644
--- a/archetype-common/src/main/java/org/apache/maven/archetype/DefaultArchetypeManager.java
+++ b/archetype-common/src/main/java/org/apache/maven/archetype/DefaultArchetypeManager.java
@@ -152,8 +152,6 @@ public class DefaultArchetypeManager
IOUtil.copy( is, zos );
}
- zos.flush();
-
zos.closeEntry();
}
}
diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java
index 58e00d1..6b9ca9a 100644
--- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java
+++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java
@@ -437,8 +437,6 @@ public class XMLOutputter
// Output final line separator
// We output this no matter what the newline flags say
out.write( currentFormat.lineSeparator );
-
- out.flush();
}
/**
@@ -451,7 +449,6 @@ public class XMLOutputter
throws IOException
{
printDocType( out, doctype );
- out.flush();
}
/**
@@ -468,7 +465,6 @@ public class XMLOutputter
// If this is the root element we could pre-initialize the
// namespace stack with the namespaces
printElement( out, element, 0, createNamespaceStack() );
- out.flush();
}
/**
@@ -487,7 +483,6 @@ public class XMLOutputter
List<?> content = element.getContent();
printContentRange( out, content, 0, content.size(),
0, createNamespaceStack() );
- out.flush();
}
/**
@@ -503,7 +498,6 @@ public class XMLOutputter
throws IOException
{
printContentRange( out, list, 0, list.size(), 0, createNamespaceStack() );
- out.flush();
}
/**
@@ -516,7 +510,6 @@ public class XMLOutputter
throws IOException
{
printCDATA( out, cdata );
- out.flush();
}
/**
@@ -530,7 +523,6 @@ public class XMLOutputter
throws IOException
{
printText( out, text );
- out.flush();
}
/**
@@ -543,7 +535,6 @@ public class XMLOutputter
throws IOException
{
printComment( out, comment );
- out.flush();
}
/**
@@ -561,8 +552,6 @@ public class XMLOutputter
currentFormat.setIgnoreTrAXEscapingPIs( true );
printProcessingInstruction( out, pi );
currentFormat.setIgnoreTrAXEscapingPIs( currentEscapingPolicy );
-
- out.flush();
}
/**
@@ -575,7 +564,6 @@ public class XMLOutputter
throws IOException
{
printEntityRef( out, entity );
- out.flush();
}
// * * * * * * * * * * Output to a String * * * * * * * * * *
diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java b/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java
index 790a982..c0548ff 100644
--- a/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java
+++ b/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java
@@ -714,8 +714,6 @@ public class DefaultFilesetArchetypeGenerator
velocity.getEngine().mergeTemplate( templateFileName, encoding, context, stringWriter );
writer.write( StringUtils.unifyLineSeparators( stringWriter.toString() ) );
-
- writer.flush();
}
catch ( Exception e )
{
diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/old/DefaultOldArchetype.java b/archetype-common/src/main/java/org/apache/maven/archetype/old/DefaultOldArchetype.java
index 5e90fc5..573ef41 100644
--- a/archetype-common/src/main/java/org/apache/maven/archetype/old/DefaultOldArchetype.java
+++ b/archetype-common/src/main/java/org/apache/maven/archetype/old/DefaultOldArchetype.java
@@ -759,8 +759,6 @@ public class DefaultOldArchetype
velocity.getEngine().mergeTemplate( template, descriptor.getEncoding(), context, stringWriter );
writer.write( StringUtils.unifyLineSeparators( stringWriter.toString() ) );
-
- writer.flush();
}
catch ( Exception e )
{
diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java
index 7e7d435..0efeb14 100644
--- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java
+++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java
@@ -816,7 +816,6 @@ public class IntegrationTestMojo
interpolatedFile.getParentFile().mkdirs();
writer.write( xml );
- writer.flush();
}
}
catch ( IOException e )