Skip to main content

system

fileName​

Description​

Method that generate random file name with extension

Parameters​

NameTypeDescription
ext<String>You can define what extension to use. If the parameter passed isn't valid it will randomize from internal list

Returns​

  • <String>

Usage​

  1. Without passing parameters

    1. code
    console.log(pure.system.fileName());
    1. result
    'computer-tools.lua'
  2. Describing that i want an file name using jpeg as extension

    1. code
    console.log(pure.system.fileName('jpeg'));
    1. result
    'com-facilitator.jpeg'

commonFileName​

Description​

Method that generates random common file name with extension

Parameters​

NameTypeDescription
ext<String>You can define what extension to use. If the parameter passed isn't valid it will randomize from internal list

Returns​

  • <String>

Usage​

  1. Without passing parameters

    1. code
    console.log(pure.system.commonFileName());
    1. result
    'initiative-networks-research.wav'
  2. Describing that i want an file name using jpeg as extension

    1. code
    console.log(pure.system.commonFileName('jpeg'));
    1. result
    'fault-tolerant.jpeg'

mimeType​

Description​

Method that generate random internet media type

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.mimeType());
    1. result
    'application/vnd.paos.xml'

commonFileType​

Description​

Method that generate random common file type

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.commonFileType());
    1. result
    'video'

commonFileExt​

Description​

Method that generate random common file extension

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.commonFileExt());
    1. result
    'png'

fileType​

Description​

Method that generate random file type

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.fileType());
    1. result
    'x-shader'

fileExt​

Description​

Method that generate random file extension

Parameters​

NameTypeDescription
mimeType<String>Define what internet media type to use. If the string passed isn't valid it will randomize from internal list

Returns​

  • <String>

Usage​

  1. Without passing parameters

    1. code
    console.log(pure.system.fileExt());
    1. result
    'cdmic'
  2. Describing that i want an file extension using video/x-msvideo as mime-type

    1. code
    console.log(pure.system.fileExt('video/x-msvideo'));
    1. result
    'avi'

directoryPath​

Description​

Method that generate random fake directory path

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.directoryPath());
    1. result
    '/Applications'

filePath​

Description​

Method that generate random fake file path

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.filePath());
    1. result
    '/opt/include/card.xap'

semver​

Description​

Method that generate random semantic versioning number

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.system.semver());
    1. result
    '9.0.2'