Method: GraphQL::Schema::Member::BaseDSLMethods#graphql_name
- Defined in:
- lib/graphql/schema/member/base_dsl_methods.rb
#graphql_name(new_name = nil) ⇒ String
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.
Call this with a new name to override the default name for this schema member; OR call it without an argument to get the name of this schema member
The default name is implemented in default_graphql_name
20 21 22 23 24 25 26 27 |
# File 'lib/graphql/schema/member/base_dsl_methods.rb', line 20 def graphql_name(new_name = nil) if new_name GraphQL::NameValidator.validate!(new_name) @graphql_name = new_name else @graphql_name ||= default_graphql_name end end |