juneau-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jamesbog...@apache.org
Subject [1/2] juneau git commit: BeanContext refactoring.
Date Sun, 07 Jan 2018 03:14:10 GMT
Repository: juneau
Updated Branches:
  refs/heads/master 4eaa07281 -> 3ce3bddda


http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/yaml/proto/YamlSerializerBuilder.java
----------------------------------------------------------------------
diff --git a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/yaml/proto/YamlSerializerBuilder.java
b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/yaml/proto/YamlSerializerBuilder.java
index b1db8be..5bf001a 100644
--- a/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/yaml/proto/YamlSerializerBuilder.java
+++ b/juneau-core/juneau-marshall/src/main/java/org/apache/juneau/yaml/proto/YamlSerializerBuilder.java
@@ -403,37 +403,25 @@ public class YamlSerializerBuilder extends SerializerBuilder {
 	}
 
 	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFilters(Class<?>...values) {
+	public YamlSerializerBuilder beanFilters(Object...values) {
 		super.beanFilters(values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFilters(Collection<Class<?>> values) {
+	public YamlSerializerBuilder beanFilters(Class<?>...values) {
 		super.beanFilters(values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFilters(boolean append, Class<?>...values) {
+	public YamlSerializerBuilder beanFilters(boolean append, Object...values) {
 		super.beanFilters(append, values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFilters(boolean append, Collection<Class<?>>
values) {
-		super.beanFilters(append, values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFiltersRemove(Class<?>...values) {
-		super.beanFiltersRemove(values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public YamlSerializerBuilder beanFiltersRemove(Collection<Class<?>> values)
{
+	public YamlSerializerBuilder beanFiltersRemove(Object...values) {
 		super.beanFiltersRemove(values);
 		return this;
 	}
@@ -529,6 +517,12 @@ public class YamlSerializerBuilder extends SerializerBuilder {
 	}
 
 	@Override /* BeanContextBuilder */
+	public YamlSerializerBuilder beanDictionary(Class<?>...values) {
+		super.beanDictionary(values);
+		return this;
+	}
+
+	@Override /* BeanContextBuilder */
 	public YamlSerializerBuilder beanDictionary(boolean append, Object...values) {
 		super.beanDictionary(append, values);
 		return this;

http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-rest/juneau-rest-client/src/main/java/org/apache/juneau/rest/client/RestClientBuilder.java
----------------------------------------------------------------------
diff --git a/juneau-rest/juneau-rest-client/src/main/java/org/apache/juneau/rest/client/RestClientBuilder.java
b/juneau-rest/juneau-rest-client/src/main/java/org/apache/juneau/rest/client/RestClientBuilder.java
index 1bb4166..28e4c7e 100644
--- a/juneau-rest/juneau-rest-client/src/main/java/org/apache/juneau/rest/client/RestClientBuilder.java
+++ b/juneau-rest/juneau-rest-client/src/main/java/org/apache/juneau/rest/client/RestClientBuilder.java
@@ -1348,37 +1348,19 @@ public class RestClientBuilder extends BeanContextBuilder {
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFilters(Class<?>...values) {
+	public RestClientBuilder beanFilters(Object...values) {
 		super.beanFilters(values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFilters(Collection<Class<?>> values) {
-		super.beanFilters(values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFilters(boolean append, Class<?>...values) {
-		super.beanFilters(append, values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFilters(boolean append, Collection<Class<?>> values)
{
+	public RestClientBuilder beanFilters(boolean append, Object...values) {
 		super.beanFilters(append, values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFiltersRemove(Class<?>...values) {
-		super.beanFiltersRemove(values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public RestClientBuilder beanFiltersRemove(Collection<Class<?>> values) {
+	public RestClientBuilder beanFiltersRemove(Object...values) {
 		super.beanFiltersRemove(values);
 		return this;
 	}
@@ -1474,6 +1456,12 @@ public class RestClientBuilder extends BeanContextBuilder {
 	}
 
 	@Override /* BeanContextBuilder */
+	public RestClientBuilder beanDictionary(Class<?>...values) {
+		super.beanDictionary(values);
+		return this;
+	}
+
+	@Override /* BeanContextBuilder */
 	public RestClientBuilder beanDictionary(boolean append, Object...values) {
 		super.beanDictionary(append, values);
 		return this;

http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestContextBuilder.java
----------------------------------------------------------------------
diff --git a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestContextBuilder.java
b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestContextBuilder.java
index 5e0416e..8552de6 100644
--- a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestContextBuilder.java
+++ b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestContextBuilder.java
@@ -198,7 +198,7 @@ public class RestContextBuilder extends BeanContextBuilder implements
ServletCon
 				converters(r.converters());
 				guards(reverse(r.guards()));
 				children(r.children());
-				beanFilters(r.beanFilters());
+				beanFilters((Object[])r.beanFilters());
 				pojoSwaps(r.pojoSwaps());
 				paramResolvers(r.paramResolvers());
 				if (r.serializerListener() != SerializerListener.Null.class)
@@ -2568,37 +2568,25 @@ public class RestContextBuilder extends BeanContextBuilder implements
ServletCon
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFilters(Class<?>...values) {
+	public RestContextBuilder beanFilters(Object...values) {
 		super.beanFilters(values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFilters(Collection<Class<?>> values) {
+	public RestContextBuilder beanFilters(Class<?>...values) {
 		super.beanFilters(values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFilters(boolean append, Class<?>...values) {
+	public RestContextBuilder beanFilters(boolean append, Object...values) {
 		super.beanFilters(append, values);
 		return this;
 	}
 
 	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFilters(boolean append, Collection<Class<?>> values)
{
-		super.beanFilters(append, values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFiltersRemove(Class<?>...values) {
-		super.beanFiltersRemove(values);
-		return this;
-	}
-
-	@Override /* BeanContextBuilder */
-	public RestContextBuilder beanFiltersRemove(Collection<Class<?>> values) {
+	public RestContextBuilder beanFiltersRemove(Object...values) {
 		super.beanFiltersRemove(values);
 		return this;
 	}
@@ -2694,6 +2682,12 @@ public class RestContextBuilder extends BeanContextBuilder implements
ServletCon
 	}
 
 	@Override /* BeanContextBuilder */
+	public RestContextBuilder beanDictionary(Class<?>...values) {
+		super.beanDictionary(values);
+		return this;
+	}
+
+	@Override /* BeanContextBuilder */
 	public RestContextBuilder beanDictionary(boolean append, Object...values) {
 		super.beanDictionary(append, values);
 		return this;

http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestJavaMethod.java
----------------------------------------------------------------------
diff --git a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestJavaMethod.java
b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestJavaMethod.java
index 194df12..db200fe 100644
--- a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestJavaMethod.java
+++ b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/RestJavaMethod.java
@@ -252,7 +252,7 @@ class RestJavaMethod implements Comparable<RestJavaMethod>  {
 					sgb.append(m.serializers());
 				
 					if (! inherit.contains("PROPERTIES"))
-						sgb.beanFilters(ps.getClassArrayProperty(BEAN_beanFilters)).pojoSwaps(ps.getClassArrayProperty(BEAN_pojoSwaps));
+						sgb.beanFilters((Object[])ps.getClassArrayProperty(BEAN_beanFilters)).pojoSwaps(ps.getClassArrayProperty(BEAN_pojoSwaps));
 					else
 						sgb.apply(ps);
 					for (Property p1 : m.properties())
@@ -285,21 +285,21 @@ class RestJavaMethod implements Comparable<RestJavaMethod>  {
 						}
 						sgb.excludeProperties(bpxMap);
 					}
-					sgb.beanFilters(m.beanFilters());
+					sgb.beanFilters((Object[])m.beanFilters());
 					sgb.pojoSwaps(m.pojoSwaps());
 				}
 
 				if (pgb != null) {
 					pgb.append(m.parsers());
 					if (! inherit.contains("PROPERTIES"))
-						pgb.beanFilters(ps.getClassArrayProperty(BEAN_beanFilters)).pojoSwaps(ps.getClassArrayProperty(BEAN_pojoSwaps));
+						pgb.beanFilters((Object[])ps.getClassArrayProperty(BEAN_beanFilters)).pojoSwaps(ps.getClassArrayProperty(BEAN_pojoSwaps));
 					else
 						pgb.apply(ps);
 					for (Property p1 : m.properties())
 						pgb.set(p1.name(), p1.value());
 					for (String p1 : m.flags())
 						pgb.set(p1, true);
-					pgb.beanFilters(m.beanFilters());
+					pgb.beanFilters((Object[])m.beanFilters());
 					pgb.pojoSwaps(m.pojoSwaps());
 				}
 
@@ -309,7 +309,7 @@ class RestJavaMethod implements Comparable<RestJavaMethod>  {
 						uepb.set(p1.name(), p1.value());
 					for (String p1 : m.flags())
 						uepb.set(p1, true);
-					uepb.beanFilters(m.beanFilters());
+					uepb.beanFilters((Object[])m.beanFilters());
 					uepb.pojoSwaps(m.pojoSwaps());
 				}
 				
@@ -319,7 +319,7 @@ class RestJavaMethod implements Comparable<RestJavaMethod>  {
 						bcb.set(p1.name(), p1.value());
 					for (String p1 : m.flags())
 						bcb.set(p1, true);
-					bcb.beanFilters(m.beanFilters());
+					bcb.beanFilters((Object[])m.beanFilters());
 					bcb.pojoSwaps(m.pojoSwaps());
 				}
 				

http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestMethod.java
----------------------------------------------------------------------
diff --git a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestMethod.java
b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestMethod.java
index 7d06033..d705e31 100644
--- a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestMethod.java
+++ b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestMethod.java
@@ -449,12 +449,9 @@ public @interface RestMethod {
 	 * 		</ul>
 	 * 	<li>Methods:
 	 * 		<ul>
-	 * 			<li>{@link RestContextBuilder#beanFilters(Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(Collection)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Collection)}
-	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Collection)}
+	 * 			<li>{@link RestContextBuilder#beanFilters(Object...)}
+	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Object...)}
+	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Object...)}
 	 * 		</ul>
 	 *	</ul>
 	 */

http://git-wip-us.apache.org/repos/asf/juneau/blob/3ce3bddd/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestResource.java
----------------------------------------------------------------------
diff --git a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestResource.java
b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestResource.java
index e017671..0b7ca1c 100644
--- a/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestResource.java
+++ b/juneau-rest/juneau-rest-server/src/main/java/org/apache/juneau/rest/annotation/RestResource.java
@@ -174,12 +174,9 @@ public @interface RestResource {
 	 * 		</ul>
 	 * 	<li>Methods:
 	 * 		<ul>
-	 * 			<li>{@link RestContextBuilder#beanFilters(Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(Collection)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Collection)}
-	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Class...)}
-	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Collection)}
+	 * 			<li>{@link RestContextBuilder#beanFilters(Object...)}
+	 * 			<li>{@link RestContextBuilder#beanFilters(boolean, Object...)}
+	 * 			<li>{@link RestContextBuilder#beanFiltersRemove(Object...)}
 	 * 		</ul>
 	 *	</ul>
 	 */


Mime
View raw message