camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1073282 - in /camel/trunk/camel-core/src: main/java/org/apache/camel/builder/ test/java/org/apache/camel/processor/interceptor/
Date Tue, 22 Feb 2011 10:19:58 GMT
Author: davsclaus
Date: Tue Feb 22 10:19:58 2011
New Revision: 1073282

URL: http://svn.apache.org/viewvc?rev=1073282&view=rev
Log:
CAMEL-3689: Renamed adviceByXX to weaveByXX

Modified:
    camel/trunk/camel-core/src/main/java/org/apache/camel/builder/AdviceWithRouteBuilder.java
    camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksMatchTest.java
    camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksTest.java
    camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksToStringPatternTest.java

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/builder/AdviceWithRouteBuilder.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/builder/AdviceWithRouteBuilder.java?rev=1073282&r1=1073281&r2=1073282&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/builder/AdviceWithRouteBuilder.java
(original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/builder/AdviceWithRouteBuilder.java
Tue Feb 22 10:19:58 2011
@@ -85,7 +85,7 @@ public abstract class AdviceWithRouteBui
     }
 
     /**
-     * Advices by matching id of the nodes in the route.
+     * Weaves by matching id of the nodes in the route.
      * <p/>
      * Uses the {@link org.apache.camel.util.EndpointHelper#matchPattern(String, String)}
matching algorithm.
      *
@@ -93,14 +93,14 @@ public abstract class AdviceWithRouteBui
      * @return the builder
      * @see org.apache.camel.util.EndpointHelper#matchPattern(String, String)
      */
-    public AdviceWithBuilder adviceById(String pattern) {
+    public AdviceWithBuilder weaveById(String pattern) {
         ObjectHelper.notNull(originalRoute, "originalRoute", this);
 
         return new AdviceWithBuilder(this, pattern, null);
     }
 
     /**
-     * Advices by matching the to string representation of the nodes in the route.
+     * Weaves by matching the to string representation of the nodes in the route.
      * <p/>
      * Uses the {@link org.apache.camel.util.EndpointHelper#matchPattern(String, String)}
matching algorithm.
      *
@@ -108,7 +108,7 @@ public abstract class AdviceWithRouteBui
      * @return the builder
      * @see org.apache.camel.util.EndpointHelper#matchPattern(String, String)
      */
-    public AdviceWithBuilder adviceByToString(String pattern) {
+    public AdviceWithBuilder weaveByToString(String pattern) {
         ObjectHelper.notNull(originalRoute, "originalRoute", this);
 
         return new AdviceWithBuilder(this, null, pattern);

Modified: camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksMatchTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksMatchTest.java?rev=1073282&r1=1073281&r2=1073282&view=diff
==============================================================================
--- camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksMatchTest.java
(original)
+++ camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksMatchTest.java
Tue Feb 22 10:19:58 2011
@@ -30,7 +30,7 @@ public class AdviceWithTasksMatchTest ex
             @Override
             public void configure() throws Exception {
                 // replace all gold id's with the following route path
-                adviceById("gold*").replace().multicast().to("mock:a").to("mock:b");
+                weaveById("gold*").replace().multicast().to("mock:a").to("mock:b");
             }
         });
 

Modified: camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksTest.java?rev=1073282&r1=1073281&r2=1073282&view=diff
==============================================================================
--- camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksTest.java
(original)
+++ camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksTest.java
Tue Feb 22 10:19:58 2011
@@ -30,7 +30,7 @@ public class AdviceWithTasksTest extends
             context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
                 @Override
                 public void configure() throws Exception {
-                    adviceById("xxx").replace().to("mock:xxx");
+                    weaveById("xxx").replace().to("mock:xxx");
                 }
             });
             fail("Should hve thrown exception");
@@ -44,9 +44,9 @@ public class AdviceWithTasksTest extends
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                // advice the node in the route which has id = bar
+                // weave the node in the route which has id = bar
                 // and replace it with the following route path
-                adviceById("bar").replace().multicast().to("mock:a").to("mock:b");
+                weaveById("bar").replace().multicast().to("mock:a").to("mock:b");
             }
         });
         // END SNIPPET: e1
@@ -67,8 +67,8 @@ public class AdviceWithTasksTest extends
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                // advice the node in the route which has id = bar and remove it
-                adviceById("bar").remove();
+                // weave the node in the route which has id = bar and remove it
+                weaveById("bar").remove();
             }
         });
         // END SNIPPET: e2
@@ -88,9 +88,9 @@ public class AdviceWithTasksTest extends
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                // advice the node in the route which has id = bar
+                // weave the node in the route which has id = bar
                 // and insert the following route path before the adviced node
-                adviceById("bar").before().to("mock:a").transform(constant("Bye World"));
+                weaveById("bar").before().to("mock:a").transform(constant("Bye World"));
             }
         });
         // END SNIPPET: e3
@@ -110,9 +110,9 @@ public class AdviceWithTasksTest extends
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                // advice the node in the route which has id = bar
+                // weave the node in the route which has id = bar
                 // and insert the following route path after the advice node
-                adviceById("bar").after().to("mock:a").transform(constant("Bye World"));
+                weaveById("bar").after().to("mock:a").transform(constant("Bye World"));
             }
         });
         // END SNIPPET: e4

Modified: camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksToStringPatternTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksToStringPatternTest.java?rev=1073282&r1=1073281&r2=1073282&view=diff
==============================================================================
--- camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksToStringPatternTest.java
(original)
+++ camel/trunk/camel-core/src/test/java/org/apache/camel/processor/interceptor/AdviceWithTasksToStringPatternTest.java
Tue Feb 22 10:19:58 2011
@@ -30,7 +30,7 @@ public class AdviceWithTasksToStringPatt
             context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
                 @Override
                 public void configure() throws Exception {
-                    adviceByToString("xxx").replace().to("mock:xxx");
+                    weaveByToString("xxx").replace().to("mock:xxx");
                 }
             });
             fail("Should hve thrown exception");
@@ -44,9 +44,9 @@ public class AdviceWithTasksToStringPatt
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                // advice nodes in the route which has foo anywhere in their to string representation
+                // weave nodes in the route which has foo anywhere in their to string representation
                 // and replace them with the following route path
-                adviceByToString(".*foo.*").replace().multicast().to("mock:a").to("mock:b");
+                weaveByToString(".*foo.*").replace().multicast().to("mock:a").to("mock:b");
             }
         });
         // END SNIPPET: e1
@@ -66,7 +66,7 @@ public class AdviceWithTasksToStringPatt
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                adviceByToString(".*bar.*").remove();
+                weaveByToString(".*bar.*").remove();
             }
         });
 
@@ -84,7 +84,7 @@ public class AdviceWithTasksToStringPatt
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                adviceByToString(".*bar.*").before().to("mock:a").transform(constant("Bye
World"));
+                weaveByToString(".*bar.*").before().to("mock:a").transform(constant("Bye
World"));
             }
         });
 
@@ -102,7 +102,7 @@ public class AdviceWithTasksToStringPatt
         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
             @Override
             public void configure() throws Exception {
-                adviceByToString(".*bar.*").after().to("mock:a").transform(constant("Bye
World"));
+                weaveByToString(".*bar.*").after().to("mock:a").transform(constant("Bye World"));
             }
         });
 



Mime
View raw message