Posts

What is a Java string?

Image
  A   Java   string is a sequence of characters that exists as an   object   of the   class   java.lang. Java strings are created and manipulated through the string class. Once created, a string is immutable -- its value cannot be changed. A string is sequence of characters. A class is a user-defined template for creating an object. A string class is a user-defined template for creating and manipulating string objects, which are sequences of characters. Methods of class string enable the following capabilities: examining individual characters in the string; comparing strings; searching strings; and copying strings with characters converted from uppercase to lowercase or vice versa.

SimpleExpandableListAdapter in Android with Example

Image
Android ExpandableListView is a view that is used to shows items as a vertically scrolling two-level list. The basic difference with ListView is it allows two levels of the display which are groups that can be easily expanded and collapsed by touching to view and their respective children’s items. In order to show the view, ExpandableListViewAdapter is used in android. In many apps, an ExpandableListView facility is required. For example: In a “city” app(for any city), if the user wants to see a list of engineering colleges/list of art colleges/list of medical colleges, etc., List of vegetables/List of fruits/List of Nuts etc., for a “jiomart” kind of app List of Hatchback/List of crosscut/List of Sedan etc., for a “Uber” kind of app