當前位置: 首頁>>代碼示例>>Java>>正文


Java Printer.println方法代碼示例

本文整理匯總了Java中android.util.Printer.println方法的典型用法代碼示例。如果您正苦於以下問題:Java Printer.println方法的具體用法?Java Printer.println怎麽用?Java Printer.println使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在android.util.Printer的用法示例。


在下文中一共展示了Printer.println方法的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: dump

import android.util.Printer; //導入方法依賴的package包/類
@Override
protected void dump(FileDescriptor fd, PrintWriter fout, String[] args) {
    super.dump(fd, fout, args);

    final Printer p = new PrintWriterPrinter(fout);
    p.println("LatinIME state :");
    p.println("  Keyboard mode = " + mKeyboardSwitcher.getKeyboardMode());
    p.println("  mCapsLock=" + mCapsLock);
    p.println("  mComposing=" + mComposing.toString());
    p.println("  mPredictionOn=" + mPredictionOn);
    p.println("  mCorrectionMode=" + mCorrectionMode);
    p.println("  mPredicting=" + mPredicting);
    p.println("  mAutoCorrectOn=" + mAutoCorrectOn);
    p.println("  mAutoSpace=" + mAutoSpace);
    p.println("  mCompletionOn=" + mCompletionOn);
    p.println("  TextEntryState.state=" + TextEntryState.getState());
    p.println("  mSoundOn=" + mSoundOn);
    p.println("  mVibrateOn=" + mVibrateOn);
    p.println("  mPopupOn=" + mPopupOn);
}
 
開發者ID:PhilippC,項目名稱:keepass2android,代碼行數:21,代碼來源:KP2AKeyboard.java

示例2: dump

import android.util.Printer; //導入方法依賴的package包/類
@Override
protected void dump(final FileDescriptor fd, final PrintWriter fout, final String[] args) {
    super.dump(fd, fout, args);

    final Printer p = new PrintWriterPrinter(fout);
    p.println("LatinIME state :");
    p.println("  VersionCode = " + ApplicationUtils.getVersionCode(this));
    p.println("  VersionName = " + ApplicationUtils.getVersionName(this));
    final Keyboard keyboard = mKeyboardSwitcher.getKeyboard();
    final int keyboardMode = keyboard != null ? keyboard.mId.mMode : -1;
    p.println("  Keyboard mode = " + keyboardMode);
    final SettingsValues settingsValues = mSettings.getCurrent();
    p.println(settingsValues.dump());
    p.println(mDictionaryFacilitator.dump(this /* context */));
    // TODO: Dump all settings values
}
 
開發者ID:sergeychilingaryan,項目名稱:AOSP-Kayboard-7.1.2,代碼行數:17,代碼來源:LatinIME.java

示例3: dump

import android.util.Printer; //導入方法依賴的package包/類
public void dump(Printer printer, String prefix) {
    printer.println("------crash begin------");
    printer.println("crash time:" + DateUtils.format(System.currentTimeMillis(), DateUtils.YMD_HMS));
    printer.println(prefix + "appName=" + mAppName);
    printer.println(prefix + "appVersionCode=" + mAppVersionCode);
    printer.println(prefix + "appVersionName=" + mAppVersionName);
    printer.println(prefix + "sdkVersion=" + mSDKVersion);
    printer.println(prefix + "deviceName=" + mDeviceName);
    printer.println(prefix + "deviceId=" + mDeviceId);
    printer.println(prefix + "osVersion=" + mOsVersion);
    printer.println(prefix + "osName=" + mOsName);
    printer.println(prefix + "arch=" + mArch);
    printer.println(prefix + "product=" + mProduct);
    printer.println(prefix + "cpuCoreCount=" + mCpuCoreCount);
    printer.println(prefix + "memorySize=" + memorySize);
    printer.println(prefix + "threadName=" + mThreadName);
    printer.println(prefix + "errorMessage=" + mErrorMessage);
    printer.println("------crash end------");
}
 
開發者ID:jacklongway,項目名稱:LiteSDK,代碼行數:20,代碼來源:CrashInfo.java

示例4: dump

