# Print output for @column tags ?>
public
static
class
SetSchemaResponse.MigrationFailure
extends Object
| java.lang.Object | |
| ↳ | android.app.appsearch.SetSchemaResponse.MigrationFailure |
The class represents a post-migrated GenericDocument that failed to be saved by
AppSearchSession#setSchema.
Public constructors | |
|---|---|
MigrationFailure(String namespace, String documentId, String schemaType, AppSearchResult<?> failedResult)
Constructs a new |
|
Public methods | |
|---|---|
AppSearchResult<Void>
|
getAppSearchResult()
Returns the |
String
|
getDocumentId()
Returns the id of the |
String
|
getNamespace()
Returns the namespace of the |
String
|
getSchemaType()
Returns the schema type of the |
String
|
toString()
Returns a string representation of the object. |
Inherited methods | |
|---|---|
public MigrationFailure (String namespace, String documentId, String schemaType, AppSearchResult<?> failedResult)
Constructs a new MigrationFailure.
| Parameters | |
|---|---|
namespace |
String: The namespace of the document which failed to be migrated.
This value cannot be null. |
documentId |
String: The id of the document which failed to be migrated.
This value cannot be null. |
schemaType |
String: The type of the document which failed to be migrated.
This value cannot be null. |
failedResult |
AppSearchResult: The reason why the document failed to be indexed.
This value cannot be null. |
| Throws | |
|---|---|
IllegalArgumentException |
if the provided failedResult was not a failure. |
public AppSearchResult<Void> getAppSearchResult ()
Returns the AppSearchResult that indicates why the post-migration GenericDocument failed to be indexed.
| Returns | |
|---|---|
AppSearchResult<Void> |
This value cannot be null. |
public String getDocumentId ()
Returns the id of the GenericDocument that failed to be migrated.
| Returns | |
|---|---|
String |
This value cannot be null. |
public String getNamespace ()
Returns the namespace of the GenericDocument that failed to be migrated.
| Returns | |
|---|---|
String |
This value cannot be null. |
public String getSchemaType ()
Returns the schema type of the GenericDocument that failed to be migrated.
| Returns | |
|---|---|
String |
This value cannot be null. |
public String toString ()
Returns a string representation of the object. In general, the
toString method returns a string that
"textually represents" this object. The result should
be a concise but informative representation that is easy for a
person to read.
It is recommended that all subclasses override this method.
The toString method for class Object
returns a string consisting of the name of the class of which the
object is an instance, the at-sign character `@', and
the unsigned hexadecimal representation of the hash code of the
object. In other words, this method returns a string equal to the
value of:
getClass().getName() + '@' + Integer.toHexString(hashCode())
| Returns | |
|---|---|
String |
This value cannot be null. |