Android Open Source - AudioChoice Audio Choice Local Server






From Project

Back to project page AudioChoice.

License

The source code is released under:

Apache License

If you think the Android project AudioChoice listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.hwrdprkns.audiochoice.server;
//from  w w w  . ja v  a2  s  .co  m
import android.content.Context;

import com.hwrdprkns.audiochoice.R;

public class AudioChoiceLocalServer extends NanoHTTPD {

    private Context context;

    public AudioChoiceLocalServer(Context context) {
        super ("localhost", 9001);
        this.context = context;
    }

    @SuppressWarnings("unused")
    public AudioChoiceLocalServer(Context context, String unusedURI) {
        this(context);
    }

    @Override public Response serve(IHTTPSession session) {
        return new Response(Response.Status.OK, "audio/mpeg", context.getResources().openRawResource(R.raw.wildfire));
    }
}




Java Source Code List

com.hwrdprkns.audiochoice.BasicMediaExtractorMediaPlayer.java
com.hwrdprkns.audiochoice.BasicMediaPlayer.java
com.hwrdprkns.audiochoice.BasicProxyMediaPlayer.java
com.hwrdprkns.audiochoice.BasicStreamMediaPlayer.java
com.hwrdprkns.audiochoice.IAudioPlayer.java
com.hwrdprkns.audiochoice.IPlayerView.java
com.hwrdprkns.audiochoice.MainActivity.java
com.hwrdprkns.audiochoice.MainFragment.java
com.hwrdprkns.audiochoice.server.AudioChoiceLocalServer.java
com.hwrdprkns.audiochoice.server.NanoHTTPD.java