FlowingDrawer Effect in Android

It is new Sliding Panel flowing and bouncing effect in android and swipe right to display drawer with flowing effects. Use it if you bored to see the old sliding panel drawer.

android libraries,android libraries list,android development,android library,android apps,android applications,android projects,android tools,FlowingDrawer,Github,mxn (mxn21),Android Sliding Panels

How to Use

For a working implementation of this project see the app/ folder.

Download Code

MainActivity:

@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
           ....
        mLeftDrawerLayout = (LeftDrawerLayout) findViewById(R.id.id_drawerlayout);
        FragmentManager fm = getSupportFragmentManager();
        MyMenuFragment mMenuFragment = (MyMenuFragment) fm.findFragmentById(R.id.id_container_menu);
        FlowingView mFlowingView = (FlowingView) findViewById(R.id.sv);
        if (mMenuFragment == null) {
            fm.beginTransaction().add(R.id.id_container_menu, mMenuFragment = new MyMenuFragment()).commit();
        }
        mLeftDrawerLayout.setFluidView(mFlowingView);
        mLeftDrawerLayout.setMenuFragment(mMenuFragment);
        ...
    }

activity_main.xml:

   <com.mxn.soul.flowingdrawer_core.LeftDrawerLayout

android:id="@+id/id_drawerlayout"
        xmlns:app="http://schemas.android.com/apk/res-auto"
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:clipChildren="false"
        >

        <!--content-->
        <android.support.design.widget.CoordinatorLayout
            android:id="@+id/content"
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:orientation="vertical">
        </android.support.design.widget.CoordinatorLayout>

        <!--menu-->
        <RelativeLayout
            android:layout_width="280dp"
            android:layout_height="match_parent"
            android:layout_gravity="start"
            android:clipChildren="false"
            >
            <com.mxn.soul.flowingdrawer_core.FlowingView
                android:id="@+id/sv"
                android:layout_width="match_parent"
                android:layout_height="match_parent"/>
            <FrameLayout
                android:id="@+id/id_container_menu"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:layout_alignParentLeft="true"
                android:layout_marginRight="25dp"
                android:paddingRight="10dp"
                />
        </RelativeLayout>

    </com.mxn.soul.flowingdrawer_core.LeftDrawerLayout>

You should know : Main Reason of Bad App Reviews
  • use LeftDrawerLayout as the root of xml.
  • The root has two child, first for content,second for menu.
  • menu'root alse has two child , first for FlowingView to display flowing effects,second for fragment .
  • fragment need to has a 'marginRight', for example 25dp. marginRight here is important . 'marginRight' have effect on drawer's elasticity. The more 'marginRight' is the more elastic. Try to set '10dp', '25dp' ,'50dp' to see the difference.
  • make the fragment of menu extends MenuFragment.
  • pay attention to MenuFragment's onCreateView: return setupReveal(root) ;

@Override
        public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
            View view = inflater.inflate(R.layout.fragment_menu, container,
                    false);
            .......
            return  setupReveal(view) ;
        }

  • in MenuFragment.xml ,add 'android:background="@android:color/transparent" '
  • in MainActivity,use
Helpful for you : Easy way of Multiple Image Pick in Android

mMenuFragment = new MyMenuFragment();
mLeftDrawerLayout.setFluidView(mFlowingView);
mLeftDrawerLayout.setMenuFragment(mMenuFragment);
in order .

  • you can call mLeftDrawerLayout.closeDrawer() and mLeftDrawerLayout.openDrawer() to close or open drawer automatically.

Solve : com.mysql.jdbc.exceptions.jdbc4.CommunicationsException

I spend some days to solve this problem. I have tested many approaches that have been mentioned in different web sites, but non of them worked.
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
If you get a SQLException: Connection refused or Connection timed out or a MySQL specific CommunicationsException:
solve SQLException, Connection refused, Connection timed out, MySQL specific CommunicationsException, CommunicationsException, Communications link failure

Communications link failure, then it means that the DB isn't reachable at all. This can have one or more of the following causes:


  1. IP address or hostname in JDBC URL is wrong.
  2. Hostname in JDBC URL is not recognized by local DNS server.
  3. Port number is missing or wrong in JDBC URL.
  4. DB server is down.
  5. DB server doesn't accept TCP/IP connections.
  6. DB server has run out of connections.
  7. Something in between Java and DB is blocking connections, e.g. a firewall or proxy. 

