Module: ElasticGraph::Warehouse::SchemaDefinition::FactoryExtension Private

Defined in:
elasticgraph-warehouse/lib/elastic_graph/warehouse/schema_definition/factory_extension.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Extension module applied to ElasticGraph::SchemaDefinition::Factory to add warehouse field type support.

Instance Method Summary collapse

Instance Method Details

#new_enum_type(name) {|ElasticGraph::SchemaDefinition::SchemaElements::EnumType| ... } ⇒ ElasticGraph::SchemaDefinition::SchemaElements::EnumType

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Creates a new enum type with warehouse extensions.

Parameters:

  • name (String)

    the name of the enum type

Yields:

Returns:



25
26
27
28
29
30
31
32
# File 'elasticgraph-warehouse/lib/elastic_graph/warehouse/schema_definition/factory_extension.rb', line 25

def new_enum_type(name)
  super(name) do |type|
    type.extend EnumTypeExtension
    # :nocov: -- currently all invocations have a block
    yield type if block_given?
    # :nocov:
  end
end

#new_interface_type(name) {|ElasticGraph::SchemaDefinition::SchemaElements::InterfaceType| ... } ⇒ ElasticGraph::SchemaDefinition::SchemaElements::InterfaceType

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Creates a new interface type with warehouse extensions.

Parameters:

  • name (String)

    the name of the interface type

Yields:

Returns:



39
40
41
42
43
44
45
46
# File 'elasticgraph-warehouse/lib/elastic_graph/warehouse/schema_definition/factory_extension.rb', line 39

def new_interface_type(name)
  super(name) do |type|
    type.extend ObjectAndInterfaceExtension
    # :nocov: -- currently all invocations have a block
    yield type if block_given?
    # :nocov:
  end
end

#new_object_type(name) {|ElasticGraph::SchemaDefinition::SchemaElements::ObjectType| ... } ⇒ ElasticGraph::SchemaDefinition::SchemaElements::ObjectType

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Creates a new object type with warehouse extensions.

Parameters:

  • name (String)

    the name of the object type

Yields:

Returns:



53
54
55
56
57
58
59
60
# File 'elasticgraph-warehouse/lib/elastic_graph/warehouse/schema_definition/factory_extension.rb', line 53

def new_object_type(name)
  super(name) do |type|
    type.extend ObjectAndInterfaceExtension
    # :nocov: -- currently all invocations have a block
    yield type if block_given?
    # :nocov:
  end
end

#new_scalar_type(name) {|ElasticGraph::SchemaDefinition::SchemaElements::ScalarType| ... } ⇒ ElasticGraph::SchemaDefinition::SchemaElements::ScalarType

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Creates a new scalar type with warehouse extensions.

Parameters:

  • name (String)

    the name of the scalar type

Yields:

Returns:



67
68
69
70
71
72
73
74
# File 'elasticgraph-warehouse/lib/elastic_graph/warehouse/schema_definition/factory_extension.rb', line 67

def new_scalar_type(name)
  super(name) do |type|
    type.extend ScalarTypeExtension
    # :nocov: -- currently all invocations have a block
    yield type if block_given?
    # :nocov:
  end
end