target.apidocs.com.google.api.services.sheets.v4.model.DataValidationRule.html Maven / Gradle / Ivy
DataValidationRule (Google Sheets API v4-rev20230526-2.0.0)
com.google.api.services.sheets.v4.model
Class DataValidationRule
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.sheets.v4.model.DataValidationRule
-
public final class DataValidationRule
extends com.google.api.client.json.GenericJson
A data validation rule.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Google Sheets API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
DataValidationRule()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
DataValidationRule
clone()
BooleanCondition
getCondition()
The condition that data in the cell must match.
String
getInputMessage()
A message to show the user when adding data to the cell.
Boolean
getShowCustomUi()
True if the UI should be customized based on the kind of condition.
Boolean
getStrict()
True if invalid data should be rejected.
DataValidationRule
set(String fieldName,
Object value)
DataValidationRule
setCondition(BooleanCondition condition)
The condition that data in the cell must match.
DataValidationRule
setInputMessage(String inputMessage)
A message to show the user when adding data to the cell.
DataValidationRule
setShowCustomUi(Boolean showCustomUi)
True if the UI should be customized based on the kind of condition.
DataValidationRule
setStrict(Boolean strict)
True if invalid data should be rejected.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getCondition
public BooleanCondition getCondition()
The condition that data in the cell must match.
- Returns:
- value or
null
for none
-
setCondition
public DataValidationRule setCondition(BooleanCondition condition)
The condition that data in the cell must match.
- Parameters:
condition
- condition or null
for none
-
getInputMessage
public String getInputMessage()
A message to show the user when adding data to the cell.
- Returns:
- value or
null
for none
-
setInputMessage
public DataValidationRule setInputMessage(String inputMessage)
A message to show the user when adding data to the cell.
- Parameters:
inputMessage
- inputMessage or null
for none
-
getShowCustomUi
public Boolean getShowCustomUi()
True if the UI should be customized based on the kind of condition. If true, "List" conditions
will show a dropdown.
- Returns:
- value or
null
for none
-
setShowCustomUi
public DataValidationRule setShowCustomUi(Boolean showCustomUi)
True if the UI should be customized based on the kind of condition. If true, "List" conditions
will show a dropdown.
- Parameters:
showCustomUi
- showCustomUi or null
for none
-
getStrict
public Boolean getStrict()
True if invalid data should be rejected.
- Returns:
- value or
null
for none
-
setStrict
public DataValidationRule setStrict(Boolean strict)
True if invalid data should be rejected.
- Parameters:
strict
- strict or null
for none
-
set
public DataValidationRule set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public DataValidationRule clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2023 Google. All rights reserved.