Package com.iizix.js.build.compressors
Class HtmlMetrics
- java.lang.Object
- com.iizix.js.build.compressors.HtmlMetrics
public class HtmlMetrics extends java.lang.Object
Class that stores metrics about HTML documents.- Author:
- Sergiy Kovalchuk
Constructor Summary
Constructors Constructor Description HtmlMetrics()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getEmptyChars()
Returns number of empty characters (spaces, tabs, end of lines) in a documentint
getFilesize()
Returns total filesize of a documentint
getInlineEventSize()
Returns total size of inline event handlers (onclick
, etc)int
getInlineScriptSize()
Returns total size of inline<script>
tagsint
getInlineStyleSize()
Returns total size of inline<style>
tagsvoid
setEmptyChars(int emptyChars)
void
setFilesize(int filesize)
void
setInlineEventSize(int inlineEventSize)
void
setInlineScriptSize(int inlineScriptSize)
void
setInlineStyleSize(int inlineStyleSize)
java.lang.String
toString()
Method Detail
getFilesize
public int getFilesize()
Returns total filesize of a document- Returns:
- total filesize of a document, in bytes
setFilesize
public void setFilesize(int filesize)
- Parameters:
filesize
- the filesize to set
getEmptyChars
public int getEmptyChars()
Returns number of empty characters (spaces, tabs, end of lines) in a document- Returns:
- number of empty characters in a document
setEmptyChars
public void setEmptyChars(int emptyChars)
- Parameters:
emptyChars
- the emptyChars to set
getInlineScriptSize
public int getInlineScriptSize()
Returns total size of inline<script>
tags- Returns:
- total size of inline
<script>
tags, in bytes
setInlineScriptSize
public void setInlineScriptSize(int inlineScriptSize)
- Parameters:
inlineScriptSize
- the inlineScriptSize to set
getInlineStyleSize
public int getInlineStyleSize()
Returns total size of inline<style>
tags- Returns:
- total size of inline
<style>
tags, in bytes
setInlineStyleSize
public void setInlineStyleSize(int inlineStyleSize)
- Parameters:
inlineStyleSize
- the inlineStyleSize to set
getInlineEventSize
public int getInlineEventSize()
Returns total size of inline event handlers (onclick
, etc)- Returns:
- total size of inline event handlers, in bytes
setInlineEventSize
public void setInlineEventSize(int inlineEventSize)
- Parameters:
inlineEventSize
- the inlineEventSize to set
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object