Top Description Methods
com.google.protobuf

public Interface MessageLiteOrBuilder

Known Direct Subinterfaces
com.google.protobuf.MessageOrBuilder, com.google.protobuf.GeneratedMessageLite.ExtendableMessageOrBuilder, com.google.protobuf.MessageLite, com.google.protobuf.MessageLite.Builder

Base interface for methods common to MessageLite and MessageLite.Builder to provide type equivalency.
Author
[email protected] (Jon Perlow)

Method Summary

Modifier and TypeMethod and Description
public MessageLite
getDefaultInstanceForType()

Get an instance of the type with no fields set.

public boolean
isInitialized()

Returns true if all required fields in the message and all embedded messages are set, false otherwise.

Method Detail

getDefaultInstanceForTypeback to summary
public MessageLite getDefaultInstanceForType()

Get an instance of the type with no fields set. Because no fields are set, all getters for singular fields will return default values and repeated fields will appear empty. This may or may not be a singleton. This differs from the getDefaultInstance() method of generated message classes in that this method is an abstract method of the MessageLite interface whereas getDefaultInstance() is a static method of a specific class. They return the same thing.

isInitializedback to summary
public boolean isInitialized()

Returns true if all required fields in the message and all embedded messages are set, false otherwise.

See also: MessageOrBuilder#getInitializationErrorString()