|
Class: StreamWrapper (in XML)
Object
|
+--Link
|
+--XML::StreamWrapper
- Package:
- stx:goodies/xml/vw
- Category:
- XML-VW-Parsing
- Version:
- rev:
1.39
date: 2023/10/23 15:29:44
- user: stefan
- file: StreamWrapper.st directory: goodies/xml/vw
- module: stx stc-classLibrary: vw
This class is used by the XMLParser to wrap both internal and external streams with proper encoding before handing them to the parser for processing
Instance Variables:
stream <EncodedStream> stream being wrapped
isInternal <Boolean> true if the stream is internal and hencer doesn't need careful line-end treatment
protocol <String> name of stream type, 'internal' or 'file'
name <String | nil> the name of the stream, if it is named
usedAsExternal <Boolean> flag used to override protocol and say how stream is being used?
entity <Entity | nil> if wrapping on behalf of an Entity this is it?
cr <Character> cache of Character cr
lf <Character> cache of Character lf
instance creation
-
emptyWithExtraSpace: space
-
-
stream: str protocol: key name: value entity: entity
-
accessing
-
characterSize: aCharacter
-
return the number of bytes required to encode aCharacter
-
checkEncoding
-
Look for UTF-8 or UTF-16 BOM and set the encoded stream accordingly.
-
close
-
-
column
-
-
column: something
-
-
entity
-
-
line
-
-
line: something
-
-
name
-
-
protocol
-
-
stream
-
declaration
-
encodingDeclIn: aParser
-
ok, the stream is already unicode or decoding to unicode, so ignore the encoding: directive
-
expected: string
-
-
mustFind: str errorOn: aParser
-
-
quotedString
-
-
sdDeclIn: aParser
-
-
skipIf: str
-
-
skipSpaceIn: aParser
-
-
textDeclIn: aParser
-
-
versionInfoIn: aParser
-
-
xmlDeclIn: aParser
-
Modified (format): / 23-02-2022 / 00:42:39 / cg
initialization
-
stream: str protocol: key name: value entity: ent
-
-
usedAsExternal
-
-
usedAsExternal: aBoolean
-
private
-
error: aStringOrMessage
-
(comment from inherited method)
Raise an error with error message aString.
The error is reported by raising the Error exception,
which is non-proceedable.
If no handler has been setup, a debugger is entered.
streaming
-
nextFor: aParser
-
@Commented by Stefan Vogel at: 2023-10-23 17:14 Reason: ascii is never 0 here - see above
-
skip: count
-
testing
-
atEnd
-
|