flyweb / flyweb-android

Android app for flyweb
2 stars 0 forks source link

Implement an embedded HTTP Server #10

Open irenewchen opened 7 years ago

irenewchen commented 7 years ago

Implement an embedded HTTP Server using NanoHTTPD. Needs to support file uploads. Should be instantiated when users indicate that they want to share files.

irenewchen commented 7 years ago

@kannanvijayan I finished this part. Added a temporary little button at the bottom of the UI from DiscoverActivity that takes us to another activity called ShareActivity, which will presumably be the screen for sharing files.

Currently the UI for ShareActivity doesn't show anything, but when you go to the activity, a server will be started. You can then visit the server by typing the IP address of your phone + port number 8080 into the browser, and send file upload requests from there. Once you send a file upload request, it should appear in Downloads on your phone if everything went well.

I'm thinking the next step is to write the UI component for selecting files to upload. Then after that, write the part where you discover files being shared in real time, similar to how you wrote the part for discovering Flyweb services.

For the UI, this is essentially task 5 of issue #9 right? Do you know if the NanoHttpd library can handle this? I think I saw some related documentation, but haven't dived into it yet.

irenewchen commented 7 years ago

New Subtasks: