GetClassMethod looks up the method with the specified signature on class.
(class ClassID, name, signature string)
| 49 | |
| 50 | // GetClassMethod looks up the method with the specified signature on class. |
| 51 | func (c *Connection) GetClassMethod(class ClassID, name, signature string) (Method, error) { |
| 52 | methods, err := c.GetMethods(ReferenceTypeID(class)) |
| 53 | if err != nil { |
| 54 | return Method{}, err |
| 55 | } |
| 56 | method := methods.FindBySignature(name, signature) |
| 57 | if method == nil { |
| 58 | return Method{}, fmt.Errorf("Method '%s%s' not found", name, signature) |
| 59 | } |
| 60 | return *method, nil |
| 61 | } |
| 62 | |
| 63 | // WaitForClassPrepare blocks until a class with a name that matches the pattern |
| 64 | // is prepared, and then returns the thread that prepared the class. |
no test coverage detected