To solve the one or the other, follow the following advices:


  1. Verify and test them with ping.
  2. Refresh DNS or use IP address in JDBC URL instead.
  3. Verify it based on my.cnf of MySQL DB.
  4. Start the DB.
  5. Verify if mysqld is started without the --skip-networking option.
  6. Restart the DB and fix your code accordingly that it closes connections in finally.
  7. Disable firewall and/or configure firewall/proxy to allow/forward the port. 

Scan Credit Card in Android or iPhone

The open-source code for the card.io-Android-SDK: provides fast, easy credit card scanning in mobile apps. Entering your credit card number for online purchases is a nuisance, particularly on a small iPhone keyboard.

You likely have your credit card information stored with the online retailers that you frequent often, but for purchases at sites where you haven't saved your payment information, a new feature in mobile technology lets you scan your card instead of entering your number manually and now for android also.

Download Demo Project

Demo Image


Tap the link and it will open a scanner with a credit-card-size rectangle. Position your card and it will scan both your name and number. You will still need to manually enter the expiration date, however, and the three-digit code on the back of your card.

Mobile payments made seamless

To scan a credit card, the user simply has to hold the credit card briefly in front of the device’s camera: credit card details will automatically be recognized.

Demo Video


It does not process payments, but it can be used with any payment gateway.

Android Nutella - Next Android Version after Marshmallow

Android Nutella is the next new version of Android after launching of  Android M(Marshmallow). Hugo Barra  and Andy Rubin served Android N as product spokesperson, representing Android at press conferences and Google I/O, Google’s annual developer-focused conference at October 2015.

You should know : Best 20 Features of Andriod Marshmallow

Before leaving Google, founder of Android Andy Rubin announced the upcoming next version named Android N.
Android Nutella - Next Android Version after Marshmallow,Next Android Version after Marshmallow,Android Version after Marshmallow,Version after Marshmallow,Android Nutella

According to Andy Rubin-What I learned [at Google] is, assuming that the mobile evolution is going to evolve at a rapid pace, neural networks, deep learning and android versions are also going to continue to evolve. There is a point in time – I have no idea when it is – but end of year launching Android 6.1 named Nutell or called Android N.

Increase Battery and Data Life :

No more battery drain from seldom used apps: App Standby limits their impact on battery life so your charge lasts longer with less mobile data consumed.
In Nutella version you can charge your battery by your network strength that's interesting sound.

Simplified security with your fingerprint and eye-retina :

Skip the crazy passwords: The key is at hand or eyes. You can choose security lock by your face-detection, eye-retina or fingerprint. They unlocks your phone and lets you securely breeze through sign in and checkout on Android Pay, the Play Store and even in apps.

Only for Android Developers : Main Reason of Bad App Reviews

Not much informations gather by their interview but hopefully it make better and better our mobile technologies. 

Main Reason of Bad App Reviews

After working hard to create and launch your app, the last thing you want is negative reviews. One app maker reported that even a .1 drop in an online app rating caused a 5% decline in downloads, and a .3 decrease resulted in a 60% drop. Such problems can be prevented by making sure you know what causes negative reviews.
It should be noted that bad written reviews are not the full extent of disgruntled user expression.


Some users that are unhappy or upset will tell their friends about their bad experiences. Others may share their opinions on social media.

Geekology : Animated Email Send in Android

If you want to avoid having negative views about your app expressed in all formats, one of the best things to do is to thoroughly test it using a testing service like Monkop, before you launch. It probably also be very beneficial to test it on the largest number of devices possible. Below are nine causes of bad reviews or even app deletion.

1. Freezing

A survey of 500 consumers found that 76% of the respondents said an app that freezes might cause them to write a bad review. (This percentage was even greater than the number who said crashing would cause them to do the same, which was 71%.) If an app froze for just 5 seconds, 18% said they would delete it from their device.

2. Crashing

We have all used software or apps that crashed too often, and may have even lost important work due to crashes. User frustration is highest when an app crashes often, so an app should not be publicly launched until it is stable.

3. Bugs