import android.util.Printer; //導入方法依賴的package包/類
public void dump(Printer printer) {
    printer.println("  Prepared statement cache:");
    Map<String, PreparedStatement> cache = snapshot();
    if (!cache.isEmpty()) {
        int i = 0;
        for (Map.Entry<String, PreparedStatement> entry : cache.entrySet()) {
            PreparedStatement statement = entry.getValue();
            if (statement.mInCache) { // might be false due to a race with entryRemoved
                String sql = entry.getKey();
                printer.println("    " + i + ": statementPtr=0x"
                        + Long.toHexString(statement.mStatementPtr)
                        + ", numParameters=" + statement.mNumParameters
                        + ", type=" + statement.mType
                        + ", readOnly=" + statement.mReadOnly
                        + ", sql=\"" + trimSqlForDisplay(sql) + "\"");
            }
            i += 1;
        }
    } else {
        printer.println("    <none>");
    }
}
 
開發者ID:doppllib,項目名稱:core-doppl,代碼行數:23,代碼來源:SQLiteConnection.java

示例5: dump

import android.util.Printer; //導入方法依賴的package包/類
@Override
protected void dump(FileDescriptor fd, PrintWriter fout, String[] args) {
    super.dump(fd, fout, args);

    final Printer p = new PrintWriterPrinter(fout);
    p.println("LatinIME state :");
    p.println("  Keyboard mode = " + mKeyboardSwitcher.getKeyboardMode());
    p.println("  mComposing=" + mComposing.toString());
    p.println("  mPredictionOnForMode=" + mPredictionOnForMode);
    p.println("  mCorrectionMode=" + mCorrectionMode);
    p.println("  mPredicting=" + mPredicting);
    p.println("  mAutoCorrectOn=" + mAutoCorrectOn);
    p.println("  mAutoSpace=" + mAutoSpace);
    p.println("  mCompletionOn=" + mCompletionOn);
    p.println("  TextEntryState.state=" + TextEntryState.getState());
    p.println("  mSoundOn=" + mSoundOn);
    p.println("  mVibrateOn=" + mVibrateOn);
    p.println("  mPopupOn=" + mPopupOn);
}
 
開發者ID:klausw,項目名稱:hackerskeyboard,代碼行數:20,代碼來源:LatinIME.java

示例6: dumpSpans

import android.util.Printer; //導入方法依賴的package包/類
/**
 * Debugging tool to print the spans in a CharSequence.  The output will
 * be printed one span per line.  If the CharSequence is not a Spanned,
 * then the entire string will be printed on a single line.
 */
public static void dumpSpans(CharSequence cs, Printer printer, String prefix) {
    if (cs instanceof Spanned) {
        Spanned sp = (Spanned) cs;
        Object[] os = sp.getSpans(0, cs.length(), Object.class);

        for (int i = 0; i < os.length; i++) {
            Object o = os[i];
            printer.println(prefix + cs.subSequence(sp.getSpanStart(o),
                    sp.getSpanEnd(o)) + ": "
                    + Integer.toHexString(System.identityHashCode(o))
                    + " " + o.getClass().getCanonicalName()
                     + " (" + sp.getSpanStart(o) + "-" + sp.getSpanEnd(o)
                     + ") fl=#" + sp.getSpanFlags(o));
        }
    } else {
        printer.println(prefix + cs + ": (no spans)");
    }
}
 
開發者ID:Sellegit,項目名稱:j2objc,代碼行數:24,代碼來源:TextUtils.java

示例7: dump

import android.util.Printer; //導入方法依賴的package包/類
@Override
protected void dump(final FileDescriptor fd, final PrintWriter fout, final String[] args) {
    super.dump(fd, fout, args);

    final Printer p = new PrintWriterPrinter(fout);
    p.println("LatinIME state :");
    final Keyboard keyboard = mKeyboardSwitcher.getKeyboard();
    final int keyboardMode = keyboard != null ? keyboard.mId.mMode : -1;
    p.println("  Keyboard mode = " + keyboardMode);
    final SettingsValues settingsValues = mSettings.getCurrent();
    p.println("  mIsSuggestionsSuggestionsRequested = "
            + settingsValues.isSuggestionsRequested(mDisplayOrientation));
    p.println("  mCorrectionEnabled=" + settingsValues.mCorrectionEnabled);
    p.println("  isComposingWord=" + mWordComposer.isComposingWord());
    p.println("  mSoundOn=" + settingsValues.mSoundOn);
    p.println("  mVibrateOn=" + settingsValues.mVibrateOn);
    p.println("  mKeyPreviewPopupOn=" + settingsValues.mKeyPreviewPopupOn);
    p.println("  inputAttributes=" + settingsValues.mInputAttributes);
}
 
