/*******************************************************************************
 * Copyright 2017 julien@squidsolutions.com
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *******************************************************************************/
package com.squid.kraken.v4.model;

import com.google.gson.annotations.SerializedName;

import io.swagger.annotations.ApiModelProperty;

/**
 * a Rollup allows to specify which dimension to use for the sub-total level. The dimension is defined by its indice in the analysis job, starting at 0. In order to compute a grand-total, use indice -1. It is also possible to define how to sort sub-total using the position, default to FIRST.
 */

public class RollUp extends Base  {
	@SerializedName("col")
	private Integer col = null;

	/**
	 * define how to sort the sub-total, either before the detailled data (FIRST) or after (LAST)
	 */
	public enum PositionEnum {
		@SerializedName("FIRST")
		FIRST("FIRST"),

		@SerializedName("LAST")
		LAST("LAST");

		private String value;

		PositionEnum(String value) {
			this.value = value;
		}

		@Override
		public String toString() {
			return String.valueOf(value);
		}
	}

	@SerializedName("position")
	private PositionEnum position = null;

	public RollUp col(Integer col) {
		this.col = col;
		return this;
	}

	/**
	 * the indice of the dimension to rollup on, or -1 to compute a grand-total.
	 * @return col
	 **/
	@ApiModelProperty(example = "0", value = "the indice of the dimension to rollup on, or -1 to compute a grand-total.")
	public Integer getCol() {
		return col;
	}

	public void setCol(Integer col) {
		this.col = col;
	}

	public RollUp position(PositionEnum position) {
		this.position = position;
		return this;
	}

	/**
	 * define how to sort the sub-total, either before the detailled data (FIRST) or after (LAST)
	 * @return position
	 **/
	@ApiModelProperty(example = "FIRST", value = "define how to sort the sub-total, either before the detailled data (FIRST) or after (LAST)")
	public PositionEnum getPosition() {
		return position;
	}

	public void setPosition(PositionEnum position) {
		this.position = position;
	}

}


@@ -976,16 +976,19 @@
 l level.
+%0A *
  The dim
@@ -1057,16 +1057,19 @@
 at 0. In
+%0A *
  order t
@@ -1133,24 +1133,27 @@
 le to define
+%0A *
  how to sort
@@ -1239,17 +1239,16 @@
 ds Base 
- 
 %7B%0A%09@Seri
@@ -1295,16 +1295,53 @@
  null;%0A%0A
+%09private boolean complementaryAxes;%0A%0A
 %09/**%0A%09 *
@@ -1399,32 +1399,36 @@
 e detailled data
+%0A%09 *
  (FIRST) or afte
@@ -1947,16 +1947,21 @@
 -total.%0A
+%09 * %0A
 %09 * @ret
@@ -2358,32 +2358,36 @@
 e detailled data
+%0A%09 *
  (FIRST) or afte
@@ -2395,16 +2395,21 @@
  (LAST)%0A
+%09 * %0A
 %09 * @ret
@@ -2709,11 +2709,195 @@
 on;%0A%09%7D%0A%0A
+%09public boolean isComplementaryAxes() %7B%0A%09%09return complementaryAxes;%0A%09%7D%0A%0A%09public void setComplementaryAxes(boolean complementaryAxes) %7B%0A%09%09this.complementaryAxes = complementaryAxes;%0A%09%7D%0A%0A
 %7D%0A
-%0A

Add missing property