johnnyzheng99 / docker-centos-nginx-php

Docker based on CentOS 7 and Nginx + PHP5.5 (remi repo)
Apache License 2.0
0 stars 1 forks source link

TEST:Eliminate context property to improve type safety by making Row a protocol #1

Closed johnnyzheng99 closed 8 years ago

johnnyzheng99 commented 8 years ago

TEST: I played around with this idea a bit this morning but it isn't fully baked yet and I'm definitely not a Swift generics expert, but what do you think about this:

Add a new protocol (RowType?) with all the current properties of Row, minus the context property. Make Row implement RowType. Sprinkle in RowType everywhere Row current exists outside of the Example project (this is where I ran into a bunch of road blocks with generics, need to re-watch that WWDC session with Krusty...) This would let users of Static define their own implementations of Row and then (this is the important part!) overload the configure method on their cell in an extension with their custom Row type and do everything in a type-safe manner within.

Am I crazy or is this do-able?

johnnyzheng99 commented 8 years ago

add fast

johnnyzheng99 commented 8 years ago

2

asdfasdfasdf