1 JSCache

Class deister.axional.script.lib.ax.util.cache.JSCache


Individual cache instance generated by GlobalCacheController.

Method Summary

Modifier and Type
Method
Description
Ax.text.String 
asJSON()
This is a vanilla JSON, not convertible back to ResultSet
void 
void 
clear()
Remove all cache entries
Compare two resultset withs a default delta
compare(IResultSetConvertible other,double delta)
computeIfAbsent(Object key, Function mappingFunction)
Given an object key, if it is not already in the cache, attemps to compute its value using the mappingFunction and enters it into this cache unless
cursor()
boolean 
Compare two resultset withs a default delta
boolean 
equals(IResultSetConvertible other,double delta)
void 
forEach(Consumer arg0)
int 
Gets the capacity (number of buckets, filled or empty) of this cache.
int 
Gets cache size (number of entries).
boolean 
Returns an Iterator over this cache.
remove(Object key)
Remove a cache entry
Ax.text.String 
toCSV()
Convert a ResultSet to CSV
void 
Convert a ResultSet to CSV using a provided configurator
byte[] 
Convert a ResultSet to Excel without consumer, returning directly it's bytes using default type (XLSX)
void 
Convert a ResultSet to CSV using a provided configurator
Ax.text.String 
toFOP()
Ax.text.String 
Convert the ResultSet to a FOP XML document
Ax.text.String 
toFOPTableBody(double width)
Ax.text.String 
toFOPTableBody(Consumer<FOPReportConfig> config, double width)
Convert the ResultSet to a FOP XML table body document so it can be integrated into another document
Ax.text.String 
toHTML()
Ax.text.String 
Convert the ResultSet to a HTML document
Ax.text.String 
toJSON()
Convert a ResultSet to JSON that can be digested by aa JSON2ResultSet again into a SQLResultSetArray
Ax.text.String 
Convert a ResultSet to JSON
Ax.text.String 
Convert the ResultSet to a Javascript declaration (useful for coding)
byte[] 
toPDF()
byte[] 
Convert the ResultSet to a PDF document
byte[] 
toPDF(Ax.text.String fop)
Useful method for testing so we can produce a FOP and transform to PDF
Returns the content of this cache as a ResultSet
Perform a conversion to resultset
toRow()
toSQLCA(Object value)
Converts the object to SQLCA
Ax.text.String 
Returns a string representation of this cache.
Ax.text.String 
toText()
Ax.text.String 
Convert the ResultSet to a TEXT document
byte[] 
toXLS()
Convert a ResultSet to Excel (XLS)
byte[] 
toXLSX()
Convert a ResultSet to Excel (XLSX using streaming api)

Method Detail

deister.axional.script.lib.ax.util.cache.JSCache.__toResultSet

resultset deister.axional.script.lib.ax.util.cache.JSCache.__toResultSet(
	object value
)
Parameters:
value - 
Returns:
resultset

deister.axional.script.lib.ax.util.cache.JSCache.asJSON

string deister.axional.script.lib.ax.util.cache.JSCache.asJSON()
Info:
This is a vanilla JSON, not convertible back to ResultSet
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.asJSON

null deister.axional.script.lib.ax.util.cache.JSCache.asJSON(
	object config
)
Parameters:
config - 
Returns:
null

deister.axional.script.lib.ax.util.cache.JSCache.clear

null deister.axional.script.lib.ax.util.cache.JSCache.clear()
Info:
Remove all cache entries
Returns:
null

deister.axional.script.lib.ax.util.cache.JSCache.compare

object deister.axional.script.lib.ax.util.cache.JSCache.compare(
	object other
)
Info:
Compare two resultset withs a default delta
Parameters:
other - 
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.compare

object deister.axional.script.lib.ax.util.cache.JSCache.compare(
	object other,
	double delta
)
Parameters:
other - 
delta - 
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.computeIfAbsent

object deister.axional.script.lib.ax.util.cache.JSCache.computeIfAbsent(
	object key,
	object mappingFunction
)
Info:
Given an object key, if it is not already in the cache, attemps to compute its value using the mappingFunction and enters it into this cache unless
Parameters:
key - key with which the specified value is to be associated
mappingFunction - the function to compute a value
Returns:
object

Example
Copy
null

deister.axional.script.lib.ax.util.cache.JSCache.cursor

object deister.axional.script.lib.ax.util.cache.JSCache.cursor()
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.equals

boolean deister.axional.script.lib.ax.util.cache.JSCache.equals(
	object other
)
Info:
Compare two resultset withs a default delta
Parameters:
other - 
Returns:
boolean

deister.axional.script.lib.ax.util.cache.JSCache.equals

boolean deister.axional.script.lib.ax.util.cache.JSCache.equals(
	object other,
	double delta
)
Parameters:
other - 
delta - 
Returns:
boolean

deister.axional.script.lib.ax.util.cache.JSCache.forEach

null deister.axional.script.lib.ax.util.cache.JSCache.forEach(
	object arg0
)
Parameters:
arg0 - 
Returns:
null

deister.axional.script.lib.ax.util.cache.JSCache.getCapacity

smallint deister.axional.script.lib.ax.util.cache.JSCache.getCapacity()
Info:
Gets the capacity (number of buckets, filled or empty) of this cache.
Returns:
smallint

deister.axional.script.lib.ax.util.cache.JSCache.getSize

