All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.odftoolkit.odfdom.dom.element.table.TableCalculationSettingsElement Maven / Gradle / Ivy

/************************************************************************
 *
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER
 *
 * Copyright 2008, 2010 Oracle and/or its affiliates. All rights reserved.
 *
 * Use is subject to license terms.
 *
 * 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. You can also
 * obtain a copy of the License at http://odftoolkit.org/docs/license.txt
 *
 * 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.
 *
 ************************************************************************/

/*
 * This file is automatically generated.
 * Don't edit manually.
 */
package org.odftoolkit.odfdom.dom.element.table;

import org.odftoolkit.odfdom.pkg.OdfElement;
import org.odftoolkit.odfdom.pkg.ElementVisitor;
import org.odftoolkit.odfdom.pkg.OdfFileDom;
import org.odftoolkit.odfdom.pkg.OdfName;
import org.odftoolkit.odfdom.dom.OdfDocumentNamespace;
import org.odftoolkit.odfdom.dom.DefaultElementVisitor;
import org.odftoolkit.odfdom.dom.attribute.table.TableAutomaticFindLabelsAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TableCaseSensitiveAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TableNullYearAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TablePrecisionAsShownAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TableSearchCriteriaMustApplyToWholeCellAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TableUseRegularExpressionsAttribute;
import org.odftoolkit.odfdom.dom.attribute.table.TableUseWildcardsAttribute;

/**
 * DOM implementation of OpenDocument element  {@odf.element table:calculation-settings}.
 *
 */
public class TableCalculationSettingsElement extends OdfElement {

	public static final OdfName ELEMENT_NAME = OdfName.newName(OdfDocumentNamespace.TABLE, "calculation-settings");

	/**
	 * Create the instance of TableCalculationSettingsElement
	 *
	 * @param  ownerDoc     The type is OdfFileDom
	 */
	public TableCalculationSettingsElement(OdfFileDom ownerDoc) {
		super(ownerDoc, ELEMENT_NAME);
	}

