|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.gjt.sp.jedit.io.BufferLocalEncodingDetector
public class BufferLocalEncodingDetector
An encoding detector which finds buffer-local-property syntax. This reads the sample in the system default encoding for first 10 lines and look for ":encoding=..." syntax. This can fail if the stream cannot be read in the system default encoding or ":encoding=..." is not placed at near the top of the stream.
| Constructor Summary | |
|---|---|
BufferLocalEncodingDetector()
|
|
| Method Summary | |
|---|---|
java.lang.String |
detectEncoding(java.io.InputStream sample)
Returns the name of a detected encoding for the bytes in sample. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BufferLocalEncodingDetector()
| Method Detail |
|---|
public java.lang.String detectEncoding(java.io.InputStream sample)
throws java.io.IOException
EncodingDetector
detectEncoding in interface EncodingDetectorjava.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||