code: @SuppressWarnings("rawtypes")
    public static BaseEntity marshal(DefaultEntityManager entityManager, Object entity,
        Intent intent) {
      Marshaller marshaller = new Marshaller(entityManager, entity, intent);
      return marshaller.marshal();
    }
docs: Marshals the given entity (POJO) into the format needed for the low level Cloud Datastore API.
  
  @param entityManager
  the entity manager
  @param entity
  the entity to marshal
  @param intent
  the intent or purpose of marshalling. Marshalling process varies slightly depending on
  the purpose. For example, if the purpose if INSERT or UPSERT, the marshaller would
  auto generate any keys. Where as if the purpose is UPDATE, then then marshaller will
  NOT generate any keys.
  @return the marshaled object