Bugs are also one of the main reasons users become upset with an app, and will vent their dissatisfaction in online reviews. A buggy app will not generate positive reviews or many downloads.

4. Draining the Device Battery

Battery life is one of top issues for mobile devices, so any app that burns up a lot of energy and drains the battery is going to irritate many users. In fact, a consumer survey found that heavy battery usage was one of the main reasons a user would delete an app.

5. Bad Performance

If an app has a very slow load time, users will probably respond negatively. (One survey found that slowness could also cause users to delete an app.) Similarly, if the app doesn’t do what it is supposed to, users will become upset and may write negative reviews. Testing performance throughout the development process is more effective, instead of only doing it just before launch.

6. Poor App Localization

Research has demonstrated that another cause of negative reviews is poor localization, “Over 1/3 of all users experience poor app localization.” Source: Consumer App Usage & Preferences, Park Associates and Google, November 2013 Google Confidential and Proprietary

7. Difficult to use

Ease of use is one of things users like most - if an app is difficult to use then it will probably have a low adoption rate, negative reviews and high abandonment rate.  Launching an app before it is ready is not likely to result in success. You want to anticipate problems and solve them before users ever interact with an app. Test it before launch and gather feedback  in order to refine it before going live.

8. Poor User Interface

If an app has counter-intuitive menus, for example, the user experience will be difficult and they may lose interest if too much effort is required to learn the interface. Additionally, about 6% of apps submitted to the Apple App store are rejected due to poor design.

9. High Memory Usage

Apps that require an unusual amount of memory can be slow and cause crashes. Users don’t like slow apps, and some will not tolerate them at all.
After reading about all these problems, releasing an app to the public might seem intimidating. There is a simple and effective solution - testing your app carefully as you develop it, and again before the launch. Thoroughly document all the problems by testing your app, and then resolve all issues before any real users lay eyes on it. Using this approach you can avoid headaches and keep your users happy. Testing is a proven way to avoid negative reviews, and should be required for any app development project.

Animated Email Send in Android

This is a small attempt to attract users when they are using in app feature to send out an email. The usage of this repo serves the purpose like contacting the support desk, inviting another user over email or any other form of email based features.
How to Animated Email Send in Android, animation in android, animation with email, send email with animation in android

Why to use?

An user having used multiple applications is bored to see the traditional loading indicator, would always prefer to see something new and providing such user experience helps to retain users.

There are cases where users may not like the idea of taking them to email client app(passing an SEND_TO action intent) since the users do not like to promote an app feature from his direct email account.

You should read : Fetch your Gmail Account using Java Mail API

More often users do not return to the origin application that took him to email client app as they become busy reading the other emails - leads to fall in user engagement.

How to Use?

Very simple - Have a button in your activity and click listener to call the following call:
startActivity(new Intent(YourActivity.this,EnvelopeActivity.class));
The above will take the user to email client app for sending out an email. (I suggest not to use this because of last two reasons mentioned in 'Why to use' section.)

Download Demo Project

For handling the emails within the app:

startActivityForResult(new Intent(YourActivity.this,EnvelopeActivity.class), SOME_INTENT_REQUEST_CODE);
Have overriding onActivityResult in your calling activity to get the email subject and message part that you can use in your own app. (Refer MainActivity.java to check how to do that)

MainActivity.java
import android.content.Intent;
import android.os.Handler;
import android.support.v7.app.ActionBarActivity;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.animation.Animation;
import android.view.animation.AnimationSet;
import android.view.animation.RotateAnimation;
import android.view.animation.ScaleAnimation;
import android.view.animation.TranslateAnimation;
import android.widget.RelativeLayout;
import android.widget.TextView;


public class MainActivity extends AppCompatActivity {

