I have to pass a custom object to method, but the constraint is it accepts only String array, Is there any way to pass custom object to that method. Please note I cannot change the receiving method to accept the object.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Venkatesh,
Why not simply create one more class that extents from the base, and override the method to accept the custom objects!
Hope the class you are using is not final.