ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xav...@apache.org
Subject svn commit: r640525 - in /ant/ivy/core/trunk/src/java/org/apache/ivy: ant/IvyRepositoryReport.java ant/IvyResolve.java core/search/SearchEngine.java plugins/matcher/RegexpPatternMatcher.java plugins/resolver/AbstractResourceResolver.java
Date Mon, 24 Mar 2008 19:08:49 GMT
Author: xavier
Date: Mon Mar 24 12:08:45 2008
New Revision: 640525

URL: http://svn.apache.org/viewvc?rev=640525&view=rev
Log:
fix style

Modified:
    ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyRepositoryReport.java
    ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyResolve.java
    ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java
    ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/matcher/RegexpPatternMatcher.java
    ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractResourceResolver.java

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyRepositoryReport.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyRepositoryReport.java?rev=640525&r1=640524&r2=640525&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyRepositoryReport.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyRepositoryReport.java Mon Mar 24 12:08:45
2008
@@ -95,7 +95,8 @@
             if ((revision == null) || settings.getVersionMatcher().isDynamic(mrid)) {
                 criteria = new ModuleRevisionId(new ModuleId(organisation, module), branch,
"*");
             } else {
-                criteria = new ModuleRevisionId(new ModuleId(organisation, module), branch,
revision);
+                criteria = new ModuleRevisionId(
+                    new ModuleId(organisation, module), branch, revision);
             }
             
             ModuleRevisionId[] mrids = ivy.listModules(criteria, settings.getMatcher(matcher));

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyResolve.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyResolve.java?rev=640525&r1=640524&r2=640525&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyResolve.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/ant/IvyResolve.java Mon Mar 24 12:08:45 2008
@@ -302,8 +302,8 @@
                     if (file != null) {
                         getProject().setProperty("ivy.resolved.file." + resolveId,
                             file.getAbsolutePath());
-                        settings
-                                .setVariable("ivy.resolved.file." + resolveId, file.getAbsolutePath());
+                        settings.setVariable(
+                            "ivy.resolved.file." + resolveId, file.getAbsolutePath());
                     }
                 }
             }

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java?rev=640525&r1=640524&r2=640525&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/search/SearchEngine.java Mon Mar 24 12:08:45
2008
@@ -73,7 +73,8 @@
 
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] orgs = resolver.listTokenValues(new String[] {IvyPatternHelper.ORGANISATION_KEY},
new HashMap());
+            Map[] orgs = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.ORGANISATION_KEY}, new HashMap());
             for (int i = 0; i < orgs.length; i++) {
                 String org = (String) orgs[i].get(IvyPatternHelper.ORGANISATION_KEY);
                 entries.add(new OrganisationEntry(resolver, org));
@@ -88,7 +89,8 @@
 
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] orgs = resolver.listTokenValues(new String[] {IvyPatternHelper.ORGANISATION_KEY},
new HashMap());
+            Map[] orgs = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.ORGANISATION_KEY}, new HashMap());
             for (int i = 0; i < orgs.length; i++) {
                 entries.add(orgs[i].get(IvyPatternHelper.ORGANISATION_KEY));
             }
@@ -105,7 +107,8 @@
         
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] modules = resolver.listTokenValues(new String[] {IvyPatternHelper.MODULE_KEY},
tokenValues);
+            Map[] modules = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.MODULE_KEY}, tokenValues);
             for (int i = 0; i < modules.length; i++) {
                 String module = (String) modules[i].get(IvyPatternHelper.MODULE_KEY);
                 entries.add(new ModuleEntry(org, module));
@@ -123,7 +126,8 @@
         
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] modules = resolver.listTokenValues(new String[] {IvyPatternHelper.MODULE_KEY},
tokenValues);
+            Map[] modules = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.MODULE_KEY}, tokenValues);
             for (int i = 0; i < modules.length; i++) {
                 entries.add(modules[i].get(IvyPatternHelper.MODULE_KEY));
             }
