me.wener.jraphql.lang.FragmentDefinition Maven / Gradle / Ivy
package me.wener.jraphql.lang;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonPOJOBuilder;
import java.util.Collections;
import java.util.List;
import lombok.Builder;
import lombok.NonNull;
import lombok.Value;
/**
* @author wener
* @since 16/03/2018
*/
@Value
@Builder(toBuilder = true)
@JsonDeserialize(builder = FragmentDefinition.FragmentDefinitionBuilder.class)
public class FragmentDefinition implements ExecutableDefinition {
@NonNull private SourceLocation sourceLocation;
@NonNull @Builder.Default private List comments = Collections.emptyList();
@NonNull private String name;
@NonNull private String typeCondition;
private SelectionSet selectionSet;
@NonNull @Builder.Default private List directives = Collections.emptyList();
public static class FragmentDefinitionBuilder
implements Builders.BuildDefinition,
Builders.BuildName,
Builders.BuildDirectives,
Builders.BuildTypeCondition,
Builders.BuildSelectionSet {}
}