I installed the 1.5.2 Scala plugin in Android Studio 1.2.2. I have an existing (functioning) project coded in Java. I added a trivial class in Scala to replace an existing Java class just to try it out. The IDE seems to validate the Scala code but the reference to the class from the Java code is unresolved. I don't know why. I've successfully mixed the languages under SBT on the server side of this project.
The Java code referencing looks like this:
package net.from.apprise;
import java.util.*;
import java.io.Serializable;
import org.json.*;
class ItemRelation extends SharableRecord implements Serializable, JSONable {
public static final String TAG = "IR";
String listKey;
String description;
String barCode;
Purch purch;
snip...
Purch was changed from Purchase which is defined in Java and was resolving OK. The Scala code is:
package net.from.apprise
class Purch {
val whatever:Int = 1
}
Attempts to build yield: error: cannot find symbol class Purch
The Scala code for the Purch class lives in app/build/main/scala/net.from.apprise directory. Similarly, the Java source is in app/build/main/java/net.from.apprise. AS sees the Scala code, and issues errors if there are any. But no resolution between classes.
Do I need to do something special or am I overlooking something dumb? Configuration of AS? Naming convention?