Posts

finally block always executes aftertry block. Sofinally
block will be executed even if an unexpected exception occurs. But finally
is useful for more than just exception handling — it allows the
programmer to avoid having cleanup code accidentally bypassed by a
return,
continue,
or break. You can put cleanup code in a finally
block that is always a good practice, even when no exceptions are
anticipated.

This is part one of a test multipart e-mail.The second part is file as an attachment------=_Part_3_16554308.1316757817718Content-Type: text/plain; charset=us-ascii; name=testfile.txtContent-Transfer-Encoding: 7bitContent-Disposition: attachment; filename=testfile.txt

Hi,

This is a test file.------=_Part_3_16554308.1316757817718--
------------------…

Finally, Google launched openly for all the new social networking Google Plus + to compete Facebook. It's fast and easy transition of pictures from Piccassa to your profile. Some good features like make circles of your friends type and Hangout for video chat.

This class has been added in Java 5. Since the LinkedList class has been enhanced to implement the Queue interface, basic queues can be handled with a LinkedList. The purpose of a PriorityQueue is to create a "priority-in, priority out" not just a typical FIFO queue. A PriorityQueue's elements are ordered either by natural ordering (in which case the elements that are sorted first will be accessed first) or according to a Comparator. In either case, the elements' ordering represents their relative priority.See Example: import java.util.*; class PriorityQueueTest{ static class PQsort implements Comparator<Integer> { // inverse sort public int compare(Integer one, Integer two) { return two - one; // unboxing } } public static void main(String[] args) { int[] ia = {1,5,3,7,6,9,8 }; // unordered data PriorityQueue<Integer> pq1 =new PriorityQueue<Integer>(); // use natural order for(int x : ia) // l…

First we hope you have already updated the path environment variable by adding the Android SDK/tools path into it.

Now first see how many apk are there in your android emulator. Give the following command...

C:\Android\android-sdk\tools>adb shell ls data/appApiDemos.apkGestureBuilder.apkSoftKeyboard.apkCubeLiveWallpapers.apkcom.example.test.apkcom.example.gridviewTest.apkcom.example.android.apis.graphics.apkcom.rcreations.send2printer.apk**Note: Here as you already know that Android is a Linux based OS, so you need to use ls command to see all .apk files in app directory under data directory.
--------------------------------------------------------------------------------
Now remove the app whatever you want, use this command...C:\Android\android-sdk\tools>adb shell rm data/app/com.rcreations.send2printer.apk

Now see whether your file com.rcreations.send2printer.apkhas been removed or not.

=======List all file with their names in a existing directory on your hard disk=====String walkImageDir="C://MyDirectory//imageFiles"; File dir = new File(imageDir); System.out.println("===dir.isDirectory()====="+dir.isDirectory());