+ private Set<String> excludes = new HashSet<String>();\r
+ \r
+ public Set<String> getExcludes() {\r
+ return excludes;\r
+ }\r
+\r
+ /**\r
+ * This method allows supplying a List of property names to be ignored\r
+ * during the serialization to JSON. The <code>excludes</code> will be\r
+ * merged with the property names configured by subclasses which override\r
+ * {@link {@link #getIgnorePropNames()}.\r
+ * \r
+ * @param excludes\r
+ */\r
+ public void setExcludes(Set<String> excludes) {\r
+ this.excludes = excludes;\r
+ }\r
+ \r
+ /**\r
+ * Implementations of this abstract class may override this method in order\r
+ * to supply a List of property names to be ignored in\r
+ * {@link #processBean(Object, JsonConfig)}. This feature generally is used\r
+ * when {@link #processBeanSecondStep(CdmBase, JSONObject, JsonConfig)} is\r
+ * implemented. such that this method is responsible of serializing this\r
+ * property.\r
+ * \r
+ * @return a List of property names.\r
+ */\r
+ public abstract List<String> getIgnorePropNames();\r
+ \r
+ /**\r
+ * merges and returns {@link {@link #getIgnorePropNames()} with\r
+ * {@link #excludes}\r
+ * \r
+ * @return\r
+ */\r
+ protected Set<String> getMergedExcludes(){\r
+ Set<String> mergedExcludes = new HashSet<String>(excludes);\r
+ if(getIgnorePropNames() != null){\r
+ mergedExcludes.addAll(getIgnorePropNames()); \r
+ }\r
+ return mergedExcludes;\r
+ }\r
+\r