Skip to content

AutoValue abstract class problem #1

@dominikmicuta

Description

@dominikmicuta

In implementation of ClassElementAdapter there is a check for

if (Modifier.isAbstract(rawType.getModifiers())) {
    throw new IllegalArgumentException("Cannot serialize abstract class " + rawType.getName());
}

is this necessary? Autovalue model with SoupAdapter annotation is throwing exception.

Unless correct adapter is provided by SoupAdapter Annotation than this should be handled by user.
Also interfaces dont make sence until user define correct adapter.
Or am I missing something?

Manual creation with Jsouper.Builder is working fine for our abstract model classes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions