Class: File

File

new File(obj)

Create a file from the server's object representation.

Parameters:
Name Type Description
obj Object

Data from the server, which doesn't follow typical javaScript naming conventions.

Source:

Members

(readonly) action :string

Action taken at the head, one of 'add', 'edit', 'delete', 'branch', 'move_add', 'move_delete', 'integrate', 'import', 'purge', or 'archive'.

Type:
  • string
Source:

(readonly) change :string

ID of the changelist that created this file revision.

Type:
  • string
Source:

(readonly) date :Date

Date of when the file revision was created

Type:
  • Date
Source:

depotFile :string

The absolute depot path of the file

Type:
  • string
Source:

(readonly) name :string

For consistency with Node operations

Type:
  • string
Source:

(readonly) pathId :Array.<string>

For consistency with Node operations

Type:
  • Array.<string>
Source:

(readonly) revision :number

File's revision number.

Type:
  • number
Source:

(readonly) type :string

File type - one of 'text', 'binary', 'symlink', 'apple', 'resource', 'unicode', 'utf16'

Type:
  • string
Source: