[Recycler View and Glide] Implementing an APP for Android E-book Reading

http://www.cnblogs.com/xfangs/ Welcome to comment below this article, Xiaofang needs encouragement and support!!! This series of tutorials is for learning and communication only. Views on the Final Realization Effect of Novel Reader The firstA blog post     Preface In the last article, we implemented the basic functions of ViewPager. Ac ...

Posted by deansp2001 on Wed, 17 Apr 2019 00:33:32 -0700

JavaScript Design Patterns

1. Singleton Model Definition: A specific class has only one instance Application scenarios: A mask Realization way Each object is a monomer, because their reference positions are different. Use the new operator Store the first generated object in a global variable. Disadvantage: Global variables are easily overwritten. You can use closur ...

Posted by tcr480 on Tue, 16 Apr 2019 17:27:32 -0700

view related content code snippet notes

Get the control in fragment in activity  getFragmentManager().findFragmentById(id).getView().findViewById(id) HolderView item view processing @Override public View getView(int i, View convertView, ViewGroup viewGroup) { HolderView holderView; // Important to not just null check, but rather to a instanceof // since we might g ...

Posted by lhale on Mon, 15 Apr 2019 18:06:33 -0700

adapter calls methods in fragment s

adapter calls methods in fragment s Foreword: Yesterday, I met a technical problem. For me, ha. My demo requirement is to put a RecyclerView in fragment, and then RecyclerView displays some simple data, which needs to request the network. Then I customized an adapter and found that when dealing with click events of RecyclerView subitems, b ...

Posted by Gamic on Sun, 14 Apr 2019 15:03:32 -0700

The Bottom Navigation Bar of Android Learning Implements the Android Characteristic Bottom Navigation Bar

Android There are many ways to implement the bottom navigation bar, such as TabHost, TabLayout, or TextView, which can achieve the effect of the bottom navigation bar, but there is no official and unified navigation bar style of Google. Today, we are talking about the recent addition of Google to Material. Bottom Navigation Bar in design ...

Posted by Bootsman123 on Fri, 12 Apr 2019 11:21:33 -0700

MongoDB Distributed File Storage System

Summary For BSON document objects in MongoDB's storage base unit, field values can be of binary type. Based on this feature, we can store files directly in MongoDB, but there is a limitation. Because a single BSON object in MongoDB cannot be larger than 16MB, we need GridFS if we need to store larger files. Small File Storage System and Gr ...

Posted by adaminms on Fri, 12 Apr 2019 03:03:32 -0700

On MVP and MVVM of Android Architecture

Reprinted from: http://www.cnblogs.com/BoBoMEe/p/5573447.html Summary MVP(Model-View-Presenter) is a variant and evolutionary model of traditional MVC(Model-View-Controller) in Android development. Mainly used to isolate UI, UI logic and business logic, data, create loosely coupled and reusable objects. We know that View layer is changeabl ...

Posted by noon on Wed, 10 Apr 2019 12:51:31 -0700

Rewrite FragmentTabHost to avoid creating content page Fragments again during navigation bar switching

Problem Description: In the previous article, we used onActivityCreated (...) for each fragment in the navigation bar. This method prints a toast and displays the toast dialog box when repeatedly switching pages. This means that each content page fragment is recreated when switching. It is expected that the first entry is created, and then the ...

Posted by Draicone on Tue, 09 Apr 2019 18:48:32 -0700

Piecewise Cluster of MongoDB

Brief introduction of fragmented cluster As mentioned before, the replication set of MongoDB is mainly used to achieve automatic failover to achieve high availability. However, with the growth of business scale and the passage of time, the volume of business data will become larger and larger. Current business data may be less than several hu ...

Posted by Monadoxin on Mon, 08 Apr 2019 21:48:30 -0700

spdlog source code reading (2): creation and use of sinks

2. sink creation 2.1 or rotating_file_sink We still take rotating_file_sink as an example to illustrate the process of sink creation in spdlog. The file_log.cpp file can be found in spdlog-master/tests. The example code for rotate is as follows: TEST_CASE("rotating_file_logger1", "[rotating_logger]]") { 1. prepare_logdir(); 2. std::stri ...

Posted by releasedj on Mon, 08 Apr 2019 18:36:30 -0700