mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
24 lines
698 B
Java
Vendored
24 lines
698 B
Java
Vendored
package test;
|
|
|
|
class ClassObject {
|
|
void accessToClassObject() {
|
|
WithClassObject.Companion.foo();
|
|
WithClassObject.Companion.getValue();
|
|
WithClassObject.Companion.getValueWithGetter();
|
|
WithClassObject.Companion.getVariable();
|
|
WithClassObject.Companion.setVariable(0);
|
|
WithClassObject.Companion.getVariableWithAccessors();
|
|
WithClassObject.Companion.setVariableWithAccessors(0);
|
|
}
|
|
|
|
void accessToPackageObject() {
|
|
PackageInner.INSTANCE.foo();
|
|
PackageInner.INSTANCE.getValue();
|
|
}
|
|
|
|
void accessToInnerClass() {
|
|
new WithClassObject.MyInner().foo();
|
|
new WithClassObject.MyInner().getValue();
|
|
}
|
|
}
|