    private static final int EMAIL_ACTIVITY_REQUEST = 1;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.act_main);


        findViewById(R.id.show_dialog_btn).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {

                Intent intent =new Intent(MainActivity.this, EnvelopeActivity.class);
                startActivityForResult(intent, EMAIL_ACTIVITY_REQUEST);
            }
        });


    }

    public void onActivityResult(int requestCode, int resultCode, Intent data) {

        if(requestCode == EMAIL_ACTIVITY_REQUEST && resultCode == RESULT_OK) {

            String[] to = data.getStringArrayExtra(Intent.EXTRA_EMAIL);
            String subject = data.getStringExtra(Intent.EXTRA_SUBJECT);
            String msg = data.getStringExtra(Intent.EXTRA_TEXT);

            Log.d(MainActivity.class.getSimpleName(),"To:"+to[0]);
            Log.d(MainActivity.class.getSimpleName(),"Subject:"+subject);
            Log.d(MainActivity.class.getSimpleName(),"Msg:"+msg);

            //TODO: Use your own api to send out email for the above params.

        }

    }

}

Note: Email subject and message field validations are not done, it is left to your choice of handling and you are free to edit the source.

How it looks? 


Easy way of Multiple Image Pick in Android

Smart android gallery with multiple image selection action.

Today I am going to discuss about implementation of selecting multiple photos from Gallery. You know, I personally have searched enough to find out a solution which allows me to select multiple images from android’s native gallery, I have tried different solutions to achieve the same.


Firstly make button for action and you can use it for single/multiple

Download demo

For Single image selection
luminous.ACTION_PICK for choosing single image.

For Multiple image selection
luminous.ACTION_MULTIPLE_PICK for choosing multiple image.


MainActivity.java

// For single image
Intent i = new Intent(Action.ACTION_PICK);
startActivityForResult(i, 100);

// For multiple images
Intent i = new Intent(Action.ACTION_MULTIPLE_PICK);
startActivityForResult(i, 200);

@Override
    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
        super.onActivityResult(requestCode, resultCode, data);

        if (requestCode == 100 && resultCode == Activity.RESULT_OK) {
            adapter.clear();

            viewSwitcher.setDisplayedChild(1);
            String single_path = data.getStringExtra("single_path");
            imageLoader.displayImage("file://" + single_path, imgSinglePick);

        } else if (requestCode == 200 && resultCode == Activity.RESULT_OK) {
            String[] all_path = data.getStringArrayExtra("all_path");

            ArrayList<CustomGallery> dataT = new ArrayList<CustomGallery>();

            for (String string : all_path) {
                CustomGallery item = new CustomGallery();
                item.sdcardPath = string;

                dataT.add(item);
            }

            viewSwitcher.setDisplayedChild(0);
            adapter.addAll(dataT);
        }
    }


In AndroidManifest.xml

<activity android:name="CustomGalleryActivity" >
            <intent-filter>
                <action android:name="luminous.ACTION_PICK" />
                <action android:name="luminous.ACTION_MULTIPLE_PICK" />

                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
 </activity>

Holographic Display Easy on Samsung Phone Now

The USPTO (U.S. Patent & Trademark Office) is filled with patents from each manufacturer on the market. Some make it to the market, other’s don’t, and a choose few of them are merely insane. We're not certain underneath which class this one matches under, however what we all know is a lot of you may be serious about what Samsung has under its sleeve.

A Samsung submitting from Q3 2014 has not too long ago been revealed, showcasing know-how that might enable a tool to show holograms. These wouldn't be the total-on holographic movies you see in films and different excessive-tech merchandise, although.
A mobile device is provided which is capable of displaying a hologram. The mobile device includes a main body including a screen; a light guide member disposed above the screen; an entrance optical member disposed on a surface of the light guide member; and an image hologram disposed on a surface of the light guide member and laterally spaced apart from the entrance optical member. When an area of the screen corresponding to the entrance optical member emits a light, a holographic image stored in the image hologram is displayed above the light guide member.                                                                                  - According to USPTO 
So right here’s the way it will work. This patented system would have a traditional physique and a display screen. A lightweight emission machine could be positioned proper above the display, and one other thicker materials proper above that picture supply. Because of this, it is possible for you to to visualise your icons and content material inside that piece of glass (or no matter materials is used).

Certain, it might not be what you had been anticipating, however keep in mind smartphones are restricted in house and sources, which is why Samsung’s implementation of this expertise appears to be reserved for small holograms and icons.

You can read this : Best 20 Features of Andriod Marshmallow

Regardless, it will likely be a cool function that future Samsung handsets could sport. Gimmick or not, it's going to undoubtedly be a dialog starter.

Because it goes with all patent filings, we aren't certain when, or if, this expertise is being taken to manufacturing. Samsung is fairly adventurous on the subject of adopting new purposes, although. They had been among the many first to make use of versatile shows and introduce curved smartphones. Sammy was additionally the primary to take tremendous-sized shows to the mainstream market.

Developer should see once : Amazon Appstore Features for Android Developers

The checklist goes on, so I say we've excessive possibilities of one thing coming down the street. Simply don’t quote me on that but!

However the concept is fairly cool as it could serve up as notifications. So as an alternative of strolling over to your cellphone to see if there's a e mail, textual content, or missed name, the holographic show will be capable of challenge the notification above your smartphone’s show, which we have now to confess feels like a fairly neat trick.

What do you assume? Would you wish to see a telephone that creates tiny, cute holograms on high of your telephone? Hit the feedback and tell us should you suppose it is a whole gimmick or an superior function!

Best 20 Features of Andriod Marshmallow

Google has officially announced what the M in Android M stands for, and it's Marshmallow. Here are the features you can expect from Android 6.
Here are the features that take Android Marshmallow a step further. Is it enough to steamroll iOS 9 and Windows 10? For now at least, we’ll leave that to you.

Android 6.0 Marshmallow features

So let's start with those six key areas that Google has focussed on for Marshmallow:

1. App permissions 

First up, app permissions. As had previously been speculated, app permissions have been overhauled in Android M, and you can now choose to accept or deny individual permissions as you see fit. Permissions have also been simplified, and will now be requested the first time you try to use a feature, not at the point of installation.

Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

"You don't have to agree to permissions that don't make sense to you,"
Burke said, and used WhatsApp to give an example of how this works. If you want to record a voice message, WhatsApp will prompt you with a one-time request for permission to use your mic: if you still wish to give it access and record the message, you can, but you don't have to. In this way, Android M is giving you greater control of the information apps can access, and this is a truly positive step forward for Android.

You can modify the permissions granted to apps at a later date in your Settings, or you can view permissions by type and see which apps have that permission granted. It's all about giving you much more control over your Android device.

2. Web experience

Google has been exploring trends in the way web content is consumed to provide a better user experience when interacting with websites and apps.
"Chrome Custom Tabs is a new feature that gives developers a way to harness all of Chrome's capabilities, while still keeping control of the look and feel of the experience,"
                                                                                                                    -said Burke.
Chrome Custom Tabs will allow apps to open a customized Chrome window on top of the active app, instead of launching the Chrome app separately. It's claimed that  this provides a faster and more intuitive user-experience when navigating between apps and the web.

Chrome Custom Tabs supports automatic sign-in, saved passwords, autofill, and multi-process security to assist the integration of the app and web experience. So, for example, a Pinterest custom tab will have a Pinterest share button embedded in it, can include custom overflow menu options, and doesn't require the Pinterest developers to build their own web browser.

3. Fingerprint support

Google will "standardize support" for fingerprint scanners on phones running Android Marshmallow. The new functionality will allow fingerprint scanners to be used not only to unlock phones, but to make purchases when shopping in real-life or within Play Store apps.
Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

Of course, your device will need a hardware fingerprint scanner to begin with, but with Google's full support, expect to see these appear on many more devices in the future.

4. Mobile payments

Android Pay is Google's new mobile payments system, designed to make the checkout process easier and faster. Google is aiming to provide "simplicity, security, and choice" with Android Pay, allowing you to use your existing credit cards to pay for products in more than 700,000 stores in the US.
Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

Compatible with any device featuring NFC capabilities (and running 4.4 KitKat or above), the Android Pay platform is being supported by American Express, Visa, Mastercard, and Discover, as well as carriers such as AT&T, Verizon and T-Mobile. Google's response to Apple Pay is here.

5. App links 

"When a user selects a weblink from somewhere, Android doesn't know whether to show it in a web browser, or some other app that claims support for the link." This was the problem facing the Google developers before Android Marshmallow.

You may be familiar with the 'Open with' dialogue box which appears when you try to open a link within an app on Android. You might be asked if you want to open a link with YouTube, or with Chrome, for example.

App links are being changed in Android 6.0, so that Android has a greater awareness of which apps can open content directly, instead of stopping users every time with the dialog box. If you tap a Twitter link in an email, for example, the Twitter app will open automatically instead of prompting you to ask if you want to use Twitter to view it.

