webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Classes | Public Member Functions | Static Public Member Functions | List of all members
com.google.protobuf.MapField< K, V > Class Template Reference

Inherits com.google.protobuf.MutabilityOracle.

Public Member Functions

Map< K, V > getMap ()
 
Map< K, V > getMutableMap ()
 
void mergeFrom (MapField< K, V > other)
 
void clear ()
 
boolean equals (Object object)
 
int hashCode ()
 
MapField< K, V > copy ()
 
void makeImmutable ()
 
boolean isMutable ()
 
void ensureMutable ()
 

Static Public Member Functions

static< K, V > MapField< K, V > emptyMapField (MapEntry< K, V > defaultEntry)
 
static< K, V > MapField< K, V > newMapField (MapEntry< K, V > defaultEntry)
 

Detailed Description

Internal representation of map fields in generated messages.

This class supports accessing the map field as a Map to be used in generated API and also supports accessing the field as a List to be used in reflection API. It keeps track of where the data is currently stored and do necessary conversions between map and list.

This class is a protobuf implementation detail. Users shouldn't use this class directly.

THREAD-SAFETY NOTE: Read-only access is thread-safe. Users can call getMap() and getList() concurrently in multiple threads. If write-access is needed, all access must be synchronized.

Member Function Documentation

◆ clear()

void com.google.protobuf.MapField< K, V >.clear ( )
inline

◆ copy()

MapField<K, V> com.google.protobuf.MapField< K, V >.copy ( )
inline

Returns a deep copy of this MapField.

◆ emptyMapField()

static <K, V> MapField<K, V> com.google.protobuf.MapField< K, V >.emptyMapField ( MapEntry< K, V >  defaultEntry)
inlinestatic

Returns an immutable empty MapField.

◆ ensureMutable()

void com.google.protobuf.MapField< K, V >.ensureMutable ( )
inline

◆ equals()

boolean com.google.protobuf.MapField< K, V >.equals ( Object  object)
inline

◆ getMap()

Map<K, V> com.google.protobuf.MapField< K, V >.getMap ( )
inline

Returns the content of this MapField as a read-only Map.

◆ getMutableMap()

Map<K, V> com.google.protobuf.MapField< K, V >.getMutableMap ( )
inline

Gets a mutable Map view of this MapField.

◆ hashCode()

int com.google.protobuf.MapField< K, V >.hashCode ( void  )
inline

◆ isMutable()

boolean com.google.protobuf.MapField< K, V >.isMutable ( )
inline

Returns whether this field can be modified.

◆ makeImmutable()

void com.google.protobuf.MapField< K, V >.makeImmutable ( )
inline

Makes this list immutable. All subsequent modifications will throw an UnsupportedOperationException.

◆ mergeFrom()

void com.google.protobuf.MapField< K, V >.mergeFrom ( MapField< K, V >  other)
inline

◆ newMapField()

static <K, V> MapField<K, V> com.google.protobuf.MapField< K, V >.newMapField ( MapEntry< K, V >  defaultEntry)
inlinestatic

Creates a new mutable empty MapField.


The documentation for this class was generated from the following file: