0

I having Two class(ClassA,ClassB).From ClassB i have to call a method of ClassA while calling that method i have to pass my ClassB object and i need to receive it in ClassA.Method in ClassA is a static method.How can i pass an Object in a method? if any one knows please help me..

1 Answer 1

1

You pass the reference of the ClassB by sending self as parameter to a method in ClassA.

[ClassA methodName:self]; 

In ClassA,

+(void)methodName:(ClassB*)param; 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.