首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >端点法中的堆栈溢出错误

端点法中的堆栈溢出错误
EN

Stack Overflow用户
提问于 2016-06-30 12:32:13
回答 1查看 81关注 0票数 0

我正在开发一个使用端点的google应用程序引擎驱动的android应用程序,在我正在编写的api中,我一直没有明显的理由得到堆栈溢出错误。

到目前为止,这里是我的端点api类中的两个方法:

代码语言:javascript
复制
@ApiMethod(name = "saveProfile")
public Profile saveProfile(@Named("userId") String userId,
                               @Named("firstName") String firstName,
                               @Named("lastName") String lastName,
                               @Named("birthday") String birthday) {

        Profile profile = ofy().load().key(Key.create(Profile.class, userId)).now();
        if (profile == null) {
            profile = new Profile(userId, firstName, lastName, birthday);
        } else {
            profile.updateProfile(firstName, lastName, birthday);
        }
        ofy().save().entity(profile).now();
        return profile;
    }

@ApiMethod(name = "getSuggestedFriends")
public List<Profile> getSuggestedFriends(@Named("userId") String userId) {

    Profile profile = ofy().load().key(Key.create(Profile.class, userId)).now();
    if (profile != null) {
        /**
         * Queries for users with same last name as you (presumably family).
         */
        Query<Profile> sameLastName = ofy().load().type(Profile.class).order("birthday");
        sameLastName = sameLastName.filter("lastName =", profile.getLastName());

        /**
         * Gets the friends of your friends.
         */
        List<Profile> suggestedFriends = new ArrayList<>(0);
        for (Profile friend : profile.getFriends()) {
            for (Profile friendOfFriend : friend.getFriends()) {
                if (!profile.getFriends().contains(friendOfFriend))
                    suggestedFriends.add(friendOfFriend);
            }
        }

        /**
         * Merge the 2 lists into 1 list of suggested friends.
         */
        for (Profile suggestedFriend : sameLastName) {
            if (!profile.getFriends().contains(suggestedFriend))
                suggestedFriends.add(suggestedFriend);
        }
        return suggestedFriends;
    } else
        return null;
}

有人能提供一些洞察力和解决方案,为什么会发生这种情况?

编辑:

大多数堆栈跟踪(它非常长):

代码语言:javascript
复制
java.lang.StackOverflowError
    at java.util.AbstractCollection.toArray(AbstractCollection.java:176)
    at sun.reflect.annotation.AnnotationParser.toArray(AnnotationParser.java:865)
    at java.lang.reflect.Field.getDeclaredAnnotations(Field.java:1139)
    at java.lang.reflect.AccessibleObject.getAnnotations(AccessibleObject.java:207)
    at com.googlecode.objectify.impl.FieldProperty.<init>(FieldProperty.java:36)
    at com.googlecode.objectify.impl.KeyMetadata.findKeyFields(KeyMetadata.java:77)
    at com.googlecode.objectify.impl.KeyMetadata.<init>(KeyMetadata.java:50)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:64)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.ClassPopulator.<init>(ClassPopulator.java:88)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.createEntityClassTranslator(ClassTranslatorFactory.java:66)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:48)
    at com.googlecode.objectify.impl.translate.ClassTranslatorFactory.create(ClassTranslatorFactory.java:36)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)
    at com.googlecode.objectify.impl.translate.Translators.get(Translators.java:117)
    at com.googlecode.objectify.impl.translate.CreateContext.getTranslator(CreateContext.java:27)
    at com.googlecode.objectify.impl.translate.CollectionTranslatorFactory.create(CollectionTranslatorFactory.java:38)
    at com.googlecode.objectify.impl.translate.Translators.create(Translators.java:138)

干杯。

EN

回答 1

Stack Overflow用户

发布于 2020-04-02 04:28:57

这种情况就是这样的:

代码语言:javascript
复制
public class Entity
{
    private List<Entity> children;
}

根据您的情况,您可以尝试“序列化”孩子。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/38123192

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档