Advertisement
Guest User

Untitled

a guest
Oct 18th, 2018
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.71 KB | None | 0 0
  1. 2018-10-18 20:48:46.629 2262-2814/? E/ajkt: Phenotype API error. Event # bqfx@a7bff772, EventCode: 7 [CONTEXT service_id=51 ]
  2. ajjn: 29505: No config packages for log source, or config package not registered
  3. at ajlg.a(:com.google.android.gms@14367040@14.3.67 (100700-216465562):51)
  4. at ajlf.b(Unknown Source:2)
  5. at ajkt.a(:com.google.android.gms@14367040@14.3.67 (100700-216465562):105)
  6. at ajkt.a(:com.google.android.gms@14367040@14.3.67 (100700-216465562):99)
  7. at xaj.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):27)
  8. at bedi.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):2)
  9. at qfl.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):35)
  10. at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
  11. at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
  12. at qlf.run(Unknown Source:7)
  13. at java.lang.Thread.run(Thread.java:764)
  14. 2018-10-18 20:48:46.630 2262-2814/? E/AsyncOperation: serviceID=51, operation=GetExperimentTokensOperationCall
  15. OperationException[Status{statusCode=No config packages for log source, or config package not registered, resolution=null}]
  16. at ajkt.a(:com.google.android.gms@14367040@14.3.67 (100700-216465562):113)
  17. at ajkt.a(:com.google.android.gms@14367040@14.3.67 (100700-216465562):99)
  18. at xaj.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):27)
  19. at bedi.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):2)
  20. at qfl.run(:com.google.android.gms@14367040@14.3.67 (100700-216465562):35)
  21. at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
  22. at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
  23. at qlf.run(Unknown Source:7)
  24. at java.lang.Thread.run(Thread.java:764)
  25.  
  26. package com.blogspot.andrdoc.guessthecelebrity;
  27.  
  28. import android.graphics.Bitmap;
  29. import android.graphics.BitmapFactory;
  30. import android.os.AsyncTask;
  31. import android.support.v7.app.AppCompatActivity;
  32. import android.os.Bundle;
  33. import android.util.Log;
  34. import android.view.View;
  35. import android.widget.ImageView;
  36. import android.widget.TextView;
  37. import android.widget.Toast;
  38.  
  39. import java.io.InputStream;
  40. import java.io.InputStreamReader;
  41. import java.net.HttpURLConnection;
  42. import java.net.URL;
  43. import java.util.Random;
  44. import java.util.regex.Matcher;
  45. import java.util.regex.Pattern;
  46.  
  47. import javax.net.ssl.HttpsURLConnection;
  48.  
  49. public class MainActivity extends AppCompatActivity {
  50. String toast;
  51. ImageView myimage;
  52. TextView options;
  53. TextView toption1;
  54. TextView toption2;
  55. TextView toption3;
  56. TextView toption4;
  57. Bitmap heroimg;
  58. String result;
  59. String heroimagelink;
  60. String rightheronames;
  61. String userchoice;
  62. String option1;
  63. String option2;
  64. String option3;
  65. int t=0;
  66. int i=1;
  67. int x=1;
  68.  
  69.  
  70. private class Downloadbackground extends AsyncTask<String, Void, String> {
  71.  
  72. @Override
  73. protected String doInBackground(String... strings) {
  74. URL url;
  75. HttpURLConnection httpconnect = null;
  76. try
  77. {
  78. url = new URL(strings[0]);
  79. httpconnect = (HttpURLConnection) url.openConnection();
  80. InputStream in = httpconnect.getInputStream();
  81. InputStreamReader reader = new InputStreamReader(in);
  82. int data = reader.read();
  83.  
  84. while (data != -1) {
  85. char current = (char) data;
  86. result +=current;
  87. data = reader.read();
  88.  
  89. }
  90. return result;
  91. }
  92. catch (Exception e)
  93. {
  94. e.printStackTrace();
  95. return null;
  96. }
  97. //myheropicsnnames();
  98.  
  99.  
  100. }
  101. }
  102. /*private class Downloading extends AsyncTask<String, Void, Bitmap>
  103. {
  104.  
  105. @Override
  106. protected Bitmap doInBackground(String... strings) {
  107. HttpsURLConnection httpURLConnection = null;
  108. URL url1;
  109. Bitmap myimg = null;
  110. try {
  111. url1 = new URL(strings[0]);
  112. httpURLConnection = (HttpsURLConnection) url1.openConnection();
  113. InputStream in = httpURLConnection.getInputStream();
  114. InputStreamReader reader = new InputStreamReader(in);
  115.  
  116. myimg = BitmapFactory.decodeStream(in);
  117. return myimg;
  118.  
  119.  
  120. } catch (Exception e) {
  121. e.printStackTrace();
  122. return null;
  123. }
  124.  
  125. }
  126. }*/
  127.  
  128. /*public void randomno()
  129. {
  130. Random random= new Random();
  131. t=random.nextInt(100)+1;
  132. x=random.nextInt(4)+1;
  133.  
  134. }
  135. public void myheropicsnnames()
  136. {
  137. Pattern p= Pattern.compile("src="(.*?)"");
  138. Matcher m=p.matcher(result);
  139. while (m.find())
  140. {
  141. heroimagelink=m.group(i);
  142. }
  143. Pattern k= Pattern.compile("alt="(.*?)">");
  144. Matcher l=k.matcher(result);
  145. while (l.find())
  146. {
  147. rightheronames=l.group(i);
  148. }
  149. randomno();
  150. while (l.find())
  151. {
  152. option1=l.group(t);
  153. }
  154. randomno();
  155. while (l.find())
  156. {
  157. option2=l.group(t);
  158. }
  159. randomno();
  160. while (l.find())
  161. {
  162. option3=l.group(t);
  163. }
  164. i++;
  165. }
  166. public void buttonclick(View view)
  167. {
  168. userchoice=options.getText().toString();
  169. if (userchoice==rightheronames)
  170. {
  171. toast="Fucking Awesome";
  172. }
  173. else
  174. {
  175. toast="STFU! The right answer is"+rightheronames;
  176. }
  177. Toast.makeText(this,toast,Toast.LENGTH_LONG).show();
  178. }
  179. public void gotfucked()
  180. {
  181. myimage= findViewById(R.id.imageView);
  182. myimage.setImageBitmap(heroimg);
  183. toption1=findViewById(R.id.textView);
  184. toption2=findViewById(R.id.textView2);
  185. toption3=findViewById(R.id.textView3);
  186. toption4=findViewById(R.id.textView4);
  187. if(x==1)
  188. {
  189. toption1.setText(rightheronames);
  190. toption2.setText(option1);
  191. toption3.setText(option2);
  192. toption4.setText(option3);
  193. }
  194. else if(x==2)
  195. {
  196. toption1.setText(option1);
  197. toption2.setText(rightheronames);
  198. toption3.setText(option2);
  199. toption4.setText(option3);
  200. }else if(x==3)
  201. {
  202. toption1.setText(option2);
  203. toption2.setText(option1);
  204. toption3.setText(rightheronames);
  205. toption4.setText(option3);
  206. }else
  207. {
  208. toption1.setText(option2);
  209. toption2.setText(option1);
  210. toption3.setText(option3);
  211. toption4.setText(rightheronames);
  212. }
  213. }*/
  214.  
  215.  
  216.  
  217.  
  218. @Override
  219. protected void onCreate(Bundle savedInstanceState) {
  220. super.onCreate(savedInstanceState);
  221. setContentView(R.layout.activity_main);
  222.  
  223. Downloadbackground task = new Downloadbackground();
  224. try {
  225. result = task.execute("http://www.posh24.se/kandisar").get();
  226. Log.i("Code", result);
  227. //Log.i("Links", heroimagelink);
  228. //Log.i("Names", rightheronames);
  229. }
  230. catch (Exception e)
  231. {
  232. e.printStackTrace();
  233. }
  234. /*Downloading task1 = new Downloading();
  235. try {
  236. heroimg = task1.execute("https://www.google.com").get();
  237. }
  238. catch (Exception e)
  239. {
  240. e.printStackTrace();
  241. }
  242. myheropicsnnames();
  243. gotfucked();*/
  244.  
  245.  
  246. }
  247. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement