Search in sources :

Example 81 with Nullable

use of android.support.annotation.Nullable in project MaterialIntroView by iammert.

the class RecyclerviewFragment method onCreateView.

@Nullable
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
    View view = inflater.inflate(R.layout.fragment_recyclerview, container, false);
    recyclerView = (RecyclerView) view.findViewById(R.id.recycler_view);
    initializeRecyclerview();
    loadData();
    new Handler().postDelayed(new Runnable() {

        @Override
        public void run() {
            showMaterialIntro();
        }
    }, 2000);
    return view;
}
Also used : Handler(android.os.Handler) RecyclerView(android.support.v7.widget.RecyclerView) View(android.view.View) MaterialIntroView(co.mobiwise.materialintro.view.MaterialIntroView) Nullable(android.support.annotation.Nullable)

Example 82 with Nullable

use of android.support.annotation.Nullable in project android-oss by kickstarter.

the class BaseFragment method onCreateView.

/**
   * Called when a fragment instantiates its user interface view, between `onCreate` and `onActivityCreated`.
   * Can return null for non-graphical fragments.
   */
@CallSuper
@Override
@Nullable
public View onCreateView(@NonNull final LayoutInflater inflater, @Nullable final ViewGroup container, @Nullable final Bundle savedInstanceState) {
    final View view = super.onCreateView(inflater, container, savedInstanceState);
    Timber.d("onCreateView %s", this.toString());
    lifecycle.onNext(FragmentEvent.CREATE_VIEW);
    return view;
}
Also used : View(android.view.View) CallSuper(android.support.annotation.CallSuper) Nullable(android.support.annotation.Nullable)

Example 83 with Nullable

use of android.support.annotation.Nullable in project k-9 by k9mail.

the class AttachmentProvider method getAttachmentDataSource.

@Nullable
private OpenPgpDataSource getAttachmentDataSource(String accountUuid, String attachmentId) throws MessagingException {
    final Account account = Preferences.getPreferences(getContext()).getAccount(accountUuid);
    LocalStore localStore = LocalStore.getInstance(account, getContext());
    return localStore.getAttachmentDataSource(attachmentId);
}
Also used : Account(com.fsck.k9.Account) LocalStore(com.fsck.k9.mailstore.LocalStore) Nullable(android.support.annotation.Nullable)

Example 84 with Nullable

use of android.support.annotation.Nullable in project SeriesGuide by UweTrottmann.

the class PurchaseDataSource method getEntitlementRecordByReceiptId.

/**
     * Find entitlement record by specified receipt ID.
     */
@Nullable
public PurchaseRecord getEntitlementRecordByReceiptId(final String receiptId) {
    Timber.d("getEntitlementRecordByReceiptId: receiptId (%s)", receiptId);
    final String where = AmazonBillingSQLiteHelper.COLUMN_RECEIPT_ID + "= ?";
    final Cursor cursor = database.query(AmazonBillingSQLiteHelper.TABLE_PURCHASES, allColumns, where, new String[] { receiptId }, null, null, null);
    final PurchaseRecord result;
    cursor.moveToFirst();
    if (cursor.isAfterLast()) {
        result = null;
        Timber.d("getEntitlementRecordByReceiptId: no record found ");
    } else {
        result = cursorToPurchaseRecord(cursor);
        Timber.d("getEntitlementRecordByReceiptId: found ");
    }
    cursor.close();
    return result;
}
Also used : Cursor(android.database.Cursor) Nullable(android.support.annotation.Nullable)

Example 85 with Nullable

use of android.support.annotation.Nullable in project SeriesGuide by UweTrottmann.

the class PurchaseDataSource method getLatestEntitlementRecordBySku.

/**
     * Return the entitlement for given user and sku.
     */
@Nullable
public PurchaseRecord getLatestEntitlementRecordBySku(String userId, String sku) {
    Timber.d("getEntitlementRecordBySku: userId (%s), sku (%s)", userId, sku);
    final String where = AmazonBillingSQLiteHelper.COLUMN_USER_ID + " = ? and " + AmazonBillingSQLiteHelper.COLUMN_SKU + " = ?";
    final Cursor cursor = database.query(AmazonBillingSQLiteHelper.TABLE_PURCHASES, allColumns, where, new String[] { userId, sku }, null, null, AmazonBillingSQLiteHelper.COLUMN_DATE_FROM + " desc ");
    final PurchaseRecord result;
    cursor.moveToFirst();
    if (cursor.isAfterLast()) {
        result = null;
        Timber.d("getEntitlementRecordBySku: no record found ");
    } else {
        result = cursorToPurchaseRecord(cursor);
        Timber.d("getEntitlementRecordBySku: found ");
    }
    cursor.close();
    return result;
}
Also used : Cursor(android.database.Cursor) Nullable(android.support.annotation.Nullable)

Aggregations

Nullable (android.support.annotation.Nullable)582 View (android.view.View)315 TextView (android.widget.TextView)163 RecyclerView (android.support.v7.widget.RecyclerView)85 BindView (butterknife.BindView)57 ImageView (android.widget.ImageView)52 ArrayList (java.util.ArrayList)43 IOException (java.io.IOException)36 Bundle (android.os.Bundle)35 LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)35 Intent (android.content.Intent)32 ViewGroup (android.view.ViewGroup)32 Cursor (android.database.Cursor)29 Uri (android.net.Uri)27 File (java.io.File)24 AdapterView (android.widget.AdapterView)22 List (java.util.List)20 NonNull (android.support.annotation.NonNull)19 Context (android.content.Context)15 Bitmap (android.graphics.Bitmap)15