This is almost a blink-and-you'll-miss-it improvement, but it's representative of Google's attention to detail: Android M is probably going to feel more usable without many people even realising why.

6. Power and charging

We all hate running out of battery and Android Marshmallow wants to ease our pain by making use of a new function called Doze to improve device standby time. By using motion detectors, Android will recognize when a device hasn’t been interacted with for a while, such as when a person is asleep or a phone has been left on a table, and reduce background processes.
Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date
Burke said that Google tested two Nexus 9 devices, one running Lollipop and one running the Android M preview, and learned that Android M will provide up to twice as much standby time. Even in Doze mode, though, Android can still start alarms or notify you of priority notifications.

Android Marshmallow also supports USB Type-C, which provides faster charging, and lets users charge other devices with their phone.

7. Improved cut, copy and paste

When you select text on a current Android device, a series of confusing icons appears at the top of the screen, and figuring out what they all do takes trial-and-error. In Android Marshmallow, the words 'cut', 'copy' and 'paste' will simply float above selected text, making the process much simpler.

It might seem a minor change, but these new cut, copy and paste options are an overdue update to one of the most commonly used features. The new, more intuitive approach mirrors the iOS way of doing things – and why not if it works?

Let's dive a bit deeper into Android 6.0 What else is new in Android Marshmallow?

What else is new in Android Marshmallow?

What else is new in Android Marshmallow?

Let's dive a bit deeper into Android 6.0 to see what awaits us when we get it.
Check first seven Android Marshmallow features Best 20 Features of Andriod Marshmallow

8. Auto Backup and Restore for Apps

Possibly the most interesting aspect of Android Marshmallow not discussed in Google’s I/O keynote speech was Android Auto Backup and Restore for Apps. This feature will be used in conjunction with Google Drive to automatically backup app data and settings with a file size of 25 MB or less.

These backups occur no more than once per day, and run only when the device is idle and connected to Wi-Fi and power. The uploaded data does not count towards your Google Drive storage quota, and is encrypted.

If you lose your device or delete the app, your previous progress will be restored the next time you install it, and it even works with apps which are side-loaded or accessed through a third-party app store.

9. New app drawer

One of the most immediately obvious visual changes to Android 6.0 is the new app drawer. This now scrolls vertically instead of horizontally, and is held against a white background, rather than a muted shade of your homepage wallpaper. Across the top of the menu you will see your four most recently used apps.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

10. Android Marshmallow RAM manager 

Google has introduced a new RAM manager to Android M, with the aim of providing users with more accurate and comprehensible information regarding the maximum and average RAM usage of apps.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

The menu can be found in Settings > Apps > Options (three dots button) > Advanced > Memory. Though it's a little hard to navigate to, the page offers a far clearer insight into app demands, and the overall effect they will have on your device.

With a reading of an individual app's RAM consumption, as well as how often it is running in the background, users will be able to better determine which apps should be removed in endless bid to increase device performance and battery life.

Android M even includes a simple bar at the top of the page displaying the current performance status of a person's handset; if it says 'good performance', you're probably running an efficient set of apps.

11. Adoptable Storage Devices

Though Google has in the past tried to step away from external storage use (the reason why none of its Nexus devices house a microSD card slot), it appears that Android Marshmallow is striking a compromise.

Adoptable Storage Devices is Google's new storage feature which essentially takes an external storage source (such as an SD card or USB drive) and formats it like an internal storage space. This means that app and personal data can be moved freely between a devices internal storage and its 'adopted' storage source.

Adopted storage devices are wrapped in a layer of encryption to soothe security concerns and both microSD cards and USB OTG drives are currently supported.

12. Android Marshmallow dark theme

Buried within the the first developer preview of the Android 6.0 settings was a 'Dark theme' option which transformed the menu background to a dark grey color rather than the normal pale shade. At the time, this only affected the settings menu, not the app drawer, and its function was purely cosmetic. Still, it looked nice on our Nexus 6 and we hoped it would get developed further.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

You can find the dark theme in Settings > Developer Options (which is enabled by tapping on your device build number seven times in the 'About Phone' page.) /
But in the second developer preview of Android 6.0, that dark theme had been removed by Google. We're not sure why this happened or if it's a permanent removal, but we're hoping to see the dark theme make a triumphant return – in more than just the Settings menu – when Android M is finalized.

13. Google Now 

Google Now has been improved upon once again with Android Marshmallow. It is now smarter than ever, and focuses on three key areas: being aware of different contexts, providing answers and helping you take action,

Google Now's context awareness understands more than100 million different places, so when you ask "How far is it to there?" Google Now know exactly which "there" you're referring to. This awareness is compounded by Google's Knowledge Graph, which understands one billion different entities, from sports teams to gas stations, TV shows to recipes.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

Google Now is also rolling out a pilot program called Now on Tap with 100 popular apps. Now on Tap provides Google Now-like content right where you are, without having to leave the app you're in. So if you're in Spotify and say "Ok Google, what is his real name?" Now on Tap will know you're talking about the musician you're listening to and provide search results right there and then.

The same goes for the content of emails. If someone asks you a question about a restaurant or to remember something on your way home, Now on Tap can automatically pop up a restaurant card with Maps info, Yelp, OpenTable and the dialer, as well as offer to set a reminder for whatever it was you were supposed to not forget.

What you need to know about Google Now on Tap

14. Visual Voicemail

Information gleaned from the Android Developer Preview issue tracker page indicated that Android M will include Visual Voicemail service accessible from the dialer. According to a report by Android Police, it appears that T-Mobile and Orange France will be the only two carriers to support the functionality, but more are sure to follow (after all, Android Marshmallow is still in its early stages).
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

What is visual voicemail? It's basically how it sounds: visual voicemail presents your voicemail with a visual interface, rather than the audio-based setup like in current Android smartphones – whereby you call your carrier and listen for instructions. Though it may seem like a small addition, the functionality requires cooperation from carriers, which may suggest why few are currently on board.

15. Rotating home screen

A surprisingly slow feature to make it to Android, the screen rotation function for the home screen has finally made an appearance. Now you can use your phone in landscape format both in apps and on the home screen.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

16. Delete screenshots

The second version of the Android M developer preview added a new delete option to the screenshot preview in the notifications shade. Previously you just had the option to share a screenshot from the notifications. Now you can delete it as well.

17. Remove status bar icons

Android Marshmallow brings toggles for which icons you see in the status bar. If, for example, you always have Bluetooth on and don't really need a persistent icon taking up space in your status bar, now you can simply remove it. The same goes for the Cast icon, hotspot, Do Not Disturb, alarm set, work profile, Wi-Fi, cellular data and more.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

They're available in the new System UI Tuner, which needs to be enabled in Developer Options if you are running a developer preview of Android M (to enable this, go to Settings > About Phone and tap Build Number seven times. You'll now see Developer Options at the bottom of the Settings menu.)

18. RAM Manager

The memory section is now located front and center in the Settings menu. We're not sure how often the average person is going to want to check in on memory usage, but having it plainly visible will hopefully cause more people to become familiar with what RAM management is and what you can use it for.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

19. Network Settings Reset option

Hidden away in the Backup and Reset settings is another new feature called Network Settings Reset. This lets you instantly wipe all of your network settings, including Wi-Fi connections, cellular data and Bluetooth connections.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

20. Storage gets a makeover

Internal storage is always a hassle for smartphone users. Even with microSD expansion and USB On The Go (OTG) you always seem to need to keep an eye on available storage space. The new version of Android M introduces a simple line bar that shows how much space you have on your device with a breakdown of what is using up your internal storage.
Android M, Android 6, Android 52, Google, features, iOS 9, LG, Motorola, Samsung, Google IO,Android 6.0 marshmallow, Android M, android marshmallow, android update, android 6.0 marshmallow features, android 6.0, android 6, android marshmallow features, android 6.0 marshmallow release date

Java Properties Class Example

Properties

The Properties class is a subclass of Hashtable. Usually Properties are configuration values managed as key/value pairs. The key identifier is used to retrieve the value like variable name used to retrieve the variable’s value.
Properties class in java, Properties class Example in java, System properties in java,Java Properties Class Example,Properties Class Example,Class Example,

We can use the Properties class whenever we need to store key/value pairs in which both the keys and values are strings. Some of the important features of the Properties class include:

  • Use with other classes – Properties class is used by a few other Java classes. For example, System.getProperties() returns a Properties object with environmental values.
  • Default property – The Properties class enables you to specify a default property. If a key is not associated with any value, the default property is returned.
Do you know Clone Object in Java

The constructors in the Properties class are:

  • Properties(): Creates an empty Properties object without any default values.
  • Properties(Properties propDefault):Creates a Properties object and uses the default values provided in propDefault.

Methods in Properties class

Some of the important methods in the Properties class are:
  • Object setProperty(String k, String v): Maps the value v with the key k and returns the previous value associated with k.
  • String getProperty(String k):Obtains the value associated with k and returns it.
  • void store(OutputStream so, String ds) throws IOException: Writes the Property list to the output stream that is linked to so after writing ds.
  • void load(InputStream si) throws IOException: Reads a Property list form the input stream that is linked to si.

Reading System Properties using Properties class

package com.blogspot.geekonjava;
 
import java.util.Properties;
 
public class SystemPropertiesDemo {
 
    public static void main(String[] args) {
        Properties properties = System.getProperties();
        properties.list(System.out);
    }
}
On the above example displays the current System properties like below.
— listing properties —
os.name=Linux
sun.jnu.encoding=UTF-8
java.library.path=/usr/lib/jvm/java-8-oracle/jre/lib/am…
java.specification.name=Java Platform API Specification
java.class.version=52.0
sun.management.compiler=HotSpot 64-Bit Tiered Compilers
os.version=3.13.0-55-generic
user.home=/home/geekonjava
user.timezone=
java.awt.printerjob=sun.print.PSPrinterJob
file.encoding=UTF-8
java.specification.version=1.8
user.name=geekonjava
java.class.path=/home/geekonjava/…
java.vm.specification.version=1.8
sun.arch.data.model=64
java.home=/usr/lib/jvm/java-8-oracle/jre
sun.java.command=com.onlinetutorials.SystemPropertiesDemo
java.specification.vendor=Oracle Corporation
user.language=en
awt.toolkit=sun.awt.X11.XToolkit
java.vm.info=mixed mode
java.version=1.8.0_45
java.ext.dirs=/usr/lib/jvm/java-8-oracle/jre/lib/ex…
sun.boot.class.path=/usr/lib/jvm/java-8-oracle/jre/lib/re…
java.vendor=Oracle Corporation
file.separator=/
java.vendor.url.bug=http://bugreport.sun.com/bugreport/
sun.cpu.endian=little
sun.io.unicode.encoding=UnicodeLittle
sun.desktop=gnome
sun.cpu.isalist=

Getting properties from properties class

package com.blogspot.geekonjava;
 
import java.io.FileReader;
import java.util.Properties;
 
public class PropertiesReadDemo {
 
    public static void main(String[] args) throws Exception {
        FileReader file = new FileReader("dbprops.properties");
        Properties properties = new Properties();
        properties.load(file);
        System.out.println("userName : " + properties.getProperty("username"));
        System.out.println("password : " + properties.getProperty("password"));
    }
}

Output:
 userName : geekonjava
password : 123456
Check this one tooDisadvantage of Hibernate
On the above example, by using the FileReader object we are reading the dbprops.property file. After reading the properties file, we need to load the file into properties class in order  to get property values. By using the load() method we can load the property file into Java Properties.
Properties class in java, Properties class Example in java, System properties in java,Java Properties Class Example,Properties Class Example,Class Example,

Writing data to properties class dynamically

We can also create a properties file dynamically like below.
package com.blogspot.geekonjava;
 
import java.util.Properties;
 
public class PropertiesWriteDemo {
 
    public static void main(String[] args) throws Exception {
        Properties properties = new Properties();
 
        properties.setProperty("username", "online tutorial spoint");
        properties.setProperty("password", "123456");
 
        properties.store(new FileWriter("dbprops.properties"), "Db-Configurations");
    }
}
Output:#Db-Configurations
#Thu Jun 18 21:12:51 IST 2015
password=123456
username=geekonjava
On the above example, by using the store(Writer writer,String comments) we are writing the property list (key / element pairs) in to dbprops.properties file.