Page Speed Optimization Libraries  1.2.24.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Types | Public Member Functions
net_instaweb::ScriptTagScanner Class Reference

List of all members.

Public Types

enum  ScriptClassification { kNonScript, kUnknownScript, kJavaScript }
enum  ExecutionModeFlags { kExecuteSync = 0, kExecuteDefer = 1, kExecuteAsync = 2, kExecuteForEvent = 4 }
 Bit flags that specify when the script is to be run. More...

Public Member Functions

 ScriptTagScanner (HtmlParse *html_parse)
ScriptClassification ParseScriptElement (HtmlElement *element, HtmlElement::Attribute **src)
int ExecutionMode (const HtmlElement *element) const

Member Enumeration Documentation

Bit flags that specify when the script is to be run.

Enumerator:
kExecuteForEvent 

IE extension. If this is set, script will not run in browsers following HTML5, and will run at hard-to-describe time in IE.


Member Function Documentation

Returns which execution model attributes are set. Keep in mind, however, that HTML5 browsers will ignore kExecuteDefer and kExecuteAsync on elements without src=''

Examines an HTML element and determine if it is a script. If it's not, it returns kNonScript and doesn't touch *src. If it is a script, it returns whether it is JavaScript or not, and sets *src to the src attribute (perhaps NULL)


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines