Skip to content
This repository has been archived by the owner on Feb 28, 2022. It is now read-only.

Commit

Permalink
Update no-op version of Kolumbus
Browse files Browse the repository at this point in the history
  • Loading branch information
MGaetan89 committed May 8, 2016
1 parent 9e84254 commit 2cceb15
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
45 changes: 45 additions & 0 deletions kolumbus-no-op/src/main/kotlin/io/kolumbus/Architect.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
/*
* Copyright (C) 2016 MGaetan89
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package io.kolumbus

import android.widget.TextView
import io.realm.RealmList
import io.realm.RealmModel

open class Architect {
open fun displayAny(textView: TextView, value: Any) = Unit

open fun displayBoolean(textView: TextView, value: Boolean) = Unit

open fun displayColor(textView: TextView, value: String, color: Int) = Unit

open fun displayEmpty(textView: TextView) = Unit

open fun displayFloat(textView: TextView, value: Float) = Unit

open fun displayInt(textView: TextView, value: Int) = Unit

open fun displayNull(textView: TextView) = Unit

open fun <T : RealmModel> displayRealmList(textView: TextView, value: RealmList<T>, type: Class<out RealmModel>) = Unit

open fun <T : RealmModel> displayRealmModel(textView: TextView, value: T) = Unit

open fun displayString(textView: TextView, value: String) = Unit

open fun displayUrl(textView: TextView, value: String) = Unit
}
2 changes: 2 additions & 0 deletions kolumbus-no-op/src/main/kotlin/io/kolumbus/Kolumbus.kt
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,6 @@ object Kolumbus {
fun forgetAll() = Unit

fun navigate(context: Context) = Unit

fun withArchitect(architect: Architect) = this
}

0 comments on commit 2cceb15

Please sign in to comment.