if (type instanceof CfmlCompositeElementType) {
return ((CfmlCompositeElementType)type).createPsiElement(node);
}
else if (type == CfmlElementTypes.COMPONENT_DEFINITION) {
return new CfmlComponentImpl(node);
}
else if (type == CfmlElementTypes.COMPONENT_TAG) {
return new CfmlTagComponentImpl(node);
}
throw new AssertionError("Unknown type: " + type);