Class TranscodeQueueImpl
java.lang.Object
com.biglybt.core.devices.impl.TranscodeQueueImpl
- All Implemented Interfaces:
TranscodeQueue
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate AsyncDispatcher(package private) booleanprivate static final Stringprivate TranscodeJobImplprivate static final Objectprivate CopyOnWriteList<TranscodeQueueListener> private TranscodeManagerImpl(package private) int(package private) boolean(package private) List<TranscodeJobImpl> (package private) AESemaphore(package private) AEThread2 -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadd(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, boolean add_stopped) add(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, boolean add_stopped, boolean stream, int transcode_requirement) add(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, int transcode_requirement, boolean add_stopped) voidvoidaddListener(TranscodeQueueListener listener) protected TranscodeProviderAnalysisanalyse(TranscodeJobImpl job) protected voidanalyse(TranscodeJobImpl job, TranscodeAnalysisListener listener) protected voidprotected voidclose()protected voidvoidgenerate(IndentWriter writer) protected intgetIndex(TranscodeJobImpl job) protected TranscodeJobImplgetJob(TranscodeFile for_file) intgetJobs()longprotected voidbooleanisPaused()booleanprotected voidjobChanged(TranscodeJob job, boolean schedule, boolean persistable) protected voidprotected voidprotected voidprotected DiskManagerFileInfolookupFile(byte[] hash, int index) protected TranscodeProfilelookupProfile(String profile_id) protected TranscodeTargetlookupTarget(String target_id) voidmoveDown(TranscodeJobImpl job) voidmoveUp(TranscodeJobImpl job) voidpause()protected booleanprocess(TranscodeJobImpl job) protected voidremove(TranscodeJobImpl job, boolean force) voidvoidremoveListener(TranscodeQueueListener listener) voidresume()protected voidprotected voidschedule()voidsetMaxBytesPerSecond(long max) protected voidupdateStatus(int tick_count)
-
Field Details
-
CONFIG_FILE
- See Also:
-
KEY_XCODE_ERROR
-
manager
-
queue
List<TranscodeJobImpl> queue -
queue_sem
AESemaphore queue_sem -
queue_thread
AEThread2 queue_thread -
current_job
-
anaylsis_dispatcher
-
listeners
-
action_listeners
-
paused
volatile boolean paused -
max_bytes_per_sec
volatile int max_bytes_per_sec -
config_dirty
volatile boolean config_dirty
-
-
Constructor Details
-
TranscodeQueueImpl
-
-
Method Details
-
initialise
protected void initialise() -
process
-
schedule
protected void schedule() -
updateStatus
protected void updateStatus(int tick_count) -
checkJobStatus
protected void checkJobStatus() -
add
public TranscodeJobImpl add(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, boolean add_stopped) throws TranscodeException - Specified by:
addin interfaceTranscodeQueue- Throws:
TranscodeException
-
add
public TranscodeJobImpl add(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, int transcode_requirement, boolean add_stopped) throws TranscodeException - Specified by:
addin interfaceTranscodeQueue- Throws:
TranscodeException
-
add
public TranscodeJobImpl add(TranscodeTarget target, TranscodeProfile profile, DiskManagerFileInfo file, boolean add_stopped, boolean stream, int transcode_requirement) throws TranscodeException - Throws:
TranscodeException
-
remove
- Throws:
TranscodeActionVetoException
-
jobChanged
-
getIndex
-
getJobs
- Specified by:
getJobsin interfaceTranscodeQueue
-
getJobCount
public int getJobCount()- Specified by:
getJobCountin interfaceTranscodeQueue
-
getCurrentJob
- Specified by:
getCurrentJobin interfaceTranscodeQueue
-
isTranscoding
public boolean isTranscoding()- Specified by:
isTranscodingin interfaceTranscodeQueue
-
getJob
-
moveUp
-
moveDown
-
pause
public void pause()- Specified by:
pausein interfaceTranscodeQueue
-
isPaused
public boolean isPaused()- Specified by:
isPausedin interfaceTranscodeQueue
-
resume
public void resume()- Specified by:
resumein interfaceTranscodeQueue
-
getMaxBytesPerSecond
public long getMaxBytesPerSecond()- Specified by:
getMaxBytesPerSecondin interfaceTranscodeQueue
-
setMaxBytesPerSecond
public void setMaxBytesPerSecond(long max) - Specified by:
setMaxBytesPerSecondin interfaceTranscodeQueue
-
lookupTarget
- Throws:
TranscodeException
-
lookupProfile
- Throws:
TranscodeException
-
lookupFile
- Throws:
TranscodeException
-
analyse
protected void analyse(TranscodeJobImpl job, TranscodeAnalysisListener listener) throws TranscodeException - Throws:
TranscodeException
-
analyse
- Throws:
TranscodeException
-
configDirty
protected void configDirty() -
loadConfig
protected void loadConfig() -
saveConfig
protected void saveConfig() -
close
protected void close() -
addListener
- Specified by:
addListenerin interfaceTranscodeQueue
-
removeListener
- Specified by:
removeListenerin interfaceTranscodeQueue
-
addActionListener
- Specified by:
addActionListenerin interfaceTranscodeQueue
-
removeActionListener
- Specified by:
removeActionListenerin interfaceTranscodeQueue
-
log
-
log
-
generate
-