Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Internet Explorer alert
This browser is not recommended for use with smartdevicelink.com, and may not function properly. Upgrade to a different browser to guarantee support of all features.
close alert
Documentation
PutFile

PutFile Class Reference

Constructors

Instance Methods

Constructors

new PutFile(parameters)

Initalizes an instance of PutFile.

Instance Methods

putFile.getCrc() ⇒ Number

Get the Crc

Kind: Instance method of PutFile
Returns: Number - the KEY_CRC value

putFile.getFileData() ⇒ Uint8Array

Get the file data.

Kind: Instance method of PutFile
Returns: Uint8Array - A byte array of the file contents.

putFile.getFileName() ⇒ String

Get the FileName

Kind: Instance method of PutFile
Returns: String - the KEY_FILE_NAME value

putFile.getFileType() ⇒ FileType

Get the FileType

Kind: Instance method of PutFile
Returns: FileType - the KEY_FILE_TYPE value

putFile.getLength() ⇒ Number

Get the Length

Kind: Instance method of PutFile
Returns: Number - the KEY_LENGTH value

putFile.getOffset() ⇒ Number

Get the Offset

Kind: Instance method of PutFile
Returns: Number - the KEY_OFFSET value

putFile.getPersistentFile() ⇒ Boolean

Get the PersistentFile

Kind: Instance method of PutFile
Returns: Boolean - the KEY_PERSISTENT_FILE value

putFile.getSystemFile() ⇒ Boolean

Get the SystemFile

Kind: Instance method of PutFile
Returns: Boolean - the KEY_SYSTEM_FILE value

putFile.setCrc(crc) ⇒ PutFile

Set the Crc

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
crc Number Additional CRC32 checksum to protect data integrity up to 512 Mbits - The desired Crc. {'num_min_value': 0, 'num_max_value': 4294967295}

putFile.setFileData(fileData) ⇒ PutFile

Set the file data.

Kind: Instance method of PutFile
Returns: PutFile - The class instance to support method chaining.

ParamTypeDescription
fileData Uint8Array A byte array of the file contents.

putFile.setFileName(name) ⇒ PutFile

Set the FileName

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
name String File reference name. - The desired FileName. {'string_min_length': 1, 'string_max_length': 255}

putFile.setFileType(type) ⇒ PutFile

Set the FileType

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
type FileType Selected file type. - The desired FileType.

putFile.setLength(length) ⇒ PutFile

Set the Length

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
length Number Optional length in bytes for resuming partial data chunks If offset is set to 0, then length is the total length of the file to be downloaded - The desired Length. {'num_min_value': 0, 'num_max_value': 2000000000}

putFile.setOffset(offset) ⇒ PutFile

Set the Offset

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
offset Number Optional offset in bytes for resuming partial data chunks - The desired Offset. {'num_min_value': 0, 'num_max_value': 2000000000}

putFile.setPersistentFile(file) ⇒ PutFile

Set the PersistentFile

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
file Boolean Indicates if the file is meant to persist between sessions / ignition cycles. If set to TRUE, then the system will aim to persist this file through session / cycles. While files with this designation will have priority over others, they are subject to deletion by the system at any time. In the event of automatic deletion by the system, the app will receive a rejection and have to resend the file. If omitted, the value will be set to false. - The desired PersistentFile.

putFile.setSystemFile(file) ⇒ PutFile

Set the SystemFile

Kind: Instance method of PutFile
Returns: PutFile - The class instance for method chaining.

ParamTypeDescription
file Boolean Indicates if the file is meant to be passed thru core to elsewhere on the system. If set to TRUE, then the system will instead pass the data thru as it arrives to a predetermined area outside of core. If omitted, the value will be set to false. - The desired SystemFile.
View on GitHub.com
Previous Section Next Section