10:50 am - Sunday April 30, 2017

Author Archives: veera

The unmodifiableMap() method is used to return an unmodifiable view of the specified map in descending order using unmodifiableMap(Map m)

BACK          The unmodifiableMap() method is used to return an unmodifiable view of the specified map in descending order Example Program import java.util.*; public class UnmodifiableMapclt { public static void main(String[]...

The SortedSet interface extends Set and declares the behavior of a set sorted in ascending order using synchronizedSortedSet(SortedSet s)

BACK                The SortedSet interface extends Set and declares the behavior of a set sorted in ascending order. Example Program import java.util.Collections; import java.util.SortedSet; import java.util.TreeSet; public...

sample

package SecondTask; import java.util.Collections; import java.util.SortedSet; import java.util.TreeSet; public class SynchronizedShortedtst { public static void main(String[] args) { ...

The unmodifiableList() method is used to returns an unmodifiable view of the specified list unmodifiableList(List list)

BACK The unmodifiableList() method is used to returns an unmodifiable view of the specified list. Example Program import java.util.*; public class Unmodifiablelst { public static void main(String[] args) { // creating arraylist List...

The unmodifiableCollection() method is used to return an unmodifiable view of the specified collection using unmodifiableCollection(Collection c)

BACK This Collections Program is used to set the elements using newSetFromMap() Method Example Program import java.util.*; public class UnmodifiableCltion { public static void main(String[] args) { // create a array list List<Character>...

The unmodifiableCollection() method is used to return an unmodifiable view of the specified collection using unmodifiableCollection(Collection c)

BACK          The unmodifiableCollection() method is used to return an unmodifiable view of the specified collection Example Program   </div> <div class="toolbar"></div> <div class="toolbar">package...

The unmodifiableCollection() method is used to return an unmodifiable view of the specified collection using unmodifiableCollection(Collection c)

BACK           The unmodifiableCollection() method is used to return an unmodifiable view of the specified collection Example Program import java.util.*; public class UnmodifiableCltion { public static void main(String[]...

The SortedSet interface extends Set and declares the behavior of a set sorted in ascending order using synchronizedSortedSet(SortedSet s)

BACK The SortedSet interface extends Set and declares the behavior of a set sorted in ascending order. In addition to those methods defined by Set, the SortedSet interface declares the methods summarized in below Table.The synchronizedSortedSet()...

Returns the value to which the specified key is mapped using V get(Object key)

BACK Returns the value to which the specified key is mapped using  V get(Object key) Example Program package V1; import java.util.Hashtable; public class V1 { public static void main(String args[]) { // create hash table Hashtable...

StringBuffer example program to delete a range of char V get(Object key)

BACK   StringBuffer example program to delete a range of char V get(Object key) Example Program </div> <div class="toolbar"></div> <div class="toolbar"> import java.util.Hashtable; public...

StringBuffer example program to delete a range of char

BACK   StringBuffer example program to delete a range of char Example Program public class StringBufferDeleteExample { public static void main(String[] args) { StringBuffer sb = new StringBuffer("Students"); sb.delete(3,...

Collection.frequency returns the number of elements in the specified collection frequency(Collection c, Object o)

BACK Collection.frequency returns the number of elements in the specified collection  frequency(Collection<?> c, Object o) Example Program import java.util.ArrayList; import java.util.Collections; public class Frequency { public...

This Program is used to get an enumeration over the specified collection using enumeration(Collection) method

BACK This Program is used to get an enumeration over the specified collection using enumeration(Collection<T>) method Example Program import java.util.ArrayList; import java.util.Collections; import java.util.Enumeration; import...

returns the empty set (immutable) emptySet() method

BACK This Program used to return rhe empty set values using empty() set method. Example Program import java.util.Collections; import java.util.Set; public class EmptySet { public static void main(String[] args) { Set<String>...

Iterator program to iterate the elements in the List and display it using List Iterator.

BACK Iterator program to iterate the elements in the List and display it using List Iterator. Example Program import java.util.*; public class LinkedListDemo { public static void main(String[] args) { // create a LinkedList ...

List Iterator example program is to iterate the elements in arraylist with specified position

BACK List Iterator example program is to iterate the elements in arraylist with specified position Example Program import java.util.*; public class LinkedListDemo { public static void main(String[] args) { // create a LinkedList LinkedList...

Contains object program to check whether the cbject exist in the list using Contains method

BACK Contains object program to check whether the cbject exist in the list using Contains() method Example Program import java.util.ArrayList; public class ArrayListDemo { public static void main(String[] args) { // create an...

Clear elements example program to clear the elements in the arraylist using clear() method

BACK Clear elements example program to clear the elements in the arraylist using clear() method Example Program import java.util.ArrayList; public class ClearArraylist { public static void main(String[] args) { ArrayList<Integer>...

AddAll program is to insert all elements in the specified collection into Arraylist.

BACK AddAll program is to insert all elements in the specified collection into Arraylist. using addall() method. Example Program import java.util.ArrayList; public class ArrayListDemo { public static void main(String args[]) { //...

This Collections Program is used to set the elements using newSetFromMap() Method

BACK This Collections Program is used to set the elements using newSetFromMap() Method Example Program import java.util.*; public class CollectionsDemo { public static void main(String[] args) { // create a list with n copies List...