Code Monkey home page Code Monkey logo

datasyncalgorithmsprototype's Introduction

Data Sync Algorithms Prototype

This is a practice run at a data synchronization subroutine. It started with a small .playground file, but the single page ballooned and got unmanageable. I also wanted breakpoints! So I decided to create a project so I can separate all the UI from the algorithms. I put this on GitHub because... why not?

What's Up?

  • The UI consists of 4 collection views in 4 columns
  • The top button wipes them and generates new data
  • The first column shows data that's current
  • The second column shows data that is fresh and is coming in
  • The third column shows that the data should look like after the fresh data has been incorporated into the first column (note that it's not a merge of 2 arrays, but a special incorporation)
  • The fourth column looks like the first column and will be the one that gets updated to look like the third column
  • Red cells represent data that's been created locally but not synced with the backend or whatever yet (so incoming data may or may not have received that data, so my algorithms have to figure out which ones get updated or not)
  • Also, red cells appear at the bottom after each incorporation so they don't get lost as more data flows in

Why?

  • This particular synchronization/update model is specialized for another project I'm working on
  • Data comes in at a fixed size
  • Only the latest data comes in per call
  • Data on the device is built from the little fixed sized packets of data that comes in over time
  • This exercise is a prototype to get all this logic working
  • It's practice to learn how batch updates work on UICollectionViews
  • And then it's just plain algorithm design practice to get efficient logic

datasyncalgorithmsprototype's People

Contributors

xavierliancw avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.