Safe Haskell | None |
---|
- type HeaderSet = [Header]
- data Context
- newContext :: Size -> IO Context
- data DecodeError = IndexOverrun Index
- printContext :: Context -> IO ()
- clearHeaderSet :: Context -> Context
- getHeaderSet :: Context -> HeaderSet
- emitNotEmitted :: Context -> IO Context
- clearRefSets :: Context -> IO Context
- removeRef :: Context -> Index -> IO Context
- newEntry :: Context -> Entry -> IO Context
- pushRef :: Context -> Index -> Entry -> IO Context
- emitOnly :: Context -> Header -> IO Context
- isPresentIn :: Index -> Context -> Bool
- getEntry :: Index -> Context -> IO Entry
- whichTable :: Index -> Context -> IO (WhichTable, Entry)
- lookupHeader :: Header -> Context -> IO HeaderCache
Types
newContext :: Size -> IO ContextSource
Creating a new Context
.
The first argument is the size of HeaderTable
.
printContext :: Context -> IO ()Source
Printing Context
Initialization and final results
getHeaderSet :: Context -> HeaderSetSource
Getting HeaderSet
as emitted headers.
emitNotEmitted :: Context -> IO ContextSource
Emitting non-emitted headers.
Processing
clearRefSets :: Context -> IO ContextSource
The reference set is emptied.
newEntry :: Context -> Entry -> IO ContextSource
The header field is emitted. The header field is inserted at the beginning of the header table. A reference to the new entry is added to the reference set.
pushRef :: Context -> Index -> Entry -> IO ContextSource
The header field corresponding to the referenced entry is emitted. The referenced header table entry is added to the reference set.
Auxiliary functions
Table
whichTable :: Index -> Context -> IO (WhichTable, Entry)Source
Which table does Index
refer to?
lookupHeader :: Header -> Context -> IO HeaderCacheSource
Which table contains Header
?