com.google.appengine.api.datastore

## Class ExtendableEntityUtil

- java.lang.Object
- - com.google.appengine.api.datastore.ExtendableEntityUtil

-     public final class ExtendableEntityUtil
      extends java.lang.Object

  Internal class that provides utility methods for `ExtendableEntity` objects.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `areKeysEqual(Key key1, Key key2)` Check if the input `Key` objects are equal (including keys that are incomplete).
    `static void` | `checkSupportedValue(java.lang.String propertyName, java.lang.Object value, boolean valuePreChecked, java.util.Set<java.lang.Class<?>> supportedTypes)` If the specified object cannot be used as the value for a `Entity` property, throw an exception with the appropriate explanation.
    `static Key` | `createKey(Key parent, java.lang.String kind)` Creates a new `Key` with the provided parent and kind.

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

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

- - ### Method Detail

    - #### createKey

          public static Key createKey(Key parent,
                      java.lang.String kind)

      Creates a new `Key` with the provided parent and kind. The instantiated will be incomplete.
      Parameters:
        `parent` - the parent of the key to create, can be `null`
        `kind` - the kind of the key to create

    - #### areKeysEqual

          public static boolean areKeysEqual(Key key1,
                             Key key2)

      Check if the input `Key` objects are equal (including keys that are incomplete).
      Parameters:
        `key1` - the first input key
        `key2` - the second input key
      Returns:
        `true` if the keys are equal. `false` otherwise.

    - #### checkSupportedValue

          public static void checkSupportedValue(java.lang.String propertyName,
                                 java.lang.Object value,
                                 boolean valuePreChecked,
                                 java.util.Set<java.lang.Class<?>> supportedTypes)

      If the specified object cannot be used as the value for a `Entity` property, throw an exception with the appropriate explanation.
      Parameters:
        `propertyName` - the name of the property.
        `value` - value in question
        `supportedTypes` - the types considered to be valid types for the value.
        `valuePreChecked` - `true` if the value without the name has already been checked. `false` otherwise.
      Throws:
        `java.lang.IllegalArgumentException` - if the type is not supported, or if the object is in some other way invalid.