	/**
	 * Get the element name
	 *
	 * @return  return   OdfName the name of element {@odf.element table:calculation-settings}.
	 */
	public OdfName getOdfName() {
		return ELEMENT_NAME;
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableAutomaticFindLabelsAttribute , See {@odf.attribute table:automatic-find-labels}
	 *
	 * @return - the Boolean , the value or null, if the attribute is not set and no default value defined.
	 */
	public Boolean getTableAutomaticFindLabelsAttribute() {
		TableAutomaticFindLabelsAttribute attr = (TableAutomaticFindLabelsAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "automatic-find-labels");
		if (attr != null) {
			return Boolean.valueOf(attr.booleanValue());
		}
		return Boolean.valueOf(TableAutomaticFindLabelsAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableAutomaticFindLabelsAttribute , See {@odf.attribute table:automatic-find-labels}
	 *
	 * @param tableAutomaticFindLabelsValue   The type is Boolean
	 */
	public void setTableAutomaticFindLabelsAttribute(Boolean tableAutomaticFindLabelsValue) {
		TableAutomaticFindLabelsAttribute attr = new TableAutomaticFindLabelsAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setBooleanValue(tableAutomaticFindLabelsValue.booleanValue());
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableCaseSensitiveAttribute , See {@odf.attribute table:case-sensitive}
	 *
	 * @return - the String , the value or null, if the attribute is not set and no default value defined.
	 */
	public String getTableCaseSensitiveAttribute() {
		TableCaseSensitiveAttribute attr = (TableCaseSensitiveAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "case-sensitive");
		if (attr != null) {
			return String.valueOf(attr.getValue());
		}
		return TableCaseSensitiveAttribute.DEFAULT_VALUE_TRUE;
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableCaseSensitiveAttribute , See {@odf.attribute table:case-sensitive}
	 *
	 * @param tableCaseSensitiveValue   The type is String
	 */
	public void setTableCaseSensitiveAttribute(String tableCaseSensitiveValue) {
		TableCaseSensitiveAttribute attr = new TableCaseSensitiveAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setValue(tableCaseSensitiveValue);
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableNullYearAttribute , See {@odf.attribute table:null-year}
	 *
	 * @return - the Integer , the value or null, if the attribute is not set and no default value defined.
	 */
	public Integer getTableNullYearAttribute() {
		TableNullYearAttribute attr = (TableNullYearAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "null-year");
		if (attr != null) {
			return Integer.valueOf(attr.intValue());
		}
		return Integer.valueOf(TableNullYearAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableNullYearAttribute , See {@odf.attribute table:null-year}
	 *
	 * @param tableNullYearValue   The type is Integer
	 */
	public void setTableNullYearAttribute(Integer tableNullYearValue) {
		TableNullYearAttribute attr = new TableNullYearAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setIntValue(tableNullYearValue.intValue());
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TablePrecisionAsShownAttribute , See {@odf.attribute table:precision-as-shown}
	 *
	 * @return - the Boolean , the value or null, if the attribute is not set and no default value defined.
	 */
	public Boolean getTablePrecisionAsShownAttribute() {
		TablePrecisionAsShownAttribute attr = (TablePrecisionAsShownAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "precision-as-shown");
		if (attr != null) {
			return Boolean.valueOf(attr.booleanValue());
		}
		return Boolean.valueOf(TablePrecisionAsShownAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TablePrecisionAsShownAttribute , See {@odf.attribute table:precision-as-shown}
	 *
	 * @param tablePrecisionAsShownValue   The type is Boolean
	 */
	public void setTablePrecisionAsShownAttribute(Boolean tablePrecisionAsShownValue) {
		TablePrecisionAsShownAttribute attr = new TablePrecisionAsShownAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setBooleanValue(tablePrecisionAsShownValue.booleanValue());
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableSearchCriteriaMustApplyToWholeCellAttribute , See {@odf.attribute table:search-criteria-must-apply-to-whole-cell}
	 *
	 * @return - the Boolean , the value or null, if the attribute is not set and no default value defined.
	 */
	public Boolean getTableSearchCriteriaMustApplyToWholeCellAttribute() {
		TableSearchCriteriaMustApplyToWholeCellAttribute attr = (TableSearchCriteriaMustApplyToWholeCellAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "search-criteria-must-apply-to-whole-cell");
		if (attr != null) {
			return Boolean.valueOf(attr.booleanValue());
		}
		return Boolean.valueOf(TableSearchCriteriaMustApplyToWholeCellAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableSearchCriteriaMustApplyToWholeCellAttribute , See {@odf.attribute table:search-criteria-must-apply-to-whole-cell}
	 *
	 * @param tableSearchCriteriaMustApplyToWholeCellValue   The type is Boolean
	 */
	public void setTableSearchCriteriaMustApplyToWholeCellAttribute(Boolean tableSearchCriteriaMustApplyToWholeCellValue) {
		TableSearchCriteriaMustApplyToWholeCellAttribute attr = new TableSearchCriteriaMustApplyToWholeCellAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setBooleanValue(tableSearchCriteriaMustApplyToWholeCellValue.booleanValue());
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableUseRegularExpressionsAttribute , See {@odf.attribute table:use-regular-expressions}
	 *
	 * @return - the Boolean , the value or null, if the attribute is not set and no default value defined.
	 */
	public Boolean getTableUseRegularExpressionsAttribute() {
		TableUseRegularExpressionsAttribute attr = (TableUseRegularExpressionsAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "use-regular-expressions");
		if (attr != null) {
			return Boolean.valueOf(attr.booleanValue());
		}
		return Boolean.valueOf(TableUseRegularExpressionsAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableUseRegularExpressionsAttribute , See {@odf.attribute table:use-regular-expressions}
	 *
	 * @param tableUseRegularExpressionsValue   The type is Boolean
	 */
	public void setTableUseRegularExpressionsAttribute(Boolean tableUseRegularExpressionsValue) {
		TableUseRegularExpressionsAttribute attr = new TableUseRegularExpressionsAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setBooleanValue(tableUseRegularExpressionsValue.booleanValue());
	}

	/**
	 * Receives the value of the ODFDOM attribute representation TableUseWildcardsAttribute , See {@odf.attribute table:use-wildcards}
	 *
	 * @return - the Boolean , the value or null, if the attribute is not set and no default value defined.
	 */
	public Boolean getTableUseWildcardsAttribute() {
		TableUseWildcardsAttribute attr = (TableUseWildcardsAttribute) getOdfAttribute(OdfDocumentNamespace.TABLE, "use-wildcards");
		if (attr != null) {
			return Boolean.valueOf(attr.booleanValue());
		}
		return Boolean.valueOf(TableUseWildcardsAttribute.DEFAULT_VALUE);
	}

	/**
	 * Sets the value of ODFDOM attribute representation TableUseWildcardsAttribute , See {@odf.attribute table:use-wildcards}
	 *
	 * @param tableUseWildcardsValue   The type is Boolean
	 */
	public void setTableUseWildcardsAttribute(Boolean tableUseWildcardsValue) {
		TableUseWildcardsAttribute attr = new TableUseWildcardsAttribute((OdfFileDom) this.ownerDocument);
		setOdfAttribute(attr);
		attr.setBooleanValue(tableUseWildcardsValue.booleanValue());
	}

	/**
	 * Create child element {@odf.element table:iteration}.
	 *
	 * @return the element {@odf.element table:iteration}
	 */
	public TableIterationElement newTableIterationElement() {
		TableIterationElement tableIteration = ((OdfFileDom) this.ownerDocument).newOdfElement(TableIterationElement.class);
		this.appendChild(tableIteration);
		return tableIteration;
	}

	/**
	 * Create child element {@odf.element table:null-date}.
	 *
	 * @return the element {@odf.element table:null-date}
	 */
	public TableNullDateElement newTableNullDateElement() {
		TableNullDateElement tableNullDate = ((OdfFileDom) this.ownerDocument).newOdfElement(TableNullDateElement.class);
		this.appendChild(tableNullDate);
		return tableNullDate;
	}

	@Override
	public void accept(ElementVisitor visitor) {
		if (visitor instanceof DefaultElementVisitor) {
			DefaultElementVisitor defaultVisitor = (DefaultElementVisitor) visitor;
			defaultVisitor.visit(this);
		} else {
			visitor.visit(this);
		}
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy