๐
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import ์๋ต | |
| public class MyIntentService extends IntentService { | |
| public MyIntentService() { | |
| super("MyIntentService"); | |
| } | |
| @Override | |
| protected void onHandleIntent(Intent intent) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... ์๋ต | |
| <uses-permission android:name="android.permission.INTERNET" /> | |
| <application | |
| android:icon="@mipmap/ic_launcher" | |
| android:label="andtest" | |
| android:usesCleartextTraffic="true"> | |
| <service | |
| android:name=".MyIntentService" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import ์๋ต | |
| // Permission - Manifest.xml : <uses-permission android:name="android.permission.FOREGROUND_SERVICE" /> | |
| public class MyService extends Service { | |
| public MyService() { | |
| } | |
| @Override | |
| public IBinder onBind(Intent intent) { | |
| // TODO: Return the communication channel to the service. | |
| throw new UnsupportedOperationException("Not yet implemented"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import ์๋ต | |
| // ๋ฐฑ๊ทธ๋ผ์ด์ฝ๋์ ์ถ๊ฐํ์์ต๋๋ค | |
| public class MainActivity3 extends AppCompatActivity { | |
| @Override | |
| protected void onCreate(Bundle savedInstanceState) { | |
| super.onCreate(savedInstanceState); | |
| setContentView(R.layout.activity_main3); | |
| ConstraintLayout c = (ConstraintLayout) findViewById(R.id.main3); | |
| ResultReceiver mRecevier = new ResultReceiver(new Handler()){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import, main ์๋ต | |
| class ForegroundPage extends StatelessWidget { | |
| @override | |
| Widget build(BuildContext context) { | |
| return Scaffold( | |
| appBar: AppBar(title: Text("Flutter Foreground")), | |
| body: Center( | |
| child: TextButton( | |
| child: Text("PLAY"), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import ์๋ต | |
| // ... ๊ธฐ์กด ๋ด์ฉ๊ณผ ๊ฐ์ด ๊ตฌ์ฑํ์์ต๋๋ค | |
| // * Service ํ์ผ ์์ฑ ๋ฐ Permission ๋ฑ๋กํด์ฃผ์ธ์(์๋๋ก์ด๋ ๋ด์ฉ์ ๋ฏธ๋ฆฌ ๋ณด์๋ฉด ์์ํฉ๋๋ค) | |
| public class MainActivity extends FlutterActivity { | |
| private static final String CHANNEL = "app.james.cam/cam"; | |
| private static final String SEND_CHANNEL = "app.james.cam/cam2"; | |
| MethodChannel sendChannel; | |
| private static final String BACK_CHANNEL2 = "app.james.cam/intentservice"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ... import ์๋ต | |
| // ... ์๋๋ก์ด๋ ๋ด์ฉ ๊ทธ๋๋ก ์ฌ์ฉ ๊ฐ๋ฅํ์ง๋ง | |
| // ์๋ฆผ์ ์ด๋ฏธ์ง ๋ด์ฉ ๋ณ๊ฒฝ ๋ฐ ์ด๋ ธํ ์ด์ ์ด ํ์ํฉ๋๋ค | |
| public class MyService extends Service { | |
| public MyService() { | |
| } | |
| @Override | |
| public IBinder onBind(Intent intent) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="ko"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
| <title>Live</title> | |
| <style> | |
| *{ | |
| padding: 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="ko"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <meta http-equiv="X-UA-Compatible" content="ie=edge" /> | |
| <title>JAMES_DEV_TEST only PeerJS</title> | |
| <style> | |
| *{ | |
| padding: 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // * Node.js ๊ฐ๋ฐ ํ ์คํธ์ฉ HTTPS pem ์์ฑ | |
| // : ํด๋น ์๋ฒ ํ์ผ์ ์์น์ keys ํด๋๋ฅผ ์์ฑํ๊ณ ์๋์ ๋ด์ฉ์ผ๋ก ์์ฑํ pem์ ๋ด์์ฃผ์ธ์. | |
| // > openssl genrsa 1024 > private.pem | |
| // > openssl req -x509 -new -key private.pem > public.pem | |
| // * npm i -s expreess https path | |
| var express = require('express'), | |
| app = express(), | |
| fs = require('fs'), |