I was making a really simple test program which asks the user for a permission. Here is my code:
package com.extensions.simpleMath;
import com.google.appinventor.components.annotations.DesignerComponent;
import com.google.appinventor.components.annotations.SimpleObject;
import com.google.appinventor.components.annotations.SimpleFunction;
import com.google.appinventor.components.annotations.SimpleEvent;
import com.google.appinventor.components.annotations.SimpleProperty;
import com.google.appinventor.components.common.ComponentCategory;
import com.google.appinventor.components.runtime.AndroidNonvisibleComponent;
import com.google.appinventor.components.runtime.AndroidViewComponent;
import com.google.appinventor.components.runtime.ComponentContainer;
import com.google.appinventor.components.runtime.EventDispatcher;
@DesignerComponent(version = 1,
category = ComponentCategory.EXTENSION,
description = "",
nonVisible = true,
iconName = "")
@SimpleObject(external = true)
public class simpleMath extends AndroidNonvisibleComponent {
public simpleMath(ComponentContainer container) {
super(container.$form());
}
@UsesPermissions(permissionNames = "android.permission.SET_WALLPAPER")
}
The problem is that when I build it, it gives me this error:
Buildfile: C:\Users\Beep\Desktop\Appinventor\extension-template-master\build.xml
javac:
[javac] Compiling 1 source file to C:\Users\Beep\Desktop\Appinventor\extension-template-master\build\classes
[javac] warning: [options] bootstrap class path not set in conjunction with -source 1.7
[javac] C:\Users\Beep\Desktop\Appinventor\extension-template-master\src\com\extensions\simpleMath\simpleMath.java:34: error: illegal start of type
[javac] }
[javac] ^
[javac] C:\Users\Beep\Desktop\Appinventor\extension-template-master\src\com\extensions\simpleMath\simpleMath.java:34: error: reached end of file while parsing
[javac] }
[javac] ^
[javac] 2 errors
[javac] 1 warning
BUILD FAILED
C:\Users\Beep\Desktop\Appinventor\extension-template-master\build.xml:29: Compile failed; see the compiler error output for details.
Total time: 0 seconds
Why is this happening? Thanks.