Package graphql.language
Class SourceLocation
java.lang.Object
graphql.language.SourceLocation
- All Implemented Interfaces:
Serializable
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionSourceLocation
(int line, int column) SourceLocation
(int line, int column, String sourceName) -
Method Summary
Modifier and TypeMethodDescriptionboolean
int
int
getLine()
static SourceLocation
getLocation
(GraphQLSchemaElement schemaElement) This method can returnSourceLocation
that help create the given schema element.int
hashCode()
toString()
-
Field Details
-
EMPTY
-
-
Constructor Details
-
SourceLocation
public SourceLocation(int line, int column) -
SourceLocation
-
-
Method Details
-
getLine
public int getLine() -
getColumn
public int getColumn() -
getSourceName
-
equals
-
hashCode
public int hashCode() -
toString
-
getLocation
This method can returnSourceLocation
that help create the given schema element. If the schema is created from input files andSchemaGenerator.Options.isCaptureAstDefinitions()
is set to true then schema elements contain a reference to theSourceLocation
that helped create that runtime schema element.- Parameters:
schemaElement
- the schema element- Returns:
- the source location if available or null if it's not.
-