開發者ID:slightfoot,項目名稱:android-kioskime,代碼行數:20,代碼來源:LatinIME.java

示例8: dump

import android.util.Printer; //導入方法依賴的package包/類
@Override
protected void dump(final FileDescriptor fd, final PrintWriter fout, final String[] args) {
    super.dump(fd, fout, args);

    final Printer p = new PrintWriterPrinter(fout);
    p.println("LatinIME state :");
    p.println("  VersionCode = " + ApplicationUtils.getVersionCode(this));
    p.println("  VersionName = " + ApplicationUtils.getVersionName(this));
    final Keyboard keyboard = mKeyboardSwitcher.getKeyboard();
    final int keyboardMode = keyboard != null ? keyboard.mId.mMode : -1;
    p.println("  Keyboard mode = " + keyboardMode);
}
 
開發者ID:rkkr,項目名稱:simple-keyboard,代碼行數:13,代碼來源:LatinIME.java

示例9: dump

import android.util.Printer; //導入方法依賴的package包/類
private void dump(Printer printer, boolean verbose) {
    synchronized (mLock) {
        if (mConnectionPoolLocked != null) {
            printer.println("");
            // TODO: 17/6/6
            //                mConnectionPoolLocked.dump(printer, verbose);
        }
    }
}
 
開發者ID:kkmike999,項目名稱:YuiHatano,代碼行數:10,代碼來源:ShadowSQLiteDatabase.java

示例10: dump

import android.util.Printer; //導入方法依賴的package包/類
public final void dump(Printer pw, String prefix) {
    pw.println(prefix + this + " @ " + SystemClock.uptimeMillis());
    if (mLooper == null) {
        pw.println(prefix + "looper uninitialized");
    } else {
        mLooper.dump(pw, prefix + "  ");
    }
}
 
開發者ID:doppllib,項目名稱:core-doppl,代碼行數:9,代碼來源:Handler.java

示例11: dump

import android.util.Printer; //導入方法依賴的package包/類
private void dump(Printer printer, boolean verbose) {
    synchronized (mLock) {
        if (mConnectionPoolLocked != null) {
            printer.println("");
            mConnectionPoolLocked.dump(printer, verbose);
        }
    }
}
 
開發者ID:doppllib,項目名稱:core-doppl,代碼行數:9,代碼來源:SQLiteDatabase.java

示例12: dumpUnsafe

import android.util.Printer; //導入方法依賴的package包/類
/**
 * Dumps debugging information about this connection, in the case where the
 * caller might not actually own the connection.
 *
 * This function is written so that it may be called by a thread that does not
 * own the connection.  We need to be very careful because the connection state is
 * not synchronized.
 *
 * At worst, the method may return stale or slightly wrong data, however
 * it should not crash.  This is ok as it is only used for diagnostic purposes.
 *
 * @param printer The printer to receive the dump, not null.
 * @param verbose True to dump more verbose information.
 */
void dumpUnsafe(Printer printer, boolean verbose) {
    printer.println("Connection #" + mConnectionId + ":");
    if (verbose) {
        printer.println("  connectionPtr: 0x" + Long.toHexString(mConnectionPtr));
    }
    printer.println("  isPrimaryConnection: " + mIsPrimaryConnection);
    printer.println("  onlyAllowReadOnlyOperations: " + mOnlyAllowReadOnlyOperations);

    mRecentOperations.dump(printer, verbose);

    if (verbose) {
        mPreparedStatementCache.dump(printer);
    }
}
 
開發者ID:doppllib,項目名稱:core-doppl,代碼行數:29,代碼來源:SQLiteConnection.java

示例13: print

import android.util.Printer; //導入方法依賴的package包/類
public void print(Printer printer) {
    Iterator i$ = this.idToPresenter.entrySet().iterator();

    while (i$.hasNext()) {
        Map.Entry entry = (Map.Entry) i$.next();
        Object view = ((Presenter) entry.getValue()).getView();
        printer.println("id: " + entry.getKey() + (view == null ? "" : " => view: " + view.toString()));
    }

}
 
開發者ID:jackmiras,項目名稱:nucleolus,代碼行數:11,代碼來源:DefaultPresenterManager.java


注:本文中的android.util.Printer.println方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。