default -> companion: replace all mentions of default and default object

This commit is contained in:
Pavel V. Talanov
2015-03-16 14:56:06 +03:00
parent a0783757e8
commit 06916d98c6
1019 changed files with 2468 additions and 2469 deletions
@@ -3,7 +3,7 @@ package pack
class C(arg1: Int, arg2: Int = 0, arg3: Int = 0)
public class User {
default object {
companion object {
public fun main() {
val c1 = C(100, 100, 100)
val c2 = C(100, 100)
@@ -19,7 +19,7 @@ class C(val myArg1: Int) {
}
public class User {
default object {
companion object {
public fun main() {
val c1 = C(100, 100, 100)
val c2 = C(100, 100)
@@ -10,7 +10,7 @@ class C(arg1: Int, arg2: Int, arg3: Int) {
}
public class User {
default object {
companion object {
public fun main() {
val c1 = C(1, 2, 3)
val c2 = C(5, 6)
@@ -34,7 +34,7 @@ class CustomerBuilder {
}
public class User {
default object {
companion object {
public fun main() {
val customer = CustomerBuilder().WithFirstName("Homer").WithLastName("Simpson").Build()
System.out.println(customer.firstName)
@@ -21,7 +21,7 @@ public class Identifier<T> {
}
public class User {
default object {
companion object {
public fun main() {
val i1 = Identifier("name", false, true)
val i2 = Identifier("name", false)
@@ -21,7 +21,7 @@ public class Identifier {
}
public class User {
default object {
companion object {
public fun main() {
val i1 = Identifier("name", false, true)
val i2 = Identifier("name", false)
@@ -8,7 +8,7 @@ class C(private val arg1: Int, private val arg2: Int, private val arg3: Int) {
System.out.println(foo(1) + this.foo(2) + other.foo(3) + staticFoo(4) + C.staticFoo(5))
}
default object {
companion object {
private fun staticFoo(p: Int): Int {
return p
}
@@ -1,7 +1,7 @@
class A(nested: A.Nested = A.Nested(A.Nested.FIELD)) {
class Nested(p: Int) {
default object {
companion object {
public val FIELD: Int = 0
}
@@ -4,7 +4,7 @@ import A.Nested
class A(nested: Nested = Nested(Nested.FIELD)) {
class Nested(p: Int) {
default object {
companion object {
public val FIELD: Int = 0
}
@@ -6,7 +6,7 @@ import pack.A.Nested
class A(nested: Nested = Nested(Nested.FIELD)) {
class Nested(p: Int) {
default object {
companion object {
public val FIELD: Int = 0
}
@@ -6,7 +6,7 @@ import pack.A.*
class A(nested: Nested = Nested(Nested.FIELD)) {
class Nested(p: Int) {
default object {
companion object {
public val FIELD: Int = 0
}
@@ -1,7 +1,7 @@
open class Base(nested: Base.Nested) {
class Nested(p: Int) {
default object {
companion object {
public val FIELD: Int = 0
}
@@ -12,7 +12,7 @@ class C {
}
public class User {
default object {
companion object {
public fun main() {
val c1 = C(1, 2, 3)
val c2 = C(5, 6)
@@ -18,7 +18,7 @@ class C(arg1: Int, arg2: Int = 0, arg3: Int = 0) {
}
public class User {
default object {
companion object {
public fun main() {
val c1 = C(100, 100, 100)
val c2 = C(100, 100)
@@ -48,7 +48,7 @@ class Outer {
}
}
default object {
companion object {
fun foo() {
val nested1 = Nested1(1)
@@ -4,7 +4,7 @@ class C() {
System.out.println(staticField1 + C.staticField2)
}
default object {
companion object {
private val staticField1 = 0
private val staticField2 = 0
}
@@ -16,7 +16,7 @@ public class Test {
myName = foo(name)
}
default object {
companion object {
fun foo(n: String): String {
return ""
@@ -25,7 +25,7 @@ public class Test {
}
public class User {
default object {
companion object {
public fun main() {
val t = Test("name")
}