@@ -141,7 +145,8 @@
         
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] revisions = resolver.listTokenValues(new String[] {IvyPatternHelper.REVISION_KEY},
tokenValues);
+            Map[] revisions = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.REVISION_KEY}, tokenValues);
             for (int i = 0; i < revisions.length; i++) {
                 String revision = (String) revisions[i].get(IvyPatternHelper.REVISION_KEY);
                 entries.add(new RevisionEntry(module, revision));
@@ -160,7 +165,8 @@
         
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
-            Map[] revisions = resolver.listTokenValues(new String[] {IvyPatternHelper.REVISION_KEY},
tokenValues);
+            Map[] revisions = resolver.listTokenValues(
+                new String[] {IvyPatternHelper.REVISION_KEY}, tokenValues);
             for (int i = 0; i < revisions.length; i++) {
                 entries.add(revisions[i].get(IvyPatternHelper.REVISION_KEY));
             }
@@ -181,10 +187,12 @@
         List ret = new ArrayList();
 
         Map criteria = new HashMap();
-        addMatcher(matcher, moduleCrit.getOrganisation(), criteria, IvyPatternHelper.ORGANISATION_KEY);
+        addMatcher(matcher, moduleCrit.getOrganisation(), 
+                   criteria, IvyPatternHelper.ORGANISATION_KEY);
         addMatcher(matcher, moduleCrit.getName(), criteria, IvyPatternHelper.MODULE_KEY);
         
-        String[] tokensToList = new String[] {IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY};
+        String[] tokensToList = new String[] {
+                IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY};
 
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
@@ -212,12 +220,15 @@
         List ret = new ArrayList();
 
         Map criteria = new HashMap();
-        addMatcher(matcher, moduleCrit.getOrganisation(), criteria, IvyPatternHelper.ORGANISATION_KEY);
+        addMatcher(matcher, moduleCrit.getOrganisation(), 
+                   criteria, IvyPatternHelper.ORGANISATION_KEY);
         addMatcher(matcher, moduleCrit.getName(), criteria, IvyPatternHelper.MODULE_KEY);
         addMatcher(matcher, moduleCrit.getBranch(), criteria, IvyPatternHelper.BRANCH_KEY);
         addMatcher(matcher, moduleCrit.getRevision(), criteria, IvyPatternHelper.REVISION_KEY);
         
-        String[] tokensToList = new String[] {IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY,
IvyPatternHelper.BRANCH_KEY, IvyPatternHelper.REVISION_KEY};
+        String[] tokensToList = new String[] {
+                IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY, 
+                IvyPatternHelper.BRANCH_KEY, IvyPatternHelper.REVISION_KEY};
 
         for (Iterator iter = settings.getResolvers().iterator(); iter.hasNext();) {
             DependencyResolver resolver = (DependencyResolver) iter.next();
@@ -235,14 +246,18 @@
         return (ModuleRevisionId[]) ret.toArray(new ModuleRevisionId[ret.size()]);
     }
 
-    public ModuleRevisionId[] listModules(DependencyResolver resolver, ModuleRevisionId moduleCrit,
PatternMatcher matcher) {
+    public ModuleRevisionId[] listModules(
+            DependencyResolver resolver, ModuleRevisionId moduleCrit, PatternMatcher matcher)
{
         Map criteria = new HashMap();
-        addMatcher(matcher, moduleCrit.getOrganisation(), criteria, IvyPatternHelper.ORGANISATION_KEY);
+        addMatcher(matcher, moduleCrit.getOrganisation(), 
+                   criteria, IvyPatternHelper.ORGANISATION_KEY);
         addMatcher(matcher, moduleCrit.getName(), criteria, IvyPatternHelper.MODULE_KEY);
         addMatcher(matcher, moduleCrit.getBranch(), criteria, IvyPatternHelper.BRANCH_KEY);
         addMatcher(matcher, moduleCrit.getRevision(), criteria, IvyPatternHelper.REVISION_KEY);
         
-        String[] tokensToList = new String[] {IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY,
IvyPatternHelper.BRANCH_KEY, IvyPatternHelper.REVISION_KEY};
+        String[] tokensToList = new String[] {
+                IvyPatternHelper.ORGANISATION_KEY, IvyPatternHelper.MODULE_KEY, 
+                IvyPatternHelper.BRANCH_KEY, IvyPatternHelper.REVISION_KEY};
 
         Map[] moduleIdAsMap = resolver.listTokenValues(tokensToList, criteria);
         ModuleRevisionId[] result = new ModuleRevisionId[moduleIdAsMap.length];
@@ -257,7 +272,8 @@
         return result;
     }
     
-    private void addMatcher(PatternMatcher patternMatcher, String expression, Map criteria,
String key) {
+    private void addMatcher(
+            PatternMatcher patternMatcher, String expression, Map criteria, String key) {
         if (expression == null) {
             return;
         }

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/matcher/RegexpPatternMatcher.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/matcher/RegexpPatternMatcher.java?rev=640525&r1=640524&r2=640525&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/matcher/RegexpPatternMatcher.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/matcher/RegexpPatternMatcher.java Mon
Mar 24 12:08:45 2008
@@ -76,7 +76,8 @@
             char[] expressionChars = expression.toCharArray();
             for (int i = 0; i < expressionChars.length; i++) {
                 char ch = expressionChars[i];
-                if (!Character.isLetterOrDigit(ch) && !Character.isWhitespace(ch)
&& ('-' != ch) && ('_' != ch)) {
+                if (!Character.isLetterOrDigit(ch) && !Character.isWhitespace(ch)

+                        && ('-' != ch) && ('_' != ch)) {
                     result = Boolean.FALSE;
                     break;
                 }

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractResourceResolver.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractResourceResolver.java?rev=640525&r1=640524&r2=640525&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractResourceResolver.java
(original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/plugins/resolver/AbstractResourceResolver.java
Mon Mar 24 12:08:45 2008
@@ -250,7 +250,7 @@
         Map tokenValues = new HashMap(criteria);
         tokenValues.put(IvyPatternHelper.TYPE_KEY, "ivy");
         tokenValues.put(IvyPatternHelper.EXT_KEY, "xml");
-        for (Iterator it = ivyPatterns.iterator(); it.hasNext(); ) {
+        for (Iterator it = ivyPatterns.iterator(); it.hasNext();) {
             String ivyPattern = (String) it.next();
             result.addAll(resolveTokenValues(tokens, ivyPattern, tokenValues, false));
         }
@@ -260,7 +260,7 @@
             tokenValues = new HashMap(criteria);
             tokenValues.put(IvyPatternHelper.TYPE_KEY, "jar");
             tokenValues.put(IvyPatternHelper.EXT_KEY, "jar");
-            for (Iterator it = artifactPatterns.iterator(); it.hasNext(); ) {
+            for (Iterator it = artifactPatterns.iterator(); it.hasNext();) {
                 String artifactPattern = (String) it.next();
                 result.addAll(resolveTokenValues(tokens, artifactPattern, tokenValues, true));
             }
@@ -274,7 +274,7 @@
         Set tokenSet = new HashSet(Arrays.asList(tokens));
         
         Map tokenValues = new HashMap();
-        for (Iterator it = criteria.entrySet().iterator(); it.hasNext(); ) {
+        for (Iterator it = criteria.entrySet().iterator(); it.hasNext();) {
             Map.Entry entry = (Entry) it.next();
             Object key = entry.getKey();
             Object value = entry.getValue();
@@ -316,7 +316,8 @@
             }
             
             tokenValues.put(token, values[i]);
-            String moreResolvedPattern = IvyPatternHelper.substituteTokens(partiallyResolvedPattern,
tokenValues);
+            String moreResolvedPattern = IvyPatternHelper.substituteTokens(
+                partiallyResolvedPattern, tokenValues);
 
             Map newCriteria = new HashMap(criteria);
             newCriteria.put(token, values[i]);
@@ -325,7 +326,9 @@
             } else if (noMd && "module".equals(token)) {
                 newCriteria.put("artifact", values[i]);
             }
-            result.addAll(resolveTokenValues((String[]) tokenSet.toArray(new String[tokenSet.size()]),
moreResolvedPattern, newCriteria, noMd));
+            result.addAll(resolveTokenValues(
+                (String[]) tokenSet.toArray(new String[tokenSet.size()]), 
+                moreResolvedPattern, newCriteria, noMd));
         }
 
         return result;



Mime
View raw message