Code example for Editable

Methods: toString

0
            @Override 
            public void afterTextChanged(Editable s) {
                if (mPositiveButton == null) {
                    mPositiveButton = dialog.getButton(AlertDialog.BUTTON_POSITIVE);
                } 
                mPositiveButton.setEnabled(s.toString().trim().length() > 0);
            } 
        }); 
 
        return dialog;
    } 
} 
Connect your IDE to all the code out there  Get Codota for Java