walterf25 Expert Licensed User Longtime User Feb 15, 2020 #1 I have the following line in my header file of a library i'm trying to wrap: Code: Copy - (void)setChartData:(B4IArray *)xValues : (B4IArray *)yValues; But when i run the file through the B4Ih2xml jar I get the following error: Error parsing array type: B4IArray * parser._parsetype (java line: 763) java.lang.IllegalStateException: No match found at java.util.regex.Matcher.group(Unknown Source) at anywheresoftware.b4a.keywords.Regex$MatcherWrapper.Group(Regex.java:140) at b4j.example.parser._parsetype(parser.java:763) at b4j.example.parser._parsemethod(parser.java:537) at b4j.example.parser._parseline(parser.java:462) at b4j.example.parser._parseh(parser.java:307) at b4j.example.parser._parse(parser.java:213) at b4j.example.main._appstart(main.java:48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at anywheresoftware.b4a.BA.raiseEvent2(BA.java:93) at anywheresoftware.b4a.BA.raiseEvent(BA.java:84) at b4j.example.main.main(main.java:29) Click to expand... Why do I get this error, does the B4Ih2xml not recognize the B4IArray type? Any ideas? Thanks, Walter
I have the following line in my header file of a library i'm trying to wrap: Code: Copy - (void)setChartData:(B4IArray *)xValues : (B4IArray *)yValues; But when i run the file through the B4Ih2xml jar I get the following error: Error parsing array type: B4IArray * parser._parsetype (java line: 763) java.lang.IllegalStateException: No match found at java.util.regex.Matcher.group(Unknown Source) at anywheresoftware.b4a.keywords.Regex$MatcherWrapper.Group(Regex.java:140) at b4j.example.parser._parsetype(parser.java:763) at b4j.example.parser._parsemethod(parser.java:537) at b4j.example.parser._parseline(parser.java:462) at b4j.example.parser._parseh(parser.java:307) at b4j.example.parser._parse(parser.java:213) at b4j.example.main._appstart(main.java:48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at anywheresoftware.b4a.BA.raiseEvent2(BA.java:93) at anywheresoftware.b4a.BA.raiseEvent(BA.java:84) at b4j.example.main.main(main.java:29) Click to expand... Why do I get this error, does the B4Ih2xml not recognize the B4IArray type? Any ideas? Thanks, Walter
Erel B4X founder Staff member Licensed User Longtime User Feb 16, 2020 #2 You need to add the array type as a comment. Example: Code: Copy - (B4IArray */*byte,1*/)ReadBytes:(NSString *)Dir :(NSString *)FileName; - (B4INativeObject *)RunMethod:(NSString *)MethodName :(B4IArray */*NSObject,1*/)Params; Upvote 0
You need to add the array type as a comment. Example: Code: Copy - (B4IArray */*byte,1*/)ReadBytes:(NSString *)Dir :(NSString *)FileName; - (B4INativeObject *)RunMethod:(NSString *)MethodName :(B4IArray */*NSObject,1*/)Params;
walterf25 Expert Licensed User Longtime User Feb 17, 2020 #3 Erel said: You need to add the array type as a comment. Example: Code: Copy - (B4IArray */*byte,1*/)ReadBytes:(NSString *)Dir :(NSString *)FileName; - (B4INativeObject *)RunMethod:(NSString *)MethodName :(B4IArray */*NSObject,1*/)Params; Click to expand... What about if I change B4IArray to NSMutableArray * I've tried doing that and in B4I i see the NSMutableArray is changed to Object, but when I try calling the function i get an error saying something like No selector found. Any ideas? Walter Upvote 0
Erel said: You need to add the array type as a comment. Example: Code: Copy - (B4IArray */*byte,1*/)ReadBytes:(NSString *)Dir :(NSString *)FileName; - (B4INativeObject *)RunMethod:(NSString *)MethodName :(B4IArray */*NSObject,1*/)Params; Click to expand... What about if I change B4IArray to NSMutableArray * I've tried doing that and in B4I i see the NSMutableArray is changed to Object, but when I try calling the function i get an error saying something like No selector found. Any ideas? Walter
Erel B4X founder Staff member Licensed User Longtime User Feb 17, 2020 #4 walterf25 said: Any ideas? Click to expand... As I said, you need to add the array type as a comment. Upvote 0
walterf25 said: Any ideas? Click to expand... As I said, you need to add the array type as a comment.
walterf25 Expert Licensed User Longtime User Feb 17, 2020 #5 Erel said: As I said, you need to add the array type as a comment. Click to expand... Thanks is working now. Walter Upvote 0
Erel said: As I said, you need to add the array type as a comment. Click to expand... Thanks is working now. Walter