本文整理匯總了Java中com.parse.Parse.getLogLevel方法的典型用法代碼示例。如果您正苦於以下問題:Java Parse.getLogLevel方法的具體用法?Java Parse.getLogLevel怎麽用?Java Parse.getLogLevel使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.parse.Parse
的用法示例。
在下文中一共展示了Parse.getLogLevel方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getMergedOptions
import com.parse.Parse; //導入方法依賴的package包/類
private Bundle getMergedOptions() {
// Read activity metadata from AndroidManifest.xml
ActivityInfo activityInfo = null;
try {
activityInfo = getPackageManager().getActivityInfo(
this.getComponentName(), PackageManager.GET_META_DATA);
} catch (NameNotFoundException e) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_ERROR &&
Log.isLoggable(LOG_TAG, Log.WARN)) {
Log.w(LOG_TAG, e.getMessage());
}
}
// The options specified in the Intent (from ParseLoginBuilder) will
// override any duplicate options specified in the activity metadata
Bundle mergedOptions = new Bundle();
if (activityInfo != null && activityInfo.metaData != null) {
mergedOptions.putAll(activityInfo.metaData);
}
if (getIntent().getExtras() != null) {
mergedOptions.putAll(getIntent().getExtras());
}
return mergedOptions;
}
示例2: getMergedOptions
import com.parse.Parse; //導入方法依賴的package包/類
private Bundle getMergedOptions() {
// Read activity metadata from AndroidManifest.xml
ActivityInfo activityInfo = null;
try {
activityInfo = getPackageManager().getActivityInfo(
this.getComponentName(), PackageManager.GET_META_DATA);
} catch (NameNotFoundException e) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_ERROR &&
Log.isLoggable("ParseLoginActivity", Log.WARN)) {
Log.w("ParseLoginActivity", e.getMessage());
}
}
// The options specified in the Intent (from ParseLoginBuilder) will
// override any duplicate options specified in the activity metadata
Bundle mergedOptions = new Bundle();
if (activityInfo != null && activityInfo.metaData != null) {
mergedOptions.putAll(activityInfo.metaData);
}
if (getIntent().getExtras() != null) {
mergedOptions.putAll(getIntent().getExtras());
}
return mergedOptions;
}
示例3: debugLog
import com.parse.Parse; //導入方法依賴的package包/類
protected void debugLog(String text) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_DEBUG &&
Log.isLoggable(getLogTag(), Log.WARN)) {
Log.w(getLogTag(), text);
}
}
示例4: fromBundle
import com.parse.Parse; //導入方法依賴的package包/類
/**
* Constructs a ParseLoginConfig object from a bundle. Unrecognized keys are
* ignored.
* <p/>
* This can be used to pass an ParseLoginConfig object between activities, or
* to read settings from an activity's meta-data in Manefest.xml.
*
* @param bundle
* The Bundle representation of the ParseLoginConfig object.
* @param context
* The context for resolving resource IDs.
* @return The ParseLoginConfig instance.
*/
public static ParseLoginConfig fromBundle(Bundle bundle, Context context) {
ParseLoginConfig config = new ParseLoginConfig();
Set<String> keys = bundle.keySet();
if (keys.contains(APP_LOGO)) {
config.setAppLogo(bundle.getInt(APP_LOGO));
}
if (keys.contains(PARSE_LOGIN_ENABLED)) {
config.setParseLoginEnabled(bundle.getBoolean(PARSE_LOGIN_ENABLED));
}
if (keys.contains(PARSE_LOGIN_BUTTON_TEXT)) {
config.setParseLoginButtonText(bundle.getCharSequence(PARSE_LOGIN_BUTTON_TEXT));
}
if (keys.contains(PARSE_SIGNUP_BUTTON_TEXT)) {
config.setParseSignupButtonText(bundle.getCharSequence(PARSE_SIGNUP_BUTTON_TEXT));
}
if (keys.contains(PARSE_LOGIN_HELP_TEXT)) {
config.setParseLoginHelpText(bundle.getCharSequence(PARSE_LOGIN_HELP_TEXT));
}
if (keys.contains(PARSE_LOGIN_INVALID_CREDENTIALS_TOAST_TEXT)) {
config.setParseLoginInvalidCredentialsToastText(bundle
.getCharSequence(PARSE_LOGIN_INVALID_CREDENTIALS_TOAST_TEXT));
}
if (keys.contains(PARSE_LOGIN_EMAIL_AS_USERNAME)) {
config.setParseLoginEmailAsUsername(bundle.getBoolean(PARSE_LOGIN_EMAIL_AS_USERNAME));
}
if (keys.contains(PARSE_SIGNUP_MIN_PASSWORD_LENGTH)) {
config.setParseSignupMinPasswordLength(bundle.getInt(PARSE_SIGNUP_MIN_PASSWORD_LENGTH));
}
if (keys.contains(PARSE_SIGNUP_SUBMIT_BUTTON_TEXT)) {
config.setParseSignupSubmitButtonText(bundle.getCharSequence(PARSE_SIGNUP_SUBMIT_BUTTON_TEXT));
}
if (keys.contains(FACEBOOK_LOGIN_ENABLED)) {
config.setFacebookLoginEnabled(bundle.getBoolean(FACEBOOK_LOGIN_ENABLED));
}
if (keys.contains(FACEBOOK_LOGIN_BUTTON_TEXT)) {
config.setFacebookLoginButtonText(bundle.getCharSequence(FACEBOOK_LOGIN_BUTTON_TEXT));
}
if (keys.contains(FACEBOOK_LOGIN_PERMISSIONS) &&
bundle.getInt(FACEBOOK_LOGIN_PERMISSIONS) != 0) {
// Only for converting from activity meta-data.
try {
config.setFacebookLoginPermissions(stringArrayToCollection(context
.getResources().getStringArray(
bundle.getInt(FACEBOOK_LOGIN_PERMISSIONS))));
} catch (NotFoundException e) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_ERROR) {
Log.w(LOG_TAG, "Facebook permission string array resource not found");
}
}
} else if (keys.contains(FACEBOOK_LOGIN_PERMISSIONS_STRING_ARRAY)) {
// For converting from a bundle produced by this class's toBundle()
config.setFacebookLoginPermissions(stringArrayToCollection(bundle
.getStringArray(FACEBOOK_LOGIN_PERMISSIONS_STRING_ARRAY)));
}
if (keys.contains(TWITTER_LOGIN_ENABLED)) {
config.setTwitterLoginEnabled(bundle.getBoolean(TWITTER_LOGIN_ENABLED));
}
if (keys.contains(TWITTER_LOGIN_BUTTON_TEXT)) {
config.setTwitterLoginButtonText(bundle
.getCharSequence(TWITTER_LOGIN_BUTTON_TEXT));
}
return config;
}
示例5: debugLog
import com.parse.Parse; //導入方法依賴的package包/類
private void debugLog(String message) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_DEBUG &&
Log.isLoggable(LOG_TAG, Log.DEBUG)) {
Log.d(LOG_TAG, message);
}
}
示例6: debugLog
import com.parse.Parse; //導入方法依賴的package包/類
private void debugLog(String message) {
if (Parse.getLogLevel() <= Parse.LOG_LEVEL_DEBUG &&
Log.isLoggable(LOG_TAG, Log.DEBUG)) {
Log.d(LOG_TAG, message);
}
}