Package com.google.protobuf

# Class TypeRegistry

java.lang.Object
com.google.protobuf.TypeRegistry

public class TypeRegistry extends Object
A TypeRegistry is used to resolve Any messages. You must provide a TypeRegistry containing all message types used in Any message fields.

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static final class`
`TypeRegistry.Builder`
A Builder is used to build `TypeRegistry`.

## Method Summary

Modifier and Type
Method
Description
`Descriptors.Descriptor`
`find(String name)`
Find a type by its full name.
`final Descriptors.Descriptor`
`getDescriptorForTypeUrl(String typeUrl)`
Find a type by its typeUrl.
`static TypeRegistry`
`getEmptyTypeRegistry()`
`static TypeRegistry.Builder`
`newBuilder()`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Method Details

### getEmptyTypeRegistry

public static TypeRegistry getEmptyTypeRegistry()

### newBuilder

public static TypeRegistry.Builder newBuilder()

### find

public Descriptors.Descriptor find(String name)
Find a type by its full name. Returns null if it cannot be found in this `TypeRegistry`.

### getDescriptorForTypeUrl

public final Descriptors.Descriptor getDescriptorForTypeUrl(String typeUrl) throws InvalidProtocolBufferException
Find a type by its typeUrl. Returns null if it cannot be found in this `TypeRegistry`.

Throws:
  `InvalidProtocolBufferException`