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


Java StickyListHeadersAdapter類代碼示例

本文整理匯總了Java中se.emilsjolander.stickylistheaders.StickyListHeadersAdapter的典型用法代碼示例。如果您正苦於以下問題:Java StickyListHeadersAdapter類的具體用法?Java StickyListHeadersAdapter怎麽用?Java StickyListHeadersAdapter使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


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

示例1: onLoadFinished

import se.emilsjolander.stickylistheaders.StickyListHeadersAdapter; //導入依賴的package包/類
@Override
protected void onLoadFinished(Optional<List<RoomFinderRoom>> result) {
    showLoadingEnded();
    if (!result.isPresent()) {
        if (NetUtils.isConnected(this)) {
            showErrorLayout();
        } else {
            showNoInternetLayout();
        }
        return;
    }

    facilities = result.get();
    StickyListHeadersAdapter adapter = new RoomFinderListAdapter(this, facilities);
    stickyList.setAdapter(adapter);
    stickyList.setOnItemClickListener(this);
}
 
開發者ID:TCA-Team,項目名稱:TumCampusApp,代碼行數:18,代碼來源:BarrierFreeFacilitiesActivity.java

示例2: StickyListHeadersAdapterDecorator

import se.emilsjolander.stickylistheaders.StickyListHeadersAdapter; //導入依賴的package包/類
/**
 * Create a new {@code StickyListHeadersAdapterDecorator}, decorating given {@link android.widget.BaseAdapter}.
 *
 * @param baseAdapter the {@code BaseAdapter} to decorate. If this is a {@code BaseAdapterDecorator}, it should wrap an instance of
 *                    {@link se.emilsjolander.stickylistheaders.StickyListHeadersAdapter}.
 */
public StickyListHeadersAdapterDecorator(@NonNull final BaseAdapter baseAdapter) {
    super(baseAdapter);

    BaseAdapter adapter = baseAdapter;
    while (adapter instanceof BaseAdapterDecorator) {
        adapter = ((BaseAdapterDecorator) adapter).getDecoratedBaseAdapter();
    }

    if (!(adapter instanceof StickyListHeadersAdapter)) {
        throw new IllegalArgumentException(adapter.getClass().getCanonicalName() + " does not implement StickyListHeadersAdapter");
    }

    mStickyListHeadersAdapter = (StickyListHeadersAdapter) adapter;
}
 
開發者ID:sathishmscict,項目名稱:ListViewAnimations,代碼行數:21,代碼來源:StickyListHeadersAdapterDecorator.java

示例3: setAdapter

import se.emilsjolander.stickylistheaders.StickyListHeadersAdapter; //導入依賴的package包/類
/**
 * Set the adapter. You can provide a {@link CardArrayAdapter}, or a {@link it.gmariotti.cardslib.library.internal.CardCursorAdapter}
 * or a generic adapter.
 * Pay attention: your generic adapter has to call {@link CardArrayAdapter#getView} method
 *
 * @param adapter
 */
@Override
public void setAdapter(StickyListHeadersAdapter adapter) {
    if (adapter instanceof StickyCardArrayAdapter) {
        setAdapter((StickyCardArrayAdapter) adapter);
    } else {
        Log.e(TAG, "You are using a generic adapter. Pay attention: your adapter has to call cardArrayAdapter#getView method");
        super.setAdapter(adapter);
    }
}
 
開發者ID:tajchert,項目名稱:CEEHack,代碼行數:17,代碼來源:StickyCardListView.java

示例4: setAdapter

import se.emilsjolander.stickylistheaders.StickyListHeadersAdapter; //導入依賴的package包/類
@Override
public void setAdapter(StickyListHeadersAdapter adapter) {
    super.setAdapter(adapter);
    if (mScroller != null)
        mScroller.setAdapter(adapter);
}
 
開發者ID:tengbinlive,項目名稱:info_demo,代碼行數:7,代碼來源:IndexableListView.java


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