MJCurPlaylistAutomation: Difference between revisions

From wiki.jriver.com
Jump to navigation Jump to search
No edit summary
 
Line 66: Line 66:
===number Continuous() (read / write)===
===number Continuous() (read / write)===
'''Description:''' the continuous state (0 = off, 1 = on)
'''Description:''' the continuous state (0 = off, 1 = on)

[[Category:COM Automation]]

Latest revision as of 05:38, 4 May 2015

interface for working with "Playing Now" (the current playlist)

Functions[edit]

number GetNumberFiles()[edit]

Description: returns the number of files in "Playing Now"
Return Value: number of files

MJFileAutomation * GetFile(number nFile)[edit]

Description: gets the MJFileAutomation interface for the given file index
Parameters:

  • nFile: the index of the file to retrieve (0 to GetNumberFiles() - 1)

Return Value: MJFileAutomation interface

void RemoveAllFiles()[edit]

Description: removes all of the files from "Playing Now" (stops playback)

boolean RemoveFile(number nFile)[edit]

Description: removes a specific file from "Playing Now"
Parameters:

  • nFile: the index of the file to retrieve (0 to GetNumberFiles() - 1)

Return Value: 0 on failure, non-zero on success

boolean AddFile(string strFilename, number nPosition)[edit]

Description: adds a file to "Playing Now"
Parameters:

  • strFilename: the filename of the file to add
  • nPosition: the position to add the file inside "Playing Now"

Return Value: 0 on failure, non-zero on success

boolean AddFileByKey(number nKey, number nPosition)[edit]

Description: Add the file to "Playing Now"
Parameters:

  • nKey: the key of the file to add
  • nPosition: the position to add the file inside "Playing Now"

Return value: 0 for failure, non-zero for success

boolean MoveFile(number nFileOld, number nFileNew)[edit]

Description: moves a file to a new location in "Playing Now"
Parameters:

  • nFileOld: the index of the file to move
  • nFileNew: the index to move the file to

Return Value: 0 on failure, non-zero on success

boolean ReShuffleFiles()[edit]

Description: shuffles "Playing Now" so it's in a random order
Return Value: 0 on failure, non-zero on success

number GetNextFile()[edit]

Description: gets the index of the "Next" file to play
Return Value: index of file (0 to GetNumberFiles() - 1)

boolean GetPreviousFile()[edit]

Description: gets the index of the "Previous" file played
Return Value: index of file (0 to GetNumberFiles() - 1)

boolean GetCanPlayNext()[edit]

Description: Determine if there is another file to play after the currently playing file
Return Value: true only if there is one

Properties[edit]

number Position() (read / write)[edit]

Description: the index of the current track (0 to GetNumberFiles() - 1)

number Shuffle() (read / write)[edit]

Description: the shuffle state (0 = off, 1 = on)

number Continuous() (read / write)[edit]

Description: the continuous state (0 = off, 1 = on)