GraphQL\Type\Definition\InterfaceType::getField PHP Method

getField() public method

public getField ( $name ) : FieldDefinition
$name
return FieldDefinition
    public function getField($name)
    {
        if (null === $this->fields) {
            $this->getFields();
        }
        Utils::invariant(isset($this->fields[$name]), 'Field "%s" is not defined for type "%s"', $name, $this->name);
        return $this->fields[$name];
    }