ব্যবসা এবং আগ্রহের অন্যান্য পয়েন্ট
সেভ করা পৃষ্ঠা গুছিয়ে রাখতে 'সংগ্রহ' ব্যবহার করুন
আপনার পছন্দ অনুযায়ী কন্টেন্ট সেভ করুন ও সঠিক বিভাগে রাখুন।
ডিফল্টরূপে, আগ্রহের পয়েন্টগুলি (POIs) তাদের সংশ্লিষ্ট আইকনগুলির সাথে বেস মানচিত্রে উপস্থিত হয়৷ POI-এর মধ্যে পার্ক, স্কুল, সরকারি ভবন এবং আরও অনেক কিছু রয়েছে। এছাড়াও, যখন মানচিত্রের ধরন kGMSTypeNormal
হয় তখন ব্যবসায়িক POI ডিফল্টরূপে মানচিত্রে উপস্থিত হয়। ব্যবসায়িক POIগুলি দোকান, রেস্তোরাঁ, হোটেল এবং আরও অনেক কিছুর মতো ব্যবসার প্রতিনিধিত্ব করে।
একটি POI একটি প্লেস আইডির সাথে মিলে যায়, যেমনটি iOS-এর জন্য Places SDK-এ সংজ্ঞায়িত করা হয়েছে। উদাহরণস্বরূপ, বিনোদনমূলক পার্কগুলি POI, কিন্তু জলের ফোয়ারাগুলির মতো জিনিসগুলি সাধারণত POI নয় (যদি না সেগুলি জাতীয় বা ঐতিহাসিক তাত্পর্যের হয়)।
POI-তে ক্লিক ইভেন্টের জন্য শোনা
আপনি যদি একটি POI-তে ট্যাপ করা ব্যবহারকারীর প্রতিক্রিয়া জানাতে চান, তাহলে GMSMapViewDelegate
প্রয়োগ করুন এবং mapView(_:didTapPOIWithPlaceID:name:location:)
পদ্ধতিটি প্রয়োগ করুন, যেমনটি নিম্নলিখিত উদাহরণে দেখানো হয়েছে:
সুইফট
import GoogleMaps
class POI: UIViewController, GMSMapViewDelegate {
override func loadView() {
let camera = GMSCameraPosition.camera(
withLatitude: 47.603,
longitude:-122.331,
zoom:14
)
let mapView = GMSMapView.map(withFrame: .zero, camera: camera)
mapView.delegate = self
self.view = mapView
}
func mapView(
_ mapView: GMSMapView,
didTapPOIWithPlaceID placeID: String,
name: String,
location: CLLocationCoordinate2D
) {
print("You tapped \(name): \(placeID), \(location.latitude)/\(location.longitude)")
}
}
উদ্দেশ্য-C
#import "POI.h"
@import GoogleMaps;
@interface POI () <GMSMapViewDelegate>
@end
@implementation POI
- (void)loadView {
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:47.603
longitude:-122.331
zoom:14];
GMSMapView *mapView = [GMSMapView mapWithFrame:CGRectZero camera:camera];
mapView.delegate = self;
self.view = mapView;
}
#pragma mark - GMSMapViewDelegate
- (void)mapView:(GMSMapView *)mapView
didTapPOIWithPlaceID:(NSString *)placeID
name:(NSString *)name
location:(CLLocationCoordinate2D)location {
NSLog(@"You tapped %@: %@, %f/%f", name, placeID, location.latitude, location.longitude);
}
@end
একটি তথ্য উইন্ডোতে বিস্তারিত দেখানো হচ্ছে
POI গুলি ডিফল্টরূপে মানচিত্রে প্রদর্শিত হয়, কিন্তু কোনো ডিফল্ট অন-ক্লিক UI নেই (ব্যবহারকারী যখন কোনো POI ট্যাপ করে তখন API স্বয়ংক্রিয়ভাবে কোনো তথ্য উইন্ডো বা অন্য কোনো ব্যবহারকারী ইন্টারফেস প্রদর্শন করে না)। নিম্নলিখিত উদাহরণ দেখায় কিভাবে একটি POI এর জন্য একটি তথ্য উইন্ডো প্রদর্শন করতে একটি মার্কার ব্যবহার করতে হয়:
সুইফট
// Declare GMSMarker instance at the class level.
let infoMarker = GMSMarker()
// Attach an info window to the POI using the GMSMarker.
func mapView(
_ mapView: GMSMapView,
didTapPOIWithPlaceID placeID: String,
name: String,
location: CLLocationCoordinate2D
) {
infoMarker.snippet = placeID
infoMarker.position = location
infoMarker.title = name
infoMarker.opacity = 0;
infoMarker.infoWindowAnchor.y = 1
infoMarker.map = mapView
mapView.selectedMarker = infoMarker
}
উদ্দেশ্য-C
// Declare a GMSMarker instance at the class level.
GMSMarker *infoMarker;
// Attach an info window to the POI using the GMSMarker.
- (void)mapView:(GMSMapView *)mapView
didTapPOIWithPlaceID:(NSString *)placeID
name:(NSString *)name
location:(CLLocationCoordinate2D)location {
infoMarker = [GMSMarker markerWithPosition:location];
infoMarker.snippet = placeID;
infoMarker.title = name;
infoMarker.opacity = 0;
CGPoint pos = infoMarker.infoWindowAnchor;
pos.y = 1;
infoMarker.infoWindowAnchor = pos;
infoMarker.map = mapView;
mapView.selectedMarker = infoMarker;
}
মানচিত্রে দেখানো থেকে POI বন্ধ করা হচ্ছে
আপনি সমস্ত POI বা POI-এর নির্দিষ্ট বিভাগে কাস্টম শৈলী প্রয়োগ করে POI লুকাতে পারেন।
নিম্নলিখিত JSON শৈলী ঘোষণা মানচিত্রে সমস্ত ব্যবসা POI লুকিয়ে রাখে:
[
{
"featureType": "poi.business",
"stylers": [
{ "visibility": "off" }
]
}
]
আরেকটি উদাহরণ হিসাবে, নিম্নলিখিত JSON POI-এর সমস্ত বিভাগের প্রদর্শনকে সরল করে:
[
{
"featureType": "poi",
"stylers": [
{ "visibility": "simplified" }
]
}
]
আরও বিশদ বিবরণের জন্য, স্টাইলিং সহ মানচিত্রের বৈশিষ্ট্যগুলি লুকানোর নির্দেশিকা দেখুন।
অন্য কিছু উল্লেখ না করা থাকলে, এই পৃষ্ঠার কন্টেন্ট Creative Commons Attribution 4.0 License-এর অধীনে এবং কোডের নমুনাগুলি Apache 2.0 License-এর অধীনে লাইসেন্স প্রাপ্ত। আরও জানতে, Google Developers সাইট নীতি দেখুন। Java হল Oracle এবং/অথবা তার অ্যাফিলিয়েট সংস্থার রেজিস্টার্ড ট্রেডমার্ক।
2025-08-29 UTC-তে শেষবার আপডেট করা হয়েছে।
[null,null,["2025-08-29 UTC-তে শেষবার আপডেট করা হয়েছে।"],[[["\u003cp\u003ePoints of interest (POIs) such as parks, schools, and businesses are displayed on the base map by default, with business POIs appearing only in the \u003ccode\u003ekGMSTypeNormal\u003c/code\u003e map type.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can listen for click events on POIs and respond to user taps by implementing the \u003ccode\u003eGMSMapViewDelegate\u003c/code\u003e and the \u003ccode\u003emapView(_:didTapPOIWithPlaceID:name:location:)\u003c/code\u003e method.\u003c/p\u003e\n"],["\u003cp\u003eWhile POIs are shown automatically, there is no default on-click UI; developers can display an info window by using a marker and attaching it to the POI.\u003c/p\u003e\n"],["\u003cp\u003eCustom styles can be applied to hide all or specific categories of POIs on the map, such as business POIs or simplifying the display of all POIs.\u003c/p\u003e\n"]]],[],null,["Select platform: [Android](/maps/documentation/android-sdk/poi \"View this page for the Android platform docs.\") [iOS](/maps/documentation/ios-sdk/poi \"View this page for the iOS platform docs.\") [JavaScript](/maps/documentation/javascript/examples/event-poi \"View this page for the JavaScript platform docs.\")\n\n\u003cbr /\u003e\n\nBy default, points of interest (POIs) appear on the base map along with their\ncorresponding icons. POIs include parks, schools, government buildings, and\nmore. In addition, *business* POIs appear by default on the map when the map\ntype is `kGMSTypeNormal`. Business POIs represent businesses such as shops,\nrestaurants, hotels, and more.\n\nA POI corresponds to a [Place ID](/maps/documentation/places/ios-sdk/place-id#id-overview),\nas defined in the Places SDK for iOS. For example, recreational parks are POIs,\nbut things like water fountains are generally not POIs (unless they're of\nnational or historic significance).\n\nListening for click events on POIs\n\nIf you want to respond to a user tapping on a POI, implement\n[`GMSMapViewDelegate`](/maps/documentation/ios-sdk/reference/objc/Protocols/GMSMapViewDelegate),\nand implement the\n[`mapView(_:didTapPOIWithPlaceID:name:location:)`](/maps/documentation/ios-sdk/reference/objc/Protocols/GMSMapViewDelegate#-mapview:didtappoiwithplaceid:name:location:)\nmethod, as shown in the following example:\n\n\nSwift \n\n```swift\nimport GoogleMaps\n\nclass POI: UIViewController, GMSMapViewDelegate {\n\n override func loadView() {\n let camera = GMSCameraPosition.camera(\n withLatitude: 47.603,\n longitude:-122.331,\n zoom:14\n )\n let mapView = GMSMapView.map(withFrame: .zero, camera: camera)\n mapView.delegate = self\n self.view = mapView\n }\n\n func mapView(\n _ mapView: GMSMapView,\n didTapPOIWithPlaceID placeID: String,\n name: String,\n location: CLLocationCoordinate2D\n ) {\n print(\"You tapped \\(name): \\(placeID), \\(location.latitude)/\\(location.longitude)\")\n }\n}\n \n```\n\nObjective-C \n\n```objective-c\n#import \"POI.h\"\n@import GoogleMaps;\n\n@interface POI () \u003cGMSMapViewDelegate\u003e\n\n@end\n\n@implementation POI\n\n- (void)loadView {\n GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:47.603\n longitude:-122.331\n zoom:14];\n GMSMapView *mapView = [GMSMapView mapWithFrame:CGRectZero camera:camera];\n mapView.delegate = self;\n self.view = mapView;\n}\n\n#pragma mark - GMSMapViewDelegate\n\n- (void)mapView:(GMSMapView *)mapView\n didTapPOIWithPlaceID:(NSString *)placeID\n name:(NSString *)name\n location:(CLLocationCoordinate2D)location {\n NSLog(@\"You tapped %@: %@, %f/%f\", name, placeID, location.latitude, location.longitude);\n}\n\n@end\n \n```\n\n\u003cbr /\u003e\n\nShowing details in an info window\n\nPOIs appear on the map by default, but there is no default on-click UI (the API\ndoes not automatically display an info window or any other user interface when\nthe user taps a POI). The following example shows how to use a marker to\ndisplay an info window for a POI:\n\n\nSwift \n\n```swift\n// Declare GMSMarker instance at the class level.\nlet infoMarker = GMSMarker()\n\n// Attach an info window to the POI using the GMSMarker.\nfunc mapView(\n _ mapView: GMSMapView,\n didTapPOIWithPlaceID placeID: String,\n name: String,\n location: CLLocationCoordinate2D\n) {\n infoMarker.snippet = placeID\n infoMarker.position = location\n infoMarker.title = name\n infoMarker.opacity = 0;\n infoMarker.infoWindowAnchor.y = 1\n infoMarker.map = mapView\n mapView.selectedMarker = infoMarker\n}\n \n```\n\nObjective-C \n\n```objective-c\n// Declare a GMSMarker instance at the class level.\nGMSMarker *infoMarker;\n\n// Attach an info window to the POI using the GMSMarker.\n- (void)mapView:(GMSMapView *)mapView\n didTapPOIWithPlaceID:(NSString *)placeID\n name:(NSString *)name\n location:(CLLocationCoordinate2D)location {\n infoMarker = [GMSMarker markerWithPosition:location];\n infoMarker.snippet = placeID;\n infoMarker.title = name;\n infoMarker.opacity = 0;\n CGPoint pos = infoMarker.infoWindowAnchor;\n pos.y = 1;\n infoMarker.infoWindowAnchor = pos;\n infoMarker.map = mapView;\n mapView.selectedMarker = infoMarker;\n}\n \n```\n\n\u003cbr /\u003e\n\nStopping POIs from showing on the map\n\nYou can hide POIs by applying custom styles to all POIs or\nto specific categories of POIs.\n\nThe following JSON style declaration hides all business POIs on the map: \n\n [\n {\n \"featureType\": \"poi.business\",\n \"stylers\": [\n { \"visibility\": \"off\" }\n ]\n }\n ]\n\nAs another example, the following JSON simplifies the display of all categories\nof POIs: \n\n [\n {\n \"featureType\": \"poi\",\n \"stylers\": [\n { \"visibility\": \"simplified\" }\n ]\n }\n ]\n\nFor more details, see the guide to [hiding map features with styling](/maps/documentation/ios-sdk/hiding-features)."]]