fs::unit_conv (private)

 fs::unit_conv value

Defined in packages/file-storage/tcl/file-storage-procs.tcl

Convert units to value. This should done more generic, ... we have in NaviServer c-level support for this which should be used if available in the future.

Parameters:
value (required)

Partial Call Graph (max 5 caller/called nodes):
%3 fs::max_upload_size fs::max_upload_size (public) fs::unit_conv fs::unit_conv fs::max_upload_size->fs::unit_conv

Testcases:
No testcase defined.
Source code:
    if {[regexp {^([0-9.]+)\s*(MB|KB)} $value . number unit]} {
        set value [expr {int($number * ($unit eq "KB" ? 1024 : 1024*1024))}]
    }
    return $value
Generic XQL file:
packages/file-storage/tcl/file-storage-procs.xql

PostgreSQL XQL file:
packages/file-storage/tcl/file-storage-procs-postgresql.xql

Oracle XQL file:
packages/file-storage/tcl/file-storage-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: