webpg.inline

Handles all inline GPG/PGP data found on content pages

Summary
webpg.inlineHandles all inline GPG/PGP data found on content pages
Functions
initSets up the context and calls the PGPDataSearch method to find PGP data in the page.
PGPDataSearchSearches the document for elements that contain PGP Data blocks.
ignoreInnersAvoids detection of PGP blocks found inside of other PGP blocks.
PGPBlockParseParses range contents and sends the appropriate request for the PGP blocks discovered.
addResultsFrameCreates the results container(s) and iframe for the inline formatting
addResultsReplacementFrameCreates a results iframe that replaces the element that contained the original PGP data

Functions

init

init: function(doc)

Sets up the context and calls the PGPDataSearch method to find PGP data in the page.

Parameters

doc<document> The document object to parse

PGPDataSearch

PGPDataSearch: function(doc)

Searches the document for elements that contain PGP Data blocks.  Calls the PGPBlockParse method if PGP data is found

Parameters

doc<document> The document to search

ignoreInners

ignoreInners: function(idx,
end,
node)

Avoids detection of PGP blocks found inside of other PGP blocks.

Parameters

idx<int> The current position of the block detected
end<int> The last position of the block detected
node<object> The node we are currently working on

PGPBlockParse

PGPBlockParse: function(range,
node,
blockType)

Parses range contents and sends the appropriate request for the PGP blocks discovered.  Calls the addResultsFrame method for any matching PGP blocks.

Parameters

range<range> The range containing the identified PGP block
node<obj> The node that PGP data was discovered in
blockType<int> The type of webpg.constants.PGPBlocks found

addResultsFrame

addResultsFrame: function(node,
range)

Creates the results container(s) and iframe for the inline formatting

Parameters

node<obj> The node that PGP data was discovered in
range<range> The range containing the identified PGP block

addResultsReplacementFrame

addResultsReplacementFrame: function(element)

Creates a results iframe that replaces the element that contained the original PGP data

Parameters

elementThe HTML element that contained the PGP Data
init: function(doc)
Sets up the context and calls the PGPDataSearch method to find PGP data in the page.
PGPDataSearch: function(doc)
Searches the document for elements that contain PGP Data blocks.
ignoreInners: function(idx,
end,
node)
Avoids detection of PGP blocks found inside of other PGP blocks.
PGPBlockParse: function(range,
node,
blockType)
Parses range contents and sends the appropriate request for the PGP blocks discovered.
addResultsFrame: function(node,
range)
Creates the results container(s) and iframe for the inline formatting
addResultsReplacementFrame: function(element)
Creates a results iframe that replaces the element that contained the original PGP data
Close