Rebol Programming/size?

USAGE:Edit

SIZE? target 

DESCRIPTION:Edit

Returns the size of a file or URL's contents.

SIZE? is a function value.

ARGUMENTSEdit

  • target -- (Type: file url)

(SPECIAL ATTRIBUTES)Edit

  • catch

SOURCE CODEEdit

size?: func [
    "Returns the size of a file or URL's contents." 
    [catch] 
    target [file! url!] 
    /local info
][
    info: throw-on-error [info? target] 
    either none? info [none] [info/size]
]