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
private static final int MY_SOCKET_TIMEOUT_MS = 10000; | |
ProgressDialog ringProgressDialog; | |
ringProgressDialog = ProgressDialog.show(this, "", "please wait", true); | |
ringProgressDialog.setCancelable(false); | |
ringProgressDialog.show(); | |
StringRequest request = new StringRequest(Request.Method.POST, End_Points.CHECK_LEAVES, | |
new Response.Listener<String>() { | |
@Override |
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
public class Insta extends Fragment { | |
WebView webView; | |
@Override | |
public View onCreateView(LayoutInflater inflater, ViewGroup container, | |
Bundle savedInstanceState) { | |
View root = inflater.inflate(R.layout.activity_my_insta, container, | |
false); | |
webView=(WebView)root.findViewById(R.id.webView); | |
WebSettings webSettings=webView.getSettings(); |
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
<?php | |
$name=$_POST['name']; | |
echo $name | |
?> |
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
<?php | |
$conn = new mysqli("localhost", "example", "password", "yourDB"); | |
// Check connection | |
if ($conn->connect_error) { | |
die("Connection failed: " . $conn->connect_error); | |
} |
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
<?php | |
$conn = new mysqli("localhost", "example", "password", "yourDB"); | |
// Check connection | |
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
<?php | |
$conn = new mysqli("localhost", "example", "password", "yourDB"); | |
// Check connection | |
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
package dorid; | |
import java.awt.LinearGradientPaint; | |
public class LinearSearchClass { | |
static int [] numAarray; | |
public static void main(String[] args) { | |
// TODO Auto-generated method stub | |
numAarray=new int[]{3,2,4,5,6,6,7,8,9,9,0,9}; |
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
package dorid; | |
public class BinarySearchClass { | |
private static int[] numAarray; | |
private static final int numberToSearch = 89; | |
public static void main(String[] args) { | |
// TODO Auto-generated method stub | |
// array must be sorted |
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
Asynchronous HTTP Requests in Android Using Volley | |
Volley is the new Swiss Army Knife of Android Developers, it provides some nice utilities which makes the networking for Android apps easier and faster. The good thing about Volley is that it abstracts away the low level details of what HTTP client library is being used under the hood and helps you focus on writing nice and clean RESTful HTTP requests. Additionally all requests in Volley are executed asynchronously on a different thread without blocking your “main thread”. | |
What are the features that Volley provides? | |
Important features of the Volley library: | |
A high level API to make asynchronous RESTful HTTP requests | |
An elegant and robust Request queue |
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
Creational patterns: how you create objects. | |
Structural patterns: how you compose objects. | |
Behavioral patterns: how you coordinate object interactions. | |
Creational: | |
Builder | |
Dependency Injection | |
Singleton |
OlderNewer