What type is a points vector in objective C
up vote
0
down vote
favorite
I have the following declaration for a function and I don't know what I am doing wrong with regards to the type declaration:
//function is defined in the OpenCVWrapper.mm file .....no errors
+ (NSArray *)analysePoints:(std::vector<cv::Point> )pointsVector{
.......
}
//error is in the OpenCVWrapper.h file
@interface OpenCVWrapper : NSObject
+ (NSArray *)analysePoints:(NSMutableArray *)mutableArray:(std::vector<cv::Point>)pointsArray;
//red marker under the std
@end
I am getting the error "expecting type" for the vector. What am I doing wrong here?
vector objective-c++
add a comment |
up vote
0
down vote
favorite
I have the following declaration for a function and I don't know what I am doing wrong with regards to the type declaration:
//function is defined in the OpenCVWrapper.mm file .....no errors
+ (NSArray *)analysePoints:(std::vector<cv::Point> )pointsVector{
.......
}
//error is in the OpenCVWrapper.h file
@interface OpenCVWrapper : NSObject
+ (NSArray *)analysePoints:(NSMutableArray *)mutableArray:(std::vector<cv::Point>)pointsArray;
//red marker under the std
@end
I am getting the error "expecting type" for the vector. What am I doing wrong here?
vector objective-c++
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space betweenmutableArray
and the:(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.
– user1118321
Nov 8 at 6:18
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have the following declaration for a function and I don't know what I am doing wrong with regards to the type declaration:
//function is defined in the OpenCVWrapper.mm file .....no errors
+ (NSArray *)analysePoints:(std::vector<cv::Point> )pointsVector{
.......
}
//error is in the OpenCVWrapper.h file
@interface OpenCVWrapper : NSObject
+ (NSArray *)analysePoints:(NSMutableArray *)mutableArray:(std::vector<cv::Point>)pointsArray;
//red marker under the std
@end
I am getting the error "expecting type" for the vector. What am I doing wrong here?
vector objective-c++
I have the following declaration for a function and I don't know what I am doing wrong with regards to the type declaration:
//function is defined in the OpenCVWrapper.mm file .....no errors
+ (NSArray *)analysePoints:(std::vector<cv::Point> )pointsVector{
.......
}
//error is in the OpenCVWrapper.h file
@interface OpenCVWrapper : NSObject
+ (NSArray *)analysePoints:(NSMutableArray *)mutableArray:(std::vector<cv::Point>)pointsArray;
//red marker under the std
@end
I am getting the error "expecting type" for the vector. What am I doing wrong here?
vector objective-c++
vector objective-c++
edited Nov 8 at 5:55
asked Nov 8 at 4:43
kangarooChris
203314
203314
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space betweenmutableArray
and the:(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.
– user1118321
Nov 8 at 6:18
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36
add a comment |
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space betweenmutableArray
and the:(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.
– user1118321
Nov 8 at 6:18
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space between
mutableArray
and the :(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.– user1118321
Nov 8 at 6:18
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space between
mutableArray
and the :(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.– user1118321
Nov 8 at 6:18
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
Actually, I found the solution through user11118321 input to look at the bigger picture. I am using this set up in a swift app that uses openCV through a bridging header. It is actually not possible to import or use a vector in swift.
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
Actually, I found the solution through user11118321 input to look at the bigger picture. I am using this set up in a swift app that uses openCV through a bridging header. It is actually not possible to import or use a vector in swift.
add a comment |
up vote
1
down vote
Actually, I found the solution through user11118321 input to look at the bigger picture. I am using this set up in a swift app that uses openCV through a bridging header. It is actually not possible to import or use a vector in swift.
add a comment |
up vote
1
down vote
up vote
1
down vote
Actually, I found the solution through user11118321 input to look at the bigger picture. I am using this set up in a swift app that uses openCV through a bridging header. It is actually not possible to import or use a vector in swift.
Actually, I found the solution through user11118321 input to look at the bigger picture. I am using this set up in a swift app that uses openCV through a bridging header. It is actually not possible to import or use a vector in swift.
answered Nov 8 at 6:52
kangarooChris
203314
203314
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53201664%2fwhat-type-is-a-points-vector-in-objective-c%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You haven't provided enough information for us to help you. Please copy and paste the exact wording of the message. Also, it would help if we knew which files you were importing into this source file (that is, which headers). Also, what is the name of your source file? Does it end in ".m" or ".mm", or something else?
– user1118321
Nov 8 at 5:33
just added information requested above. "Expected a type" is the error message.
– kangarooChris
Nov 8 at 5:57
sorry, just noticed that I deleted the NSMutableArray part to avoid confusion, but in the addition I did not delete it. So the first statement in .mm file is + (NSArray *)analysePoints:(NSMutableArray *)mutableArray : (std::vector<cv::Point> )pointsArray{....
– kangarooChris
Nov 8 at 5:59
By "exact wording of the message" I mean the entire message - the file name, the text it's complaining about and everything else. It makes a difference to helping you. Also, you haven't told us which headers you're including. Finally, the spacing between arguments in your header file is ambiguous to the compiler. There should be a space between
mutableArray
and the:(std::vector<cv::Point>)pointsArray
part. The compiler should warn you about that, though the warning may be masked by the error.– user1118321
Nov 8 at 6:18
can I ask a different question? What is the type of a vector? The compiler asks for a type and I seem to not provide the right type. The above is really all there is (no additional info about the error message) except that I am also including #import <Foundation/Foundation.h>. #import <UIKit/UIKit.h>. Thank you for your patience!
– kangarooChris
Nov 8 at 6:36