PropertyDefinedNode


@ExperimentalAppSearchApi
class PropertyDefinedNode : FunctionNode


FunctionNode representing the `propertyDefined` query function.

The `propertyDefined` query function will return all documents of types that define the given property. This will include documents that do not have the property itself, so long as that property is a part of the document's schema.

If you need to restrict to documents that have >=1 value(s) populated for that property, see HasPropertyNode.

Summary

Public constructors

Constructor for a PropertyDefinedNode representing the query function `propertyDefined` that takes in a PropertyPath.

Public functions

String

Returns the name of the function represented by PropertyDefinedNode.

PropertyPath

Returns the PropertyDefinedNode representing the property being checked for in the document.

Unit

Sets the property being checked for in the document, as represented by PropertyDefinedNode.

Inherited Constants

From androidx.appsearch.ast.FunctionNode
const String!
FUNCTION_NAME_GET_SEARCH_STRING_PARAMETER = "getSearchStringParameter"

Name of the query function represented by androidx.appsearch.ast.query.GetSearchStringParameterNode.

const String!

Name of the query function represented by androidx.appsearch.ast.query.HasPropertyNode.

const String!
FUNCTION_NAME_PROPERTY_DEFINED = "propertyDefined"

Name of the query function represented by androidx.appsearch.ast.query.PropertyDefinedNode.

Inherited functions

From androidx.appsearch.ast.Node
(Mutable)List<Node!>

Get a list of the node's child Nodes.

Public constructors

PropertyDefinedNode

Added in 1.1.0-alpha06
PropertyDefinedNode(property: PropertyPath)

Constructor for a PropertyDefinedNode representing the query function `propertyDefined` that takes in a PropertyPath.

Public functions

getFunctionName

Added in 1.1.0-alpha06
fun getFunctionName(): String

Returns the name of the function represented by PropertyDefinedNode.

getProperty

Added in 1.1.0-alpha06
fun getProperty(): PropertyPath

Returns the PropertyDefinedNode representing the property being checked for in the document.

setProperty

Added in 1.1.0-alpha06
fun setProperty(property: PropertyPath): Unit

Sets the property being checked for in the document, as represented by PropertyDefinedNode.