public class

SetSchemaResponse.MigrationFailure

extends java.lang.Object

 java.lang.Object

↳androidx.appsearch.app.SetSchemaResponse.MigrationFailure

Overview

The class represents a post-migrated GenericDocument that failed to be saved by AppSearchSession.setSchema(SetSchemaRequest).

Summary

Constructors
publicMigrationFailure(java.lang.String namespace, java.lang.String documentId, java.lang.String schemaType, AppSearchResult<java.lang.Object> failedResult)

Constructs a new SetSchemaResponse.MigrationFailure.

Methods
public AppSearchResult<java.lang.Void>getAppSearchResult()

Returns the AppSearchResult that indicates why the post-migration GenericDocument failed to be indexed.

public BundlegetBundle()

Returns the Bundle of the SetSchemaResponse.MigrationFailure.

public java.lang.StringgetDocumentId()

Returns the id of the GenericDocument that failed to be migrated.

public java.lang.StringgetNamespace()

Returns the namespace of the GenericDocument that failed to be migrated.

public java.lang.StringgetSchemaType()

Returns the schema type of the GenericDocument that failed to be migrated.

public java.lang.StringtoString()

from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructors

public MigrationFailure(java.lang.String namespace, java.lang.String documentId, java.lang.String schemaType, AppSearchResult<java.lang.Object> failedResult)

Constructs a new SetSchemaResponse.MigrationFailure.

Parameters:

namespace: The namespace of the document which failed to be migrated.
documentId: The id of the document which failed to be migrated.
schemaType: The type of the document which failed to be migrated.
failedResult: The reason why the document failed to be indexed.

Methods

public Bundle getBundle()

Returns the Bundle of the SetSchemaResponse.MigrationFailure.

public java.lang.String getNamespace()

Returns the namespace of the GenericDocument that failed to be migrated.

public java.lang.String getDocumentId()

Returns the id of the GenericDocument that failed to be migrated.

public java.lang.String getSchemaType()

Returns the schema type of the GenericDocument that failed to be migrated.

public AppSearchResult<java.lang.Void> getAppSearchResult()

Returns the AppSearchResult that indicates why the post-migration GenericDocument failed to be indexed.

public java.lang.String toString()