SportsOrganization.BuilderBase


@ExperimentalAppSearchApi
public class SportsOrganization.BuilderBase<T extends SportsOrganization.BuilderBase<T>> extends Organization.BuilderBase

Known indirect subclasses

Builder for SportsOrganization.

Summary

Public constructors

BuilderBase(@NonNull SportsOrganization sportsOrganization)

Constructor for SportsOrganization.BuilderBase with all the existing values.

BuilderBase(
    @NonNull String namespace,
    @NonNull String id,
    @NonNull String sport
)

Constructor for SportsOrganization.BuilderBase.

Public methods

@NonNull SportsOrganization

Builds a Thing object.

@NonNull T

Sets the accent color of the sports organization as a Color.

Inherited methods

From androidx.appsearch.builtintypes.Organization.BuilderBase
@NonNull T

Sets the logo of the organization.

From androidx.appsearch.builtintypes.Thing.BuilderBase
@NonNull T

Adds an alias for the item.

@NonNull T

Add a new action to the list of potential actions for this document.

@NonNull Thing

Builds a Thing object.

@NonNull T

Clears the aliases, if any, for the item.

@NonNull T

Clear all the potential actions for this document.

void

If built, make a copy of previous data for every field so that the builder can be reused.

@NonNull T

Sets a list of aliases for the item.

@NonNull T
setCreationTimestampMillis(long creationTimestampMillis)

Sets the creation timestamp for the current AppSearch entity, in milliseconds using the currentTimeMillis time base.

@NonNull T

Sets the description for the item.

@NonNull T
setDocumentScore(int documentScore)

Sets the user-provided opaque document score of the current AppSearch document, which can be used for ranking using RANKING_STRATEGY_DOCUMENT_SCORE.

@NonNull T
setDocumentTtlMillis(long documentTtlMillis)

Sets the time-to-live (TTL) for the current AppSearch document as a duration in milliseconds.

@NonNull T

Sets the URL for an image of the item.

@NonNull T

Sets the name of the item.

@NonNull T

Sets a list of potential actions for this document.

@NonNull T

Sets the deeplink URL of the item.

Public constructors

BuilderBase

Added in 1.2.0-alpha02
public BuilderBase(@NonNull SportsOrganization sportsOrganization)

Constructor for SportsOrganization.BuilderBase with all the existing values.

Parameters
@NonNull SportsOrganization sportsOrganization

The existing SportsOrganization to copy values from.

BuilderBase

Added in 1.2.0-alpha02
public BuilderBase(
    @NonNull String namespace,
    @NonNull String id,
    @NonNull String sport
)

Constructor for SportsOrganization.BuilderBase.

Parameters
@NonNull String namespace

Namespace for the Document. See Document.Namespace.

@NonNull String id

The unique identifier for the Document.

@NonNull String sport

The sport of the sports organization.

Public methods

build

public @NonNull SportsOrganization build()

Builds a Thing object.

setAccentColor

Added in 1.2.0-alpha02
public @NonNullsetAccentColor(@Nullable Color accentColor)

Sets the accent color of the sports organization as a Color.

Parameters
@Nullable Color accentColor

The accent color of the sports organization.