public String getName() {
        ASTNode node;
        if (this instanceof SdImportFieldDefinition) {
            ASTNode asNode = this.getNode().findChildByType(SdTypes.AS);
            node = this.getNode().findChildByType(SdTypes.IDENTIFIER_VAL, asNode);
        } else if (this instanceof SdRankProfileDefinition || this instanceof SdDocumentSummaryDefinition
                   || this instanceof SdRankFeature) {
            node = this.getNode().findChildByType(SdTypes.IDENTIFIER_WITH_DASH_VAL);
        } else {
            node = this.getNode().findChildByType(SdTypes.IDENTIFIER_VAL);
        }
        if (node != null) {
            return node.getText();
        } else {
            return "";
        }
    }
This abstract class is used to wrap a Psi Element with SdNamedElement interface, which enables the element to be a
"name owner" (like an identifier). It allows the element to take a part in references, find usages and more.

@author Shahar Ariel
integration/intellij/src/main/java/ai/vespa/intellij/schema/psi/impl/SdNamedElementImpl.java