All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.mmauro94.mkvtoolnix_wrapper.Exceptions.kt Maven / Gradle / Ivy

Go to download

An easy to use light kotlin-jvm wrapper for most common mkvmerge and mkvpropedit CLI commands

The newest version!
package com.github.mmauro94.mkvtoolnix_wrapper

import com.github.mmauro94.mkvtoolnix_wrapper.extract.MkvExtractCommand
import com.github.mmauro94.mkvtoolnix_wrapper.merge.MkvMergeCommand
import com.github.mmauro94.mkvtoolnix_wrapper.propedit.MkvPropEditCommand

abstract class MkvToolnixException internal constructor(message: String? = null, cause: Throwable? = null) : Exception(message, cause)

sealed class MkvToolnixCommandException(open val result: MkvToolnixCommandResult<*>, message: String? = null, cause: Throwable? = null) : MkvToolnixException(message, cause){

    class MkvPropEditException internal constructor(
        override val result: MkvToolnixCommandResult,
        message: String? = null,
        cause: Throwable? = null
    ) : MkvToolnixCommandException(result, message, cause)

    class MkvMergeException internal constructor(
        override val result: MkvToolnixCommandResult,
        message: String? = null,
        cause: Throwable? = null
    ) : MkvToolnixCommandException(result, message, cause)

    class MkvExtractException internal constructor(
        override val result: MkvToolnixCommandResult,
        message: String? = null,
        cause: Throwable? = null
    ) : MkvToolnixCommandException(result, message, cause)

}

internal typealias ExceptionInitializer = (MkvToolnixCommandResult, String?, Throwable?) -> MkvToolnixCommandException




© 2015 - 2024 Weber Informatics LLC | Privacy Policy