1 Calendar
Class Ax.util.Calendar
Constructor Summary
Method Summary
Constructor Detail
Ax.util.Calendar.JSCalendar
-
Ax.util.Calendar.JSCalendar()
- Info:
-
Creates a new Calendar instance with the current date and time.
var cal = new Ax.util.Calendar();
Method Detail
Ax.util.Calendar.add
-
null Ax.util.Calendar.add( smallint type, smallint value )
- Info:
-
Adds the given amount to the field. This method can modify larger fields. - Parameters:
- type - the field to add
- value - the amount to add
- Returns:
- null
Ax.util.Calendar.get
-
smallint Ax.util.Calendar.get( smallint field )
- Info:
-
Gets the selected field from the calendar. - Parameters:
- field - the field to get, like Ax.util.Calendar.YEAR
- Returns:
- smallint
cal.get(Ax.util.Calendar.YEAR);
Ax.util.Calendar.getTime
-
date Ax.util.Calendar.getTime()
- Info:
-
Gets the calendar time as a Date object. - Returns:
- date
Ax.util.Calendar.getTimeIMillis
-
long Ax.util.Calendar.getTimeIMillis()
- Info:
-
Returns the calendar time in milliseconds since Epoch (January 1, 1970). - Returns:
- long
Ax.util.Calendar.roll
-
null Ax.util.Calendar.roll( smallint field, boolean up )
- Info:
-
Adds/substracts a single unit of time to the field. - Parameters:
- field - the field to update
- up - whether to add (true) or subtract (false) a unit of time
- Returns:
- null
Ax.util.Calendar.roll
-
null Ax.util.Calendar.roll( smallint field, smallint ammount )
- Info:
-
Adds the given amount to the field. A negative value means that the amount will be subtracted. This method does not modify larger fields. - Parameters:
- field - the field to update
- ammount - the amount to add/subtract
- Returns:
- null
Ax.util.Calendar.set
-
null Ax.util.Calendar.set( smallint type, smallint value )
- Info:
-
Sets the field with the given value. - Parameters:
- type - the field to set
- value - the value to set
- Returns:
- null
Ax.util.Calendar.set
-
null Ax.util.Calendar.set( smallint year, smallint month, smallint date )
- Info:
-
Sets the year, month and day of the calendar time. - Parameters:
- year - the year to set
- month - the month to set
- date - the day to set
- Returns:
- null
Ax.util.Calendar.set
-
null Ax.util.Calendar.set( smallint year, smallint month, smallint date, smallint hourOfDay, smallint minute )
- Info:
-
Sets the year, month, day, hour and minute to the calendar time. - Parameters:
- year - the year to set
- month - the month to set
- date - the day to set
- hourOfDay - the hour to set
- minute - the minute to set
- Returns:
- null
Ax.util.Calendar.set
-
null Ax.util.Calendar.set( smallint year, smallint month, smallint date, smallint hourOfDay, smallint minute, smallint second )
- Info:
-
Sets the year, month, day, hour, minute and second to the calendar time. - Parameters:
- year - the year to set
- month - the month to set
- date - the day to set
- hourOfDay - the hour to set
- minute - the minute to set
- second - the second to set
- Returns:
- null
2 Date
Class Ax.sql.Date
Constructor Summary
Method Summary
Constructor Detail
Ax.sql.Date.JSSQLDate
-
Ax.sql.Date.JSSQLDate()
- Info:
-
Creates a new Date instance with the current time.
var current = new Ax.sql.Date(); current.setConnection(Ax.db);
Ax.sql.Date.JSSQLDate
-
Ax.sql.Date.JSSQLDate( long time )
- Parameters:
- time -
Ax.sql.Date.JSSQLDate
-
Ax.sql.Date.JSSQLDate( object argument )
- Info:
-
Creates a new Date instance with the given argument. The argument can be: 1. Numeric (like Long or Double): milliseconds since January 1, 1970, 00:00:00. 2. javascript Dates. - Parameters:
- argument -
Ax.sql.Date.JSSQLDate
-
Ax.sql.Date.JSSQLDate( smallint y, smallint m, smallint d )
- Info:
-
Creates a new date instance with the given year, month and day. The time (hh:mm:ss) part of the date is set to midnight, at the beginning of the day d. - Parameters:
- y - the year
- m - 1-based month
- d - 1-based day
function __test (param1, param2){ let x1 = param1 +1; let x2 = param2.addMonth(1); } var testunit = [ { field1 : 1, field2 : new Ax.sql.Date()} ]; for (var row of testunit) { console.log(row) __test(row.field1, row.field2); console.log(row) }
Method Detail
Ax.sql.Date.UTC
-
long Ax.sql.Date.UTC( smallint arg0, smallint arg1, smallint arg2, smallint arg3, smallint arg4, smallint arg5 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- arg4 -
- arg5 -
- Returns:
- long
Ax.sql.Date.__getDateFullYear
-
smallint Ax.sql.Date.__getDateFullYear( smallint year )
- Parameters:
- year -
- Returns:
- smallint
Ax.sql.Date.__getTimeFromArgument
-
long Ax.sql.Date.__getTimeFromArgument( object arg )
- Parameters:
- arg -
- Returns:
- long
Ax.sql.Date.add
-
object Ax.sql.Date.add( smallint field, smallint amount )
- Info:
-
Adds the given amount to the defined field in the date, returning a new one. The field is a Ax.util.Calendar fields. - Parameters:
- field - the field to add the amount to
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addDay
-
object Ax.sql.Date.addDay( smallint amount )
- Info:
-
Adds the number of days specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addHour
-
object Ax.sql.Date.addHour( smallint amount )
- Info:
-
Adds the number of hours specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addMillisecond
-
object Ax.sql.Date.addMillisecond( smallint amount )
- Info:
-
Adds the number of milliseconds specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addMinute
-
object Ax.sql.Date.addMinute( smallint amount )
- Info:
-
Adds the number of minutes specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addMonth
-
object Ax.sql.Date.addMonth( smallint amount )
- Info:
-
Adds the number of months specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addSecond
-
object Ax.sql.Date.addSecond( smallint amount )
- Info:
-
Adds the number of seconds specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.addYear
-
object Ax.sql.Date.addYear( smallint amount )
- Info:
-
Adds the number of years specified to date object returning a new one. - Parameters:
- amount - the amount to add
- Returns:
- object
Ax.sql.Date.after
-
boolean Ax.sql.Date.after( date arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.sql.Date.afterOrEqual
-
boolean Ax.sql.Date.afterOrEqual( date d )
- Info:
-
Checks if this date is after the given date. - Parameters:
- d - the date to compare with
- Returns:
- boolean
Ax.sql.Date.before
-
boolean Ax.sql.Date.before( date arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.sql.Date.beforeOrEqual
-
boolean Ax.sql.Date.beforeOrEqual( date d )
- Info:
-
Checks if this date is before the given date. - Parameters:
- d - the date to compare with
- Returns:
- boolean
Ax.sql.Date.clearTime
-
object Ax.sql.Date.clearTime()
- Info:
-
Clear the time part (hours to milliseconds) from date, that is, set them to 0. - Returns:
- object
Ax.sql.Date.clone
-
object Ax.sql.Date.clone()
- Returns:
- object
Ax.sql.Date.compareTo
-
smallint Ax.sql.Date.compareTo( date arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.sql.Date.convertTimeZone
-
object Ax.sql.Date.convertTimeZone( string from, string to )
- Info:
-
Converts from one timezone to another. - Parameters:
- from - the timezone to convert from, like "Europe/London"
- to - the timezone to convert to, like "Europe/London"
- Returns:
- object
Ax.sql.Date.days
-
long Ax.sql.Date.days( object d2 )
- Info:
-
Returns the difference between the two given dates in days. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.duration
-
object Ax.sql.Date.duration( date d2 )
- Info:
-
Returns the Duration between the two given dates. - Parameters:
- d2 - the second date to compare
- Returns:
- object
Ax.sql.Date.equals
-
boolean Ax.sql.Date.equals( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.sql.Date.format
-
string Ax.sql.Date.format( string format )
- Info:
-
Returns a string with the date in the specified format. - Parameters:
- format - the format to use
- Returns:
- string
Ax.sql.Date.format
-
string Ax.sql.Date.format( string format, string language )
- Info:
-
Returns a string with the date in the specified format and localized for the given language. - Parameters:
- format - the format to use
- language - the local language
- Returns:
- string
console.log(current.format("EEE, MMM d, ''yy", "es")); // lun., feb. 11, '19
Ax.sql.Date.formatDecimalInt
-
null Ax.sql.Date.formatDecimalInt( smallint arg0, object arg1, smallint arg2, smallint arg3 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- Returns:
- null
Ax.sql.Date.from
-
date Ax.sql.Date.from( object arg0 )
- Parameters:
- arg0 -
- Returns:
- date
Ax.sql.Date.getDate
-
smallint Ax.sql.Date.getDate()
- Returns:
- smallint
Ax.sql.Date.getDateFullYear
-
smallint Ax.sql.Date.getDateFullYear( object date )
- Info:
-
Gets the year of the date. - Parameters:
- date - the date to get the year from in javascript
- Returns:
- smallint
Ax.sql.Date.getDateFullYear
-
smallint Ax.sql.Date.getDateFullYear( object date )
- Info:
-
Gets the year of the date. - Parameters:
- date - the date to get the year from as JSDate
- Returns:
- smallint
Ax.sql.Date.getDay
-
smallint Ax.sql.Date.getDay()
- Returns:
- smallint
Ax.sql.Date.getFullYear
-
smallint Ax.sql.Date.getFullYear()
- Info:
-
Gets the year of the date. - Returns:
- smallint
Ax.sql.Date.getHours
-
smallint Ax.sql.Date.getHours()
- Returns:
- smallint
Ax.sql.Date.getHours
-
smallint Ax.sql.Date.getHours()
- Returns:
- smallint
Ax.sql.Date.getMillisOf
-
long Ax.sql.Date.getMillisOf( date arg0 )
- Parameters:
- arg0 -
- Returns:
- long
Ax.sql.Date.getMinutes
-
smallint Ax.sql.Date.getMinutes()
- Returns:
- smallint
Ax.sql.Date.getMinutes
-
smallint Ax.sql.Date.getMinutes()
- Returns:
- smallint
Ax.sql.Date.getMonth
-
smallint Ax.sql.Date.getMonth()
- Returns:
- smallint
Ax.sql.Date.getSeconds
-
smallint Ax.sql.Date.getSeconds()
- Returns:
- smallint
Ax.sql.Date.getSeconds
-
smallint Ax.sql.Date.getSeconds()
- Returns:
- smallint
Ax.sql.Date.getTime
-
long Ax.sql.Date.getTime()
- Returns:
- long
Ax.sql.Date.getTimeZone
-
string Ax.sql.Date.getTimeZone()
- Info:
-
Returns the timezone date is represented in. By default system timezone but can be set by specific constructor or changed. - Returns:
- string
Ax.sql.Date.getTimezoneOffset
-
smallint Ax.sql.Date.getTimezoneOffset()
- Returns:
- smallint
Ax.sql.Date.getYear
-
smallint Ax.sql.Date.getYear()
- Info:
-
Gets the year of the date. - Returns:
- smallint
Ax.sql.Date.getYear
-
smallint Ax.sql.Date.getYear()
- Returns:
- smallint
Ax.sql.Date.hashCode
-
smallint Ax.sql.Date.hashCode()
- Returns:
- smallint
Ax.sql.Date.hours
-
long Ax.sql.Date.hours( date d2 )
- Info:
-
Returns the difference between the two given dates in hours. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.internalCreateDate
-
object Ax.sql.Date.internalCreateDate( long timeInMillis )
- Info:
-
Create the date type required - Parameters:
- timeInMillis -
- Returns:
- object
Ax.sql.Date.internalGetDate
-
date Ax.sql.Date.internalGetDate()
- Returns:
- date
Ax.sql.Date.internalGetYear
-
smallint Ax.sql.Date.internalGetYear()
- Returns:
- smallint
Ax.sql.Date.isEngineAvailable
-
boolean Ax.sql.Date.isEngineAvailable()
- Returns:
- boolean
Ax.sql.Date.millis
-
long Ax.sql.Date.millis( date d2 )
- Info:
-
Returns the difference between the two given dates in milliseconds. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.minutes
-
long Ax.sql.Date.minutes( date d2 )
- Info:
-
Returns the difference between the two given dates in minutes. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.months
-
long Ax.sql.Date.months( object d2 )
- Info:
-
Returns the difference between the two given dates in months. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.parse
-
long Ax.sql.Date.parse( string arg0 )
- Parameters:
- arg0 -
- Returns:
- long
Ax.sql.Date.seconds
-
long Ax.sql.Date.seconds( date d2 )
- Info:
-
Returns the difference between the two given dates in seconds. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.set
-
object Ax.sql.Date.set( smallint field, smallint value )
- Info:
-
Sets the given value to the defined field in the date, returning a new one. Fields are: ERA = 0, YEAR = 1, MONTH = 2, WEEK_OF_YEAR = 3, WEEK_OF_MONTH = 4, DAY_OF_MONTH = 5, DAY_OF_YEAR = 6, DAY_OF_WEEK = 7, DAY_OF_WEEK_IN_MONTH = 8, AM_PM = 9, HOUR = 10, HOUR_OF_DAY = 11, MINUTE = 12, SECOND = 13, MILLISECOND = 14, ZONE_OFFSET = 15, DST_OFFSET = 16, FIELD_COUNT = 17. - Parameters:
- field - the field to set
- value - the amount to add
- Returns:
- object
Ax.sql.Date.setConnection
-
object Ax.sql.Date.setConnection( object conn )
- Info:
-
Setups a database connection to format the date accordingly. - Parameters:
- conn - the database connection
- Returns:
- object
Ax.sql.Date.setConnection
-
object Ax.sql.Date.setConnection( object conn )
- Info:
-
Setups a database connection to format the date accordingly. - Parameters:
- conn - the database connection
- Returns:
- object
Ax.sql.Date.setDate
-
null Ax.sql.Date.setDate( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setHours
-
null Ax.sql.Date.setHours( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setHours
-
null Ax.sql.Date.setHours( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setMinutes
-
null Ax.sql.Date.setMinutes( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setMinutes
-
null Ax.sql.Date.setMinutes( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setMonth
-
null Ax.sql.Date.setMonth( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setSeconds
-
null Ax.sql.Date.setSeconds( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setSeconds
-
null Ax.sql.Date.setSeconds( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setTime
-
null Ax.sql.Date.setTime( long arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setTime
-
null Ax.sql.Date.setTime( long arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.setTimeZone
-
object Ax.sql.Date.setTimeZone( string to )
- Info:
-
Sets the date timezone. - Parameters:
- to - the timezone to set, like "Europe/London"
- Returns:
- object
Ax.sql.Date.setYear
-
null Ax.sql.Date.setYear( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.sql.Date.toCalendar
-
object Ax.sql.Date.toCalendar()
- Info:
-
Converts the date to a Calendar object. - Returns:
- object
Ax.sql.Date.toGMTString
-
string Ax.sql.Date.toGMTString()
- Returns:
- string
Ax.sql.Date.toHumanReadable
-
string Ax.sql.Date.toHumanReadable( object d )
- Info:
-
Returns the Duration in human readable format as a String with format like "2 d 20:14:56" or "20:14:56" when days are 0. - Parameters:
- d - the duration
- Returns:
- string
Ax.sql.Date.toISOString
-
string Ax.sql.Date.toISOString()
- Info:
-
Returns the date formated as ISO_8601 ("yyyy-MM-dd") without time part. - Returns:
- string
Ax.sql.Date.toInstant
-
object Ax.sql.Date.toInstant()
- Returns:
- object
Ax.sql.Date.toInstant
-
object Ax.sql.Date.toInstant()
- Returns:
- object
Ax.sql.Date.toJavaSqlDate
-
date Ax.sql.Date.toJavaSqlDate()
- Info:
-
To be used when a native java.sql.Date object is needed in Ax JavaScript code. For example, consider a report having a variable ('FECHA' = '2022-06-19') of type Date which is returned as a column ('fecha') in the main ResultSet this way: var rsOutput = new Ax.rs.Reader().memory(options = - Returns:
- date
Ax.sql.Date.toLocalDate
-
object Ax.sql.Date.toLocalDate()
- Returns:
- object
Ax.sql.Date.toLocalDate
-
object Ax.sql.Date.toLocalDate()
- Info:
-
Converts the date to the system's timezone. - Returns:
- object
Ax.sql.Date.toLocaleString
-
string Ax.sql.Date.toLocaleString()
- Returns:
- string
Ax.sql.Date.toSQLQueryString
-
string Ax.sql.Date.toSQLQueryString()
- Info:
-
Returns the date formated as the SQL agent requires. Informix: MDY(m,d,y) - Returns:
- string
Ax.sql.Date.toString
-
string Ax.sql.Date.toString()
- Info:
-
Converts the date to a human-readable string or database format. - Returns:
- string
var current = new Ax.sql.Date(); current.setConnection(Ax.db); console.log(current);
Ax.sql.Date.toString
-
string Ax.sql.Date.toString()
- Returns:
- string
Ax.sql.Date.toString
-
string Ax.sql.Date.toString()
- Returns:
- string
Ax.sql.Date.valueOf
-
date Ax.sql.Date.valueOf( string arg0 )
- Parameters:
- arg0 -
- Returns:
- date
Ax.sql.Date.valueOf
-
date Ax.sql.Date.valueOf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- date
Ax.sql.Date.weeks
-
long Ax.sql.Date.weeks( object d2 )
- Info:
-
Returns the difference between the two given dates in weeks. - Parameters:
- d2 - the second date to compare
- Returns:
- long
Ax.sql.Date.years
-
long Ax.sql.Date.years( object d2 )
- Info:
-
Returns the difference between the two given dates in years. - Parameters:
- d2 - the second date to compare
- Returns:
- long
3 ExecutorService
Class Ax.util.ExecutorService
Constructor Summary
Method Summary
Constructor Detail
Ax.util.ExecutorService.JSExecutorService
-
Ax.util.ExecutorService.JSExecutorService()
- Info:
-
Creates a new Executor Service.
Ax.util.ExecutorService.JSExecutorService
-
Ax.util.ExecutorService.JSExecutorService( smallint parallelism )
- Info:
-
Creates a new Executor Service. - Parameters:
- parallelism - the desired parallelism level.
Method Detail
Ax.util.ExecutorService.getParallelism
-
smallint Ax.util.ExecutorService.getParallelism()
- Info:
-
Gets the parallelism level. - Returns:
- smallint
Ax.util.ExecutorService.invokeAll
-
array Ax.util.ExecutorService.invokeAll( object task, object[] args )
- Info:
-
Runs a javascript function in parallel, with the given arguments. - Parameters:
- task - the js function to execute
- args - an array of parameters to be used for each execution
- Returns:
- array
Ax.util.ExecutorService.invokeAll
-
array Ax.util.ExecutorService.invokeAll( object task, array args )
- Info:
-
Runs a javascript function in parallel, with the given arguments. - Parameters:
- task - the js function to execute
- args - a list of parameters to be used for each execution
- Returns:
- array
Ax.util.ExecutorService.invokeAndGet
-
array Ax.util.ExecutorService.invokeAndGet( object task, object[] args )
- Info:
-
Runs a javascript function in parallel, with the given arguments. - Parameters:
- task - the js function to execute
- args - an array with the parameters to use for each execution
- Returns:
- array
Ax.util.ExecutorService.invokeAndGet
-
array Ax.util.ExecutorService.invokeAndGet( object task, object collection )
- Info:
-
Runs a javascript function in parallel, with the given arguments. - Parameters:
- task - the js function to execute
- collection - a collection with the parameters to use for each execution
- Returns:
- array
Ax.util.ExecutorService.invokeAndGet
-
array Ax.util.ExecutorService.invokeAndGet( object task, object[] args )
- Info:
-
Runs a javascript function in parallel, with the given arguments. - Parameters:
- task - the js function to execute
- args - an array with the parameters to use for each execution
- Returns:
- array
Ax.util.ExecutorService.submit
-
object Ax.util.ExecutorService.submit( object task, object argument )
- Info:
-
Submits the given function for parallel execution, with the given argument. - Parameters:
- task - the js function to execute
- argument - the function argument
- Returns:
- object
Ax.util.ExecutorService.submit
-
object Ax.util.ExecutorService.submit( object task, object argument )
- Info:
-
Submits the given function for parallel execution, with the given argument. - Parameters:
- task - the function to execute
- argument - the function argument
- Returns:
- object
4 Error
Class Ax.util.Error
Method Summary
Method Detail
Ax.util.Error.getColumnNumber
-
static object Ax.util.Error.getColumnNumber( object o )
- Parameters:
- o -
- Returns:
- object
Ax.util.Error.getErrorCode
-
static object Ax.util.Error.getErrorCode( object o )
- Info:
-
Retrieves the vendor-specific exception code if the exception is of type SQLException, otherwise returns null - Parameters:
- o -
- Returns:
- object
Ax.util.Error.getFileName
-
static string Ax.util.Error.getFileName( object o )
- Parameters:
- o -
- Returns:
- string
Ax.util.Error.getLineNumber
-
static object Ax.util.Error.getLineNumber( object o )
- Parameters:
- o -
- Returns:
- object
Ax.util.Error.getMessage
-
static string Ax.util.Error.getMessage( object error )
- Info:
-
Extracts the error message from a native JS object. - Parameters:
- error - the object to extract the message from
- Returns:
- string
try { throw new Ax.lang.Exception("Something wrong happened!"); } catch(e) { const message = Ax.util.Error.getMessage(e); console.log(message); }
Ax.util.Error.getMessage
-
static string Ax.util.Error.getMessage( object error )
- Info:
-
Extracts the error message from an instance of Throwable object. - Parameters:
- error - the throwable to extract the error message from
- Returns:
- string
Ax.util.Error.getSQLState
-
static string Ax.util.Error.getSQLState( object o )
- Info:
-
Retrieves the SQLState code if the exception is of type SQLException, otherwise returns null - Parameters:
- o -
- Returns:
- string
Ax.util.Error.getStackTrace
-
static string Ax.util.Error.getStackTrace( object error )
- Info:
-
Extracts the stack trace from a native JS object. - Parameters:
- error - the object to extract the stack trace form
- Returns:
- string
try { ... } catch(e) { const stack = Ax.util.Error.getStackTrace(e); }
Ax.util.Error.getStackTrace
-
static string Ax.util.Error.getStackTrace( object error )
- Info:
-
Extracts the stack trace from an instance of Throwable object. - Parameters:
- error - the throwable to extract the stack trace from
- Returns:
- string
Ax.util.Error.isSQL
-
static boolean Ax.util.Error.isSQL( object o )
- Parameters:
- o -
- Returns:
- boolean
5 List
Class Ax.util.List
Constructor Summary
Method Summary
Constructor Detail
Ax.util.List.JSArrayList
-
Ax.util.List.JSArrayList()
Method Detail
Ax.util.List.add
-
boolean Ax.util.List.add( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.add
-
null Ax.util.List.add( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- null
Ax.util.List.add
-
boolean Ax.util.List.add( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.add
-
null Ax.util.List.add( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- null
Ax.util.List.add
-
boolean Ax.util.List.add( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.addAll
-
boolean Ax.util.List.addAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.addAll
-
boolean Ax.util.List.addAll( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- boolean
Ax.util.List.addAll
-
boolean Ax.util.List.addAll( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- boolean
Ax.util.List.addAll
-
boolean Ax.util.List.addAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.batchRemove
-
boolean Ax.util.List.batchRemove( object arg0, boolean arg1, smallint arg2, smallint arg3 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- Returns:
- boolean
Ax.util.List.checkInvariants
-
null Ax.util.List.checkInvariants()
- Returns:
- null
Ax.util.List.clear
-
null Ax.util.List.clear()
- Returns:
- null
Ax.util.List.clear
-
null Ax.util.List.clear()
- Returns:
- null
Ax.util.List.clear
-
null Ax.util.List.clear()
- Returns:
- null
Ax.util.List.clone
-
object Ax.util.List.clone()
- Returns:
- object
Ax.util.List.contains
-
boolean Ax.util.List.contains( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.contains
-
boolean Ax.util.List.contains( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.containsAll
-
boolean Ax.util.List.containsAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.elementAt
-
object Ax.util.List.elementAt( object[] arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.List.elementData
-
object Ax.util.List.elementData( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.ensureCapacity
-
null Ax.util.List.ensureCapacity( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.List.equals
-
boolean Ax.util.List.equals( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.equals
-
boolean Ax.util.List.equals( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.equalsRange
-
boolean Ax.util.List.equalsRange( array arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- boolean
Ax.util.List.forEach
-
null Ax.util.List.forEach( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.List.get
-
object Ax.util.List.get( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.hashCode
-
smallint Ax.util.List.hashCode()
- Returns:
- smallint
Ax.util.List.hashCode
-
smallint Ax.util.List.hashCode()
- Returns:
- smallint
Ax.util.List.hashCodeRange
-
smallint Ax.util.List.hashCodeRange( smallint arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- smallint
Ax.util.List.indexOf
-
smallint Ax.util.List.indexOf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.List.indexOf
-
smallint Ax.util.List.indexOf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.List.indexOfRange
-
smallint Ax.util.List.indexOfRange( object arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- smallint
Ax.util.List.isEmpty
-
boolean Ax.util.List.isEmpty()
- Returns:
- boolean
Ax.util.List.isEmpty
-
boolean Ax.util.List.isEmpty()
- Returns:
- boolean
Ax.util.List.iterator
-
object Ax.util.List.iterator()
- Returns:
- object
Ax.util.List.iterator
-
object Ax.util.List.iterator()
- Returns:
- object
Ax.util.List.join
-
string Ax.util.List.join( array list, string delimiter )
- Info:
-
join the elements of the list with the given separator. - Parameters:
- list -
- delimiter -
- Returns:
- string
var list = Ax.util.List.join("A", 1, 1.1, new Ax.sql.Date()); // ["A", 1, 1.1, {}]
Ax.util.List.lastIndexOf
-
smallint Ax.util.List.lastIndexOf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.List.lastIndexOf
-
smallint Ax.util.List.lastIndexOf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.List.lastIndexOfRange
-
smallint Ax.util.List.lastIndexOfRange( object arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- smallint
Ax.util.List.listIterator
-
object Ax.util.List.listIterator( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.listIterator
-
object Ax.util.List.listIterator()
- Returns:
- object
Ax.util.List.listIterator
-
object Ax.util.List.listIterator()
- Returns:
- object
Ax.util.List.listIterator
-
object Ax.util.List.listIterator( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.of
-
array Ax.util.List.of( object[] args )
- Info:
-
Creates a List with the content passed as arguments. - Parameters:
- args - the list content
- Returns:
- array
var list = Ax.util.List.of("A", 1, 1.1, new Ax.sql.Date()); // ["A", 1, 1.1, {}]
Ax.util.List.remove
-
object Ax.util.List.remove( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.remove
-
boolean Ax.util.List.remove( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.remove
-
object Ax.util.List.remove( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.remove
-
boolean Ax.util.List.remove( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.removeAll
-
boolean Ax.util.List.removeAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.removeAll
-
boolean Ax.util.List.removeAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.removeIf
-
boolean Ax.util.List.removeIf( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.removeIf
-
boolean Ax.util.List.removeIf( object arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- boolean
Ax.util.List.replaceAll
-
null Ax.util.List.replaceAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.List.retainAll
-
boolean Ax.util.List.retainAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.retainAll
-
boolean Ax.util.List.retainAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.List.set
-
object Ax.util.List.set( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.List.set
-
object Ax.util.List.set( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.List.size
-
smallint Ax.util.List.size()
- Returns:
- smallint
Ax.util.List.sort
-
null Ax.util.List.sort( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.List.spliterator
-
object Ax.util.List.spliterator()
- Returns:
- object
Ax.util.List.subList
-
array Ax.util.List.subList( smallint arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- array
Ax.util.List.subList
-
array Ax.util.List.subList( smallint arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- array
Ax.util.List.subListRangeCheck
-
null Ax.util.List.subListRangeCheck( smallint arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- null
Ax.util.List.toArray
-
object[] Ax.util.List.toArray()
- Returns:
- object[]
Ax.util.List.toArray
-
object Ax.util.List.toArray( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.toArray
-
object[] Ax.util.List.toArray()
- Returns:
- object[]
Ax.util.List.toArray
-
object Ax.util.List.toArray( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.List.toString
-
string Ax.util.List.toString()
- Returns:
- string
Ax.util.List.trimToSize
-
null Ax.util.List.trimToSize()
- Returns:
- null
6 Map
Class Ax.util.Map
Constructor Summary
Method Summary
Constructor Detail
Ax.util.Map.JSHashMap
-
Ax.util.Map.JSHashMap()
Method Detail
Ax.util.Map.afterNodeAccess
-
null Ax.util.Map.afterNodeAccess( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.afterNodeInsertion
-
null Ax.util.Map.afterNodeInsertion( boolean arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.afterNodeRemoval
-
null Ax.util.Map.afterNodeRemoval( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.capacity
-
smallint Ax.util.Map.capacity()
- Returns:
- smallint
Ax.util.Map.clear
-
null Ax.util.Map.clear()
- Returns:
- null
Ax.util.Map.clear
-
null Ax.util.Map.clear()
- Returns:
- null
Ax.util.Map.clone
-
object Ax.util.Map.clone()
- Returns:
- object
Ax.util.Map.comparableClassFor
-
object Ax.util.Map.comparableClassFor( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.compareComparables
-
smallint Ax.util.Map.compareComparables( object arg0, object arg1, object arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- smallint
Ax.util.Map.compute
-
object Ax.util.Map.compute( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.computeIfAbsent
-
object Ax.util.Map.computeIfAbsent( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.computeIfPresent
-
object Ax.util.Map.computeIfPresent( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.containsKey
-
boolean Ax.util.Map.containsKey( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.Map.containsKey
-
boolean Ax.util.Map.containsKey( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.Map.containsValue
-
boolean Ax.util.Map.containsValue( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.Map.containsValue
-
boolean Ax.util.Map.containsValue( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.Map.entrySet
-
object Ax.util.Map.entrySet()
- Returns:
- object
Ax.util.Map.equals
-
boolean Ax.util.Map.equals( object arg0 )
- Parameters:
- arg0 -
- Returns:
- boolean
Ax.util.Map.filter
-
object Ax.util.Map.filter( object map, string prefix )
- Info:
-
Gets a map with all keys starting with the specific prefix. - Parameters:
- map - the source map
- prefix - the filtering prefix
- Returns:
- object
Ax.util.Map.forEach
-
null Ax.util.Map.forEach( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.get
-
object Ax.util.Map.get( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.get
-
object Ax.util.Map.get( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.getNode
-
object Ax.util.Map.getNode( smallint arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.getOrDefault
-
object Ax.util.Map.getOrDefault( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.hash
-
smallint Ax.util.Map.hash( object arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.Map.hashCode
-
smallint Ax.util.Map.hashCode()
- Returns:
- smallint
Ax.util.Map.internalWriteEntries
-
null Ax.util.Map.internalWriteEntries( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.isEmpty
-
boolean Ax.util.Map.isEmpty()
- Returns:
- boolean
Ax.util.Map.isEmpty
-
boolean Ax.util.Map.isEmpty()
- Returns:
- boolean
Ax.util.Map.keySet
-
object Ax.util.Map.keySet()
- Returns:
- object
Ax.util.Map.keySet
-
object Ax.util.Map.keySet()
- Returns:
- object
Ax.util.Map.keysToArray
-
object Ax.util.Map.keysToArray( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.loadFactor
-
object Ax.util.Map.loadFactor()
- Returns:
- object
Ax.util.Map.merge
-
object Ax.util.Map.merge( object arg0, object arg1, object arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- object
Ax.util.Map.newNode
-
object Ax.util.Map.newNode( smallint arg0, object arg1, object arg2, object arg3 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- Returns:
- object
Ax.util.Map.newTreeNode
-
object Ax.util.Map.newTreeNode( smallint arg0, object arg1, object arg2, object arg3 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- Returns:
- object
Ax.util.Map.of
-
object Ax.util.Map.of( object[] args )
- Info:
-
Creates a java Map with the given arguments as content. The given arguments must be even, so for each pair the first argument is the key and the second is the value. - Parameters:
- args - the map content
- Returns:
- object
var list = Ax.util.Map.of("A", 1, "B", 2); // { "A": 1, "B": 2 }
Ax.util.Map.prepareArray
-
object Ax.util.Map.prepareArray( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.put
-
object Ax.util.Map.put( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.put
-
object Ax.util.Map.put( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.putAll
-
null Ax.util.Map.putAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.putAll
-
null Ax.util.Map.putAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.putIfAbsent
-
object Ax.util.Map.putIfAbsent( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.putMapEntries
-
null Ax.util.Map.putMapEntries( object arg0, boolean arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- null
Ax.util.Map.putVal
-
object Ax.util.Map.putVal( smallint arg0, object arg1, object arg2, boolean arg3, boolean arg4 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- arg4 -
- Returns:
- object
Ax.util.Map.reinitialize
-
null Ax.util.Map.reinitialize()
- Returns:
- null
Ax.util.Map.remove
-
object Ax.util.Map.remove( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.remove
-
boolean Ax.util.Map.remove( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- boolean
Ax.util.Map.remove
-
object Ax.util.Map.remove( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.Map.removeNode
-
object Ax.util.Map.removeNode( smallint arg0, object arg1, object arg2, boolean arg3, boolean arg4 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- arg4 -
- Returns:
- object
Ax.util.Map.replace
-
boolean Ax.util.Map.replace( object arg0, object arg1, object arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- boolean
Ax.util.Map.replace
-
object Ax.util.Map.replace( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.replaceAll
-
null Ax.util.Map.replaceAll( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.Map.replacementNode
-
object Ax.util.Map.replacementNode( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.replacementTreeNode
-
object Ax.util.Map.replacementTreeNode( object arg0, object arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.Map.resize
-
object Ax.util.Map.resize()
- Returns:
- object
Ax.util.Map.size
-
smallint Ax.util.Map.size()
- Returns:
- smallint
Ax.util.Map.size
-
smallint Ax.util.Map.size()
- Returns:
- smallint
Ax.util.Map.tableSizeFor
-
smallint Ax.util.Map.tableSizeFor( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- smallint
Ax.util.Map.toString
-
string Ax.util.Map.toString()
- Returns:
- string
Ax.util.Map.treeifyBin
-
null Ax.util.Map.treeifyBin( object arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- null
Ax.util.Map.values
-
object Ax.util.Map.values()
- Returns:
- object
Ax.util.Map.values
-
object Ax.util.Map.values()
- Returns:
- object
Ax.util.Map.valuesToArray
-
object Ax.util.Map.valuesToArray( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
7 Base64
Class Ax.util.Base64
Constructor Summary
Method Summary
Constructor Detail
Ax.util.Base64.JSBase64
-
Ax.util.Base64.JSBase64()
Method Detail
Ax.util.Base64.URLdecode
-
byte[] Ax.util.Base64.URLdecode( object in )
- Info:
-
Decodes the given encoded data with URL and Filename safe base64. - Parameters:
- in - the InputStream to get the data from
- Returns:
- byte[]
Ax.util.Base64.URLdecode
-
byte[] Ax.util.Base64.URLdecode( string text )
- Info:
-
Decodes the given encoded data with URL and Filename safe base64. - Parameters:
- text - the text with the data to decode
- Returns:
- byte[]
Ax.util.Base64.URLencode
-
string Ax.util.Base64.URLencode( byte[] data )
- Info:
-
Encodes the given data with URL and Filename safe base64. - Parameters:
- data - the data to encode
- Returns:
- string
Ax.util.Base64.decode
-
byte[] Ax.util.Base64.decode( string text )
- Info:
-
Decodes the given encoded data with basic base64. - Parameters:
- text - the text with the data to decode
- Returns:
- byte[]
Ax.util.Base64.decode("SGVsbG8gd29ybGQ=")
Ax.util.Base64.decode
-
byte[] Ax.util.Base64.decode( byte[] data )
- Info:
-
Decodes the given encoded data with basic base64. - Parameters:
- data - the data to decode
- Returns:
- byte[]
Ax.util.Base64.decode
-
byte[] Ax.util.Base64.decode( object in )
- Info:
-
Decodes the given encoded data with basic base64. - Parameters:
- in - the InputStream to get the data from
- Returns:
- byte[]
Ax.util.Base64.encode
-
string Ax.util.Base64.encode( byte[] data )
- Info:
-
Encodes the given data with basic base64. - Parameters:
- data - the data to encode
- Returns:
- string
Ax.util.Base64.encode("Hello world".getBytes());
Ax.util.Base64.encode
-
string Ax.util.Base64.encode( string data )
- Info:
-
Encodes the given data with basic base64. - Parameters:
- data - the data to encode
- Returns:
- string
Ax.util.Base64.mimeDecode
-
byte[] Ax.util.Base64.mimeDecode( string text )
- Info:
-
Decodes the given encoded data with MIME base64. - Parameters:
- text - the text with the data to decode
- Returns:
- byte[]
Ax.util.Base64.mimeDecode
-
byte[] Ax.util.Base64.mimeDecode( byte[] data )
- Info:
-
Decodes the given encoded data with MIME base64. - Parameters:
- data - the data to decode
- Returns:
- byte[]
Ax.util.Base64.mimeDecode
-
byte[] Ax.util.Base64.mimeDecode( object in )
- Info:
-
Decodes the given encoded data with MIME base64. - Parameters:
- in - the InputStream to get the data from
- Returns:
- byte[]
Ax.util.Base64.mimeEncode
-
string Ax.util.Base64.mimeEncode( byte[] data )
- Info:
-
Encodes the given data with MIME base64. - Parameters:
- data - the data to encode
- Returns:
- string
8 Preferences
Class Ax.util.Preferences
Constructor Summary
Method Summary
Constructor Detail
Ax.util.Preferences.JSPreferences
-
Ax.util.Preferences.JSPreferences( string name )
- Info:
-
Creates a new preferences node with the given name, or retrieves it if it already exists. - Parameters:
- name -
let prefs = new Ax.utils.Preferences("newNode");
Method Detail
Ax.util.Preferences.getBoolean
-
boolean Ax.util.Preferences.getBoolean( string key, boolean def )
- Info:
-
Returns the boolean value represented by the string associated with the specified key in this preference node. - Parameters:
- key - key whose associated value is to be returned as a boolean
- def - the value to be returned in the event that this preference node has no value associated with key or the associated value cannot be interpreted as a boolean, or the backing store is inaccessible
- Returns:
- boolean
Ax.util.Preferences.getDouble
-
double Ax.util.Preferences.getDouble( string key, double def )
- Info:
-
Returns the double value represented by the string associated with the specified key in this preference node. - Parameters:
- key - key whose associated value is to be returned as a double
- def - the value to be returned in the event that this preference node has no value associated with key or the associated value cannot be interpreted as a double, or the backing store is inaccessible
- Returns:
- double
Ax.util.Preferences.getInt
-
smallint Ax.util.Preferences.getInt( string key, smallint def )
- Info:
-
Returns the int value represented by the string associated with the specified key in this preference node. - Parameters:
- key - key whose associated value is to be returned as an int.
- def - the value to be returned in the event that this preference node has no value associated with key or the associated value cannot be interpreted as an int, or the backing store is inaccessible.
- Returns:
- smallint
Ax.util.Preferences.getString
-
string Ax.util.Preferences.getString( string key, string def )
- Info:
-
Returns the string value represented by the string associated with the specified key in this preference node. - Parameters:
- key - key whose associated value is to be returned as a string
- def - the value to be returned in the event that this preference node has no value associated with key or the associated value cannot be interpreted as a string, or the backing store is inaccessible
- Returns:
- string
Ax.util.Preferences.setBoolean
-
null Ax.util.Preferences.setBoolean( string key, boolean def )
- Info:
-
Associates a string representing the specified boolean value with the specified key in this preference node. - Parameters:
- key - key with which the value is to be associated
- def - value to be associated with the key
- Returns:
- null
Ax.util.Preferences.setDouble
-
null Ax.util.Preferences.setDouble( string key, double def )
- Info:
-
Associates a string representing the specified double value with the specified key in this preference node. - Parameters:
- key - key with which the value is to be associated
- def - value to be associated with the key
- Returns:
- null
Ax.util.Preferences.setInt
-
null Ax.util.Preferences.setInt( string key, smallint def )
- Info:
-
Associates a string representing the specified int value with the specified key in this preference node. - Parameters:
- key - key with which the value is to be associated
- def - value to be associated with the key
- Returns:
- null
Ax.util.Preferences.setString
-
null Ax.util.Preferences.setString( string key, string def )
- Info:
-
Associates a string with the specified key in this preference node. - Parameters:
- key - key with which the value is to be associated
- def - value to be associated with the key
- Returns:
- null
9 Hex
Class Ax.util.Hex
Constructor Summary
Method Summary
Constructor Detail
Ax.util.Hex.JSHex
-
Ax.util.Hex.JSHex()
Method Detail
Ax.util.Hex.decode
-
byte[] Ax.util.Hex.decode( string text )
- Info:
-
Decodes the text content in hexadecimal. - Parameters:
- text - the text with the hexadecimal value to decode
- Returns:
- byte[]
var conversor = new Ax.util.Hex(); console.log(conversor.encode("Hello world".getBytes()));
Ax.util.Hex.encode
-
string Ax.util.Hex.encode( byte[] data )
- Info:
-
Encodes the data to hexadecimal. - Parameters:
- data - the data to encode
- Returns:
- string
var conversor = new Ax.util.Hex(); console.log(conversor.decode("48656c6c6f20776f726c64"));
10 UUID
Class Ax.util.UUID
Constructor Summary
Method Summary
Constructor Detail
Ax.util.UUID.JSUUID
-
Ax.util.UUID.JSUUID()
- Info:
-
Creates a new random UUID.
var uuid = new Ax.util.UUID();
Ax.util.UUID.JSUUID
-
Ax.util.UUID.JSUUID( string s )
- Parameters:
- s -
Method Detail
Ax.util.UUID.toString
-
string Ax.util.UUID.toString()
- Info:
-
Returns the UUID as a String. - Returns:
- string
11 RegEx
Class Ax.util.RegEx
Constructor Summary
Method Summary
Constructor Detail
Ax.util.RegEx.JSRegEx
-
Ax.util.RegEx.JSRegEx( string regex )
- Info:
-
Creates a new regular expression instance. - Parameters:
- regex - the regular expression
let regex = new Ax.util.RegEx("#\\w+-\\d+");
Method Detail
Ax.util.RegEx.parse
-
string Ax.util.RegEx.parse( string input, object config )
- Info:
-
Parses the given input with the processsing configuration function. config returns the formatted string to apply the input to. - Parameters:
- input - the text to apply the regex to
- config - the processing function, returns the text template to ad the imput to
- Returns:
- string
var input = "First: #AA-1010, Second #AB-2020"; return new Ax.util.RegEx("#\\w+-\\d+").parse(input, (matcher, _) => { var tag = matcher.group(0); return Ax.lang.String.format("<a href='http://data/%s'>%s</a>", tag, tag).toString(); });
12 Formatter
Class Ax.util.locale.Formatter
Constructor Summary
Method Summary
Constructor Detail
Ax.util.locale.Formatter.JSLocaleFormatter
-
Ax.util.locale.Formatter.JSLocaleFormatter( string lang )
- Info:
-
Creates a new locale formatter from a language code. - Parameters:
- lang - the language to get the formatter
var lf_es = new Ax.util.locale.Formatter("es");
Ax.util.locale.Formatter.JSLocaleFormatter
-
Ax.util.locale.Formatter.JSLocaleFormatter( string lang, string country )
- Info:
-
Creates a new locale formatter from a language and country. - Parameters:
- lang - the language to get the formatter
- country - the country to get the formatter
Ax.util.locale.Formatter.JSLocaleFormatter
-
Ax.util.locale.Formatter.JSLocaleFormatter( object locale )
- Info:
-
Creates a new locale formatter from the given Locale. - Parameters:
- locale - the source Locale
Method Detail
Ax.util.locale.Formatter.__format
-
string Ax.util.locale.Formatter.__format( object arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- string
Ax.util.locale.Formatter.format
-
string Ax.util.locale.Formatter.format( object arg0 )
- Parameters:
- arg0 -
- Returns:
- string
Ax.util.locale.Formatter.format
-
string Ax.util.locale.Formatter.format( object arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- string
Ax.util.locale.Formatter.format
-
string Ax.util.locale.Formatter.format( object arg0, smallint arg1, smallint arg2 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- Returns:
- string
Ax.util.locale.Formatter.getDateFormat
-
object Ax.util.locale.Formatter.getDateFormat()
- Returns:
- object
Ax.util.locale.Formatter.getDateFormatSymbols
-
object Ax.util.locale.Formatter.getDateFormatSymbols()
- Returns:
- object
Ax.util.locale.Formatter.getDecimalFormat
-
object Ax.util.locale.Formatter.getDecimalFormat()
- Returns:
- object
Ax.util.locale.Formatter.getDecimalFormatSymbols
-
object Ax.util.locale.Formatter.getDecimalFormatSymbols()
- Returns:
- object
Ax.util.locale.Formatter.getDecimalSeparatorChar
-
object Ax.util.locale.Formatter.getDecimalSeparatorChar()
- Returns:
- object
Ax.util.locale.Formatter.getLang
-
string Ax.util.locale.Formatter.getLang()
- Returns:
- string
Ax.util.locale.Formatter.getLocale
-
object Ax.util.locale.Formatter.getLocale()
- Returns:
- object
Ax.util.locale.Formatter.getName
-
string Ax.util.locale.Formatter.getName()
- Returns:
- string
Ax.util.locale.Formatter.getNumberFormat
-
object Ax.util.locale.Formatter.getNumberFormat()
- Returns:
- object
Ax.util.locale.Formatter.getTimeFormat
-
object Ax.util.locale.Formatter.getTimeFormat()
- Returns:
- object
Ax.util.locale.Formatter.getTimeZone
-
object Ax.util.locale.Formatter.getTimeZone()
- Returns:
- object
Ax.util.locale.Formatter.getTimestampFormat
-
object Ax.util.locale.Formatter.getTimestampFormat()
- Returns:
- object
Ax.util.locale.Formatter.main
-
null Ax.util.locale.Formatter.main( string[] arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.locale.Formatter.setDateFormat
-
object Ax.util.locale.Formatter.setDateFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setDateFormats
-
null Ax.util.locale.Formatter.setDateFormats( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.locale.Formatter.setDecimalFormatSymbols
-
object Ax.util.locale.Formatter.setDecimalFormatSymbols( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setJDBCDriver
-
object Ax.util.locale.Formatter.setJDBCDriver( resultset arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setJDBCDriver
-
object Ax.util.locale.Formatter.setJDBCDriver( object arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setSQLDateFormat
-
object Ax.util.locale.Formatter.setSQLDateFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setSQLTimeFormat
-
object Ax.util.locale.Formatter.setSQLTimeFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setSQLTimestampFormat
-
object Ax.util.locale.Formatter.setSQLTimestampFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setScale
-
object Ax.util.locale.Formatter.setScale( smallint arg0, smallint arg1 )
- Parameters:
- arg0 -
- arg1 -
- Returns:
- object
Ax.util.locale.Formatter.setScale
-
object Ax.util.locale.Formatter.setScale( smallint arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setTimeFormat
-
object Ax.util.locale.Formatter.setTimeFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setTimeZone
-
object Ax.util.locale.Formatter.setTimeZone( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.setTimestampFormat
-
object Ax.util.locale.Formatter.setTimestampFormat( string arg0 )
- Parameters:
- arg0 -
- Returns:
- object
Ax.util.locale.Formatter.toString
-
string Ax.util.locale.Formatter.toString( object arg0, smallint arg1, smallint arg2, string arg3 )
- Parameters:
- arg0 -
- arg1 -
- arg2 -
- arg3 -
- Returns:
- string
13 JarArchive
Class Ax.util.jar.JarArchive
Constructor Summary
Method Summary
Constructor Detail
Ax.util.jar.JarArchive.JSJarArchive
-
Ax.util.jar.JarArchive.JSJarArchive()
- Info:
-
Creates a new JarArchive instance.
var jar = new Ax.util.jar.JarArchive();
Ax.util.jar.JarArchive.JSJarArchive
-
Ax.util.jar.JarArchive.JSJarArchive( string name )
- Info:
-
Creates a new JarArchive instance with the given name. - Parameters:
- name - the jar name
Ax.util.jar.JarArchive.JSJarArchive
-
Ax.util.jar.JarArchive.JSJarArchive( file file )
- Info:
-
Creates a new JarArchive instance for the given file. - Parameters:
- file - the source file
var jar = new Ax.util.jar.JarArchive(new Ax.io.File("/tmp/documents.jar"))
Ax.util.jar.JarArchive.JSJarArchive
-
Ax.util.jar.JarArchive.JSJarArchive( object blob )
- Info:
-
Creates a new JarArchive instance from the blob contents. - Parameters:
- blob - the source blob
Ax.util.jar.JarArchive.JSJarArchive
-
Ax.util.jar.JarArchive.JSJarArchive( object blob )
- Info:
-
Creates a new JarArchive instance from the blob contents. - Parameters:
- blob - the source blob
Method Detail
Ax.util.jar.JarArchive.__toResultSet
-
resultset Ax.util.jar.JarArchive.__toResultSet( object value )
- Parameters:
- value -
- Returns:
- resultset
Ax.util.jar.JarArchive.add
-
null Ax.util.jar.JarArchive.add( string name, object source )
- Info:
-
Adds a file entry to the jar file. - Parameters:
- name - file name
- source - file source code/text
- Returns:
- null
Ax.util.jar.JarArchive.add
-
null Ax.util.jar.JarArchive.add( file source )
- Info:
-
Adds a file entry to the jar file. - Parameters:
- source - the source file
- Returns:
- null
Ax.util.jar.JarArchive.add
-
null Ax.util.jar.JarArchive.add( file source )
- Info:
-
Adds a file entry to the jar file. - Parameters:
- source - the source file
- Returns:
- null
Ax.util.jar.JarArchive.asJSON
-
string Ax.util.jar.JarArchive.asJSON()
- Info:
-
This is a vanilla JSON, not convertible back to ResultSet - Returns:
- string
Ax.util.jar.JarArchive.asJSON
-
null Ax.util.jar.JarArchive.asJSON( object config )
- Parameters:
- config -
- Returns:
- null
Ax.util.jar.JarArchive.compare
-
object Ax.util.jar.JarArchive.compare( object other )
- Info:
-
Compare two resultset withs a default delta - Parameters:
- other -
- Returns:
- object
Ax.util.jar.JarArchive.compare
-
object Ax.util.jar.JarArchive.compare( object other, double delta )
- Parameters:
- other -
- delta -
- Returns:
- object
Ax.util.jar.JarArchive.cursor
-
object Ax.util.jar.JarArchive.cursor()
- Returns:
- object
Ax.util.jar.JarArchive.equals
-
boolean Ax.util.jar.JarArchive.equals( object other )
- Info:
-
Compare two resultset withs a default delta - Parameters:
- other -
- Returns:
- boolean
Ax.util.jar.JarArchive.equals
-
boolean Ax.util.jar.JarArchive.equals( object other, double delta )
- Parameters:
- other -
- delta -
- Returns:
- boolean
Ax.util.jar.JarArchive.isResultSet
-
boolean Ax.util.jar.JarArchive.isResultSet( object value )
- Parameters:
- value -
- Returns:
- boolean
Ax.util.jar.JarArchive.iterator
-
object Ax.util.jar.JarArchive.iterator()
- Info:
-
Returns an iterator over the jar archive entries. - Returns:
- object
Ax.util.jar.JarArchive.stream
-
object Ax.util.jar.JarArchive.stream()
- Info:
-
Returns the jar archive as a Stream. - Returns:
- object
Ax.util.jar.JarArchive.toBlob
-
object Ax.util.jar.JarArchive.toBlob()
- Info:
-
Converts the jar archive to a blob. - Returns:
- object
Ax.util.jar.JarArchive.toBytes
-
byte[] Ax.util.jar.JarArchive.toBytes()
- Info:
-
Converts the jar archive to a bytearray. - Returns:
- byte[]
Ax.util.jar.JarArchive.toCSV
-
string Ax.util.jar.JarArchive.toCSV()
- Info:
-
Convert a ResultSet to CSV - Returns:
- string
Ax.util.jar.JarArchive.toCSV
-
null Ax.util.jar.JarArchive.toCSV( object config )
- Info:
-
Convert a ResultSet to CSV using a provided configurator - Parameters:
- config -
- Returns:
- null
Ax.util.jar.JarArchive.toExcel
-
byte[] Ax.util.jar.JarArchive.toExcel()
- Info:
-
Convert a ResultSet to Excel without consumer, returning directly it's bytes using default type (XLSX) - Returns:
- byte[]
Ax.util.jar.JarArchive.toExcel
-
null Ax.util.jar.JarArchive.toExcel( object config )
- Info:
-
Convert a ResultSet to CSV using a provided configurator - Parameters:
- config -
- Returns:
- null
Ax.util.jar.JarArchive.toFOP
-
string Ax.util.jar.JarArchive.toFOP()
- Returns:
- string
Ax.util.jar.JarArchive.toFOP
-
string Ax.util.jar.JarArchive.toFOP( object config )
- Info:
-
Convert the ResultSet to a FOP XML document - Parameters:
- config -
- Returns:
- string
Ax.util.jar.JarArchive.toFOPTableBody
-
string Ax.util.jar.JarArchive.toFOPTableBody( double width )
- Parameters:
- width -
- Returns:
- string
Ax.util.jar.JarArchive.toFOPTableBody
-
string Ax.util.jar.JarArchive.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
Ax.util.jar.JarArchive.toHTML
-
string Ax.util.jar.JarArchive.toHTML()
- Returns:
- string
Ax.util.jar.JarArchive.toHTML
-
string Ax.util.jar.JarArchive.toHTML( object config )
- Info:
-
Convert the ResultSet to a HTML document - Parameters:
- config -
- Returns:
- string
Ax.util.jar.JarArchive.toInputStream
-
object Ax.util.jar.JarArchive.toInputStream()
- Info:
-
Returns an InputStream for the jar archive - Returns:
- object
Ax.util.jar.JarArchive.toJSON
-
string Ax.util.jar.JarArchive.toJSON()
- Info:
-
Convert a ResultSet to JSON that can be digested by aa JSON2ResultSet again into a SQLResultSetArray - Returns:
- string
Ax.util.jar.JarArchive.toJSON
-
string Ax.util.jar.JarArchive.toJSON( object config )
- Info:
-
Convert a ResultSet to JSON - Parameters:
- config -
- Returns:
- string
Ax.util.jar.JarArchive.toJavaScript
-
string Ax.util.jar.JarArchive.toJavaScript()
- Info:
-
Convert the ResultSet to a Javascript declaration (useful for coding) - Returns:
- string
Ax.util.jar.JarArchive.toPDF
-
byte[] Ax.util.jar.JarArchive.toPDF()
- Returns:
- byte[]
Ax.util.jar.JarArchive.toPDF
-
byte[] Ax.util.jar.JarArchive.toPDF( object config )
- Info:
-
Convert the ResultSet to a PDF document - Parameters:
- config -
- Returns:
- byte[]
Ax.util.jar.JarArchive.toPDF
-
byte[] Ax.util.jar.JarArchive.toPDF( string fop )
- Info:
-
Useful method for testing so we can produce a FOP and transform to PDF - Parameters:
- fop -
- Returns:
- byte[]
Ax.util.jar.JarArchive.toResultSet
-
resultset Ax.util.jar.JarArchive.toResultSet()
- Info:
-
Generates a ResultSet from the jar archive. - Returns:
- resultset
Ax.util.jar.JarArchive.toResultSet
-
resultset Ax.util.jar.JarArchive.toResultSet( object value )
- Info:
-
Perform a conversion to resultset - Parameters:
- value -
- Returns:
- resultset
Ax.util.jar.JarArchive.toRow
-
object Ax.util.jar.JarArchive.toRow()
- Returns:
- object
Ax.util.jar.JarArchive.toSQLCA
-
object Ax.util.jar.JarArchive.toSQLCA( object value )
- Info:
-
Converts the object to SQLCA - Parameters:
- value -
- Returns:
- object
Ax.util.jar.JarArchive.toText
-
string Ax.util.jar.JarArchive.toText()
- Returns:
- string
Ax.util.jar.JarArchive.toText
-
string Ax.util.jar.JarArchive.toText( object config )
- Info:
-
Convert the ResultSet to a TEXT document - Parameters:
- config -
- Returns:
- string
Ax.util.jar.JarArchive.toXLS
-
byte[] Ax.util.jar.JarArchive.toXLS()
- Info:
-
Convert a ResultSet to Excel (XLS) - Returns:
- byte[]
Ax.util.jar.JarArchive.toXLSX
-
byte[] Ax.util.jar.JarArchive.toXLSX()
- Info:
-
Convert a ResultSet to Excel (XLSX using streaming api) - Returns:
- byte[]
14 Object
Class Ax.util.js.object
Method Summary
Method Detail
Ax.util.js.object.assign
-
static object Ax.util.js.object.assign( object[] args )
- Info:
-
This method copies all enumerable own properties from one or more source objects to a target object. It returns the target object. - Parameters:
- args - the source objects
- Returns:
- object
const source = { b: 4, c: 5 }; let row = Ax.db.executeQuery("SELECT tabname , tabid , 3 as b FROM systables").firstOne() const obj = Ax.util.js.object.assign( { a: 1, b: 2 }, row); const obj2 = Ax.util.js.object.assign( { a: 1, b: 2 }, source); // { "tabid": 1, "a": 1, "tabname": "systables", "b": 3 } // { "a": 1, "b": 4, "c": 5 }
15 CRC32
Class Ax.util.zip.CRC32
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.CRC32.JSCRC32
-
Ax.util.zip.CRC32.JSCRC32()
- Info:
-
Creates a new CRC instance.
var crc32 = new Ax.util.zip.CRC32();
Method Detail
Ax.util.zip.CRC32.getCRC
-
long Ax.util.zip.CRC32.getCRC()
- Info:
-
Returns the CRC-32 value. - Returns:
- long
Ax.util.zip.CRC32.update
-
null Ax.util.zip.CRC32.update( object data )
- Info:
-
Updates the CRC-32 checksum with the specified array of bytes. - Parameters:
- data -
- Returns:
- null
16 Zip
Class Ax.util.zip.Zip
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.Zip.JSZip
-
Ax.util.zip.Zip.JSZip( object blob )
- Info:
-
Creates a new zip compressor instance with the given Blob as destination. - Parameters:
- blob - the destination Blob object
Ax.util.zip.Zip.JSZip
-
Ax.util.zip.Zip.JSZip( file file )
- Info:
-
Creates a new zip compressor instance with the given file as destination. - Parameters:
- file - the destination file
var zip = new Ax.util.zip.Zip(new Ax.io.File("/tmp/ziptest.zip"));
Method Detail
Ax.util.zip.Zip.close
-
null Ax.util.zip.Zip.close()
- Info:
-
Flushes data to the destination resource and closes all resources. Otherwise it will happen on script termination. - Returns:
- null
Ax.util.zip.Zip.zipBlob
-
null Ax.util.zip.Zip.zipBlob( object blob )
- Info:
-
Compresses the given Blob object and attaches it to the destination zip container. - Parameters:
- blob - the Blob to compress
- Returns:
- null
Ax.util.zip.Zip.zipBlob
-
null Ax.util.zip.Zip.zipBlob( object blob, string name )
- Info:
-
Compresses the given Blob object and attaches it to the destination zip container. The second parameter will be the file name inside the zip container (can be a relative path). - Parameters:
- blob - the Blob to compress
- name - the file name in the zip container
- Returns:
- null
Ax.util.zip.Zip.zipFile
-
null Ax.util.zip.Zip.zipFile( file file )
- Info:
-
Compresses the given file and attaches it to the destination zip container. - Parameters:
- file - the file to compress
- Returns:
- null
Ax.util.zip.Zip.zipFile
-
null Ax.util.zip.Zip.zipFile( file file, string fileName )
- Info:
-
Compresses the given file and attaches it to the destination zip container. The second parameter will be the file name inside the zip container (can be a relative path). - Parameters:
- file - the file to compress
- fileName - the file name in the zip container
- Returns:
- null
Ax.util.zip.Zip.zipFile
-
null Ax.util.zip.Zip.zipFile( object blob )
- Info:
-
Compresses the given Blob object and attaches it to the destination zip container. - Parameters:
- blob - the Blob to compress
- Returns:
- null
Ax.util.zip.Zip.zipFile
-
null Ax.util.zip.Zip.zipFile( object blob, string name )
- Info:
-
Compresses the given Blob object and attaches it to the destination zip container. The second parameter will be the file name inside the zip container (can be a relative path). - Parameters:
- blob - the Blob to compress
- name - the file name in the zip container
- Returns:
- null
17 Unzip
Class Ax.util.zip.Unzip
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.Unzip.JSUnzip
-
Ax.util.zip.Unzip.JSUnzip( byte[] data )
- Info:
-
Creates a new zip uncompressor instance with the given compressed source and destination. - Parameters:
- data - the compressed data
Ax.util.zip.Unzip.JSUnzip
-
Ax.util.zip.Unzip.JSUnzip( byte[] data, string tempDirName )
- Info:
-
Creates a new zip uncompressor instance with the given compressed source and destination. - Parameters:
- data - the compressed data
- tempDirName -
Ax.util.zip.Unzip.JSUnzip
-
Ax.util.zip.Unzip.JSUnzip( byte[] data, file destDir )
- Info:
-
Creates a new zip uncompressor instance with the given compressed source and destination. - Parameters:
- data - the compressed data
- destDir - the uncompression destination file
Ax.util.zip.Unzip.JSUnzip
-
Ax.util.zip.Unzip.JSUnzip( object blob, file destDir )
- Info:
-
Creates a new zip uncompressor instance with the given compressed source and destination. - Parameters:
- blob - the compressed data
- destDir - the uncompression destination file
Ax.util.zip.Unzip.JSUnzip
-
Ax.util.zip.Unzip.JSUnzip( file file, file destDir )
- Info:
-
Creates a new zip uncompressor instance with the given compressed source and destination. - Parameters:
- file - the compressed data
- destDir - the uncompression destination file
var compressed = new Ax.io.File("/tmp/ziptest.zip"); for (var file of new Ax.util.zip.Unzip(compressed, new Ax.io.File("/tmp/unzipdir"))) { console.log("Unzipped: " + file); }
Method Detail
Ax.util.zip.Unzip.forEach
-
null Ax.util.zip.Unzip.forEach( object arg0 )
- Parameters:
- arg0 -
- Returns:
- null
Ax.util.zip.Unzip.iterator
-
object Ax.util.zip.Unzip.iterator()
- Info:
-
Provides an iterator over the unzipped files. - Returns:
- object
Ax.util.zip.Unzip.spliterator
-
object Ax.util.zip.Unzip.spliterator()
- Returns:
- object
18 Gzip
Class Ax.util.zip.Gzip
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.Gzip.JSGzip
-
Ax.util.zip.Gzip.JSGzip()
- Info:
-
Creates a new Gzip compressor object to memory destination
Ax.util.zip.Gzip.JSGzip
-
Ax.util.zip.Gzip.JSGzip( object blob )
- Info:
-
Creates a new Gzip compressor object with a Blob object as a destination for the compressed data. - Parameters:
- blob - the source Blob object
Ax.util.zip.Gzip.JSGzip
-
Ax.util.zip.Gzip.JSGzip( file file )
- Info:
-
Creates a new Gzip compressor object with a file as a destination for the compressed data. - Parameters:
- file - the source file
var src = new Ax.io.File("/etc/services"); var gzip = new Ax.util.zip.Gzip(dst);
Method Detail
Ax.util.zip.Gzip.close
-
null Ax.util.zip.Gzip.close()
- Info:
-
Flushes data to the destination resource and closes all resources. Otherwise it will happen on script termination. - Returns:
- null
Ax.util.zip.Gzip.compress
-
object Ax.util.zip.Gzip.compress( object src )
- Info:
-
Compresses the given object to the destination resource using gzip. The source object must be convertible to InputStream (file, Blob, URL, byte[]...). - Parameters:
- src - the source object to compress
- Returns:
- object
Ax.util.zip.Gzip.getBytes
-
byte[] Ax.util.zip.Gzip.getBytes()
- Returns:
- byte[]
Ax.util.zip.Gzip.toBase64
-
string Ax.util.zip.Gzip.toBase64()
- Returns:
- string
19 Gunzip
Class Ax.util.zip.Gunzip
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.Gunzip.JSGunzip
-
Ax.util.zip.Gunzip.JSGunzip( byte[] data )
- Info:
-
Creates a new Gunzip uncompressor object with a compressed file as source of compressed data. - Parameters:
- data - the source byte[] object
Ax.util.zip.Gunzip.JSGunzip
-
Ax.util.zip.Gunzip.JSGunzip( string base64 )
- Info:
-
Creates a new Gunzip uncompressor object with a compressed file as source of compressed data. - Parameters:
- base64 -
Ax.util.zip.Gunzip.JSGunzip
-
Ax.util.zip.Gunzip.JSGunzip( object blob )
- Info:
-
Creates a new Gunzip uncompressor object with a compressed file as source of compressed data. - Parameters:
- blob - the source Blob object
Ax.util.zip.Gunzip.JSGunzip
-
Ax.util.zip.Gunzip.JSGunzip( file file )
- Info:
-
Creates a new Gunzip uncompressor object with a Blob object as source of compressed data. - Parameters:
- file - the source file
var src = new Ax.io.File("/tmp/services.gz"); var gunzip = new Ax.util.zip.Gunzip(src);
Method Detail
Ax.util.zip.Gunzip.getBytes
-
byte[] Ax.util.zip.Gunzip.getBytes()
- Returns:
- byte[]
Ax.util.zip.Gunzip.uncompress
-
byte[] Ax.util.zip.Gunzip.uncompress()
- Info:
-
Uncompresses the source data. - Returns:
- byte[]
20 Bzip2
Class Ax.util.zip.Bzip2
Constructor Summary
Method Summary
Constructor Detail
Ax.util.zip.Bzip2.JSBzip2
-
Ax.util.zip.Bzip2.JSBzip2()
- Info:
-
Creates a new bzip2 compressor instance.
var bzip2 = new Ax.util.zip.Bzip2();
Method Detail
Ax.util.zip.Bzip2.compress
-
byte[] Ax.util.zip.Bzip2.compress( object src )
- Info:
-
Compresses the source object with bzip2. The object must be convertible to InputStream (file, Blob, URL, byte[]...). - Parameters:
- src - the source object to compress
- Returns:
- byte[]
Ax.util.zip.Bzip2.uncompress
-
byte[] Ax.util.zip.Bzip2.uncompress( object src )
- Info:
-
Uncompresses the source object with b2zip. The object must be convertible to InputStream (file, Blob, URL, byte[]...). - Parameters:
- src - the compressed object
- Returns:
- byte[]