smallint deister.axional.script.lib.ax.util.cache.JSCache.getSize()
Info:
Gets cache size (number of entries).
Returns:
smallint

deister.axional.script.lib.ax.util.cache.JSCache.isResultSet

boolean deister.axional.script.lib.ax.util.cache.JSCache.isResultSet(
	object value
)
Parameters:
value - 
Returns:
boolean

deister.axional.script.lib.ax.util.cache.JSCache.iterator

object deister.axional.script.lib.ax.util.cache.JSCache.iterator()
Info:
Returns an Iterator over this cache.
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.remove

object deister.axional.script.lib.ax.util.cache.JSCache.remove(
	object key
)
Info:
Remove a cache entry
Parameters:
key - 
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.spliterator

object deister.axional.script.lib.ax.util.cache.JSCache.spliterator()
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.toCSV

string deister.axional.script.lib.ax.util.cache.JSCache.toCSV()
Info:
Convert a ResultSet to CSV
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toCSV

null deister.axional.script.lib.ax.util.cache.JSCache.toCSV(
	object config
)
Info:
Convert a ResultSet to CSV using a provided configurator
Parameters:
config - 
Returns:
null

deister.axional.script.lib.ax.util.cache.JSCache.toExcel

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toExcel()
Info:
Convert a ResultSet to Excel without consumer, returning directly it's bytes using default type (XLSX)
Returns:
byte[]

deister.axional.script.lib.ax.util.cache.JSCache.toExcel

null deister.axional.script.lib.ax.util.cache.JSCache.toExcel(
	object config
)
Info:
Convert a ResultSet to CSV using a provided configurator
Parameters:
config - 
Returns:
null

deister.axional.script.lib.ax.util.cache.JSCache.toFOP

string deister.axional.script.lib.ax.util.cache.JSCache.toFOP()
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toFOP

string deister.axional.script.lib.ax.util.cache.JSCache.toFOP(
	object config
)
Info:
Convert the ResultSet to a FOP XML document
Parameters:
config - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toFOPTableBody

string deister.axional.script.lib.ax.util.cache.JSCache.toFOPTableBody(
	double width
)
Parameters:
width - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toFOPTableBody

string deister.axional.script.lib.ax.util.cache.JSCache.toFOPTableBody(
	object config,
	double width
)
Info:
Convert the ResultSet to a FOP XML table body document so it can be integrated into another document
Parameters:
config - 
width - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toHTML

string deister.axional.script.lib.ax.util.cache.JSCache.toHTML()
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toHTML

string deister.axional.script.lib.ax.util.cache.JSCache.toHTML(
	object config
)
Info:
Convert the ResultSet to a HTML document
Parameters:
config - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toJSON

string deister.axional.script.lib.ax.util.cache.JSCache.toJSON()
Info:
Convert a ResultSet to JSON that can be digested by aa JSON2ResultSet again into a SQLResultSetArray
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toJSON

string deister.axional.script.lib.ax.util.cache.JSCache.toJSON(
	object config
)
Info:
Convert a ResultSet to JSON
Parameters:
config - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toJavaScript

string deister.axional.script.lib.ax.util.cache.JSCache.toJavaScript()
Info:
Convert the ResultSet to a Javascript declaration (useful for coding)
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toPDF

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toPDF()
Returns:
byte[]

deister.axional.script.lib.ax.util.cache.JSCache.toPDF

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toPDF(
	object config
)
Info:
Convert the ResultSet to a PDF document
Parameters:
config - 
Returns:
byte[]

deister.axional.script.lib.ax.util.cache.JSCache.toPDF

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toPDF(
	string fop
)
Info:
Useful method for testing so we can produce a FOP and transform to PDF
Parameters:
fop - 
Returns:
byte[]

deister.axional.script.lib.ax.util.cache.JSCache.toResultSet

resultset deister.axional.script.lib.ax.util.cache.JSCache.toResultSet()
Info:
Returns the content of this cache as a ResultSet
Returns:
resultset

deister.axional.script.lib.ax.util.cache.JSCache.toResultSet

resultset deister.axional.script.lib.ax.util.cache.JSCache.toResultSet(
	object value
)
Info:
Perform a conversion to resultset
Parameters:
value - 
Returns:
resultset

deister.axional.script.lib.ax.util.cache.JSCache.toRow

object deister.axional.script.lib.ax.util.cache.JSCache.toRow()
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.toSQLCA

object deister.axional.script.lib.ax.util.cache.JSCache.toSQLCA(
	object value
)
Info:
Converts the object to SQLCA
Parameters:
value - 
Returns:
object

deister.axional.script.lib.ax.util.cache.JSCache.toString

string deister.axional.script.lib.ax.util.cache.JSCache.toString()
Info:
Returns a string representation of this cache.
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toText

string deister.axional.script.lib.ax.util.cache.JSCache.toText()
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toText

string deister.axional.script.lib.ax.util.cache.JSCache.toText(
	object config
)
Info:
Convert the ResultSet to a TEXT document
Parameters:
config - 
Returns:
string

deister.axional.script.lib.ax.util.cache.JSCache.toXLS

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toXLS()
Info:
Convert a ResultSet to Excel (XLS)
Returns:
byte[]

deister.axional.script.lib.ax.util.cache.JSCache.toXLSX

byte[] deister.axional.script.lib.ax.util.cache.JSCache.toXLSX()
Info:
Convert a ResultSet to Excel (XLSX using streaming api)
Returns:
byte[]