I have the following Swift code from SciChat Tutorial07 on annotations. I am looking for functionally equivalent code in Objective C. Unfortunately i could not find any relevant examples. Could anyone from the SciChart community please help. Thanks!
let totalCapacity = 500.0
// annotation collection property, used to store all annotations
let annotationGroup = SCIAnnotationCollection()
if (i%100 == 0){
let customAnnotation = SCICustomAnnotation()
let customAnnotationContentView = UILabel(frame: CGRect.init(x: 0, y: 0, width: 10, height: 10))
customAnnotationContentView.text = "Y"
customAnnotationContentView.backgroundColor = UIColor.lightGray
customAnnotation.contentView = customAnnotationContentView
customAnnotation.x1 = SCIGeneric(i)
customAnnotation.y1 = SCIGeneric(0.5)
customAnnotation.coordinateMode = .relativeY
// adding new custom annotation into the annotationGroup property
annotationGroup.add(customAnnotation)
// removing annotations that are out of visible range
let customAn = annotationGroup.item(at: 0) as! SCICustomAnnotation
if(SCIGenericDouble(customAn.x1) < Double(i) - totalCapacity){
// since the contentView is UIView element - we have to call removeFromSuperView method to remove it from screen
customAn.contentView.removeFromSuperview()
annotationGroup.remove(customAn)
}