Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow process destroying by specifying string id #173

Merged
merged 9 commits into from
Aug 9, 2022

Conversation

p3g4asus
Copy link
Collaborator

@p3g4asus p3g4asus commented Aug 7, 2022

Here I implement the @JunkFood02 idea of process destroy.

@xibr
Copy link
Collaborator

xibr commented Aug 8, 2022

I'll take a look and test it tonight if I have some free time.

Make additional checks (when possible) before killing a download process
@JunkFood02 JunkFood02 linked an issue Aug 8, 2022 that may be closed by this pull request
Copy link
Collaborator

@xibr xibr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good, I left some comments.

We may need to add the method in the sample app or add it in the readme file something like that

To cancel a specific download

YoutubeDL.getInstance().destroyProcessById( id );

@p3g4asus
Copy link
Collaborator Author

p3g4asus commented Aug 9, 2022

I made the suggested modifications and Updated both readme and example.

@xibr xibr merged commit 97327f4 into yausername:master Aug 9, 2022
JunkFood02 pushed a commit that referenced this pull request Dec 1, 2024
* Allow process destroying by specifying string id

* Throw Exception when process ID already exists.
Make additional checks (when possible) before killing a download process

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Example updated
Readme example added

Co-authored-by: iBR <[email protected]>
JunkFood02 pushed a commit that referenced this pull request Dec 1, 2024
* Allow process destroying by specifying string id

* Throw Exception when process ID already exists.
Make additional checks (when possible) before killing a download process

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Example updated
Readme example added

Co-authored-by: iBR <[email protected]>
JunkFood02 pushed a commit to JunkFood02/youtubedl-android that referenced this pull request Dec 1, 2024
* Allow process destroying by specifying string id

* Throw Exception when process ID already exists.
Make additional checks (when possible) before killing a download process

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Example updated
Readme example added

Co-authored-by: iBR <[email protected]>
JunkFood02 pushed a commit to JunkFood02/youtubedl-android that referenced this pull request Dec 1, 2024
* Allow process destroying by specifying string id

* Throw Exception when process ID already exists.
Make additional checks (when possible) before killing a download process

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Cosmetic code fixes

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Update library/src/main/java/com/yausername/youtubedl_android/YoutubeDL.java

Co-authored-by: iBR <[email protected]>

* Example updated
Readme example added

Co-authored-by: iBR <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Destroy the process to cancel a download task
3 participants