Module: ElasticGraph::Apollo::SchemaDefinition::ApolloDirectives::InterfaceObject

Included in:
ObjectTypeExtension
Defined in:
elasticgraph-apollo/lib/elastic_graph/apollo/schema_definition/apollo_directives.rb

Overview

Supports Apollo’s @interfaceObject directive.

Instance Method Summary collapse

Instance Method Details

#apollo_interface_objectvoid

This method returns an undefined value.

Adds the @interfaceObject directive to the schema element.

Examples:

Add @interfaceObject to a type

ElasticGraph.define_schema do |schema|
  schema.object_type "Campaign" do |t|
    t.apollo_interface_object
  end
end


101
102
103
# File 'elasticgraph-apollo/lib/elastic_graph/apollo/schema_definition/apollo_directives.rb', line 101

def apollo_interface_object
  directive "interfaceObject"
end