org.eclipse.core.internal.resources
Class CharsetManager
java.lang.Object
org.eclipse.core.internal.resources.CharsetManager
- All Implemented Interfaces:
- IManager
public class CharsetManager
- extends java.lang.Object
- implements IManager
Manages user-defined encodings as preferences in the project content area.
- Since:
- 3.0
Method Summary |
java.lang.String |
getCharsetFor(org.eclipse.core.runtime.IPath resourcePath,
boolean recurse)
Returns the charset explicitly set by the user for the given resource,
or null . |
void |
projectPreferencesChanged(IProject project)
|
void |
setCharsetFor(org.eclipse.core.runtime.IPath resourcePath,
java.lang.String newCharset)
|
void |
shutdown(org.eclipse.core.runtime.IProgressMonitor monitor)
|
void |
startup(org.eclipse.core.runtime.IProgressMonitor monitor)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ENCODING_PREF_NODE
public static final java.lang.String ENCODING_PREF_NODE
- See Also:
- Constant Field Values
CharsetManager
public CharsetManager(Workspace workspace)
getCharsetFor
public java.lang.String getCharsetFor(org.eclipse.core.runtime.IPath resourcePath,
boolean recurse)
- Returns the charset explicitly set by the user for the given resource,
or
null
. If no setting exists for the given resource and
recurse
is true
, every parent up to the
workspace root will be checked until a charset setting can be found.
- Parameters:
resourcePath
- the path for the resourcerecurse
- whether the parent should be queried
- Returns:
- the charset setting for the given resource
projectPreferencesChanged
public void projectPreferencesChanged(IProject project)
setCharsetFor
public void setCharsetFor(org.eclipse.core.runtime.IPath resourcePath,
java.lang.String newCharset)
throws org.eclipse.core.runtime.CoreException
- Throws:
org.eclipse.core.runtime.CoreException
shutdown
public void shutdown(org.eclipse.core.runtime.IProgressMonitor monitor)
- Specified by:
shutdown
in interface IManager
startup
public void startup(org.eclipse.core.runtime.IProgressMonitor monitor)
- Specified by:
startup
in interface IManager