extract method refactoring

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@1557431 13f79535-47bb-0310-9956-ffa450edef68
copy using channels ignored append attribute so must not be used when append is requested

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@1557432 13f79535-47bb-0310-9956-ffa450edef68
Fall back to stream based copy if channel based copy fails for some reason - PRs 53102 and 54397

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@1557433 13f79535-47bb-0310-9956-ffa450edef68