diff --git a/platform/projectModel-api/src/com/intellij/ide/highlighter/ProjectFileType.java b/platform/projectModel-api/src/com/intellij/ide/highlighter/ProjectFileType.java index 6b01887419a0..171247a1a9f1 100644 --- a/platform/projectModel-api/src/com/intellij/ide/highlighter/ProjectFileType.java +++ b/platform/projectModel-api/src/com/intellij/ide/highlighter/ProjectFileType.java @@ -1,30 +1,16 @@ -/* - * Copyright 2000-2015 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ +// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.ide.highlighter; import com.intellij.icons.AllIcons; import com.intellij.openapi.fileTypes.InternalFileType; -import com.intellij.openapi.vfs.CharsetToolkit; import com.intellij.openapi.vfs.VirtualFile; import com.intellij.projectModel.ProjectModelBundle; import org.jetbrains.annotations.NotNull; import javax.swing.*; +import java.nio.charset.StandardCharsets; -public class ProjectFileType implements InternalFileType { +public final class ProjectFileType implements InternalFileType { public static final ProjectFileType INSTANCE = new ProjectFileType(); public static final String DEFAULT_EXTENSION = "ipr"; @@ -66,7 +52,7 @@ public class ProjectFileType implements InternalFileType { } @Override - public String getCharset(@NotNull VirtualFile file, final byte @NotNull [] content) { - return CharsetToolkit.UTF8; + public String getCharset(@NotNull VirtualFile file, byte @NotNull [] content) { + return StandardCharsets.UTF_8.name(); } } \ No newline at end of file