1

What is the maximum length allowed for identifier property in - initWithCenter:radius:identifier: method of CLCircularRegion class used for region monitoring?

- initWithCenter:radius:identifier: is returning nil when the identifier length exceeds a certain limit. So what is that limit?

halfer
  • 19,824
  • 17
  • 99
  • 186
PGDev
  • 23,751
  • 6
  • 34
  • 88
  • It seems like it would be pretty trivial to work it out - why don't you try? – Paulw11 Feb 19 '16 at 07:11
  • I tried..till 511 characters it is returning the object and after that it is returning nil. But there is no documentation for it. – PGDev Feb 19 '16 at 07:29
  • Right, so it seems the limit is 511 but as you say there is no documentation. That seems quite a lot for an identifier which would typically be 8 or so characters – Paulw11 Feb 19 '16 at 07:37

1 Answers1

0

The max length is 512.
If it is exceeded, I get in iOS 14 the log

[Client] {"msg":"identifier is too long"}  

A longer ID fires also a runtime breakpoint.

Reinhard Männer
  • 14,022
  • 5
  • 54
  • 116