@Override
    public @NotNull PsiElement addArrayItem(@NotNull PsiElement array, @NotNull String itemValue) {
      if (array instanceof YAMLArrayImpl) {
        return addInlineArrayItem((YAMLSequence)array, itemValue);
      }
      else if (array instanceof YAMLSequence) {
        return addSequenceItem((YAMLSequence)array, itemValue);
      }
      else {
        throw new IllegalArgumentException("Cannot add item to a non-sequence element");
      }
    }
@Override
    public @NotNull PsiElement addArrayItem(@NotNull PsiElement array, @NotNull String itemValue)