AAI-1523 Batch reformat aai-core
[aai/aai-common.git] / aai-core / src / main / java / org / onap / aai / introspection / MarshallerProperties.java
index 2824dbb..776b07e 100644 (file)
  * limitations under the License.
  * ============LICENSE_END=========================================================
  */
+
 package org.onap.aai.introspection;
 
 import org.onap.aai.restcore.MediaType;
 
 public class MarshallerProperties {
 
-       private final MediaType type;
-       private final boolean includeRoot;
-       private final boolean wrapperAsArrayName;
-       private final boolean formatted;
-       
-       /**
-        * Instantiates a new marshaller properties.
-        *
-        * @param builder the builder
-        */
-       private MarshallerProperties(Builder builder) {
-               
-               this.type = builder.type;
-               this.includeRoot = builder.includeRoot;
-               this.wrapperAsArrayName = builder.wrapperAsArrayName;
-               this.formatted = builder.formatted;
-       }
-       
-       /**
-        * Gets the media type.
-        *
-        * @return the media type
-        */
-       public MediaType getMediaType() {
-               return this.type;
-       }
-       
-       /**
-        * Gets the include root.
-        *
-        * @return the include root
-        */
-       public boolean getIncludeRoot() {
-               return this.includeRoot;
-       }
-       
-       /**
-        * Gets the wrapper as array name.
-        *
-        * @return the wrapper as array name
-        */
-       public boolean getWrapperAsArrayName() {
-               return this.wrapperAsArrayName;
-       }
-       
-       /**
-        * Gets the formatted.
-        *
-        * @return the formatted
-        */
-       public boolean getFormatted() {
-               return this.formatted;
-       }
-       
-       public static class Builder {
-               
-               private final MediaType type;
-               private boolean includeRoot = false;
-               private boolean wrapperAsArrayName = true;
-               private boolean formatted = false;
-               
-               /**
-                * Instantiates a new builder.
-                *
-                * @param type the type
-                */
-               public Builder(MediaType type) {
-                       this.type = type;
-               }
-               
-               /**
-                * Include root.
-                *
-                * @param includeRoot the include root
-                * @return the builder
-                */
-               public Builder includeRoot (boolean includeRoot) {
-                       this.includeRoot = includeRoot;
-                       return this;
-               }
-               
-               /**
-                * Wrapper as array name.
-                *
-                * @param wrapperAsArrayName the wrapper as array name
-                * @return the builder
-                */
-               public Builder wrapperAsArrayName (boolean wrapperAsArrayName) {
-                       this.wrapperAsArrayName = wrapperAsArrayName;
-                       return this;
-               }
-               
-               /**
-                * Formatted.
-                *
-                * @param formatted the formatted
-                * @return the builder
-                */
-               public Builder formatted (boolean formatted) {
-                       this.formatted = formatted;
-                       return this;
-               }
-               
-               /**
-                * Builds the properties.
-                *
-                * @return the marshaller properties
-                */
-               public MarshallerProperties build() {
-                       return new MarshallerProperties(this);
-               }
-       }
+    private final MediaType type;
+    private final boolean includeRoot;
+    private final boolean wrapperAsArrayName;
+    private final boolean formatted;
+
+    /**
+     * Instantiates a new marshaller properties.
+     *
+     * @param builder the builder
+     */
+    private MarshallerProperties(Builder builder) {
+
+        this.type = builder.type;
+        this.includeRoot = builder.includeRoot;
+        this.wrapperAsArrayName = builder.wrapperAsArrayName;
+        this.formatted = builder.formatted;
+    }
+
+    /**
+     * Gets the media type.
+     *
+     * @return the media type
+     */
+    public MediaType getMediaType() {
+        return this.type;
+    }
+
+    /**
+     * Gets the include root.
+     *
+     * @return the include root
+     */
+    public boolean getIncludeRoot() {
+        return this.includeRoot;
+    }
+
+    /**
+     * Gets the wrapper as array name.
+     *
+     * @return the wrapper as array name
+     */
+    public boolean getWrapperAsArrayName() {
+        return this.wrapperAsArrayName;
+    }
+
+    /**
+     * Gets the formatted.
+     *
+     * @return the formatted
+     */
+    public boolean getFormatted() {
+        return this.formatted;
+    }
+
+    public static class Builder {
+
+        private final MediaType type;
+        private boolean includeRoot = false;
+        private boolean wrapperAsArrayName = true;
+        private boolean formatted = false;
+
+        /**
+         * Instantiates a new builder.
+         *
+         * @param type the type
+         */
+        public Builder(MediaType type) {
+            this.type = type;
+        }
+
+        /**
+         * Include root.
+         *
+         * @param includeRoot the include root
+         * @return the builder
+         */
+        public Builder includeRoot(boolean includeRoot) {
+            this.includeRoot = includeRoot;
+            return this;
+        }
+
+        /**
+         * Wrapper as array name.
+         *
+         * @param wrapperAsArrayName the wrapper as array name
+         * @return the builder
+         */
+        public Builder wrapperAsArrayName(boolean wrapperAsArrayName) {
+            this.wrapperAsArrayName = wrapperAsArrayName;
+            return this;
+        }
+
+        /**
+         * Formatted.
+         *
+         * @param formatted the formatted
+         * @return the builder
+         */
+        public Builder formatted(boolean formatted) {
+            this.formatted = formatted;
+            return this;
+        }
+
+        /**
+         * Builds the properties.
+         *
+         * @return the marshaller properties
+         */
+        public MarshallerProperties build() {
+            return new MarshallerProperties(this);
+        }
+    }
 }