Soru & Cevap

Webservis ızlı yanıt veriyor ...

20.11.2014 - 02:31

Başlık biraz tuhaf gelmiş olabilir. Ancak bir ulaşım uygulaması için, web servisten araçların konumuun alıp haritada göstermeye çalışıyorum. Ancak haritada annotation'lar saniyede 10 15 defa hızla yanıp sönüyor. Bunun önüne nasıl geçebilirim?

[code]

- (MKAnnotationView *)mapView:(MKMapView *)map viewForAnnotation:(id <MKAnnotation>)annotation

{

    if ([annotation isKindOfClass:[MKUserLocation class]]) {

            //Don't trample the user location annotation (pulsing blue dot).

        return nil;

    }

    static NSString *AnnotationViewID = @"annotationViewID";

    WeatherAnnotationView *annotationView =

    (WeatherAnnotationView *)[self.mapView dequeueReusableAnnotationViewWithIdentifier:AnnotationViewID];

    if (annotationView == nil)

    {

        annotationView = [[WeatherAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:AnnotationViewID];

    }

    annotationView.annotation = annotation;

    return annotationView;

}

[/code]

4 Görüntülenme

1 Cevap

Sitedeki sorulara cevap verebilmek için giriş yapın ya da üye olun.

picture-3650-1421928561.jpg
anilsozeri
20.11.2014 - 05:17
Merhaba, Background perform selector ile thread yardimiyla web servise yapacaginiz istegi belirli zaman araliklarinda tetikletebilirsiniz. Iyi calismalar.