[javac] /Users/XXXXXX/Documents/mai/appinventor/components/src/com/google/appinventor/components/runtime/Filet.java:46: error: constructor AndroidNonvisibleComponent in class AndroidNonvisibleComponent cannot be applied to given types;
[javac] public class Filet extends AndroidNonvisibleComponent implements Component {
[javac] ^
[javac] required: Form
[javac] found: no arguments
[javac] reason: actual and formal argument lists differ in length
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 1 error
[javac] 4 warnings
Sounds like a simple error which should be able get solved easily, but I can't handle it. Anyone got some ideas?
Thanks
[javac] /Users/kirikiri3/Documents/mai/appinventor/components/src/com/google/appinventor/components/runtime/Filet.java:46: error: constructor AndroidNonvisibleComponent in class AndroidNonvisibleComponent cannot be applied to given types;
[javac] public class Filet extends AndroidNonvisibleComponent implements Component{
[javac] ^
[javac] required: Form
[javac] found: no arguments
[javac] reason: actual and formal argument lists differ in length
[javac] /Users/kirikiri3/Documents/mai/appinventor/components/src/com/google/appinventor/components/runtime/Filet.java:49: error: call to super must be first statement in constructor
[javac] super(container.$form());
BUILD FAILED
/Users/kirikiri3/Documents/mai/appinventor/build.xml:36: The following error occurred while executing this line:
/Users/kirikiri3/Documents/mai/appinventor/components/build.xml:343: The following error occurred while executing this line:
/Users/kirikiri3/Documents/mai/appinventor/components/build.xml:230: Compile failed; see the compiler error output for details.
I can't exactly tell which lines these refer to, but I think these output lines are referred to the errors:
...
[depend] Looking for [Ljava.lang.Void;
Couldn't load Resource [Ljava/lang/Void;.class
...
...
[javac] java.lang.RuntimeException: Cannot convert Java type 'java.lang.Void[]' to Yail type
...
I guess it has something to do with the method of that component, which I defined like this:
@SimpleFunction(description = "Funktionsbeschreibung hier")
public void Filet2(Void... voids){
Socket socket;
File file = new File(Environment.getExternalStorageDirectory(), "bild.jpg");
byte[] bytes = new byte[(int) file.length()];
try {
socket = new Socket("192.168.178.32", 80);
BufferedInputStream bis = new BufferedInputStream(new FileInputStream(file));
BufferedOutputStream bos = new BufferedOutputStream(socket.getOutputStream());
bis.read(bytes, 0, bytes.length);
bos.write(bytes, 0, bytes.length);
bos.flush();
socket.close();
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} finally {
// bis.close();
// bos.close();
}
}
public void Filet2(Void... voids){