target.apidocs.com.google.api.services.directory.model.SchemaFieldSpec.html Maven / Gradle / Ivy
SchemaFieldSpec (Admin SDK API directory_v1-rev20220125-1.32.1)
com.google.api.services.directory.model
Class SchemaFieldSpec
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.directory.model.SchemaFieldSpec
-
public final class SchemaFieldSpec
extends GenericJson
You can use schemas to add custom fields to user profiles. You can use these fields to store
information such as the projects your users work on, their physical locations, their hire dates,
or whatever else fits your business needs. For more information, see [Custom User Fields](/admin-
sdk/directory/v1/guides/manage-schemas).
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 Admin SDK 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
Modifier and Type
Class and Description
static class
SchemaFieldSpec.NumericIndexingSpec
Indexing spec for a numeric field.
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
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
SchemaFieldSpec()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
SchemaFieldSpec
clone()
String
getDisplayName()
Display Name of the field.
String
getEtag()
The ETag of the field.
String
getFieldId()
The unique identifier of the field (Read-only)
String
getFieldName()
The name of the field.
String
getFieldType()
The type of the field.
Boolean
getIndexed()
Boolean specifying whether the field is indexed or not.
String
getKind()
The kind of resource this is.
Boolean
getMultiValued()
A boolean specifying whether this is a multi-valued field or not.
SchemaFieldSpec.NumericIndexingSpec
getNumericIndexingSpec()
Indexing spec for a numeric field.
String
getReadAccessType()
Specifies who can view values of this field.
boolean
isIndexed()
Convenience method that returns only Boolean.TRUE
or Boolean.FALSE
.
SchemaFieldSpec
set(String fieldName,
Object value)
SchemaFieldSpec
setDisplayName(String displayName)
Display Name of the field.
SchemaFieldSpec
setEtag(String etag)
The ETag of the field.
SchemaFieldSpec
setFieldId(String fieldId)
The unique identifier of the field (Read-only)
SchemaFieldSpec
setFieldName(String fieldName)
The name of the field.
SchemaFieldSpec
setFieldType(String fieldType)
The type of the field.
SchemaFieldSpec
setIndexed(Boolean indexed)
Boolean specifying whether the field is indexed or not.
SchemaFieldSpec
setKind(String kind)
The kind of resource this is.
SchemaFieldSpec
setMultiValued(Boolean multiValued)
A boolean specifying whether this is a multi-valued field or not.
SchemaFieldSpec
setNumericIndexingSpec(SchemaFieldSpec.NumericIndexingSpec numericIndexingSpec)
Indexing spec for a numeric field.
SchemaFieldSpec
setReadAccessType(String readAccessType)
Specifies who can view values of this field.
-
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
-
getDisplayName
public String getDisplayName()
Display Name of the field.
- Returns:
- value or
null
for none
-
setDisplayName
public SchemaFieldSpec setDisplayName(String displayName)
Display Name of the field.
- Parameters:
displayName
- displayName or null
for none
-
getEtag
public String getEtag()
The ETag of the field.
- Returns:
- value or
null
for none
-
setEtag
public SchemaFieldSpec setEtag(String etag)
The ETag of the field.
- Parameters:
etag
- etag or null
for none
-
getFieldId
public String getFieldId()
The unique identifier of the field (Read-only)
- Returns:
- value or
null
for none
-
setFieldId
public SchemaFieldSpec setFieldId(String fieldId)
The unique identifier of the field (Read-only)
- Parameters:
fieldId
- fieldId or null
for none
-
getFieldName
public String getFieldName()
The name of the field.
- Returns:
- value or
null
for none
-
setFieldName
public SchemaFieldSpec setFieldName(String fieldName)
The name of the field.
- Parameters:
fieldName
- fieldName or null
for none
-
getFieldType
public String getFieldType()
The type of the field.
- Returns:
- value or
null
for none
-
setFieldType
public SchemaFieldSpec setFieldType(String fieldType)
The type of the field.
- Parameters:
fieldType
- fieldType or null
for none
-
getIndexed
public Boolean getIndexed()
Boolean specifying whether the field is indexed or not. Default: `true`.
- Returns:
- value or
null
for none
-
setIndexed
public SchemaFieldSpec setIndexed(Boolean indexed)
Boolean specifying whether the field is indexed or not. Default: `true`.
- Parameters:
indexed
- indexed or null
for none
-
isIndexed
public boolean isIndexed()
Convenience method that returns only Boolean.TRUE
or Boolean.FALSE
.
Boolean properties can have four possible values:
null
, Data.NULL_BOOLEAN
, Boolean.TRUE
or Boolean.FALSE
.
This method returns Boolean.TRUE
if the default of the property is Boolean.TRUE
and it is null
or Data.NULL_BOOLEAN
.
Boolean.FALSE
is returned if the default of the property is Boolean.FALSE
and
it is null
or Data.NULL_BOOLEAN
.
Boolean specifying whether the field is indexed or not. Default: `true`.
-
getKind
public String getKind()
The kind of resource this is. For schema fields this is always
`admin#directory#schema#fieldspec`.
- Returns:
- value or
null
for none
-
setKind
public SchemaFieldSpec setKind(String kind)
The kind of resource this is. For schema fields this is always
`admin#directory#schema#fieldspec`.
- Parameters:
kind
- kind or null
for none
-
getMultiValued
public Boolean getMultiValued()
A boolean specifying whether this is a multi-valued field or not. Default: `false`.
- Returns:
- value or
null
for none
-
setMultiValued
public SchemaFieldSpec setMultiValued(Boolean multiValued)
A boolean specifying whether this is a multi-valued field or not. Default: `false`.
- Parameters:
multiValued
- multiValued or null
for none
-
getNumericIndexingSpec
public SchemaFieldSpec.NumericIndexingSpec getNumericIndexingSpec()
Indexing spec for a numeric field. By default, only exact match queries will be supported for
numeric fields. Setting the `numericIndexingSpec` allows range queries to be supported.
- Returns:
- value or
null
for none
-
setNumericIndexingSpec
public SchemaFieldSpec setNumericIndexingSpec(SchemaFieldSpec.NumericIndexingSpec numericIndexingSpec)
Indexing spec for a numeric field. By default, only exact match queries will be supported for
numeric fields. Setting the `numericIndexingSpec` allows range queries to be supported.
- Parameters:
numericIndexingSpec
- numericIndexingSpec or null
for none
-
getReadAccessType
public String getReadAccessType()
Specifies who can view values of this field. See [Retrieve users as a non-administrator
](/admin-sdk/directory/v1/guides/manage-users#retrieve_users_non_admin) for more information.
Note: It may take up to 24 hours for changes to this field to be reflected.
- Returns:
- value or
null
for none
-
setReadAccessType
public SchemaFieldSpec setReadAccessType(String readAccessType)
Specifies who can view values of this field. See [Retrieve users as a non-administrator
](/admin-sdk/directory/v1/guides/manage-users#retrieve_users_non_admin) for more information.
Note: It may take up to 24 hours for changes to this field to be reflected.
- Parameters:
readAccessType
- readAccessType or null
for none
-
set
public SchemaFieldSpec set(String fieldName,
Object value)
- Overrides:
set
in class GenericJson
-
clone
public SchemaFieldSpec clone()
- Overrides:
clone
in class GenericJson
Copyright © 2011–2022 Google. All rights reserved.