当前位置: 首页>>代码示例>>Java>>正文


Java RendererBuilder类代码示例

本文整理汇总了Java中com.pedrogomez.renderers.RendererBuilder的典型用法代码示例。如果您正苦于以下问题:Java RendererBuilder类的具体用法?Java RendererBuilder怎么用?Java RendererBuilder使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


RendererBuilder类属于com.pedrogomez.renderers包,在下文中一共展示了RendererBuilder类的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: initAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
/**
 * Initialize RVRendererAdapter
 */
private void initAdapter() {
  RandomVideoCollectionGenerator randomVideoCollectionGenerator =
      new RandomVideoCollectionGenerator();
  final AdapteeCollection<Video> videoCollection =
      randomVideoCollectionGenerator.generateListAdapteeVideoCollection(VIDEO_COUNT);
  RendererBuilder<Video> rendererBuilder = new RendererBuilder<Video>().withPrototype(
      new RemovableVideoRenderer(new RemovableVideoRenderer.Listener() {
        @Override public void onRemoveButtonTapped(Video video) {
          ArrayList<Video> clonedList =
              new ArrayList<>((Collection<? extends Video>) videoCollection);
          clonedList.remove(video);
          adapter.diffUpdate(clonedList);
        }
      })).bind(Video.class, RemovableVideoRenderer.class);

  adapter = new RVRendererAdapter<>(rendererBuilder, videoCollection);
}
 
开发者ID:pedrovgs,项目名称:Renderers,代码行数:21,代码来源:RecyclerViewActivity.java

示例2: onCreate

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
@Override protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
    ButterKnife.bind(this);

    animationSubscription = Observable.interval(1, TimeUnit.SECONDS)
            .observeOn(AndroidSchedulers.mainThread())
            .subscribeOn(Schedulers.newThread())
            .subscribe(animationTimer = PublishSubject.create());

    RendererBuilder<Item> rendererBuilder = new RendererBuilder<>(new CustomRenderer(animationTimer));
    RVRendererAdapter adapter = new RVRendererAdapter<>(rendererBuilder);
    myList.setAdapter(adapter);

    List<Item> items = new ArrayList<>();

    items.add(new Item("Madrid", 18, 10));
    items.add(new Item("California", 10, 10));
    items.add(new Item("Moscú", 20, 10));
    items.add(new Item("Taiwan", 23, 10));
    items.add(new Item("Tenerife", 17, 10));
    items.add(new Item("Madrid", 18, 10));
    items.add(new Item("California", 10, 10));
    items.add(new Item("Moscú", 20, 10));
    items.add(new Item("Taiwan", 23, 10));
    items.add(new Item("Tenerife", 17, 10));
    items.add(new Item("Madrid", 18, 10));
    items.add(new Item("California", 10, 10));
    items.add(new Item("Moscú", 20, 10));
    items.add(new Item("Taiwan", 23, 10));
    items.add(new Item("Tenerife", 17, 10));

    adapter.addAll(items);
    adapter.notifyDataSetChanged();
}
 
开发者ID:FireZenk,项目名称:RecyclerViewSyncedAnimations,代码行数:36,代码来源:MainActivity.java

示例3: initializeRenderers

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeRenderers() {
  RendererBuilder<Trace> tracesRendererBuilder = new TraceRendererBuilder(lynxConfig);
  adapter = new RendererAdapter<>(tracesRendererBuilder);
  adapter.addAll(presenter.getCurrentTraces());
  if (adapter.getCount() > 0) {
    adapter.notifyDataSetChanged();
  }
  lv_traces.setAdapter(adapter);
}
 
开发者ID:pedrovgs,项目名称:Lynx,代码行数:10,代码来源:LynxView.java

示例4: ChapterViewModelRendererAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
public ChapterViewModelRendererAdapter(LayoutInflater layoutInflater,
    RendererBuilder rendererBuilder, AdapteeCollection<ChapterViewModel> collection) {
  super(layoutInflater, rendererBuilder, collection);
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:5,代码来源:ChapterViewModelRendererAdapter.java

示例5: ChapterRendererAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
public ChapterRendererAdapter(LayoutInflater layoutInflater, RendererBuilder rendererBuilder,
    AdapteeCollection<Chapter> collection) {
  super(layoutInflater, rendererBuilder, collection);
}
 
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:5,代码来源:ChapterRendererAdapter.java

示例6: initializeAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeAdapter() {
    RendererBuilder<SpeakerViewModel> rendererBuilder = new SpeakerRendererBuilder(presenter);
    speakersCollection = new SpeakersAdapteeCollection();
    speakersAdapter = new RVRendererAdapter<>(rendererBuilder, speakersCollection);
}
 
开发者ID:pinicius,项目名称:CAS2016,代码行数:6,代码来源:SpeakersFragment.java

示例7: initializeAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeAdapter() {
    RendererBuilder<SessionSummaryViewModel> rendererBuilder = new SpeakerSessionSummaryRendererBuilder(presenter);
    speakerSessionsCollection = new SpeakerSessionsAdapteeCollection();
    sessionsAdapter = new RVRendererAdapter<>(rendererBuilder, speakerSessionsCollection);
}
 
开发者ID:pinicius,项目名称:CAS2016,代码行数:6,代码来源:SpeakerDetailsActivity.java

示例8: initializeAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeAdapter() {
    RendererBuilder<SessionViewModel> rendererBuilder = new SessionRendererBuilder(presenter);
    sessionsCollection = new SessionsAdapteeCollection();
    sessionsAdapter = new RVRendererAdapter<>(rendererBuilder, sessionsCollection);
}
 
开发者ID:pinicius,项目名称:CAS2016,代码行数:6,代码来源:DayOneSessionsFragment.java

示例9: initializeAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeAdapter() {
    RendererBuilder<RoomViewModel> rendererBuilder = new RoomRendererBuilder(presenter);
    roomsCollection = new RoomsAdapteeCollection();
    roomsAdapter = new RVRendererAdapter<>(rendererBuilder, roomsCollection);
}
 
开发者ID:pinicius,项目名称:CAS2016,代码行数:6,代码来源:RoomsFragment.java

示例10: initializeAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
private void initializeAdapter() {
    RendererBuilder<SessionSummaryViewModel> rendererBuilder = new RoomSessionSummaryRendererBuilder(presenter);
    roomSessionsCollection = new RoomSessionsAdapteeCollection();
    sessionsAdapter = new RVRendererAdapter<>(rendererBuilder, roomSessionsCollection);
}
 
开发者ID:pinicius,项目名称:CAS2016,代码行数:6,代码来源:RoomDetailsActivity.java

示例11: InventoryItemRVRendererAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
public InventoryItemRVRendererAdapter(LayoutInflater layoutInflater,
                                RendererBuilder<InventoryViewModel> rendererBuilder,
                                AdapteeCollection<InventoryViewModel> collection) {
    super(layoutInflater, rendererBuilder, collection);
}
 
开发者ID:FAU-Inf2,项目名称:fablab-android,代码行数:6,代码来源:InventoryItemRVRendererAdapter.java

示例12: ProductRVRendererAdapter

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
public ProductRVRendererAdapter(LayoutInflater layoutInflater,
                                RendererBuilder<ProductSearchViewModel> rendererBuilder,
                                AdapteeCollection<ProductSearchViewModel> collection) {
    super(layoutInflater, rendererBuilder, collection);
}
 
开发者ID:FAU-Inf2,项目名称:fablab-android,代码行数:6,代码来源:ProductRVRendererAdapter.java

示例13: withConvertView

import com.pedrogomez.renderers.RendererBuilder; //导入依赖的package包/类
protected RendererBuilder withConvertView(View convertView) {
    super.withConvertView(convertView);
    this.mConvertView = convertView;
    return this;
}
 
开发者ID:raycoarana,项目名称:baindo,代码行数:6,代码来源:BinderRendererBuilder.java


注:本文中的com.pedrogomez.renderers.RendererBuilder类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。