Returns a MapType for type. @throws IllegalArgumentException if type is not a Map type
(TypeMirror type)
| 126 | * @throws IllegalArgumentException if {@code type} is not a {@link Map} type |
| 127 | */ |
| 128 | static MapType from(TypeMirror type) { |
| 129 | checkArgument(isMap(type), "%s is not a Map", type); |
| 130 | return new AutoValue_MapType(MoreTypes.equivalence().wrap(MoreTypes.asDeclared(type))); |
| 131 | } |
| 132 | |
| 133 | /** |
| 134 | * Returns a {@link MapType} for {@code key}'s {@link Key#type() type}. |