Found 1966 Articles for Apps/Applications

How to use size() in android ConcurrentLinkedDeque?

Nitya Raut
Updated on 01-Jul-2020 11:03:00

68 Views

Before getting into the example, we should know what ConcurrentLinkedDeque is, it is unbounded deque based on linked nodes. Multiple threads can access deque elements with safety.This example demonstrates about How to use size() in android ConcurrentLinkedDequeStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken a text view to show ConcurrentLinkedDeque elements.Step 3 − Add the following code to src/MainActivity.javapackage com.example.myapplication; import android.os.Build; import android.os.Bundle; ... Read More

How to make custom dialog with rounded corners in android?

Chandu yadav
Updated on 30-Jul-2019 22:30:25

5K+ Views

This example demonstrate about How to make custom dialog with rounded corners in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken button. When user click on button, it will show custom dialog.Step 3 − Add the following code to src/MainActivity.javapackage com.example.andy.myapplication; import android.os.Build; import android.os.Bundle; import android.support.annotation.RequiresApi; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Button; public class MainActivity extends ... Read More

How to use retainAll() in android CopyOnWriteArraySet?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

58 Views

Before getting into an example, we should know what CopyOnWriteArraySet is. It is a thread-safe variant of ArrayList and operations add, set, and so on by making a fresh copy of the underlying array.This example demonstrates about How to use retainAll() in android CopyOnWriteArraySetStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken a text view to show CopyOnWriteArraySet elements.Step 3 − Add the following code ... Read More

How to make custom dialog with custom dialog view actions in android?

Arjun Thakur
Updated on 30-Jul-2019 22:30:25

858 Views

This example demonstrate about How to make custom dialog with custom dialog view actions in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken button. When user click on button, it will show custom dialog.Step 3 − Add the following code to src/MainActivity.javapackage com.example.andy.myapplication; import android.os.Build; import android.os.Bundle; import android.support.annotation.RequiresApi; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Button; public class ... Read More

How to use removeLastOccurrence() in android LinkedBlockingDeque?

Nitya Raut
Updated on 30-Jul-2019 22:30:25

51 Views

Before getting into the example, we should know what LinkedBlockingDeque is. It is implemented by Collection interface and the AbstractQueue class. It provides optional boundaries based on linked nodes. It going to pass memory size to a constructor and helps to provide memory wastage in android.This example demonstrates about How to use removeLastOccurrence() in android LinkedBlockingDequeStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken text ... Read More

How to make custom dialog in android?

Chandu yadav
Updated on 30-Jul-2019 22:30:25

5K+ Views

This example demonstrate about how to make custom dialog in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken button. When user click on button, it will show custom dialog.Step 3 − Add the following code to src/MainActivity.javapackage com.example.andy.myapplication; import android.os.Build; import android.os.Bundle; import android.support.annotation.RequiresApi; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; public class MainActivity extends AppCompatActivity {    @RequiresApi(api = ... Read More

How to use removeLastOccurrence() in android ConcurrentLinkedDeque?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

48 Views

Before getting into the example, we should know what ConcurrentLinkedDeque is, it is unbounded deque based on linked nodes. Multiple threads can access deque elements with safety.This example demonstrates about How to use removeLastOccurrence() in android ConcurrentLinkedDequeStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken a text view to show ConcurrentLinkedDeque elements.Step 3 − Add the following code to src/MainActivity.javapackage com.example.myapplication; import android.os.Build; import android.os.Bundle; ... Read More

How to create a dialog with Neutral options?

George John
Updated on 30-Jul-2019 22:30:25

316 Views

This example demonstrate about How to create a dialog with Neutral options.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken button. When user click on button, it will show dialog.Step 3 − Add the following code to src/MainActivity.javapackage com.example.andy.myapplication; import android.content.DialogInterface; import android.os.Build; import android.os.Bundle; import android.support.annotation.RequiresApi; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.Toast; public class MainActivity extends AppCompatActivity {    @RequiresApi(api = ... Read More

How to use removeLast() in android LinkedBlockingDeque?

Jennifer Nicholas
Updated on 30-Jul-2019 22:30:25

48 Views

Before getting into an example, we should know what LinkedBlockingDeque is. It is implemented by Collection interface and the AbstractQueue class. It provides optional boundaries based on linked nodes. It going to pass memory size to the constructor and helps to provide memory wastage in android.This example demonstrates about How to use removeLast() in android LinkedBlockingDequeStep 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken a ... Read More

How to use Fade In and Fade Out Android Animation in Java?

Ankith Reddy
Updated on 30-Jul-2019 22:30:25

1K+ Views

Fade in and fade out animation works based on alpha animation class. This example demonstrate about How to use Fade In and Fade Out Android Animation in Java.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/login.xml.             In the above code, we have taken imageview and two button. FadeIn button will provide fade enter animation to image view and FadeOut button provide fade exit animation to imageview.Step 3 − ... Read More

Advertisements